Interface FromOauthIdentityOptions
- All Superinterfaces:
software.amazon.jsii.JsiiSerializable
- All Known Implementing Classes:
FromOauthIdentityOptions.Jsii$Proxy
@Generated(value="jsii-pacmak/1.130.0 (build 048a5ee)",
date="2026-05-20T12:39:41.768Z")
@Stability(Stable)
public interface FromOauthIdentityOptions
extends software.amazon.jsii.JsiiSerializable
OAuth scopes (and optional custom parameters) when binding an
IOAuth2CredentialProvider to a gateway target.
Example:
Gateway gateway = Gateway.Builder.create(this, "MyGateway")
.gatewayName("my-gateway")
.build();
OAuth2CredentialProvider oauth = OAuth2CredentialProvider.usingGithub(this, "GhOAuth", GithubOAuth2CredentialProviderProps.builder()
.oAuth2CredentialProviderName("github-oauth")
.clientId("your-client-id")
.clientSecret(SecretValue.unsafePlainText("your-client-secret"))
.build());
gateway.addMcpServerTarget("Mcp", AddMcpServerTargetOptions.builder()
.gatewayTargetName("mcp-server")
.description("MCP with GitHub OAuth")
.endpoint("https://my-mcp-server.example.com")
.credentialProviderConfigurations(List.of(GatewayCredentialProvider.fromOauthIdentity(oauth, FromOauthIdentityOptions.builder()
.scopes(List.of("read:user"))
.build())))
.build());
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final classA builder forFromOauthIdentityOptionsstatic final classAn implementation forFromOauthIdentityOptions -
Method Summary
Modifier and TypeMethodDescriptionbuilder()Additional OAuth parameters for the provider.OAuth scopes the gateway should request for this target.Methods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Method Details
-
getScopes
OAuth scopes the gateway should request for this target. -
getCustomParameters
Additional OAuth parameters for the provider.Default: - none
-
builder
- Returns:
- a
FromOauthIdentityOptions.BuilderofFromOauthIdentityOptions
-