Create Index
Creates a new index.
Resource Information
This service uses the tomcat application on port 8080 by default. To see a list of default ports click here
The context for this API is /crafter-search
, please prefix the API URLs with this context.
HTTP Verb
|
POST
|
URL
|
/api/2/admin/index/create |
Response Formats
|
JSON |
Parameters
Name
|
Type
|
Required
|
Description
|
---|---|---|---|
id
|
String
|
✓
|
The index ID.
|
token
|
String
|
✓
|
The access token.
|
The access token could be optional depending on the configuration.
Example
Request
POST .../api/2/admin/index/create?token=myAccessToken
{
"id": "mysite",
}
Response
Status 201 CREATED
{ "message" : "OK" }
Responses
Status
|
Location
|
Response Body
|
---|---|---|
201
|
.../target/get/:target_id |
{ "message" : "OK" } |
400
|
{ "message" : "Validation failed", "field_errors": [...] } |
|
500
|
{ "message" : "Internal server error" } |
|
503
|
{ "message" : "Service unavailable, please try again later" } |