Get form questions

GET /forms/{formId}/questions

Get questions for a form by its ID with filtering

Headers

Path parameters

  • formId string Required

    Minimum length is 1.

Query parameters

  • id array[string]

    ID(s) to be considered for filtering

    At least 1 element. Minimum length of each is 1.

  • external-id array[string]

    External ID(s) to be considered for filtering

    At least 1 element. Minimum length of each is 1, maximum length of each is 255.

  • Includes deleted resources in the results

Responses

  • 200 application/json

    Successful operation

    Hide response attribute Show response attribute object
    • data array[object] Required
      Hide data attributes Show data attributes object
      • id string Required

        Minimum length is 1.

      • form object Required

        Additional properties are NOT allowed.

        Hide form attribute Show form attribute object
        • id string Required

          Minimum length is 1.

      • fetchConfiguration object | null

        Additional properties are NOT allowed.

        Hide fetchConfiguration attribute Show fetchConfiguration attribute object | null
        • id string Required

          Minimum length is 1.

      • order integer Required

        Minimum value is 0.

      • defaultValue string | null

        Minimum length is 1.

      • externalId string | null

        Minimum length is 1, maximum length is 255.

      • targetProperty string | null

        Minimum length is 1.

      • required boolean Required
      • hidden boolean Required
      • inputType string Required

        Values are ADDRESS, BOOLEAN, DATE, DATE_TIME, EMAIL, FETCH, FILE, LANGUAGE, LONG_TEXT, MULTI_FILE, MULTI_SELECT, NUMBER, PHONE, SELECT, SHORT_TEXT, TIME_ZONE, or URL.

      • validator object | null

        Additional properties are NOT allowed.

        Hide validator attributes Show validator attributes object | null
        • regex string Required

          A regular expression

          Minimum length is 1.

        • errorMessage object | null Required

          Additional properties are NOT allowed.

          Hide errorMessage attributes Show errorMessage attributes object | null
          • language string Required

            Values are da, de, el, en, es, fr, ja, nl, no, or pl.

          • value string Required
      • label object | null Required

        Additional properties are NOT allowed.

        Hide label attributes Show label attributes object | null
        • language string Required

          Values are da, de, el, en, es, fr, ja, nl, no, or pl.

        • value string Required
      • helpText object | null Required

        Additional properties are NOT allowed.

        Hide helpText attributes Show helpText attributes object | null
        • language string Required

          Values are da, de, el, en, es, fr, ja, nl, no, or pl.

        • value string Required
      • placeholder object | null Required

        Additional properties are NOT allowed.

        Hide placeholder attributes Show placeholder attributes object | null
        • language string Required

          Values are da, de, el, en, es, fr, ja, nl, no, or pl.

        • value string Required
      • createdAt string(date-time) Required

        Minimum length is 1.

      • updatedAt string(date-time) Required

        Minimum length is 1.

      • deletedAt string(date-time) | null Required

        Minimum length is 1.

      • answerOptions array[object] Required
        Hide answerOptions attributes Show answerOptions attributes object
        • externalId string | null

          Minimum length is 1, maximum length is 255.

        • value string | null

          Minimum length is 1, maximum length is 255.

        • label object | null Required

          Additional properties are NOT allowed.

          Hide label attributes Show label attributes object | null
          • language string Required

            Values are da, de, el, en, es, fr, ja, nl, no, or pl.

          • value string Required
        • order integer Required

          Minimum value is 0.

        • createdAt string(date-time) Required

          Minimum length is 1.

        • updatedAt string(date-time) Required

          Minimum length is 1.

        • deletedAt string(date-time) | null Required

          Minimum length is 1.

  • 404 application/json

    Resource not found

    Hide response attribute Show response attribute object
    • errors array[object] Required

      At least 1 element.

      Hide errors attributes Show errors attributes object
      • message string Required

        Minimum length is 1.

      • code string Required

        Minimum length is 1.

      • type string Required

        Minimum length is 1.

      • statusCode string Required

        Minimum length is 1.

GET /forms/{formId}/questions
curl \
 -X GET https://api.development.pexipengage.com/enterprises/acme/forms/123/questions \
 -H "Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c" \
 -H "X-Correlation-Id: a4f0048e-c983-11ed-afa1-0242ac120002" \
 -H "Accept-Language: en *"
Response examples (200)
{
  "data": [
    {
      "id": "123",
      "form": {
        "id": "123"
      },
      "fetchConfiguration": {
        "id": "123"
      },
      "order": 5,
      "defaultValue": "string",
      "externalId": "ABCD1234",
      "targetProperty": "string",
      "required": true,
      "hidden": true,
      "inputType": "SELECT",
      "validator": {
        "regex": "^.{8}",
        "errorMessage": {
          "language": "en",
          "value": "Lorem ipsum"
        }
      },
      "label": {
        "language": "en",
        "value": "Lorem ipsum"
      },
      "helpText": {
        "language": "en",
        "value": "Lorem ipsum"
      },
      "placeholder": {
        "language": "en",
        "value": "Lorem ipsum"
      },
      "createdAt": "2022-08-17T19:05:21.362Z",
      "updatedAt": "2022-08-17T19:05:21.362Z",
      "deletedAt": "2022-08-17T19:05:21.362Z",
      "answerOptions": [
        {
          "externalId": "ABCD1234",
          "value": "string",
          "label": {
            "language": "en",
            "value": "Lorem ipsum"
          },
          "order": 5,
          "createdAt": "2022-08-17T19:05:21.362Z",
          "updatedAt": "2022-08-17T19:05:21.362Z",
          "deletedAt": "2022-08-17T19:05:21.362Z"
        }
      ]
    }
  ]
}
Response examples (404)
{
  "errors": [
    {
      "message": "string",
      "code": "string",
      "type": "string",
      "statusCode": "string"
    }
  ]
}