Brands, locations and connections
Edit collection schedules
Creates or updates named collection schedules. Schedules you leave out stay unchanged.
- Body
sectionisschedule. - Body
kindiscollection.
Authentication and access
- Authentication
- Bearer API key
- Scopes
- collections:write
- Roles
- editor, owner, service
- Plans
- Optimizer, Analyzer
- Credits
- No credit charge.
Parameters
| Name | Where | Type | Required | Description |
|---|---|---|---|---|
brand_id | path | string (uuid) | Yes | |
Idempotency-Key | header | string | Yes | For 7 days, sending the same key and body for the same account and operation returns the original response. Changing the body for that key returns HTTP 409. |
Request body
{
"kind": "collection",
"schedules": [
{
"cadence_days": 1,
"enabled": false,
"id": "00000000-0000-4000-8000-000000000001",
"market": {
"country": "US",
"language": "example"
},
"max_units_per_run": 0,
"prompt_ids": [
"00000000-0000-4000-8000-000000000001"
],
"source": {
"mode": "ui_normal",
"platform": "chatgpt"
}
}
],
"section": "schedule"
}| Name | Type | Required | Description |
|---|---|---|---|
kind | "collection" | Yes | |
schedules | array of object | Yes | |
schedules[].all_locations | boolean | No | |
schedules[].allow_country_level | boolean | No | Allow a country-level answer when the source cannot apply the requested location. |
schedules[].cadence_days | 1 | 3 | 7 | 14 | 30 | Yes | |
schedules[].enabled | boolean | Yes | |
schedules[].id | string (uuid) | Yes | |
schedules[].location_ids | array of string (uuid) | No | |
schedules[].market | object | Yes | |
schedules[].market.city | string | null | null | No | |
schedules[].market.country | string | Yes | |
schedules[].market.language | string | Yes | |
schedules[].market.latitude | number | null | No | |
schedules[].market.location_id | string (uuid) | null | No | |
schedules[].market.longitude | number | null | No | |
schedules[].market.postal_code | string | null | No | |
schedules[].market.region | string | null | null | No | |
schedules[].max_units_per_run | integer | Yes | |
schedules[].next_run_at | string (date-time) | null | No | |
schedules[].prompt_ids | array of string (uuid) | Yes | |
schedules[].source | object | Yes | |
schedules[].source.device | "desktop" | "mobile" | "unknown" | No | |
schedules[].source.mode | "ui_normal" | "ui_search" | "api_normal" | "api_web" | "ai_mode" | "ai_overview" | "organic_search" | Yes | |
schedules[].source.platform | "chatgpt" | "gemini" | "claude" | "perplexity" | "google" | "bing" | "brave" | "meta_ai" | "grok" | "universal" | Yes | |
schedules[].source.provider | string | No | Optional source label for the selected platform and mode. An unsupported combination is rejected before the job starts. |
section | "schedule" | Yes |
Request examples
Set AEO_API_BASE_URL to https://api.aeoapi.dev and AEO_API_KEY to your server-side API key. Set the other environment variables to the values for your request.
Save the JSON request body as request.json. Replace sample IDs, revisions and other values with your own.
curl --fail-with-body -X PATCH "$AEO_API_BASE_URL/v2/brands/$BRAND_ID" \
-H "Authorization: Bearer $AEO_API_KEY" \
-H "Idempotency-Key: $IDEMPOTENCY_KEY" \
-H "Content-Type: application/json" \
--data-binary @request.jsonimport json
from pathlib import Path
from os import environ
from aeo_sdk import AeoClient
body = json.loads(Path("request.json").read_text())
with AeoClient(environ["AEO_API_KEY"], base_url=environ["AEO_API_BASE_URL"]) as client:
response = client.v2_patch_brands_brand_id(
brand_id=environ["BRAND_ID"],
body=body,
idempotency_key=environ["IDEMPOTENCY_KEY"],
)
print(response.body)import { AeoClient } from "@aeoapi/aeo-sdk";
import { readFile } from "node:fs/promises";
const client = new AeoClient(process.env.AEO_API_KEY!, {
baseUrl: process.env.AEO_API_BASE_URL!,
});
const body = JSON.parse(await readFile("request.json", "utf8"));
const response = await client.v2PatchBrandsBrandId(
process.env.BRAND_ID!,
body,
{
idempotencyKey: process.env.IDEMPOTENCY_KEY!,
},
);
console.log(response.body);Responses
HTTP 200
Upsert named collection schedules result.
| Name | Type | Required | Description |
|---|---|---|---|
X-RateLimit-Limit | integer | No | Requests in rate window. |
X-RateLimit-Remaining | integer | No | Remaining request tokens. |
X-RateLimit-Reset | integer | No | UTC Unix seconds when window resets. |
X-Request-Id | string (uuid) | No | Trace identifier. |
X-Usage-Units | integer | No | CU charged by this response; GET and account/usage always zero. |
application/json
{
"data": [],
"meta": {
"as_of": "2026-11-06T00:00:00Z",
"collected_at": null,
"next_cursor": null,
"next_refresh_at": null,
"request_id": "00000000-0000-4000-8000-000000000001",
"rights_filtered": false,
"schema_version": "1.0",
"stale": false,
"warnings": []
}
}| Name | Type | Required | Description |
|---|---|---|---|
data | array of object | Yes | The requested result. See the fields below for its contents. |
data[].all_locations | boolean | No | |
data[].allow_country_level | boolean | No | Allow a country-level answer when the source cannot apply the requested location. |
data[].brand_id | string (uuid) | Yes | |
data[].cadence_days | 1 | 3 | 7 | 14 | 30 | Yes | |
data[].enabled | boolean | Yes | |
data[].id | string (uuid) | Yes | |
data[].location_ids | array of string (uuid) | No | |
data[].market | object | Yes | |
data[].market.city | string | null | null | No | |
data[].market.country | string | Yes | |
data[].market.language | string | Yes | |
data[].market.latitude | number | null | No | |
data[].market.location_id | string (uuid) | null | No | |
data[].market.longitude | number | null | No | |
data[].market.postal_code | string | null | No | |
data[].market.region | string | null | null | No | |
data[].max_units_per_run | integer | Yes | |
data[].next_run_at | string (date-time) | null | No | |
data[].prompt_ids | array of string (uuid) | Yes | |
data[].source | object | Yes | |
data[].source.device | "desktop" | "mobile" | "unknown" | No | |
data[].source.mode | "ui_normal" | "ui_search" | "api_normal" | "api_web" | "ai_mode" | "ai_overview" | "organic_search" | Yes | |
data[].source.platform | "chatgpt" | "gemini" | "claude" | "perplexity" | "google" | "bing" | "brave" | "meta_ai" | "grok" | "universal" | Yes | |
data[].source.provider | string | No | Optional source label for the selected platform and mode. An unsupported combination is rejected before the job starts. |
meta | object | Yes | Information about this response, including any warnings or pagination details. |
meta.as_of | string (date-time) | Yes | The point in time that the response represents. |
meta.cohort_version | string | null | No | Identifies the version of the group used to calculate the results. |
meta.collected_at | string (date-time) | null | Yes | When the data was collected, if available. |
meta.metric_version | string | null | No | The version of the metric definition used for these results. |
meta.next_cursor | string | null | Yes | When present, pass this value as cursor to request the next page with the same filters. |
meta.next_refresh_at | string (date-time) | null | Yes | |
meta.request_id | string (uuid) | Yes | Keep this ID when reporting a problem with the request. |
meta.restricted_fields | array of string | No | Fields that your current access does not allow the API to return. |
meta.rights_filtered | boolean | Yes | Indicates whether access rights affected the returned data. |
meta.schema_version | "1.0" | Yes | The version of the response format. |
meta.stale | boolean | Yes | |
meta.warnings | array of string | Yes | Read these notes for limitations that affect the results. |
Errors
Read code and message in the error response. Keep request_id when you contact support.
- HTTP 400
invalid_request - HTTP 401
unauthenticated - HTTP 402
quota_exceeded - HTTP 403
forbidden - HTTP 404
not_found - HTTP 409
conflict - HTTP 412
precondition_failed - HTTP 422
validation_error - HTTP 429
rate_limited - HTTP 500
internal_error - HTTP 503
source_pending,feature_not_offered