Creates a synonym in the specified workspace.
Try it now
You can run this API directly in OpenAPI Explorer, which saves you the trouble of calculating signatures. After the operation succeeds, OpenAPI Explorer can automatically generate SDK code examples.
Debug
RAM authorization
The following table describes the authorization information for this API. You can use the Action element in RAM permission policy statements to grant RAM users or RAM roles the permission to call this API. For more information, see the following:
- Operation: 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 for the operation. For more information:
- For required resource types, an asterisk (*) is prefixed.
- For operations that do not support resource-level authorization, All Resources is used.
- Condition key: the condition keys defined by the cloud service itself.
- Dependent action: other permissions required to successfully perform the operation. The caller must have the permissions of all dependent actions for the operation to succeed.
| Operation | Access level | Resource type | Condition key | Dependent action |
|---|---|---|---|---|
| dataanalysisgbi:CreateSynonyms | none | *All resources * |
| None |
Request syntax
Request parameters
| Parameter | Type | Required | Description | Example value |
|---|---|---|---|---|
| workspaceId | string | Yes | The ID of the Alibaba Cloud Model Studio workspace used for the request. | llm-2v3934xtp49esw64 |
| body | object | No | The request body. | |
| word | string | Yes | The synonym itself. | Capital |
| wordSynonyms | array | Yes | The list of words to map to the synonym. | |
| wordsSynonyms | string | No | The synonym to map. | Beijing |
| columns | array | No | To map the synonym to a specific column in a data table, specify the column name in the format: table_name.column_name. | |
| columns | string | No | table_name.column_name | table.id |
Response elements
| Element | Type | Description | Example value |
|---|---|---|---|
| object | Result | ||
| data | any | The returned data. | true |
| errorMsg | string | The error message. | NoAuth |
| code | string | The error code. | NoAuth |
| success | boolean | true: The call was successful. false: The call failed. | true |
| requestId | string | The request ID. Each request has a unique ID, which facilitates troubleshooting. | FB11F719-9AC8-5C99-AB0A-4709D437FCFC |
Examples
Success response
JSON format
Error codes
| HTTP status code | Error code | Error message | Description |
|---|---|---|---|
| 401 | Internal.Error | Bad Request: Internal Error. | Internal error. Contact customer service to troubleshoot the issue. |
| 401 | NoAuth | Bad Request: Workspace.Illegal.Auth. | The current account does not have permission on the specified business space. |
| 401 | NoResourceAuth | Bad Request: Resource Auth Error. | No permission on the requested resource. Make sure the requested resource belongs to the business space specified in the parameters. |