Skip to content

Instantly share code, notes, and snippets.

@ldclakmal
Last active August 26, 2021 11:47
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ldclakmal/16ef1bc20024a78f04c3d0072ecd2026 to your computer and use it in GitHub Desktop.
Save ldclakmal/16ef1bc20024a78f04c3d0072ecd2026 to your computer and use it in GitHub Desktop.
import ballerina/http;
http:Client webAppClient = check new("https://localhost:9090",
auth = {
tokenUrl: "https://localhost:9443/oauth2/token",
clientId: "FlfJYKBD2c925h4lkycqNZlC2l4a",
clientSecret: "PJz0UhTJMrHOo68QQNpvnqAY_3Aa",
scopes: ["customer"],
clientConfig: {
secureSocket: {
cert: "/path/to/sts-public.crt"
}
}
},
secureSocket = {
cert: "/path/to/public.crt"
}
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment