DATASOURCE::APIG::Routes is used to query routes.
Syntax
{
"Type": "DATASOURCE::APIG::Routes",
"Properties": {
"HttpApiId": String,
"RouteName": String,
"RefreshOptions": String
}
}Properties
Property | Type | Required | Editable | Description | Constraint |
HttpApiId | String | Yes | Yes | The ID of the HTTP API. | None. |
RouteName | String | No | Yes | The name of the route. | None. |
RefreshOptions | String | No | Yes | The refresh policy for data source resources when the stack is updated. | Valid values:
|
Return values
Fn::GetAtt
RouteIds: the IDs of the routes.
Routes: details of the routes.
Property | Type | Description | Constraint |
RouteIds | List | The IDs of the routes. | None. |
Routes | List | Details of the routes. | None. |
Description | String | The description of the route. | None. |
RouteId | String | The ID of the route. | None. |
RouteName | String | The name of the route. | None. |
DomainInfos | String | The domain name information. | For more information, see DomainInfo. |
EnvironmentInfo | String | The environment information. | For more information, see EnvironmentInfo. |
Match | String | The matching rule for the route resource. | None. |
Backend | String | The backend service. | For more information, see Backend. |
Examples
ROSTemplateFormatVersion: '2015-09-01'
Parameters:
HttpApiId:
Type: String
Description:
en: HTTP API ID.
Required: true
Resources:
ExtensionDataSource:
Type: DATASOURCE::APIG::Routes
Properties:
HttpApiId:
Ref: HttpApiId
Outputs:
RouteIds:
Description: The list of route IDs.
Value:
Fn::GetAtt:
- ExtensionDataSource
- RouteIds
Routes:
Description: The list of routes.
Value:
Fn::GetAtt:
- ExtensionDataSource
- Routes
{
"ROSTemplateFormatVersion": "2015-09-01",
"Parameters": {
"HttpApiId": {
"Type": "String",
"Description": {
"en": "HTTP API ID."
},
"Required": true
}
},
"Resources": {
"ExtensionDataSource": {
"Type": "DATASOURCE::APIG::Routes",
"Properties": {
"HttpApiId": {
"Ref": "HttpApiId"
}
}
}
},
"Outputs": {
"RouteIds": {
"Description": "The list of route IDs.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"RouteIds"
]
}
},
"Routes": {
"Description": "The list of routes.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"Routes"
]
}
}
}
}