Add the create index request
Contributors
POST /persistence/v1/service/{serviceName}/collection/{collectionName}/index
Adds the create index request that will be used to create the index. The POST index execute API call creates the indexes that have been scheduled by using this API call.
Parameters
Name | Type | In | Required | Description |
---|---|---|---|---|
serviceName |
string |
path |
True |
Participating external service name (name of the database). |
collectionName |
string |
path |
True |
Persistence service collection name (name of the table). |
X-Service-Request-Id |
string |
header |
False |
Request identifier used to tag the request for better supportability. |
Request Body
Name | Type | Required | Description |
---|---|---|---|
index |
False |
Response
Status: 200, Success response.
Name | Type | Required | Description |
---|---|---|---|
documentId |
string |
False |
Response
Status: 4xx, Default response
Name | Type | Required | Description |
---|---|---|---|
errorCode |
string |
False |
Error code |
error |
string |
False |
Error category |
message |
string |
False |
Error description message |
Example response
{
"errorCode": "P1002",
"error": "api error",
"message": "No document found of the specified documentId"
}
Definitions
indexStructure
Name | Type | Required | Description |
---|---|---|---|
fieldName |
string |
False |
|
fieldIndexType |
False |
||
order |
False |
index
Name | Type | Required | Description |
---|---|---|---|
name |
string |
True |
|
indexProperties |
False |
||
indexStructure |
array[indexStructure] |
True |