O DATASOURCE::APIG::HttpApi recupera informações sobre uma API HTTP.
Sintaxe
{
"Type": "DATASOURCE::APIG::HttpApi",
"Properties": {
"HttpApiId": String,
"RefreshOptions": String
}
}
Propriedades
|
Propriedade |
Tipo |
Obrigatória |
Editável |
Descrição |
Restrição |
|
HttpApiId |
String |
Sim |
Sim |
ID da API. |
Nenhuma. |
|
RefreshOptions |
String |
Não |
Sim |
Política de atualização dos recursos da fonte de dados ao atualizar a pilha. |
Valores válidos:
|
Valores de retorno
Fn::GetAtt
HttpApiName: nome da API.
Type: tipo da API.
Protocols: protocolos da API.
Description: descrição da API.
ResourceGroupId: ID do grupo de recursos.
BasePath: caminho base da API.
HttpApiId: ID da API.
Exemplos
ROSTemplateFormatVersion: '2015-09-01'
Parameters:
HttpApiId:
Type: String
Description:
en: The ID of the API.
Required: true
Resources:
ExtensionDataSource:
Type: DATASOURCE::APIG::HttpApi
Properties:
HttpApiId:
Ref: HttpApiId
Outputs:
HttpApiName:
Description: The name of the API.
Value:
Fn::GetAtt:
- ExtensionDataSource
- HttpApiName
Type:
Description: The type of HTTP API.
Value:
Fn::GetAtt:
- ExtensionDataSource
- Type
Protocols:
Description: List of API Access Protocols.
Value:
Fn::GetAtt:
- ExtensionDataSource
- Protocols
Description:
Description: Description of API.
Value:
Fn::GetAtt:
- ExtensionDataSource
- Description
ResourceGroupId:
Description: The ID of the resource group.
Value:
Fn::GetAtt:
- ExtensionDataSource
- ResourceGroupId
BasePath:
Description: The base path of the API.
Value:
Fn::GetAtt:
- ExtensionDataSource
- BasePath
HttpApiId:
Description: The ID of the API.
Value:
Fn::GetAtt:
- ExtensionDataSource
- HttpApiId
{
"ROSTemplateFormatVersion": "2015-09-01",
"Parameters": {
"HttpApiId": {
"Type": "String",
"Description": {
"en": "The ID of the API."
},
"Required": true
}
},
"Resources": {
"ExtensionDataSource": {
"Type": "DATASOURCE::APIG::HttpApi",
"Properties": {
"HttpApiId": {
"Ref": "HttpApiId"
}
}
}
},
"Outputs": {
"HttpApiName": {
"Description": "The name of the API.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"HttpApiName"
]
}
},
"Type": {
"Description": "The type of HTTP API.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"Type"
]
}
},
"Protocols": {
"Description": "List of API Access Protocols.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"Protocols"
]
}
},
"Description": {
"Description": "Description of API.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"Description"
]
}
},
"ResourceGroupId": {
"Description": "The ID of the resource group.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"ResourceGroupId"
]
}
},
"BasePath": {
"Description": "The base path of the API.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"BasePath"
]
}
},
"HttpApiId": {
"Description": "The ID of the API.",
"Value": {
"Fn::GetAtt": [
"ExtensionDataSource",
"HttpApiId"
]
}
}
}
}