Show / Hide Table of Contents

Class ResourceServerScopeProps

Props to initialize ResourceServerScope.

Inheritance
System.Object
ResourceServerScopeProps
Implements
IResourceServerScopeProps
Namespace: Amazon.CDK.AWS.Cognito
Assembly: Amazon.CDK.AWS.Cognito.dll
Syntax (csharp)
public class ResourceServerScopeProps : Object, IResourceServerScopeProps
Syntax (vb)
Public Class ResourceServerScopeProps
    Inherits Object
    Implements IResourceServerScopeProps
Remarks

ExampleMetadata: infused

Examples
var pool = new UserPool(this, "Pool");

var readOnlyScope = new ResourceServerScope(new ResourceServerScopeProps { ScopeName = "read", ScopeDescription = "Read-only access" });
var fullAccessScope = new ResourceServerScope(new ResourceServerScopeProps { ScopeName = "*", ScopeDescription = "Full access" });

var userServer = pool.AddResourceServer("ResourceServer", new UserPoolResourceServerOptions {
    Identifier = "users",
    Scopes = new [] { readOnlyScope, fullAccessScope }
});

var readOnlyClient = pool.AddClient("read-only-client", new UserPoolClientOptions {
    // ...
    OAuth = new OAuthSettings {
        // ...
        Scopes = new [] { OAuthScope.ResourceServer(userServer, readOnlyScope) }
    }
});

var fullAccessClient = pool.AddClient("full-access-client", new UserPoolClientOptions {
    // ...
    OAuth = new OAuthSettings {
        // ...
        Scopes = new [] { OAuthScope.ResourceServer(userServer, fullAccessScope) }
    }
});

Synopsis

Constructors

ResourceServerScopeProps()

Properties

ScopeDescription

A description of the scope.

ScopeName

The name of the scope.

Constructors

ResourceServerScopeProps()

public ResourceServerScopeProps()

Properties

ScopeDescription

A description of the scope.

public string ScopeDescription { get; set; }
Property Value

System.String

ScopeName

The name of the scope.

public string ScopeName { get; set; }
Property Value

System.String

Implements

IResourceServerScopeProps
Back to top Generated by DocFX