Create an Index
9min
POST /{appname}/data/{servicename}/_index
Indexes are used to provide fast search when querying a data service. With this command, you can create a specific index that can be applied to your query command, for more efficient response times.
Parameters
Path
- appname - string - path parameters
- servicename - value requirements
- See ο»ΏParametersο»Ώ
Request Body
JSON
|
ο»Ώ
Request body parameters
- fields - JSON array describing the index to create
- name - The name of the index
- type - index type - should always be "JSON"
Example
This example creates an index on the fields named title and year. When querying for both title and year, the datastore can use this index for faster response times.
Node.js
Curl
|
ο»Ώ
Responses
Status Code | Description | Example Value |
200 | Successfully created index | {"ok": true} |
500 | Error occured trying to create index | {"ok": false,"msg": "...."} |
Need Help?
You can always reach out to our support team for any additional assistance on slack.
ο»Ώ

Updated 24 Mar 2022
Did this page help you?
Yes
No