Analytics apiQueryQuery

Query Property Values

Copy page

POST
/query/property-values

Authorization

AuthorizationRequiredBearer <token>

The API key for an API integration. For more details, see authentication documentation

In: header

Request Body

application/jsonOptional
fieldRequiredstring

Which JSON field to query values from

Value in: "properties" | "userProperties"
keyRequiredstring

The property key to get values for

viewsarray<string>

Optional list of views to query (defaults to all views)

limitnumber

Maximum number of values to return

Default: 100Minimum: 1Maximum: 1000

Response Body

Property values query results

TypeScript Definitions

Use the response body type in TypeScript.

resultsRequiredarray<string>

Bad Request

TypeScript Definitions

Use the response body type in TypeScript.

titleRequiredstring

A short, human-readable summary of the problem type.

statusRequirednumber

The HTTP status code.

Value in: 400
detailRequiredstring

A detailed explanation specific to this occurrence of the problem, providing context and specifics about what went wrong.

instancestring

A URI reference that identifies the specific occurrence of the problem.

requestIdstring

A unique identifier for the request, useful for troubleshooting.

codeRequiredstring

A short code indicating the error code returned.

Value in: "bad_request"
errorRequiredobject

Legacy error format for backward compatibility.

Unauthorized

TypeScript Definitions

Use the response body type in TypeScript.

titleRequiredstring

A short, human-readable summary of the problem type.

statusRequirednumber

The HTTP status code.

Value in: 401
detailRequiredstring

A detailed explanation specific to this occurrence of the problem, providing context and specifics about what went wrong.

instancestring

A URI reference that identifies the specific occurrence of the problem.

requestIdstring

A unique identifier for the request, useful for troubleshooting.

codeRequiredstring

A short code indicating the error code returned.

Value in: "unauthorized"
errorRequiredobject

Legacy error format for backward compatibility.

Forbidden

TypeScript Definitions

Use the response body type in TypeScript.

titleRequiredstring

A short, human-readable summary of the problem type.

statusRequirednumber

The HTTP status code.

Value in: 403
detailRequiredstring

A detailed explanation specific to this occurrence of the problem, providing context and specifics about what went wrong.

instancestring

A URI reference that identifies the specific occurrence of the problem.

requestIdstring

A unique identifier for the request, useful for troubleshooting.

codeRequiredstring

A short code indicating the error code returned.

Value in: "forbidden"
errorRequiredobject

Legacy error format for backward compatibility.

Unprocessable Entity

TypeScript Definitions

Use the response body type in TypeScript.

titleRequiredstring

A short, human-readable summary of the problem type.

statusRequirednumber

The HTTP status code.

Value in: 422
detailRequiredstring

A detailed explanation specific to this occurrence of the problem, providing context and specifics about what went wrong.

instancestring

A URI reference that identifies the specific occurrence of the problem.

requestIdstring

A unique identifier for the request, useful for troubleshooting.

codeRequiredstring

A short code indicating the error code returned.

Value in: "unprocessable_entity"
errorRequiredobject

Legacy error format for backward compatibility.

Internal Server Error

TypeScript Definitions

Use the response body type in TypeScript.

titleRequiredstring

A short, human-readable summary of the problem type.

statusRequirednumber

The HTTP status code.

Value in: 500
detailRequiredstring

A detailed explanation specific to this occurrence of the problem, providing context and specifics about what went wrong.

instancestring

A URI reference that identifies the specific occurrence of the problem.

requestIdstring

A unique identifier for the request, useful for troubleshooting.

codeRequiredstring

A short code indicating the error code returned.

Value in: "internal_server_error"
errorRequiredobject

Legacy error format for backward compatibility.

curl -X POST "https://api.analytics.inkeep.com/query/property-values" \
  -H "Authorization: Bearer <token>" \
  -H "Content-Type: application/json" \
  -d '{
    "field": "properties",
    "key": "theme",
    "views": [
      "events_view",
      "conversations_view",
      "semantic_threads_view",
      "feedback_view"
    ],
    "limit": 100
  }'
const body = JSON.stringify({
  "field": "properties",
  "key": "theme",
  "views": [
    "events_view",
    "conversations_view",
    "semantic_threads_view",
    "feedback_view"
  ],
  "limit": 100
})

fetch("https://api.analytics.inkeep.com/query/property-values", {
  headers: {
    "Authorization": "Bearer <token>"
  },
  body
})
package main

import (
  "fmt"
  "net/http"
  "io/ioutil"
  "strings"
)

func main() {
  url := "https://api.analytics.inkeep.com/query/property-values"
  body := strings.NewReader(`{
    "field": "properties",
    "key": "theme",
    "views": [
      "events_view",
      "conversations_view",
      "semantic_threads_view",
      "feedback_view"
    ],
    "limit": 100
  }`)
  req, _ := http.NewRequest("POST", url, body)
  req.Header.Add("Authorization", "Bearer <token>")
  req.Header.Add("Content-Type", "application/json")
  res, _ := http.DefaultClient.Do(req)
  defer res.Body.Close()
  body, _ := ioutil.ReadAll(res.Body)

  fmt.Println(res)
  fmt.Println(string(body))
}
import requests

url = "https://api.analytics.inkeep.com/query/property-values"
body = {
  "field": "properties",
  "key": "theme",
  "views": [
    "events_view",
    "conversations_view",
    "semantic_threads_view",
    "feedback_view"
  ],
  "limit": 100
}
response = requests.request("POST", url, json = body, headers = {
  "Authorization": "Bearer <token>",
  "Content-Type": "application/json"
})

print(response.text)
{
  "results": [
    "dark"
  ]
}
{
  "title": "Bad Request",
  "status": 400,
  "detail": "Bad Request",
  "instance": "/conversations/123",
  "requestId": "req_1234567890",
  "code": "bad_request",
  "error": {
    "code": "bad_request",
    "message": "Bad Request"
  }
}
{
  "title": "Unauthorized",
  "status": 401,
  "detail": "Unauthorized",
  "instance": "/conversations/123",
  "requestId": "req_1234567890",
  "code": "unauthorized",
  "error": {
    "code": "unauthorized",
    "message": "Unauthorized"
  }
}
{
  "title": "Forbidden",
  "status": 403,
  "detail": "Forbidden",
  "instance": "/conversations/123",
  "requestId": "req_1234567890",
  "code": "forbidden",
  "error": {
    "code": "forbidden",
    "message": "Forbidden"
  }
}
{
  "title": "Unprocessable Entity",
  "status": 422,
  "detail": "Unprocessable Entity",
  "instance": "/conversations/123",
  "requestId": "req_1234567890",
  "code": "unprocessable_entity",
  "error": {
    "code": "unprocessable_entity",
    "message": "Unprocessable Entity"
  }
}
{
  "title": "Internal Server Error",
  "status": 500,
  "detail": "Internal Server Error",
  "instance": "/conversations/123",
  "requestId": "req_1234567890",
  "code": "internal_server_error",
  "error": {
    "code": "internal_server_error",
    "message": "Internal Server Error"
  }
}