Skip to content

Find shopper profiles by what they answered

POST
/v1/profiles/search
curl --request POST \
--url 'https://api.octaneai.com/v1/profiles/search?limit=20' \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "groups": [ { "all": [ { "component_key": "image_choice-48su5", "kind": "choice", "op": "in", "option_labels": [ "Dry" ], "page_key": "skin", "quiz_id": "quiz_7c9e6679742540de944be07fc1f90ae7" }, { "component_key": "number_input-re853", "kind": "number", "max": 50, "min": 30, "op": "between", "page_key": "skin", "quiz_id": "quiz_7c9e6679742540de944be07fc1f90ae7" } ] }, { "all": [ { "dimension_id": "dry", "kind": "points", "op": "gt", "quiz_id": "quiz_7c9e6679742540de944be07fc1f90ae7", "value": 10 } ] } ], "match": "any_session" }'
cursor
Any of:
string
<= 200 characters

From the previous page’s next_cursor

limit
Limit
integer
default: 20 >= 1 <= 100
Media typeapplication/json
ProfileSearch

Who to find: the list filters of GET /v1/profiles except q, plus person facts and an answer filter, an OR of AND groups. Send the same body with every page: a cursor belongs to the search that answered it and is refused with any other body.

object
from
Any of:
string format: date
groups
Any of:
Array<object>
<= 4 items
ProfileSearchGroup
object
all
required
All

Every slot must hold: a term, or {any: [terms]}; at most 8 terms in the group, counting the terms inside any

Array
>= 1 items <= 8 items
Any of:
ProfileSearchTerm
object
component_key
Any of:
string
<= 200 characters
dimension_id
Any of:
string
<= 200 characters
kind
required
Kind

Choice | number | date | text | email | phone: a question of the quiz (page_key + component_key); points: a dimension (dimension_id); formula: a formula component (page_key + component_key); winner: the top dimension (dimension ids in option_ids); session: how the shopper’s session ended (value completed | abandoned, page_key the page they left on)

string
Allowed values: choice number date text email phone points formula winner session
max
Any of:
number
min
Any of:
number
op
required
Op

Choice: in | not_in; number, points, formula: eq | lt | gt | between; date: eq | before | after | between; text: contains | equals | matches | answered | not_answered; email, phone: answered | not_answered; winner: in; session: equals. not_in means answered the question and picked none of these; not_answered means took the quiz and left the question unanswered.

string
Allowed values: in not_in eq lt gt between before after contains equals matches answered not_answered
option_ids
Any of:
Array<string>
<= 50 items
option_labels
Any of:
Array<string>
<= 50 items
page_key
Any of:
string
<= 200 characters
quiz_id
required
Quiz Id

The quiz the term reads

string
/^quiz_[0-9a-f]{32}$/
value
Any of:
number
has_email
Any of:
boolean
has_marketing_consent
Any of:
boolean
has_order
Any of:
boolean
has_phone
Any of:
boolean
is_returning
Any of:
boolean
match
Match

Any_session: any time they took the quiz counts; latest_completed_per_quiz: only their latest completed take of each quiz

string
default: any_session
Allowed values: any_session latest_completed_per_quiz
quiz_id
Any of:
string
/^quiz_[0-9a-f]{32}$/
to
Any of:
string format: date

One page of the matching profiles, newest last-seen first; total is exact up to 5,000 and total_capped says when it stopped there.

Media typeapplication/json
ProfileList
object
data
required
Data

The profiles, newest last seen first

Array<object>
ProfileSummary
object
completed_count
required
Completed Count

How many of them completed

integer
email
required
Any of:
string
first_seen_at
required
Any of:
string format: date-time
id
required
Id

The profile

string
/^prof_[0-9a-f]{32}$/
last_order_at
required
Any of:
string format: date-time
last_seen_at
required
Last Seen At

The latest moment the shopper was seen

string format: date-time
orders_count
required
Orders Count

Orders linked to the shopper’s quiz sessions

integer
phone
required
Any of:
string
quizzes
required
Quizzes

The quizzes the shopper took

Array<object>
ProfileQuiz
object
id
required
Id

The quiz

string
/^quiz_[0-9a-f]{32}$/
name
required
Name

Its name

string
removed
required
Removed

True once the shopper’s data was erased on a data-deletion request: no identities or contact values remain

boolean
removed_at
required
Any of:
string format: date-time
returning
required
Any of:
boolean
sessions_count
required
Sessions Count

How many quiz sessions the shopper had

integer
shopify_customer_id
required
Any of:
string
spent
required
Any of:
Money
object
amount
required
Amount

A decimal string, as “79.97”

string
currency
required
Currency

ISO 4217 code

string
has_more
required
Has More

Whether another page follows

boolean
next_cursor
required
Any of:
string
returning_total
required
Any of:
integer
total
required
Total

How many profiles match

integer
total_capped
Total Capped

A search stops counting at 5,000: total is then that cap, read it as 5,000+

boolean
Example
{
"data": [
{
"completed_count": 1,
"email": "shopper@example.com",
"first_seen_at": "2026-09-01T12:00:00Z",
"id": "prof_50e1b7e458f14dfca7a2a5b971af2821",
"last_order_at": "2026-09-01T12:40:00Z",
"last_seen_at": "2026-09-01T12:00:00Z",
"orders_count": 1,
"phone": "+14155552671",
"quizzes": [
{
"id": "quiz_7c9e6679742540de944be07fc1f90ae7",
"name": "Find your routine"
}
],
"removed": false,
"returning": false,
"sessions_count": 1,
"shopify_customer_id": "gid://shopify/Customer/7208153301032",
"spent": {
"amount": "79.97",
"currency": "USD"
}
}
],
"has_more": false,
"returning_total": 0,
"total": 1,
"total_capped": false
}

The key is missing, malformed, revoked or expired.

Media typeapplication/problem+json
Problem

The body of every non-2xx response.

object
detail
required
Detail

What went wrong, for people

string
errors
Any of:
Array<object>
FieldError
object
field
required
Field

The input that failed, as a dotted path (body.label, query.from)

string
message
required
Message

Why it failed

string
export
Any of:
object
key
additional properties
any
feature
Any of:
Feature
string
Allowed values: merchant_api quiz_ab_testing ai_model_switch ai_advanced_model analytics_paths people_filter analytics_funnel analytics_answers quiz_shopify_customer_metafields custom_css_classes shopify_metafields_plan
plan
Any of:
PlanTier

Declared lowest first: a tier includes what every tier before it includes.

string
Allowed values: none basic plus enterprise
request_id
required
Request Id

The same value as the Request-Id header; quote it to support

string
required
Any of:
Array<string>
retry_after
Any of:
integer
status
required
Status

The HTTP status of the response

integer
title
required
Title

The machine-readable error code; the Errors guide lists every one

string
type
required
Type

A stable URI naming the error, on this API’s public host

string
Example
{
"detail": "The API key is missing, malformed, revoked or expired",
"request_id": "7c9e6679-7425-40de-944b-e07fc1f90ae7",
"status": 401,
"title": "invalid_api_key",
"type": "https://api.octaneai.com/errors/invalid_api_key"
}
WWW-Authenticate
string
Example
Bearer

The store’s plan has no API access, or the key lacks the scope.

Media typeapplication/problem+json
Problem

The body of every non-2xx response.

object
detail
required
Detail

What went wrong, for people

string
errors
Any of:
Array<object>
FieldError
object
field
required
Field

The input that failed, as a dotted path (body.label, query.from)

string
message
required
Message

Why it failed

string
export
Any of:
object
key
additional properties
any
feature
Any of:
Feature
string
Allowed values: merchant_api quiz_ab_testing ai_model_switch ai_advanced_model analytics_paths people_filter analytics_funnel analytics_answers quiz_shopify_customer_metafields custom_css_classes shopify_metafields_plan
plan
Any of:
PlanTier

Declared lowest first: a tier includes what every tier before it includes.

string
Allowed values: none basic plus enterprise
request_id
required
Request Id

The same value as the Request-Id header; quote it to support

string
required
Any of:
Array<string>
retry_after
Any of:
integer
status
required
Status

The HTTP status of the response

integer
title
required
Title

The machine-readable error code; the Errors guide lists every one

string
type
required
Type

A stable URI naming the error, on this API’s public host

string
Examples
{
"detail": "The API key does not carry the scope this route needs",
"request_id": "7c9e6679-7425-40de-944b-e07fc1f90ae7",
"required": [
"profiles:read"
],
"status": 403,
"title": "insufficient_scope",
"type": "https://api.octaneai.com/errors/insufficient_scope"
}

Not found

Media typeapplication/problem+json
Problem

The body of every non-2xx response.

object
detail
required
Detail

What went wrong, for people

string
errors
Any of:
Array<object>
FieldError
object
field
required
Field

The input that failed, as a dotted path (body.label, query.from)

string
message
required
Message

Why it failed

string
export
Any of:
object
key
additional properties
any
feature
Any of:
Feature
string
Allowed values: merchant_api quiz_ab_testing ai_model_switch ai_advanced_model analytics_paths people_filter analytics_funnel analytics_answers quiz_shopify_customer_metafields custom_css_classes shopify_metafields_plan
plan
Any of:
PlanTier

Declared lowest first: a tier includes what every tier before it includes.

string
Allowed values: none basic plus enterprise
request_id
required
Request Id

The same value as the Request-Id header; quote it to support

string
required
Any of:
Array<string>
retry_after
Any of:
integer
status
required
Status

The HTTP status of the response

integer
title
required
Title

The machine-readable error code; the Errors guide lists every one

string
type
required
Type

A stable URI naming the error, on this API’s public host

string
Example
{
"detail": "Not found",
"request_id": "7c9e6679-7425-40de-944b-e07fc1f90ae7",
"status": 404,
"title": "not_found",
"type": "https://api.octaneai.com/errors/not_found"
}

A request parameter is invalid.

Media typeapplication/problem+json
Problem

The body of every non-2xx response.

object
detail
required
Detail

What went wrong, for people

string
errors
Any of:
Array<object>
FieldError
object
field
required
Field

The input that failed, as a dotted path (body.label, query.from)

string
message
required
Message

Why it failed

string
export
Any of:
object
key
additional properties
any
feature
Any of:
Feature
string
Allowed values: merchant_api quiz_ab_testing ai_model_switch ai_advanced_model analytics_paths people_filter analytics_funnel analytics_answers quiz_shopify_customer_metafields custom_css_classes shopify_metafields_plan
plan
Any of:
PlanTier

Declared lowest first: a tier includes what every tier before it includes.

string
Allowed values: none basic plus enterprise
request_id
required
Request Id

The same value as the Request-Id header; quote it to support

string
required
Any of:
Array<string>
retry_after
Any of:
integer
status
required
Status

The HTTP status of the response

integer
title
required
Title

The machine-readable error code; the Errors guide lists every one

string
type
required
Type

A stable URI naming the error, on this API’s public host

string
Example
{
"detail": "A request parameter is invalid.",
"request_id": "7c9e6679-7425-40de-944b-e07fc1f90ae7",
"status": 422,
"title": "validation_error",
"type": "https://api.octaneai.com/errors/validation_error"
}

The key’s or the store’s bucket is full; Retry-After says when to try again.

Media typeapplication/problem+json
Problem

The body of every non-2xx response.

object
detail
required
Detail

What went wrong, for people

string
errors
Any of:
Array<object>
FieldError
object
field
required
Field

The input that failed, as a dotted path (body.label, query.from)

string
message
required
Message

Why it failed

string
export
Any of:
object
key
additional properties
any
feature
Any of:
Feature
string
Allowed values: merchant_api quiz_ab_testing ai_model_switch ai_advanced_model analytics_paths people_filter analytics_funnel analytics_answers quiz_shopify_customer_metafields custom_css_classes shopify_metafields_plan
plan
Any of:
PlanTier

Declared lowest first: a tier includes what every tier before it includes.

string
Allowed values: none basic plus enterprise
request_id
required
Request Id

The same value as the Request-Id header; quote it to support

string
required
Any of:
Array<string>
retry_after
Any of:
integer
status
required
Status

The HTTP status of the response

integer
title
required
Title

The machine-readable error code; the Errors guide lists every one

string
type
required
Type

A stable URI naming the error, on this API’s public host

string
Example
{
"detail": "Too many requests",
"request_id": "7c9e6679-7425-40de-944b-e07fc1f90ae7",
"retry_after": 1,
"status": 429,
"title": "rate_limited",
"type": "https://api.octaneai.com/errors/rate_limited"
}

The request timed out.

Media typeapplication/problem+json
Problem

The body of every non-2xx response.

object
detail
required
Detail

What went wrong, for people

string
errors
Any of:
Array<object>
FieldError
object
field
required
Field

The input that failed, as a dotted path (body.label, query.from)

string
message
required
Message

Why it failed

string
export
Any of:
object
key
additional properties
any
feature
Any of:
Feature
string
Allowed values: merchant_api quiz_ab_testing ai_model_switch ai_advanced_model analytics_paths people_filter analytics_funnel analytics_answers quiz_shopify_customer_metafields custom_css_classes shopify_metafields_plan
plan
Any of:
PlanTier

Declared lowest first: a tier includes what every tier before it includes.

string
Allowed values: none basic plus enterprise
request_id
required
Request Id

The same value as the Request-Id header; quote it to support

string
required
Any of:
Array<string>
retry_after
Any of:
integer
status
required
Status

The HTTP status of the response

integer
title
required
Title

The machine-readable error code; the Errors guide lists every one

string
type
required
Type

A stable URI naming the error, on this API’s public host

string
Example
{
"detail": "The request timed out.",
"request_id": "7c9e6679-7425-40de-944b-e07fc1f90ae7",
"status": 504,
"title": "timeout",
"type": "https://api.octaneai.com/errors/timeout"
}