ListWritingStyles
Retrieves the list of writing styles.
Try it now
You can run this API directly in OpenAPI Explorer, saving you the trouble of calculating signatures. After the call succeeds, OpenAPI Explorer can automatically generate SDK code examples.
Authorization information
The following table describes the authorization information of the API. You can use it in the Action element of a RAM permission policy statement to grant RAM users or RAM roles the permission to call this API. For more information, see the following:
-
Action: the specific permission point.
-
Access level: the access level of each operation. Valid values: Write, Read, or List.
-
Resource type: the resource types that support authorization in the operation. For more information, see the following:
- Required resource types are marked with a leading *.
- For operations that do not support resource-level authorization,
All resourcesis used.
-
Condition key: the condition keys defined by the cloud service itself.
-
Dependent action: the other permissions required to successfully perform the operation. The caller must have the permissions of the dependent actions at the same time for the operation to succeed.
| Action | Access level | Resource type | Condition key | Dependent action |
|---|---|---|---|---|
| aimiaobi:ListWritingStyles | list | *All resources * |
| None |
Request parameters
| Name | Type | Required | Description | Example value |
|---|---|---|---|---|
| WorkspaceId | string | Yes | llm-xxxxx | |
| Scene | string | Yes | Filters by writing scenario. Valid values:
| media |
| MaxResults | integer | No | The maximum number of results to return. | 100 |
| NextToken | string | No | Pagination token | next-page-token |
Response elements
| Name | Type | Description | Example value |
|---|---|---|---|
| object | Schema of Response | ||
| RequestId | string | Id of the request | 1813ceee-7fe5-41b4-87e5-982a4d18cca5 |
| TotalCount | integer | The total number of records. | 58 |
| MaxResults | integer | The maximum number of results returned. | 100 |
| NextToken | string | The next token. | next-page-token |
| Code | string | The error code. | successful |
| Message | string | The error message. | Data does not exist |
| Success | string | Indicates whether the request was successful. | true |
| Data | array<object> | The list of writing styles. | |
| data | object | The writing style object. | |
| StyleName | string | The name of the writing style. | Writing style name |
| StyleKey | string | The unique key of the writing style. | Unique key of the writing style |
| StyleDescription | string | The description of the writing style. | Writing style description |
| DistributeWriting | boolean | Indicates whether step-by-step writing is supported. | false |
| StyleImage | string | The image of the writing style. | Writing style image |
| Emoji | string | The small icon of the writing style (represented by a character symbol). | Small icon |
| TemplateDefine | WritingStyleTemplateDefine | The template definition of the writing style. | |
| DistributeStepTemplateDefine | WritingStyleTemplateDefine | The template definition for step-by-step writing. |
Examples
Success response
JSON format
{
"RequestId": "1813ceee-7fe5-41b4-87e5-982a4d18cca5",
"TotalCount": 58,
"MaxResults": 100,
"NextToken": "下一页token",
"Code": "successful",
"Message": "数据不存在",
"Success": true,
"Data": [
{
"StyleName": "文体名称",
"StyleKey": "文体唯一标识",
"StyleDescription": "文体描述",
"DistributeWriting": false,
"StyleImage": "文体图片\n\n",
"Emoji": "小图标",
"TemplateDefine": {
"Fields": [
{
"MinItemLength": 1000,
"Max": 2000,
"MinLength": 20,
"MaxLength": 2000,
"MaxItemLength": 4000,
"Name": "字段名称",
"BuildIn": true,
"Enums": [
{
"CascadingFields": [
"级联字段"
],
"Key": "枚举KEY",
"Name": "枚举名称"
}
],
"Min": 1,
"Required": false,
"MaxItem": 10,
"InitialValue": "初始值",
"CascadingFields": [
{
"MinItemLength": 1000,
"Max": 2000,
"MinLength": 20,
"MaxLength": 2000,
"MaxItemLength": 4000,
"Name": "字段名称",
"BuildIn": true,
"Enums": [
{
"CascadingFields": [
"级联字段"
],
"Key": "枚举KEY",
"Name": "枚举名称"
}
],
"Min": 1,
"Required": false,
"MaxItem": 10,
"InitialValue": "初始值",
"CascadingFields": [
{
"MinItemLength": 1000,
"Max": 2000,
"MinLength": 20,
"MaxLength": 2000,
"MaxItemLength": 4000,
"Name": "字段名称",
"BuildIn": true,
"Enums": [
{
"CascadingFields": [
"级联字段"
],
"Key": "枚举KEY",
"Name": "枚举名称"
}
],
"Min": 1,
"Required": false,
"MaxItem": 10,
"InitialValue": "初始值",
"CascadingFields": [],
"Style": {
"Placeholder": "清输入Prompt",
"Type": "media",
"ShowTime": true,
"Suffix": "后缀",
"Description": "输入框提示文案",
"Format": "yyyy-mm-dd"
},
"Key": "topic"
}
],
"Style": {
"Placeholder": "清输入Prompt",
"Type": "media",
"ShowTime": true,
"Suffix": "后缀",
"Description": "输入框提示文案",
"Format": "yyyy-mm-dd"
},
"Key": "topic"
}
],
"Style": {
"Placeholder": "清输入Prompt",
"Type": "media",
"ShowTime": true,
"Suffix": "后缀",
"Description": "输入框提示文案",
"Format": "yyyy-mm-dd"
},
"Key": "topic"
}
],
"Example": [
{
"Value": 123,
"Key": "topic"
}
]
},
"DistributeStepTemplateDefine": {
"Fields": [],
"Example": [
{
"Value": 123,
"Key": "topic"
}
]
}
}
]
}
Error codes
For more error codes, visit Error Center.