@Generated(value="jsii-pacmak/1.67.0 (build 2c027f5)", date="2022-09-19T20:26:37.697Z") @Stability(value=Stable) public interface UserPoolResourceServerOptions extends software.amazon.jsii.JsiiSerializable
Example:
UserPool pool = new UserPool(this, "Pool");
ResourceServerScope readOnlyScope = ResourceServerScope.Builder.create().scopeName("read").scopeDescription("Read-only access").build();
ResourceServerScope fullAccessScope = ResourceServerScope.Builder.create().scopeName("*").scopeDescription("Full access").build();
UserPoolResourceServer userServer = pool.addResourceServer("ResourceServer", UserPoolResourceServerOptions.builder()
.identifier("users")
.scopes(List.of(readOnlyScope, fullAccessScope))
.build());
UserPoolClient readOnlyClient = pool.addClient("read-only-client", UserPoolClientOptions.builder()
// ...
.oAuth(OAuthSettings.builder()
// ...
.scopes(List.of(OAuthScope.resourceServer(userServer, readOnlyScope)))
.build())
.build());
UserPoolClient fullAccessClient = pool.addClient("full-access-client", UserPoolClientOptions.builder()
// ...
.oAuth(OAuthSettings.builder()
// ...
.scopes(List.of(OAuthScope.resourceServer(userServer, fullAccessScope)))
.build())
.build());
| Modifier and Type | Interface and Description |
|---|---|
static class |
UserPoolResourceServerOptions.Builder
A builder for
UserPoolResourceServerOptions |
static class |
UserPoolResourceServerOptions.Jsii$Proxy
An implementation for
UserPoolResourceServerOptions |
| Modifier and Type | Method and Description |
|---|---|
static UserPoolResourceServerOptions.Builder |
builder() |
String |
getIdentifier()
A unique resource server identifier for the resource server.
|
default List<ResourceServerScope> |
getScopes()
Oauth scopes.
|
default String |
getUserPoolResourceServerName()
A friendly name for the resource server.
|
@Stability(value=Stable) @NotNull String getIdentifier()
@Stability(value=Stable) @Nullable default List<ResourceServerScope> getScopes()
Default: - No scopes will be added
@Stability(value=Stable) @Nullable default String getUserPoolResourceServerName()
Default: - same as `identifier`
@Stability(value=Stable) static UserPoolResourceServerOptions.Builder builder()
Copyright © 2022. All rights reserved.