interface ChannelNamespaceProps
| Language | Type name |
|---|---|
.NET | Amazon.CDK.AWS.AppSync.ChannelNamespaceProps |
Go | github.com/aws/aws-cdk-go/awscdk/v2/awsappsync#ChannelNamespaceProps |
Java | software.amazon.awscdk.services.appsync.ChannelNamespaceProps |
Python | aws_cdk.aws_appsync.ChannelNamespaceProps |
TypeScript (source) | aws-cdk-lib » aws_appsync » ChannelNamespaceProps |
Additional property for an AppSync channel namespace for an Event API reference.
Example
declare const api: appsync.EventApi;
new appsync.ChannelNamespace(this, 'Namespace', {
api,
authorizationConfig: {
// Override publishing authorization to API Key
publishAuthModeTypes: [appsync.AppSyncAuthorizationType.API_KEY],
// Override subscribing authorization to Lambda
subscribeAuthModeTypes: [appsync.AppSyncAuthorizationType.LAMBDA],
},
});
Properties
| Name | Type | Description |
|---|---|---|
| api | IEvent | The API this channel namespace is associated with. |
| authorization | Namespace | Authorization config for channel namespace. |
| channel | string | the name of the channel namespace. |
| code? | Code | The Event Handler code. |
| publish | Handler | onPublish handler config. |
| subscribe | Handler | onSubscribe handler config. |
api
Type:
IEvent
The API this channel namespace is associated with.
authorizationConfig?
Type:
Namespace
(optional, default: defaults to Event API default auth config)
Authorization config for channel namespace.
channelNamespaceName?
Type:
string
(optional, default: the construct's id will be used)
the name of the channel namespace.
code?
Type:
Code
(optional, default: no code is used)
The Event Handler code.
publishHandlerConfig?
Type:
Handler
(optional, default: no handler config)
onPublish handler config.
subscribeHandlerConfig?
Type:
Handler
(optional, default: no handler config)
onSubscribe handler config.

.NET
Go
Java
Python
TypeScript (