### Share of Voice Example Calculation Source: https://docs.peec.ai/metrics/brand-metrics/share-of-voice Example demonstrating how to calculate Share of Voice when competitor mentions are known. This helps in understanding relative market influence. ```text SoV: If your brand is mentioned 4 times in 10 chats and your competitor is mentioned 12 times, your share of voice is 25% (4 / (4 + 12) x 100). ``` -------------------------------- ### GET /projects/{project_id}/shopping/queries Source: https://docs.peec.ai/api-reference/project/list-fanout-shopping-queries Retrieves a list of fanout shopping queries for a specified project. ```APIDOC ## GET /projects/{project_id}/shopping/queries ### Description List the fanout shopping queries of a project. ### Method GET ### Endpoint /projects/{project_id}/shopping/queries ### Parameters #### Path Parameters - **project_id** (string) - Required - The unique identifier of the project. ``` -------------------------------- ### GET /topics Source: https://docs.peec.ai/api-reference/project/list-topics Retrieves a list of topics associated with a project. ```APIDOC ## GET /topics ### Description List the topics of a project. ### Method GET ### Endpoint https://api.peec.ai/customer/v1/topics ### Parameters #### Query Parameters - **project_id** (string) - Optional - Required if using a company api key. Example: or_f45b94ba-5e35-4982-93ed-285e72ee14eb - **limit** (number) - Optional - Default: 1000. Minimum: 1, Maximum: 10000 - **offset** (number) - Optional - Default: 0. Minimum: 0 ### Response #### Success Response (200) - **data** (array) - List of topics - **id** (string) - Topic ID - **name** (string) - Topic name #### Response Example { "data": [ { "id": "to_5524d66a-df1e-47e4-9dbc-802af39235ad", "name": "SEO" } ] } ``` -------------------------------- ### GET /models Source: https://docs.peec.ai/api-reference/project/list-models Retrieves a list of available models for the project. Supports pagination and project-specific filtering. ```APIDOC ## GET /models ### Description List the models available within the Peec AI platform. ### Method GET ### Endpoint /models ### Parameters #### Query Parameters - **project_id** (string) - Optional - Required if using a company api key. - **limit** (number) - Optional - The maximum number of models to return (default: 1000, max: 10000). - **offset** (number) - Optional - The number of items to skip before starting to collect the result set (default: 0). ### Response #### Success Response (200) - **data** (array) - A list of model objects. - **id** (string) - The unique identifier of the model. - **is_active** (boolean) - Indicates if the model is active for the project. #### Response Example { "data": [ { "id": "chatgpt-scraper", "is_active": true }, { "id": "gpt-4o-search", "is_active": true } ] } ``` -------------------------------- ### GET /prompts Source: https://docs.peec.ai/api-reference/project/list-prompts Retrieves a list of prompts for a specific project, with support for pagination and filtering by topic or tag. ```APIDOC ## GET /prompts ### Description List the prompts of a project. ### Method GET ### Endpoint /prompts ### Parameters #### Query Parameters - **project_id** (string) - Optional - Required if using a company api key - **topic_id** (string) - Optional - Filter by topic ID - **tag_id** (string) - Optional - Filter by tag ID - **limit** (number) - Optional - Number of items to return (default: 1000, max: 10000) - **offset** (number) - Optional - Number of items to skip (default: 0) ### Response #### Success Response (200) - **data** (array) - List of prompt objects #### Response Example { "data": [ { "id": "pr_93f790de-5b7a-45ee-b782-61103c81f20d", "messages": [{"content": "Example Prompt"}], "tags": [{"id": "tg_23abec5b-100a-4261-9ee7-1effe68f0149"}], "topic": {"id": "to_e6b8cdd3-a51b-4d94-a866-28dbe6b830a6"}, "user_location": {"country": "US"} } ] } ``` -------------------------------- ### GET /prompts/suggestions Source: https://docs.peec.ai/api-reference/project/list-prompt-suggestions Retrieves a list of prompt suggestions for a specific project, with optional filtering by topic and pagination support. ```APIDOC ## GET /prompts/suggestions ### Description List the prompt suggestions of a project. ### Method GET ### Endpoint https://api.peec.ai/customer/v1/prompts/suggestions ### Parameters #### Query Parameters - **project_id** (string) - Optional - Required if using a company api key. Example: or_f45b94ba-5e35-4982-93ed-285e72ee14eb - **topic_id** (string) - Optional - The ID of the topic to filter by. - **limit** (number) - Optional - The maximum number of items to return. Default: 1000. Range: 1-10000. - **offset** (number) - Optional - The number of items to skip. Default: 0. Minimum: 0. ### Response #### Success Response (200) - **data** (array) - A list of prompt suggestion objects. #### Response Example { "data": [ { "id": "ps_93f790de-5b7a-45ee-b782-61103c81f20d", "messages": [{"content": "What is the best SEO tool?"}], "tags": [{"id": "tg_23abec5b-100a-4261-9ee7-1effe68f0149"}], "topic": {"id": "to_e6b8cdd3-a51b-4d94-a866-28dbe6b830a6"}, "user_location": {"country": "AE"} } ] } ``` -------------------------------- ### GET /projects/data Source: https://docs.peec.ai/api-reference/project/list-fanout-search-queries Retrieves project data with support for filtering by various fields and pagination. ```APIDOC ## GET /projects/data ### Description Retrieves project data based on provided filters and pagination parameters. ### Method GET ### Endpoint /projects/data ### Parameters #### Request Body (multipart/form-data) - **project_id** (string) - Optional - Required if using a company api key. Example: or_f45b94ba-5e35-4982-93ed-285e72ee14eb - **limit** (number) - Optional - Default: 1000. Minimum: 1, Maximum: 10000 - **offset** (number) - Optional - Default: 0 ### Request Example { "project_id": "or_f45b94ba-5e35-4982-93ed-285e72ee14eb", "limit": 100, "offset": 0 } ``` -------------------------------- ### GET /projects/data Source: https://docs.peec.ai/api-reference/reports/get-brands-report Retrieves project data based on provided filters, limit, and offset parameters. ```APIDOC ## GET /projects/data ### Description Retrieves a list of project data. Supports filtering by chat_id or brand_id using 'in' or 'not_in' operators. ### Method GET ### Endpoint /projects/data ### Parameters #### Request Body - **project_id** (string) - Optional - Required if using a company api key. Example: or_f45b94ba-5e35-4982-93ed-285e72ee14eb - **limit** (number) - Optional - Default: 1000. Range: 1-10000 - **offset** (number) - Optional - Default: 0 ### Request Example { "project_id": "or_f45b94ba-5e35-4982-93ed-285e72ee14eb", "limit": 100, "offset": 0 } ``` -------------------------------- ### View Rate Limit Response Headers Source: https://docs.peec.ai/api/ratelimits Example of the standard HTTP headers returned by the API to track usage and reset times. ```http X-RateLimit-Limit: 100 X-RateLimit-Remaining: 42 X-RateLimit-Reset: 23 ``` -------------------------------- ### GET /brands Source: https://docs.peec.ai/api-reference/project/list-brands Retrieves a list of brands associated with a project. Supports pagination and project filtering. ```APIDOC ## GET /brands ### Description List the brands of a project. ### Method GET ### Endpoint /brands ### Parameters #### Query Parameters - **project_id** (string) - Optional - Required if using a company api key. Example: or_f45b94ba-5e35-4982-93ed-285e72ee14eb - **limit** (number) - Optional - Default: 1000. Minimum: 1, Maximum: 10000 - **offset** (number) - Optional - Default: 0. Minimum: 0 ### Response #### Success Response (200) - **data** (array) - List of brand objects - **id** (string) - Brand ID - **name** (string) - Brand name - **domains** (array) - List of associated domains - **is_own** (boolean) - Indicates if the brand is owned #### Response Example { "data": [ { "id": "kw_915e742b-396d-4a86-ad57-8bc84e8c2232", "name": "Peec AI", "domains": ["peec.ai"], "is_own": true } ] } ``` -------------------------------- ### OpenAPI Specification for List Topics Source: https://docs.peec.ai/api-reference/project/list-topics Defines the GET /topics endpoint, including query parameters for project filtering, pagination, and required security schemes. ```yaml openapi: 3.0.3 info: title: Peec AI Customer API description: Development documentation version: 1.0.0 contact: name: Peec AI Team email: support@peec.ai servers: - url: https://api.peec.ai/customer/v1 security: [] paths: /topics: get: tags: - Project summary: List Topics description: List the topics of a project operationId: getTopics parameters: - name: project_id in: query required: false schema: description: Required if using a company api key example: or_f45b94ba-5e35-4982-93ed-285e72ee14eb type: string - name: limit in: query required: false schema: default: 1000 type: number minimum: 1 maximum: 10000 - name: offset in: query required: false schema: default: 0 type: number minimum: 0 responses: '200': description: Success content: application/json: schema: description: Success type: object properties: data: type: array items: type: object properties: id: example: to_5524d66a-df1e-47e4-9dbc-802af39235ad type: string name: example: SEO type: string required: - id - name required: - data security: - APIKeyHeader: [] - APIKeyQuery: [] components: securitySchemes: APIKeyHeader: type: apiKey in: header name: X-API-Key APIKeyQuery: type: apiKey in: query name: api_key ``` -------------------------------- ### GET /websites/peec_ai Source: https://docs.peec.ai/api-reference/project/list-fanout-shopping-queries Retrieves a list of data entries based on specified filters. Supports filtering by prompt ID and chat ID. ```APIDOC ## GET /websites/peec_ai ### Description Retrieves a list of data entries, allowing filtering by prompt ID and chat ID. ### Method GET ### Endpoint /websites/peec_ai ### Query Parameters - **prompt.id** (string) - Optional - Filters results by prompt ID. Example: `prompt.id=in:pr_93f790de-5b7a-45ee-b782-61103c81f20d` - **chat.id** (string) - Optional - Filters results by chat ID. Example: `chat.id=in:ch_61184892-36ad-4e1a-8178-3a83608f7711` ### Request Example ```json { "example": "GET /websites/peec_ai?prompt.id=in:pr_93f790de-5b7a-45ee-b782-61103c81f20d&chat.id=in:ch_61184892-36ad-4e1a-8178-3a83608f7711" } ``` ### Response #### Success Response (200) - **data** (array) - An array of data entries. - **prompt** (object) - Information about the prompt. - **id** (string) - The unique identifier for the prompt. - **chat** (object) - Information about the chat. - **id** (string) - The unique identifier for the chat. - **model** (object) - Information about the model used. - **id** (string) - The unique identifier for the model. - **date** (string) - The date associated with the entry (YYYY-MM-DD). - **query** (object) - Details of the user's query. - **text** (string) - The text of the query. - **products** (array) - A list of products associated with the query. #### Response Example ```json { "example": { "data": [ { "prompt": { "id": "pr_93f790de-5b7a-45ee-b782-61103c81f20d" }, "chat": { "id": "ch_61184892-36ad-4e1a-8178-3a83608f7711" }, "model": { "id": "gpt-4o-search" }, "date": "2025-09-17", "query": { "text": "What is Peec?", "products": [ "Peec AI", "Peec Pro" ] } } ] } } ``` ### Security - APIKeyHeader: X-API-Key - APIKeyQuery: api_key ``` -------------------------------- ### GET /data Source: https://docs.peec.ai/api-reference/project/list-fanout-search-queries Retrieves filtered data based on prompt_id or chat_id criteria. ```APIDOC ## GET /data ### Description Retrieves a list of records filtered by specific fields such as prompt_id or chat_id using 'in' or 'not_in' operators. ### Method GET ### Endpoint /data ### Request Body - **field** (string) - Required - The field to filter by (e.g., prompt_id, chat_id) - **operator** (string) - Required - The operator to apply (in, not_in) - **values** (array) - Required - List of string values to filter against ### Response #### Success Response (200) - **data** (array) - List of objects containing prompt, chat, model, date, and query details. #### Response Example { "data": [ { "prompt": { "id": "pr_93f790de-5b7a-45ee-b782-61103c81f20d" }, "chat": { "id": "ch_61184892-36ad-4e1a-8178-3a83608f7711" }, "model": { "id": "gpt-4o-search" }, "date": "2025-09-17", "query": { "index": 0, "text": "What is Peec?" } } ] } ``` -------------------------------- ### POST /queries/shopping Source: https://docs.peec.ai/api-reference/project/list-fanout-shopping-queries Lists the fanout shopping queries for a given project. This endpoint allows filtering by date ranges and specific fields. ```APIDOC ## POST /queries/shopping ### Description List the fanout shopping queries of a project. ### Method POST ### Endpoint /queries/shopping ### Parameters #### Query Parameters - **project_id** (string) - Optional - Required if using a company api key #### Request Body - **project_id** (string) - Optional - Required if using a company api key - **limit** (number) - Optional - Default: 1000. Minimum: 1, Maximum: 10000 - **offset** (number) - Optional - Default: 0. Minimum: 0 - **start_date** (string) - Optional - full-date notation as defined by RFC 3339, section 5.6, for example, 2017-07-21. Default: '2026-01-01' - **end_date** (string) - Optional - full-date notation as defined by RFC 3339, section 5.6, for example, 2017-07-21. Default: '2026-01-01' - **filters** (array) - Optional - Filter results by specific fields. Multiple filters are AND'd together. - **field** (string) - Required - Enum: ['model_id', 'tag_id'] - **operator** (string) - Required - Enum: ['in', 'not_in'] - **values** (array) - Required - Minimum items: 1 - (string) - Enum: ['chatgpt-scraper', 'perplexity-scraper', 'google-ai-overview-scraper', 'gpt-4o-search', 'google-ai-mode-scraper', 'gemini-scraper', 'claude-sonnet-4', 'microsoft-copilot-scraper', 'claude-haiku-4.5', 'claude-3.5-haiku', 'gpt-4o', 'gpt-3.5-turbo', 'gemini-2.5-flash', 'sonar', 'deepseek-r1', 'llama-3.3-70b-instruct', 'grok-scraper', 'grok-api', 'llama-sonar'] ### Request Example ```json { "project_id": "or_f45b94ba-5e35-4982-93ed-285e72ee14eb", "limit": 1000, "offset": 0, "start_date": "2025-09-22", "end_date": "2025-09-22", "filters": [ { "field": "prompt_id", "operator": "in", "values": [ "pr_abc123" ] } ] } ``` ### Response #### Success Response (200) - **field1** (type) - Description #### Response Example ```json { "example": "response body" } ``` ``` -------------------------------- ### GET /reports Source: https://docs.peec.ai/api-reference/reports/get-urls-report Retrieves a report based on specified dimensions, date ranges, and filters. ```APIDOC ## GET /reports ### Description Retrieves a report based on specified dimensions, date ranges, and filters. Supports pagination and complex filtering logic. ### Method GET ### Endpoint /reports ### Parameters #### Query Parameters - **limit** (number) - Optional - Maximum number of records to return (default: 1000, min: 1, max: 10000) - **offset** (number) - Optional - Number of records to skip (default: 0, min: 0) - **start_date** (string) - Optional - Start date in RFC 3339 format (default: 2026-01-01) - **end_date** (string) - Optional - End date in RFC 3339 format (default: 2026-01-01) - **dimensions** (array) - Optional - Dimensions to break down the report by (e.g., prompt_id, model_id, tag_id, topic_id, date, country_code, chat_id) - **filters** (array) - Optional - Filter results by specific fields. Multiple filters are AND'd together. ``` -------------------------------- ### POST /prompts Source: https://docs.peec.ai/api-reference/project/create-prompt Creates a new prompt within a project by providing the prompt text, country code, and optional metadata. ```APIDOC ## POST /prompts ### Description Create a new prompt within a project. ### Method POST ### Endpoint /prompts ### Parameters #### Request Body - **text** (string) - Required - The content of the prompt (1-200 characters). - **country_code** (string) - Required - The ISO country code associated with the prompt. - **tag_ids** (array) - Optional - A list of tag identifiers. - **topic_id** (string) - Optional - The identifier for the topic. ### Request Example { "text": "Example prompt text", "country_code": "US", "tag_ids": ["tag1", "tag2"], "topic_id": "topic123" } ``` -------------------------------- ### POST /topics Source: https://docs.peec.ai/api-reference/project/create-topic Creates a new topic. Requires an API key for authentication. ```APIDOC ## POST /topics ### Description Creates a new topic in the system. Requires authentication via API Key. ### Method POST ### Endpoint /topics ### Parameters #### Request Body - **name** (string) - Required - The name of the topic (1-64 characters). - **country_code** (string) - Optional - ISO country code (e.g., US, GB, FR). ### Response #### Success Response (201) - **id** (string) - The unique identifier of the created topic. #### Error Response (409) - **message** (string) - Error message describing the conflict. ``` -------------------------------- ### Authenticate with HTTP Header Source: https://docs.peec.ai/api/authentication Use the `x-api-key` header to pass your API key for authentication. This method is recommended for enhanced security. ```bash curl -X GET "https://api.peec.ai/customer/v1/prompts" \ -H "x-api-key: YOUR_API_KEY" ``` -------------------------------- ### GET /chats/{chat_id}/content Source: https://docs.peec.ai/api-reference/project/get-chat Retrieves the full content of a specific chat session by its unique identifier. ```APIDOC ## GET /chats/{chat_id}/content ### Description Get a single chat session's details including prompt, model, sources, brands mentioned, messages, queries, and products. ### Method GET ### Endpoint https://api.peec.ai/customer/v1/chats/{chat_id}/content ### Parameters #### Path Parameters - **chat_id** (string) - Required - The unique identifier of the chat. #### Query Parameters - **project_id** (string) - Optional - Required if using a company api key. ### Response #### Success Response (200) - **id** (string) - The chat ID. - **prompt** (object) - The prompt object containing an ID. - **model** (object) - The model object containing an ID. - **sources** (array) - List of sources used in the chat. - **brands_mentioned** (array) - List of brands mentioned in the chat. - **messages** (array) - List of messages with role and content. - **queries** (array) - List of search queries. - **products** (array) - List of products mentioned. #### Response Example { "id": "ch_61184892-36ad-4e1a-8178-3a83608f7711", "prompt": { "id": "pr_93f790de-5b7a-45ee-b782-61103c81f20d" }, "model": { "id": "gpt-4o-search" }, "sources": [], "brands_mentioned": [], "messages": [ { "role": "user", "content": "Example Prompt" }, { "role": "assistant", "content": "Example Response" } ], "queries": [], "products": [] } ``` -------------------------------- ### Authenticate with Query Parameter Source: https://docs.peec.ai/api/authentication Alternatively, you can include your API key as a query parameter named `api_key` in your request URL. ```bash curl -X GET "https://api.peec.ai/customer/v1/prompts?api_key=YOUR_API_KEY" ``` -------------------------------- ### POST /topics Source: https://docs.peec.ai/api-reference/project/create-topic Create a new topic within a project by providing a name and an optional country code. ```APIDOC ## POST /topics ### Description Create a new topic within a project. ### Method POST ### Endpoint https://api.peec.ai/customer/v1/topics ### Parameters #### Request Body - **name** (string) - Required - The name of the topic (1-64 characters). - **country_code** (string) - Optional - The ISO country code associated with the topic. ### Request Example { "name": "New Project Topic", "country_code": "US" } ``` -------------------------------- ### GET /websites/peec_ai/analytics Source: https://docs.peec.ai/api-reference/reports/get-domains-report Retrieves analytics data for the specified website. Supports filtering, pagination, and dimension breakdown. ```APIDOC ## GET /websites/peec_ai/analytics ### Description Retrieves analytics data for the specified website. Supports filtering, pagination, and dimension breakdown. ### Method GET ### Endpoint /websites/peec_ai/analytics ### Query Parameters - **example** (string) - Optional - Example identifier for the query. - **limit** (number) - Optional - The maximum number of results to return. Default: 1000. Minimum: 1. Maximum: 10000. - **offset** (number) - Optional - The number of results to skip. Default: 0. Minimum: 0. - **start_date** (string) - Optional - The start date for the analytics data in YYYY-MM-DD format. Default: '2026-01-01'. - **end_date** (string) - Optional - The end date for the analytics data in YYYY-MM-DD format. Default: '2026-01-01'. - **dimensions** (array) - Optional - Dimensions to break down the report by. Possible values: `prompt_id`, `model_id`, `tag_id`, `topic_id`, `date`, `country_code`, `chat_id`. - **filters** (array) - Optional - Filter results by specific fields. Multiple filters are AND'd together. Example: `[{ "field": "domain", "operator": "in", "values": ["example.com"] }]`. ### Request Example ```json { "example": "or_f45b94ba-5e35-4982-93ed-285e72ee14eb", "limit": 100, "offset": 0, "start_date": "2025-01-01", "end_date": "2025-12-31", "dimensions": ["model_id", "country_code"], "filters": [ { "field": "domain", "operator": "in", "values": ["example.com"] }, { "field": "model_id", "operator": "in", "values": ["gpt-4o", "gemini-2.5-flash"] } ] } ``` ### Response #### Success Response (200) - **data** (array) - Array of analytics data objects. - **total** (number) - Total number of results. - **limit** (number) - The limit applied to the results. - **offset** (number) - The offset applied to the results. #### Response Example ```json { "data": [ { "model_id": "gpt-4o", "country_code": "US", "count": 150 }, { "model_id": "gemini-2.5-flash", "country_code": "US", "count": 120 } ], "total": 2, "limit": 100, "offset": 0 } ``` ``` -------------------------------- ### POST /queries/search Source: https://docs.peec.ai/api-reference/project/list-fanout-search-queries Lists the fanout search queries of a project. This endpoint allows you to retrieve search query data associated with a specific project, with options to filter and paginate the results. ```APIDOC ## POST /queries/search ### Description List the fanout search queries of a project. ### Method POST ### Endpoint https://api.peec.ai/customer/v1/queries/search ### Parameters #### Query Parameters - **project_id** (string) - Optional - Required if using a company api key #### Request Body - **project_id** (string) - Optional - Required if using a company api key - **limit** (number) - Optional - Default: 1000. Minimum: 1, Maximum: 10000 - **offset** (number) - Optional - Default: 0. Minimum: 0 - **start_date** (string) - Optional - full-date notation as defined by RFC 3339, section 5.6, for example, 2017-07-21. Default: '2026-01-01'. - **end_date** (string) - Optional - full-date notation as defined by RFC 3339, section 5.6, for example, 2017-07-21. Default: '2026-01-01'. - **filters** (array) - Optional - Filter results by specific fields. Multiple filters are AND'd together. - **field** (string) - Required - Enum: ['model_id', 'tag_id'] - **operator** (string) - Required - Enum: ['in', 'not_in'] - **values** (array) - Required - Minimum items: 1 - (string) - Enum: ['chatgpt-scraper', 'perplexity-scraper', 'google-ai-overview-scraper', 'gpt-4o-search', 'google-ai-mode-scraper', 'gemini-scraper', 'claude-sonnet-4', 'microsoft-copilot-scraper', 'claude-haiku-4.5', 'claude-3.5-haiku', 'gpt-4o', 'gpt-3.5-turbo', 'gemini-2.5-flash', 'sonar', 'deepseek-r1', 'llama-3.3-70b-instruct', 'grok-scraper', 'grok-api', 'llama-sonar'] ### Request Example ```json { "project_id": "or_f45b94ba-5e35-4982-93ed-285e72ee14eb", "limit": 100, "start_date": "2025-01-01", "end_date": "2025-12-31", "filters": [ { "field": "model_id", "operator": "in", "values": [ "gpt-4o", "gemini-2.5-flash" ] } ] } ``` ### Response #### Success Response (200) - **queries** (array) - List of search queries. - **query_id** (string) - Unique identifier for the query. - **project_id** (string) - Identifier for the project. - **prompt** (string) - The user's prompt. - **model_id** (string) - The model used for the query. - **created_at** (string) - Timestamp when the query was created. - **tags** (array) - List of tags associated with the query. - (string) #### Response Example ```json { "queries": [ { "query_id": "qu_abcdef123456", "project_id": "or_f45b94ba-5e35-4982-93ed-285e72ee14eb", "prompt": "What is the capital of France?", "model_id": "gpt-4o", "created_at": "2023-10-27T10:00:00Z", "tags": ["geography", "europe"] } ] } ``` ``` -------------------------------- ### GET /websites/peec_ai/analytics Source: https://docs.peec.ai/api-reference/reports/get-domains-report Retrieves website analytics data for the specified website. You can filter and break down the data by various dimensions. ```APIDOC ## GET /websites/peec_ai/analytics ### Description Retrieves website analytics data. Allows filtering and breakdown by specified dimensions. ### Method GET ### Endpoint /websites/peec_ai/analytics ### Parameters #### Query Parameters - **start_date** (string) - Optional - The start date for the analytics report (YYYY-MM-DD). - **end_date** (string) - Optional - The end date for the analytics report (YYYY-MM-DD). - **dimensions** (array of strings) - Optional - Dimensions to break down the report by. Possible values: `prompt_id`, `model_id`, `tag_id`, `topic_id`, `date`, `country_code`, `chat_id`. - **filters** (array of objects) - Optional - Filter results by specific fields. Multiple filters are AND'd together. - **field** (string) - Required - The field to filter on. Possible values depend on the operator. - **operator** (string) - Required - The operator to use for filtering. Possible values: `in`, `not_in`. - **values** (array of strings) - Required - The values to filter by. ### Request Example ```json { "start_date": "2024-01-01", "end_date": "2024-01-31", "dimensions": ["model_id", "tag_id"], "filters": [ { "field": "model_id", "operator": "in", "values": ["gpt-4o", "claude-3.5-haiku"] }, { "field": "tag_id", "operator": "not_in", "values": ["example-tag"] } ] } ``` ### Response #### Success Response (200) - **date** (string) - The date of the data point. - **model_id** (string) - The ID of the model used. - **tag_id** (string) - The ID of the tag associated with the data. - **prompt_id** (string) - The ID of the prompt. - **topic_id** (string) - The ID of the topic. - **country_code** (string) - The country code. - **chat_id** (string) - The ID of the chat. - **metrics** (object) - Contains various performance metrics. - **impressions** (integer) - Number of impressions. - **clicks** (integer) - Number of clicks. - **conversions** (integer) - Number of conversions. #### Response Example ```json { "data": [ { "date": "2024-01-15", "model_id": "gpt-4o", "tag_id": "news", "prompt_id": "p123", "topic_id": "t456", "country_code": "US", "chat_id": "c789", "metrics": { "impressions": 1500, "clicks": 300, "conversions": 15 } } ] } ``` ``` -------------------------------- ### Create Prompt Source: https://docs.peec.ai/api-reference/project/create-prompt This endpoint allows users to create new prompts. It supports both JSON and multipart/form-data requests. ```APIDOC ## POST /websites/peec_ai/prompts ### Description Creates a new prompt with the provided text, country code, and optional tag IDs and topic ID. ### Method POST ### Endpoint /websites/peec_ai/prompts ### Parameters #### Request Body ##### JSON Body - **text** (string) - Required - The content of the prompt. - **country_code** (string) - Required - The country code for the prompt. Must be one of the allowed enum values. - **tag_ids** (array of strings) - Optional - A list of tag IDs associated with the prompt. - **topic_id** (string) - Optional - The ID of the topic the prompt belongs to. ##### Multipart Form Data - **text** (string) - Required - The content of the prompt. Min length: 1, Max length: 200. - **country_code** (string) - Required - The country code for the prompt. Must be one of the allowed enum values. - **tag_ids** (array of strings) - Optional - A list of tag IDs associated with the prompt. - **topic_id** (string) - Optional - The ID of the topic the prompt belongs to. ### Request Example ```json { "text": "What are the latest trends in AI?", "country_code": "US", "tag_ids": ["ai", "trends"], "topic_id": "topic_123" } ``` ### Response #### Success Response (201) - **id** (string) - The unique identifier of the created prompt. #### Response Example ```json { "id": "pr_93f790de-5b7a-45ee-b782-61103c81f20d" } ``` #### Error Response (402) - **message** (string) - Error message indicating a payment-related issue. #### Error Response (409) - **message** (string) - Error message indicating a conflict, likely due to duplicate content. ``` -------------------------------- ### POST /tags Source: https://docs.peec.ai/api-reference/project/create-tag Create a new tag within a project by specifying a name and an optional color. ```APIDOC ## POST /tags ### Description Create a new tag within a project. ### Method POST ### Endpoint /tags ### Request Body - **name** (string) - Required - The name of the tag (minimum length 1). - **color** (string) - Optional - The color of the tag. Defaults to 'gray'. Available options: gray, red, orange, yellow, lime, green, cyan, blue, purple, fuchsia, pink, emerald, amber, violet, indigo, teal, sky, rose, slate, zinc, neutral, stone. ### Request Example { "name": "Urgent", "color": "red" } ### Response #### Success Response (201) - **id** (string) - The unique identifier of the created tag. #### Response Example { "id": "tg_23abec5b-100a-4261-9ee7-1effe68f0149" } ``` -------------------------------- ### GET /chats Source: https://docs.peec.ai/api-reference/project/list-chats Retrieves a list of chats associated with a specific project, with support for filtering by date, model, and other parameters. ```APIDOC ## GET /chats ### Description List the chats of a project. ### Method GET ### Endpoint /chats ### Parameters #### Query Parameters - **project_id** (string) - Optional - Required if using a company api key - **limit** (number) - Optional - Default: 1000, Min: 1, Max: 10000 - **offset** (number) - Optional - Default: 0, Min: 0 - **start_date** (string) - Optional - Format: date, Default: 2026-01-01 - **end_date** (string) - Optional - Format: date, Default: 2026-01-01 - **brand_id** (string) - Optional - **prompt_id** (string) - Optional - **model_id** (string) - Optional - Enum: chatgpt-scraper, perplexity-scraper, google-ai-overview-scraper, gpt-4o-search, google-ai-mode-scraper, gemini-scraper, claude-sonnet-4, microsoft-copilot-scraper, claude-haiku-4.5, claude-3.5-haiku, gpt-4o, gpt-3.5-turbo, gemini-2.5-flash, sonar, deepseek-r1, llama-3.3-70b-instruct, grok-scraper, grok-api, llama-sonar ### Response #### Success Response (200) - **data** (array) - List of chat objects #### Response Example { "data": [ { "id": "ch_61184892-36ad-4e1a-8178-3a83608f7711", "prompt": { "id": "pr_93f790de-5b7a-45ee-b782-61103c81f20d" }, "model": { "id": "gpt-4o-search" }, "date": "2025-09-17" } ] } ``` -------------------------------- ### Documentation Index Source: https://docs.peec.ai/api-reference/project/list-chats Fetch the complete documentation index to discover all available API pages. ```APIDOC ## GET /websites/peec_ai/docs ### Description Fetch the complete documentation index for the Peec.ai API. ### Method GET ### Endpoint /websites/peec_ai/docs ### Query Parameters - **file** (string) - Optional - Specifies the documentation file to fetch. Defaults to 'llms.txt'. ``` -------------------------------- ### Authentication Methods Source: https://docs.peec.ai/api-reference/project/create-prompt The Peec AI API supports authentication via API Key, which can be provided either in the header or as a query parameter. ```APIDOC ## Authentication ### API Key Header - **Name**: `X-API-Key` - **Type**: apiKey - **Location**: header ### API Key Query Parameter - **Name**: `api_key` - **Type**: apiKey - **Location**: query ``` -------------------------------- ### POST /prompts/suggestions/{prompt_suggestion_id}/accept Source: https://docs.peec.ai/api-reference/project/accept-prompt-suggestion Accepts a prompt suggestion by its unique ID, which results in the creation of a new prompt. ```APIDOC ## POST /prompts/suggestions/{prompt_suggestion_id}/accept ### Description Accept a prompt suggestion by ID, creating a new prompt from it. ### Method POST ### Endpoint https://api.peec.ai/customer/v1/prompts/suggestions/{prompt_suggestion_id}/accept ### Parameters #### Path Parameters - **prompt_suggestion_id** (string) - Required - The unique identifier of the prompt suggestion to accept. ### Response #### Success Response (200) - **id** (string) - The ID of the newly created prompt. #### Response Example { "id": "pr_93f790de-5b7a-45ee-b782-61103c81f20d" } ``` -------------------------------- ### List Topic Suggestions Source: https://docs.peec.ai/api-reference/project/list-topic-suggestions Retrieve a list of topic suggestions for a specific project. This endpoint is useful for understanding the available topics within a project context. ```APIDOC ## GET /topics/suggestions ### Description List the topic suggestions of a project. ### Method GET ### Endpoint /topics/suggestions ### Parameters #### Query Parameters - **project_id** (string) - Optional - Required if using a company api key - **limit** (number) - Optional - Default: 1000. Minimum: 1. Maximum: 10000. - **offset** (number) - Optional - Default: 0. Minimum: 0. ### Request Example ```json { "example": "" } ``` ### Response #### Success Response (200) - **data** (array) - An array of topic suggestions, where each item contains an 'id' and 'name'. - **id** (string) - Example: to_5524d66a-df1e-47e4-9dbc-802af39235ad - **name** (string) - Example: SEO #### Response Example ```json { "data": [ { "id": "to_5524d66a-df1e-47e4-9dbc-802af39235ad", "name": "SEO" } ] } ``` ``` -------------------------------- ### POST /brands Source: https://docs.peec.ai/api-reference/project/create-brand Create a new brand within a project by providing the brand name and optional configuration details. ```APIDOC ## POST /brands ### Description Create a new brand within a project. ### Method POST ### Endpoint /brands ### Parameters #### Request Body - **name** (string) - Required - The name of the brand. - **domains** (array) - Optional - List of domains associated with the brand. - **regex** (string) - Optional - Regex pattern for the brand. - **aliases** (array) - Optional - List of aliases for the brand. ### Request Example { "name": "My Brand", "domains": ["example.com"], "regex": "^example\\.com$", "aliases": ["brand-alias"] } ### Response #### Success Response (201) - **id** (string) - The unique identifier of the created brand. #### Response Example { "id": "kw_915e742b-396d-4a86-ad57-8bc84e8c2232" } ```