---
title: "Query Form Values"
description: "How to call Query Form Values (POST /api/form-values-reports) in the Klaviyo REST API: authentication, parameters, request and response bodies, and an example request."
url: "https://developers.klaviyo.com/en/v2025-01-15/reference/query_form_values"
revision: "2025-01-15"
latestUrl: "https://developers.klaviyo.com/en/reference/query_form_values"
operationId: "query_form_values"
aliases: ["create_form_value_report","create_form_values_report"]
method: "POST"
endpoint: "https://a.klaviyo.com/api/form-values-reports"
authentication: "privateKey"
scopes: ["forms:read"]
rateLimits: {"burst":"1/s","steady":"2/m","daily":"225/d"}
revisionHeader: {"name":"revision","required":true}
deprecated: false
related: ["https://developers.klaviyo.com/en/v2025-01-15/reference/reporting/llms.txt","https://developers.klaviyo.com/en/v2025-01-15/reference/query_campaign_values.md","https://developers.klaviyo.com/en/v2025-01-15/reference/query_flow_values.md","https://developers.klaviyo.com/en/v2025-01-15/reference/query_flow_series.md","https://developers.klaviyo.com/en/v2025-01-15/reference/query_form_series.md","https://developers.klaviyo.com/en/v2025-01-15/reference/query_segment_values.md","https://developers.klaviyo.com/en/v2025-01-15/reference/query_segment_series.md"]
---

# Query Form Values

> This is the Markdown version of https://developers.klaviyo.com/en/v2025-01-15/reference/query_form_values

```http
POST https://a.klaviyo.com/api/form-values-reports
```

Returns the requested form analytics values data.

- Revision header: `revision: 2025-01-15` (required)
- Scopes: `forms:read`
- Rate limits: Burst: `1/s`, Steady: `2/m`, Daily: `225/d`

## Example request

```bash
curl --request POST \
     --url 'https://a.klaviyo.com/api/form-values-reports' \
     --header 'Authorization: Klaviyo-API-Key your-private-api-key' \
     --header 'accept: application/vnd.api+json' \
     --header 'revision: 2025-01-15' \
     --header 'content-type: application/vnd.api+json' \
     --data '{
  "data": {
    "type": "form-values-report",
    "attributes": {
      "statistics": [
        "viewed_form",
        "submit_rate"
      ],
      "timeframe": {
        "key": "last_12_months"
      },
      "filter": "and(equals(form_id,\"abc123\"),any(form_version_id,[\"xyz123\",\"ghi456\"]))"
    }
  }
}'
```

## Headers

- `revision` (string, required): API endpoint revision (format: YYYY-MM-DD[.suffix]) Default: `2025-01-15`

## Request body

Content type: `application/vnd.api+json` (required)

- `data` (object, required)
  - `type` (string, required): Allowed values: `form-values-report`
  - `attributes` (object, required)
    - `statistics` (string[], required): List of statistics to query for. All rate statistics will be returned in fractional form [0.0, 1.0] Allowed values: `closed_form`, `closed_form_uniques`, `qualified_form`, `qualified_form_uniques`, `submit_rate`, `submits`, `submitted_form_step`, `submitted_form_step_uniques`, `viewed_form`, `viewed_form_step`, `viewed_form_step_uniques`, `viewed_form_uniques`
    - `timeframe` (oneOf, required): The timeframe to query for data within. The max length a timeframe can be is 1 year
      - One of:
        - Option 1: `Timeframe` Fields nested this deep aren't listed here; they're in the endpoint's OpenAPI document.
        - Option 2: `CustomTimeframe` Fields nested this deep aren't listed here; they're in the endpoint's OpenAPI document.
    - `group_by` (string[], nullable): List of attributes to group the data by.
      Allowed group-bys are form_id, form_version_id.
      If not passed in, the data will be grouped by form_id.
      If a group by has prerequisites, they must be passed in together. The prerequisites for form_version_id is form_id Allowed values: `form_id`, `form_version_id`
    - `filter` (string, nullable): API filter string used to filter the query.
      Allowed filters are form_id, form_version_id.
      Allowed operators are equals, any.
      Only one filter can be used per attribute, only AND can be used as a combination operator.
      Max of 100 messages per ANY filter. Example: `and(equals(form_id,"abc123"),any(form_version_id,["xyz123","ghi456"]))`

### Example request body

```json
{
  "data": {
    "type": "form-values-report",
    "attributes": {
      "statistics": [
        "viewed_form",
        "submit_rate"
      ],
      "timeframe": {
        "key": "last_12_months"
      },
      "filter": "and(equals(form_id,\"abc123\"),any(form_version_id,[\"xyz123\",\"ghi456\"]))"
    }
  }
}
```

## Responses

### 200: Success

Content type: `application/vnd.api+json`

- `data` (object, required)
  - `type` (string, required): Allowed values: `form-values-report`
  - `attributes` (object, required)
    - `results` (object[], required): An array of all the returned values data.
      Each object in the array represents one unique grouping and the results for that grouping.
      - `groupings` (object, required): Applied groupings and the values for this object
      - `statistics` (object, required): Requested statistics and their values results

#### Example response body

```json
{
  "data": {
    "type": "form-values-report",
    "attributes": {
      "results": [
        {
          "groupings": {
            "form_id": "abc123",
            "form_version_id": "012tuy"
          },
          "statistics": {
            "viewed_form": 90,
            "submits": 9,
            "submit_rate": 0.1
          }
        },
        {
          "groupings": {
            "form_id": "abc123",
            "form_version_id": "756ghi"
          },
          "statistics": {
            "viewed_form": 10,
            "submits": 1,
            "submit_rate": 0.1
          }
        }
      ]
    }
  }
}
```

### 4XX: Client Error

Content type: `application/vnd.api+json`

- `errors` (object[], required)
  - `id` (string, required)
  - `code` (string, required)
  - `title` (string, required)
  - `detail` (string, required)
  - `source` (object)
    - `pointer` (string)
    - `parameter` (string)

#### Example response body

```json
{
  "errors": [
    {
      "id": "string",
      "code": "string",
      "title": "string",
      "detail": "string",
      "source": {
        "pointer": "string",
        "parameter": "string"
      }
    }
  ]
}
```

### 5XX: Server Error

Content type: `application/vnd.api+json`

- `errors` (object[], required)
  - `id` (string, required)
  - `code` (string, required)
  - `title` (string, required)
  - `detail` (string, required)
  - `source` (object)
    - `pointer` (string)
    - `parameter` (string)

#### Example response body

```json
{
  "errors": [
    {
      "id": "string",
      "code": "string",
      "title": "string",
      "detail": "string",
      "source": {
        "pointer": "string",
        "parameter": "string"
      }
    }
  ]
}
```
