Errors

Code Description
401 Unauthorized
500 Internal Server Error
422 Missing parameters

Examples

POST /api/v2/admin/field_groups/8/fields
{
  "name": "test_field",
  "dropdown_options": [],
  "field_type": "textbox",
  "searchable": false,
  "read_only": true
}
200
{
  "ok": "ok"
}
POST /api/v2/admin/field_groups/not-found-id/fields
{
  "name": "test_field",
  "dropdown_options": [],
  "field_type": "textbox",
  "searchable": false,
  "read_only": true
}
404
{
  "error": "Field group not found"
}
POST /api/v2/admin/field_groups/not-found-id/fields
{
  "name": "test_field",
  "dropdown_options": [],
  "field_type": "textbox",
  "searchable": false,
  "read_only": true
}
401
POST /api/v2/admin/field_groups/not-found-id/fields
{
  "name": "test_field",
  "dropdown_options": [],
  "field_type": "textbox",
  "searchable": false,
  "read_only": true
}
401

Params

Param name Description
field_group_id
required

Field group ID

Validations:

  • Must be a String

name
required

Fields name

Validations:

  • Must be a String

field_type
required

Fields type

Validations:

  • Must be one of: date, textbox, textarea, rich_text, dropdown, boolean, datetime.

dropdown_options
required

Dropdown fields options

Validations:

  • Must be an array of Hash

searchable
required

Is field searchable

Validations:

  • Must be one of: true, false.

read_only
required

Is field read only

Validations:

  • Must be one of: true, false.

Headers

Header name Description
Content-Type
required
application/json
X-API-KEY
required
YOUR_API_KEY