All Products
Search
Document Center

Resource Orchestration Service:ALIYUN::MOBI::App

Last Updated:Jan 15, 2025

ALIYUN::MOBI::App is used to create an application.

Syntax

{
  "Type": "ALIYUN::MOBI::App",
  "Properties": {
    "AppIcon": String,
    "AppWorkspaceId": String,
    "AppName": String,
    "Template": Map,
    "AppDescription": String,
    "AppType": String
  }
}

Properties

Property

Type

Required

Editable

Description

Constraint

AppIcon

String

Yes

Yes

The number of the application icon.

By default, the system provides an icon in the form of a number. Default value: -1.

AppWorkspaceId

String

Yes

No

The ID of the workspace.

An application belongs to a workspace.

AppName

String

Yes

Yes

The name of the application.

None.

Template

Map

Yes

No

The template of the application.

For more information, see the "Template properties" section of this topic.

AppDescription

String

No

Yes

The description of the application.

None.

AppType

String

No

No

The type of the application.

Valid values:

  • Web

  • Copilot

Template syntax

"Template": {
  "ActualParameters": String,
  "ConnectionsContent": String,
  "TemplateId": String
}

Template properties

Property

Type

Required

Editable

Description

Constraint

ConnectionsContent

String

Yes

No

The connector configurations.

When you create an application, the application must depend on connectors to integrate external systems and services.

TemplateId

String

Yes

No

The template ID of the application.

For the template details, you can go to the template marketplace module in the service console to view all templates.

ActualParameters

String

No

No

The actual parameters.

None.

Return values

Fn::GetAtt

  • AppDescription: the description of the application.

  • ModifiedTime: the modification time of the application.

  • AppId: the ID of the application.

  • CreateTime: the creation time of the application.

  • AppIcon: the number of the application icon. By default, the system provides an icon in the form of a number. Default value: -1.

  • AppWorkspaceId: the ID of the workspace. An application belongs to a workspace.

  • AppType: the type of the application. Web applications and Copilot applications are supported.

  • AppName: the name of the application.

Examples

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  AppDescription:
    Type: String
    Description:
      en: Description of application.
    Required: false
    Default: demo72973
  AppIcon:
    Type: String
    Description:
      en: Application icon label, The system provides an icon by default, which is given in the form of a label. The default value is -1.
    Required: true
    Default: '-1'
  AppWorkspaceId:
    Type: String
    Description:
      en: Workspace ID of application, The application belongs to the workspace.
    Required: true
  AppType:
    Type: String
    Description:
      en: |-
        The application type. Web applications and Copilot applications are supported.
        - **Web**:Web application.
        - **Copilot**:Copilot application.
    AllowedValues:
      - Web
      - Copilot
    Required: false
  AppName:
    Type: String
    Description:
      en: The application name.
    Required: true
    Default: test123
Resources:
  ExtensionResource:
    Type: ALIYUN::MOBI::App
    Properties:
      AppDescription:
        Ref: AppDescription
      AppIcon:
        Ref: AppIcon
      AppWorkspaceId:
        Ref: AppWorkspaceId
      AppType:
        Ref: AppType
      AppName:
        Ref: AppName
      Template:
        ConnectionsContent:
          - name: '273971'
            description: ''
            connectorType:
              kind: mysql
              name: mysql
            folderId: /
            resourceObject:
              version: '1.0'
              id: a3908e03-0c28-4040-8d1c-xxxx
              name: Enterprise Official Template_20241120112036
              description: ''
              type: sql
              subType: mysql
              connectionTemplates:
                dev:
                  host: 192.168.1.1
                  port: 3306
                  database: admin
                  username: root
                  password: password
                production:
                  host: 192.168.1.1
                  port: 3306
                  database: admin
                  username: root
                  password: password
            resourceRequirementId: a3908e03-0c28-4040-8d1c-xxxxx
        TemplateId: 8bd986cc-8e58-42d4-9cc6-xxxxx
Outputs:
  AppDescription:
    Description: Description of application.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - AppDescription
  ModifiedTime:
    Description: Modified time of application.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - ModifiedTime
  AppId:
    Description: Application ID.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - AppId
  CreateTime:
    Description: Create time of application.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - CreateTime
  AppIcon:
    Description: Application icon label, The system provides an icon by default, which is given in the form of a label. The default value is -1.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - AppIcon
  AppWorkspaceId:
    Description: Workspace ID of application, The application belongs to the workspace.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - AppWorkspaceId
  AppType:
    Description: The application type. Web applications and Copilot applications are supported.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - AppType
  AppName:
    Description: The application name.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - AppName
{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "AppDescription": {
      "Type": "String",
      "Description": {
        "en": "Description of application."
      },
      "Required": false,
      "Default": "demo72973"
    },
    "AppIcon": {
      "Type": "String",
      "Description": {
        "en": "Application icon label, The system provides an icon by default, which is given in the form of a label. The default value is -1."
      },
      "Required": true,
      "Default": "-1"
    },
    "AppWorkspaceId": {
      "Type": "String",
      "Description": {
        "en": "Workspace ID of application, The application belongs to the workspace."
      },
      "Required": true
    },
    "AppType": {
      "Type": "String",
      "Description": {
        "en": "The application type. Web applications and Copilot applications are supported.\n- **Web**:Web application.\n- **Copilot**:Copilot application."
      },
      "AllowedValues": [
        "Web",
        "Copilot"
      ],
      "Required": false
    },
    "AppName": {
      "Type": "String",
      "Description": {
        "en": "The application name."
      },
      "Required": true,
      "Default": "test123"
    }
  },
  "Resources": {
    "ExtensionResource": {
      "Type": "ALIYUN::MOBI::App",
      "Properties": {
        "AppDescription": {
          "Ref": "AppDescription"
        },
        "AppIcon": {
          "Ref": "AppIcon"
        },
        "AppWorkspaceId": {
          "Ref": "AppWorkspaceId"
        },
        "AppType": {
          "Ref": "AppType"
        },
        "AppName": {
          "Ref": "AppName"
        },
        "Template": {
          "ConnectionsContent": [
            {
              "name": "273971",
              "description": "",
              "connectorType": {
                "kind": "mysql",
                "name": "mysql"
              },
              "folderId": "/",
              "resourceObject": {
                "version": "1.0",
                "id": "a3908e03-0c28-4040-8d1c-xxxx",
                "name": "Enterprise Official Template_20241120112036",
                "description": "",
                "type": "sql",
                "subType": "mysql",
                "connectionTemplates": {
                  "dev": {
                    "host": "192.168.1.1",
                    "port": 3306,
                    "database": "admin",
                    "username": "root",
                    "password": "password"
                  },
                  "production": {
                    "host": "192.168.1.1",
                    "port": 3306,
                    "database": "admin",
                    "username": "root",
                    "password": "password"
                  }
                }
              },
              "resourceRequirementId": "a3908e03-0c28-4040-8d1c-xxxxx"
            }
          ],
          "TemplateId": "8bd986cc-8e58-42d4-9cc6-xxxxx"
        }
      }
    }
  },
  "Outputs": {
    "AppDescription": {
      "Description": "Description of application.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "AppDescription"
        ]
      }
    },
    "ModifiedTime": {
      "Description": "Modified time of application.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "ModifiedTime"
        ]
      }
    },
    "AppId": {
      "Description": "Application ID.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "AppId"
        ]
      }
    },
    "CreateTime": {
      "Description": "Create time of application.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "CreateTime"
        ]
      }
    },
    "AppIcon": {
      "Description": "Application icon label, The system provides an icon by default, which is given in the form of a label. The default value is -1.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "AppIcon"
        ]
      }
    },
    "AppWorkspaceId": {
      "Description": "Workspace ID of application, The application belongs to the workspace.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "AppWorkspaceId"
        ]
      }
    },
    "AppType": {
      "Description": "The application type. Web applications and Copilot applications are supported.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "AppType"
        ]
      }
    },
    "AppName": {
      "Description": "The application name.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "AppName"
        ]
      }
    }
  }
}