Creates a sort script.
Try it now
Test
RAM authorization
|
Action |
Access level |
Resource type |
Condition key |
Dependent action |
|
opensearch:WriteSortScript |
*App
|
None | None |
Request syntax
POST /v4/openapi/app-groups/{appGroupIdentity}/apps/{appVersionId}/sort-scripts HTTP/1.1
Path Parameters
|
Parameter |
Type |
Required |
Description |
Example |
| appGroupIdentity |
string |
Yes |
The name or ID of the application. |
search |
| appVersionId |
string |
Yes |
The ID of the report in the application. |
1234567 |
Request parameters
|
Parameter |
Type |
Required |
Description |
Example |
| body |
object |
No |
The request body. |
|
| scriptName |
string |
No |
The name of the script. |
rank_cava_20230606_v7 |
| type |
string |
No |
The type of the script. Only cava_script is supported. |
cava_script |
| scope |
string |
No |
The applicable scope of the script. |
second_rank |
| description |
string |
No |
Request parameters
| Name | Type | Required | Description |
| scriptParams | Map | Yes | The parameters of the script to register. |
scriptParams
| Name | Type | Required | Description |
| scriptName | String | Yes | The name of the script. |
| type | String | Yes | The type of the script. Only cava_script is supported. |
| scope | String | Yes | The applicable scope of the script. Only second_rank is supported. |
Response elements
|
Element |
Type |
Description |
Example |
|
object |
|||
| requestId |
string |
The unique ID of the request. |
ABCDEFGH |
| result |
object |
The returned result. |
|
| scriptName |
string |
The name of the script. |
rank_cava_20230606_v7 |
| type |
string |
The type of the script. |
cava_script |
| scope |
string |
The applicable scope of the script. |
second_rank |
Examples
Success response
JSON format
{
"requestId": "ABCDEFGH",
"result": {
"scriptName": "rank_cava_20230606_v7\n",
"type": "cava_script",
"scope": "second_rank"
}
}
Error codes
See Error Codes for a complete list.
Release notes
See Release Notes for a complete list.