@Generated(value="jsii-pacmak/1.67.0 (build 2c027f5)", date="2022-09-19T20:26:36.170Z") @Stability(value=Stable) public class IdentitySource extends software.amazon.jsii.JsiiObject
The source can be specified either as a literal value (e.g: Auth) which
cannot be blank, or as an unresolved string token.
Example:
Function authFn;
Resource books;
RequestAuthorizer auth = RequestAuthorizer.Builder.create(this, "booksAuthorizer")
.handler(authFn)
.identitySources(List.of(IdentitySource.header("Authorization")))
.build();
books.addMethod("GET", new HttpIntegration("http://amazon.com"), MethodOptions.builder()
.authorizer(auth)
.build());
| Modifier | Constructor and Description |
|---|---|
|
IdentitySource() |
protected |
IdentitySource(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) |
protected |
IdentitySource(software.amazon.jsii.JsiiObjectRef objRef) |
| Modifier and Type | Method and Description |
|---|---|
static String |
context(String context)
Provides a properly formatted request context identity source.
|
static String |
header(String headerName)
Provides a properly formatted header identity source.
|
static String |
queryString(String queryString)
Provides a properly formatted query string identity source.
|
static String |
stageVariable(String stageVariable)
Provides a properly formatted API Gateway stage variable identity source.
|
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetprotected IdentitySource(software.amazon.jsii.JsiiObjectRef objRef)
protected IdentitySource(software.amazon.jsii.JsiiObject.InitializationMode initializationMode)
@Stability(value=Stable) public IdentitySource()
@Stability(value=Stable) @NotNull public static String context(@NotNull String context)
context - the name of the context variable the `IdentitySource` will represent. This parameter is required.@Stability(value=Stable) @NotNull public static String header(@NotNull String headerName)
headerName - the name of the header the `IdentitySource` will represent. This parameter is required.@Stability(value=Stable) @NotNull public static String queryString(@NotNull String queryString)
queryString - the name of the query string the `IdentitySource` will represent. This parameter is required.@Stability(value=Stable) @NotNull public static String stageVariable(@NotNull String stageVariable)
stageVariable - the name of the stage variable the `IdentitySource` will represent. This parameter is required.Copyright © 2022. All rights reserved.