Organization fields

Organization fields: 5 operations of the ChaosDesk REST API.

Retrieves the collection of OrganizationField resources.

GET/api/organization_fields

Responses

  • 200OrganizationField collection
  • 403Forbidden

Example request

curl -X GET "https://yourcompany.chaosdesk.io/api/organization_fields" \
  -H "Authorization: Bearer $CHAOSDESK_TOKEN" \
  -H "Accept: application/json"

Creates a OrganizationField resource.

POST/api/organization_fields

Request body application/json

keystring
Stable machine key used in rules, search, import and the API (user_fields.{key}).
titlestringrequired
type"text" | "textarea" | "dropdown" | "multiselect" | "date" | "integer" | "decimal" | "checkbox" | "regex" | "credit_card" | "lookup" | "currency"
descriptionstring | null
activeboolean
positioninteger
regex_patternstring | null
optionsobject[]
options for dropdown/multiselect

Responses

  • 201OrganizationField resource created
  • 400Invalid input
  • 403Forbidden
  • 422An error occurred

Example request

curl -X POST "https://yourcompany.chaosdesk.io/api/organization_fields" \
  -H "Authorization: Bearer $CHAOSDESK_TOKEN" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -d '{"title":"string"}'

Retrieves a OrganizationField resource.

GET/api/organization_fields/{id}

Parameters

idstringpathrequired
OrganizationField identifier

Responses

  • 200OrganizationField resource
  • 403Forbidden
  • 404Not found

Example request

curl -X GET "https://yourcompany.chaosdesk.io/api/organization_fields/{id}" \
  -H "Authorization: Bearer $CHAOSDESK_TOKEN" \
  -H "Accept: application/json"

Updates the OrganizationField resource.

PATCH/api/organization_fields/{id}

Parameters

idstringpathrequired
OrganizationField identifier

Request body application/merge-patch+json

titlestring
descriptionstring | null
activeboolean
positioninteger
regex_patternstring | null
optionsobject[]
options for dropdown/multiselect

Responses

  • 200OrganizationField resource updated
  • 400Invalid input
  • 403Forbidden
  • 404Not found
  • 422An error occurred

Example request

curl -X PATCH "https://yourcompany.chaosdesk.io/api/organization_fields/{id}" \
  -H "Authorization: Bearer $CHAOSDESK_TOKEN" \
  -H "Accept: application/json" \
  -H "Content-Type: application/merge-patch+json" \
  -d '{"title":"string","description":"string"}'

Removes the OrganizationField resource.

DELETE/api/organization_fields/{id}

Parameters

idstringpathrequired
OrganizationField identifier

Responses

  • 204OrganizationField resource deleted
  • 403Forbidden
  • 404Not found

Example request

curl -X DELETE "https://yourcompany.chaosdesk.io/api/organization_fields/{id}" \
  -H "Authorization: Bearer $CHAOSDESK_TOKEN" \
  -H "Accept: application/json"