All Products
Search
Document Center

Resource Orchestration Service:ALIYUN::ApiGateway::LogConfig

Last Updated:May 16, 2023

ALIYUN::ApiGateway::LogConfig is used to create a log configuration.

Syntax

{
  "Type": "ALIYUN::ApiGateway::LogConfig",
  "Properties": {
    "SlsLogStore": String,
    "SlsProject": String
  }
}

Properties

Property

Type

Required

Editable

Description

Constraint

SlsProject

String

Yes

Yes

The name of the log project.

None.

SlsLogStore

String

Yes

Yes

The name of the Logstore in the log project.

None.

Return values

Fn::GetAtt

  • SlsProject: the name of the log project.

  • SlsLogStore: the name of the Logstore in the log project.

Examples

YAML format

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  SlsLogStore:
    Type: String
    Description: Logstore name of SLS
    MinLength: 3
    MaxLength: 63
  SlsProject:
    Type: String
    Description: Project name of SLS
    MinLength: 3
    MaxLength: 63
Resources:
  LogConfig:
    Type: ALIYUN::ApiGateway::LogConfig
    Properties:
      SlsLogStore:
        Ref: SlsLogStore
      SlsProject:
        Ref: SlsProject
Outputs:
  SlsLogStore:
    Description: Logstore name of SLS
    Value:
      Fn::GetAtt:
        - LogConfig
        - SlsLogStore
  SlsProject:
    Description: Project name of SLS
    Value:
      Fn::GetAtt:
        - LogConfig
        - SlsProject

JSON format

{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "SlsLogStore": {
      "Type": "String",
      "Description": "Logstore name of SLS",
      "MinLength": 3,
      "MaxLength": 63
    },
    "SlsProject": {
      "Type": "String",
      "Description": "Project name of SLS",
      "MinLength": 3,
      "MaxLength": 63
    }
  },
  "Resources": {
    "LogConfig": {
      "Type": "ALIYUN::ApiGateway::LogConfig",
      "Properties": {
        "SlsLogStore": {
          "Ref": "SlsLogStore"
        },
        "SlsProject": {
          "Ref": "SlsProject"
        }
      }
    }
  },
  "Outputs": {
    "SlsLogStore": {
      "Description": "Logstore name of SLS",
      "Value": {
        "Fn::GetAtt": [
          "LogConfig",
          "SlsLogStore"
        ]
      }
    },
    "SlsProject": {
      "Description": "Project name of SLS",
      "Value": {
        "Fn::GetAtt": [
          "LogConfig",
          "SlsProject"
        ]
      }
    }
  }
}