Create Schema

POST /request-schemas

Upload schema for request validation

application/json

Body Required

Schema definition

  • title string

    Schema title

    Minimum length is 1, maximum length is 256. Format should match the following pattern: [a-zA-Z0-9_\- ]+.

Responses

  • 201 application/json

    Created request schema

    Hide response attributes Show response attributes object
  • 400 application/json

    Bad request

    Hide response attributes Show response attributes object
    • code string(string) Required

      Error code

      Minimum length is 1, maximum length is 64.

    • message string(string) Required

      Human-readable error message

      Minimum length is 1, maximum length is 1024.

  • 401 application/json

    Unauthorized request

    Hide response attributes Show response attributes object
    • code string(string) Required

      Error code

      Minimum length is 1, maximum length is 64.

    • message string(string) Required

      Human-readable error message

      Minimum length is 1, maximum length is 1024.

  • 429 application/json

    Too many requests

    Hide response attributes Show response attributes object
    • code string(string) Required

      Error code

      Minimum length is 1, maximum length is 64.

    • message string(string) Required

      Human-readable error message

      Minimum length is 1, maximum length is 1024.

  • 500 application/json

    Internal server error

    Hide response attributes Show response attributes object
    • code string(string) Required

      Error code

      Minimum length is 1, maximum length is 64.

    • message string(string) Required

      Human-readable error message

      Minimum length is 1, maximum length is 1024.

POST /request-schemas
curl \
 --request POST '/api/v1/request-schemas' \
 --header "Authorization: Bearer $ACCESS_TOKEN" \
 --header "Content-Type: application/json" \
 --data '{"title":"Request schema"}'
Request examples
{
  "title": "Request schema"
}
Response examples (201)
{
  "schemaID": "S7AB56CD456OP98BN54CAUB43211OU78",
  "updatedAt": "2017-07-21T17:32:28Z"
}
Response examples (400)
{
  "code": "string",
  "message": "string"
}
Response examples (401)
{
  "code": "string",
  "message": "string"
}
Response examples (429)
{
  "code": "string",
  "message": "string"
}
Response examples (500)
{
  "code": "string",
  "message": "string"
}