1. API
  2. Cases
  3. Fields

Fields: List

Description

Returns a list of fields.

See the Get Field API to learn more about fields.

Request

HTTP Method: GET

Query Parameter Description
team_id Optional Only include fields from a specific team.
per_page Optional Set the number of results returned per page. Defaults to 20.
page Optional Specify the page of results to return if there are multiple pages. Defaults to page 1.
curl -X GET \
  https://<tenant-domain>/api/v1/case_inputs?team_id=<<team_id>> \
  -H 'content-type: application/json' \
  -H 'Authorization: Bearer <<CREDENTIAL.tines_api_key>>'

Response

A successful response will return a list of fields.

Field description

Parameter Description
id The field ID.
name The name of the field.
key The lookup key of the field.
input_type The type of the field.
sensitive A boolean (true or false) indicating whether the sensitive field permission is required to read or write this field.
validation_type The validation type of the field. One of none, options, or regex.
validation_options An object containing validation configuration. For options type, contains an options array of accepted string values.
team An object containing the ID and name of the team the field belongs to.
team_case_input_group An object containing the name of the group the field belongs to, if any.
created_at An ISO 8601 timestamp representing when the field was created.
updated_at An ISO 8601 timestamp representing when the field was last updated.

Sample response

{
  "case_inputs": [
    {
      "id": 19990840,
      "name": "Priority",
      "key": "priority",
      "input_type": "string",
      "sensitive": false,
      "validation_type": "options",
      "validation_options": {
        "options": ["low", "medium", "high", "critical"]
      },
      "team": {
        "id": 1,
        "name": "Engineering Team"
      },
      "created_at": "2022-06-24T08:35:21Z",
      "updated_at": "2022-06-24T08:35:21Z"
    }
  ],
  "meta": {
    "current_page": "https://tenant.tines.io/api/v1/case_inputs?per_page=20&page=1",
    "previous_page": null,
    "next_page": null,
    "next_page_number": null,
    "per_page": 20,
    "pages": 1,
    "count": 1
  }
}
Was this helpful?