テンプレートを照会します。複数のフィルター方法をサポートしています。
今すぐお試しください
テスト
RAM 認証
|
アクション |
アクセスレベル |
リソースタイプ |
条件キー |
依存アクション |
|
oos:ListTemplates |
get |
Template
Template
|
|
なし |
リクエストパラメーター
|
パラメーター |
型 |
必須 / 任意 |
説明 |
例 |
| RegionId |
string |
任意 |
リージョン ID。 |
cn-hangzhou |
| TemplateName |
string |
任意 |
テンプレート名。指定されたテンプレート名を含むすべてのテンプレートが返されます。 |
MyTemplate |
| TemplateFormat |
string |
任意 |
テンプレートのフォーマット。有効な値:
|
YAML |
| ShareType |
string |
任意 |
共有タイプ。有効な値:
|
Private |
| CreatedBy |
string |
任意 |
テンプレートの作成者。
|
ACS |
| CreatedDateBefore |
string |
任意 |
作成時間が指定された時間以前のテンプレートを絞り込みます。 フォーマット: YYYY-MM-DDThh:mm:ssZ |
2019-05-16T10:26:14Z |
| CreatedDateAfter |
string |
任意 |
作成時間が指定された時間以降のテンプレートを絞り込みます。 フォーマット: YYYY-MM-DDThh:mm:ssZ |
2019-05-16T10:26:14Z |
| Tags |
object |
任意 |
キーと値のペアのタグ。キーと値のペアの数は 1 から 20 の範囲です。 |
{"k1":"k2","k2":"v2"} |
| Category |
string |
任意 |
テンプレートのカテゴリ (TimerTrigger、EventTrigger、AlarmTrigger、Other など)。 |
TimerTrigger |
| MaxResults |
integer |
任意 |
ページサイズ。有効な値: 10 から 100。デフォルト値: 50。 |
50 |
| NextToken |
string |
任意 |
次のページの結果を取得するために使用されるトークン。さらに結果がある場合、この値は現在のページの応答から取得されます。 |
xxx |
| SortField |
string |
任意 |
クエリ結果のソートに使用するフィールド。有効な値:
|
Popularity |
| SortOrder |
string |
任意 |
ソート順序。有効な値:
|
Descending |
| HasTrigger |
boolean |
任意 |
テンプレートにトリガーが含まれるかどうかを指定します。 |
true |
| TemplateType |
string |
任意 |
テンプレートタイプ。有効な値:
列挙値:
|
Automation |
| ResourceGroupId |
string |
任意 |
リソースグループの ID。 |
rg-acfmxsn4m4****** |
| IsFavorite |
boolean |
任意 |
テンプレートがお気に入りに追加されているかどうかを指定します。 |
true |
| IsExample |
boolean |
任意 |
テンプレートがサンプルテンプレートであるかどうかを指定します。 |
true |
レスポンスフィールド
|
フィールド |
型 |
説明 |
例 |
|
object |
|||
| NextToken |
string |
次のページの結果を取得するために使用されるトークン。さらに結果がある場合、この値は現在のページの応答から取得されます。 |
xxx |
| RequestId |
string |
リクエスト ID。 |
BEF54BA-17B6-449F-A219-49ACB157E3 |
| MaxResults |
integer |
ページサイズ。 |
50 |
| Templates |
array<object> |
テンプレートのメタデータ。 |
|
|
array<object> |
|||
| Hash |
string |
テンプレートコンテンツの SHA-256 ハッシュ。 |
4bc7d7a21b3e003434b9c223f6e6d2578b5ebfeb5be28c1fcf8a8a1b11907bb4 |
| UpdatedDate |
string |
テンプレートが最後に更新された時間。 |
2019-05-16T10:26:14Z |
| UpdatedBy |
string |
テンプレートを最後に更新したユーザー。 |
root(13092000) |
| TemplateType |
string |
テンプレートタイプ。 |
非公開 |
| Tags |
object |
キーと値のペアのタグ。キーと値のペアの数は 1 から 20 の範囲です。 |
{"k1":"v1","k2":"v2"} |
| TemplateName |
string |
テンプレート名。 |
MyTemplate |
| TemplateVersion |
string |
テンプレートのバージョン。"v" に 1 から始まる数字が続くフォーマットです。 |
v1 |
| TemplateFormat |
string |
テンプレートのフォーマット。システムによってフォーマットが決定され、JSON または YAML となります。 |
JSON |
| Popularity |
integer |
公開テンプレートの人気度。値の範囲は 1 から 10 です。値が大きいほど人気度が高いことを示します。ShareType が Private の場合、このフィールドの値は 説明
このフィールドは ShareType が Public の場合にのみ有効です。 |
8 |
| TotalExecutionCount |
integer |
プライベートテンプレートの実行回数の合計。ShareType が Public の場合、このフィールドの値は 説明
このフィールドは ShareType が Private の場合にのみ有効です。 |
5 |
| Description |
string |
テンプレートの説明。 |
Describe instances of given status |
| ResourceGroupId |
string |
リソースグループの ID。 |
rg-acfmxsn4m4****** |
| CreatedBy |
string |
テンプレートの作成者。 |
root(1309200) |
| CreatedDate |
string |
テンプレートが作成された時間。 |
2019-05-16T10:26:14Z |
| Category |
string |
テンプレートタイプ。 |
TimerTrigger |
| HasTrigger |
boolean |
テンプレートが正常にトリガーされたかどうかを示します。 |
true |
| TemplateId |
string |
テンプレートの ID。 |
t-94753deed38 |
| ShareType |
string |
テンプレートの共有タイプ。ユーザーが作成したテンプレートの共有タイプは Private です。有効な値:
|
Public |
| IsFavorite |
boolean |
テンプレートがお気に入りに追加されているかどうかを指定します。 |
true |
| Publisher |
string |
パブリッシャー。 |
aliyun |
| Constraints |
string |
制約事項。 |
{ "InstanceTypeFamilies": ["ecs.g8y", "ecs.c8y"], "ImageTypes": ["system"], "OSPlatforms": ["CentOS", "Ubuntu"], "OSVersions": ["CentOS7.9 64bit"] } |
| VersionName |
string |
バージョン名。 |
3 |
例
成功レスポンス
JSONJSON
{
"NextToken": "xxx",
"RequestId": "BEF54BA-17B6-449F-A219-49ACB157E3",
"MaxResults": 50,
"Templates": [
{
"Hash": "4bc7d7a21b3e003434b9c223f6e6d2578b5ebfeb5be28c1fcf8a8a1b11907bb4",
"UpdatedDate": "2019-05-16T10:26:14Z",
"UpdatedBy": "root(13092000)",
"TemplateType": "非公開",
"Tags": {
"k1": "v1",
"k2": "v2"
},
"TemplateName": "MyTemplate",
"TemplateVersion": "v1",
"TemplateFormat": "JSON",
"Popularity": 8,
"TotalExecutionCount": 5,
"Description": "Describe instances of given status",
"ResourceGroupId": "rg-acfmxsn4m4******",
"CreatedBy": "root(1309200)",
"CreatedDate": "2019-05-16T10:26:14Z",
"Category": "TimerTrigger",
"HasTrigger": true,
"TemplateId": "t-94753deed38",
"ShareType": "Public",
"IsFavorite": true,
"Publisher": "aliyun",
"Constraints": "{\n \"InstanceTypeFamilies\": [\"ecs.g8y\", \"ecs.c8y\"],\n \"ImageTypes\": [\"system\"],\n \"OSPlatforms\": [\"CentOS\", \"Ubuntu\"],\n \"OSVersions\": [\"CentOS7.9 64bit\"]\n}",
"VersionName": "3"
}
]
}
エラーコード
完全なリストについては、「エラーコード」をご参照ください。
変更履歴
完全なリストについては、「変更履歴」をご参照ください。