CfnChannelNamespaceProps Struct
Properties for defining a CfnChannelNamespace.
Example
ts
// The code below shows an example of how to instantiate this type.
// The values are placeholders you should change.
import { aws_appsync as appsync } from 'aws-cdk-lib';
const cfnChannelNamespaceProps: appsync.CfnChannelNamespaceProps = {
apiId: 'apiId',
name: 'name',
// the properties below are optional
codeHandlers: 'codeHandlers',
codeS3Location: 'codeS3Location',
handlerConfigs: {
onPublish: {
behavior: 'behavior',
integration: {
dataSourceName: 'dataSourceName',
// the properties below are optional
lambdaConfig: {
invokeType: 'invokeType',
},
},
},
onSubscribe: {
behavior: 'behavior',
integration: {
dataSourceName: 'dataSourceName',
// the properties below are optional
lambdaConfig: {
invokeType: 'invokeType',
},
},
},
},
publishAuthModes: [{
authType: 'authType',
}],
subscribeAuthModes: [{
authType: 'authType',
}],
tags: [{
key: 'key',
value: 'value',
}],
};
Properties
The `Api` ID.
codeHandlersoptionalstringcode_handlersoptionalstrcodeHandlersoptionalStringCodeHandlersoptionalstringCodeHandlersoptional*string#The event handler functions that run custom business logic to process published events and subscribe requests.
codeS3Locationoptionalstringcode_s3_locationoptionalstrcodeS3LocationoptionalStringCodeS3LocationoptionalstringCodeS3Locationoptional*string#The Amazon S3 endpoint where the code is located.
handlerConfigsoptionalIResolvable | CfnChannelNamespace.HandlerConfigsPropertyhandler_configsoptionaltyping.Union[IResolvable, HandlerConfigsProperty]handlerConfigsoptionalIResolvableHandlerConfigsoptionalIResolvableHandlerConfigsoptionalinterface{}#The configuration for the `OnPublish` and `OnSubscribe` handlers.
The name of the channel namespace.
This name must be unique within the Api .
publishAuthModesoptionalIResolvable | IResolvable | CfnChannelNamespace.AuthModeProperty[]publish_auth_modesoptionaltyping.Union[IResolvable, typing.List[typing.Union[IResolvable, AuthModeProperty]]]publishAuthModesoptionalIResolvablePublishAuthModesoptionalIResolvablePublishAuthModesoptionalinterface{}#The authorization mode to use for publishing messages on the channel namespace.
This configuration overrides the default Api authorization configuration.
subscribeAuthModesoptionalIResolvable | IResolvable | CfnChannelNamespace.AuthModeProperty[]subscribe_auth_modesoptionaltyping.Union[IResolvable, typing.List[typing.Union[IResolvable, AuthModeProperty]]]subscribeAuthModesoptionalIResolvableSubscribeAuthModesoptionalIResolvableSubscribeAuthModesoptionalinterface{}#The authorization mode to use for subscribing to messages on the channel namespace.
This configuration overrides the default Api authorization configuration.