Skip to main content

Prerequisites

  • A Scrunch workspace
  • An API key with Responses access
  • A brand ID for the brand you want to fetch responses for
The Responses API returns row-level data. It is ideal for warehouses, BI tools, audits, DE workflows, and custom analysis.
You may need to reach out to your Scrunch rep for Responses API access

Call the API

1

Set your API key

export SCRUNCH_API_KEY="your-api-key-here"
export SCRUNCH_BRAND_ID="your-brand-id"
2

Call the Responses API

This example retrieves responses for a single day (Scrunch recommends syncing by date windows).
curl "https://api.scrunchai.com/v1/$SCRUNCH_BRAND_ID/responses?start_date=2025-01-01&end_date=2025-01-02&limit=100" \
  -H "Authorization: Bearer $SCRUNCH_API_KEY" \
  -H "Accept: application/json"
Example output:
{
  "total": 128,
  "limit": 100,
  "offset": 0,
  "items": [
    {
      "id": "resp_01jk93mc9p",
      "created_at": "2025-01-01T05:12:41.000Z",
      "prompt_id": "pr_01hd8j39s",
      "prompt": "Which mattress brands are recommended for side sleepers?",
      "platform": "chatgpt",
      "brand_present": true,
      "brand_sentiment": "positive",
      "brand_position": 1,
      "response_text": "For side sleepers, the best mattresses tend to...",
      "citations": [
        {
          "url": "https://www.example.com/review",
          "title": "2024 mattress comparison",
          "source_type": "other"
        }
      ],
      "competitors": [
        { "name": "Casper", "present": true, "sentiment": "neutral" },
        { "name": "Purple", "present": true, "sentiment": "positive" }
      ],
      "tags": ["mattress", "comparison"],
      "stage": "evaluation"
    }
  ]
}
3

Paginate through responses

Use the offset parameter to retrieve subsequent batches:
curl "https://api.scrunchai.com/v1/$SCRUNCH_BRAND_ID/responses?start_date=2025-01-01&end_date=2025-01-02&limit=100&offset=100" \
  -H "Authorization: Bearer $SCRUNCH_API_KEY"

When to use the Responses API

Use the Responses API when you need:
  • Full AI-generated answers
  • Citations and source URLs used in responses
  • Per-response presence, position, sentiment
  • Competitor mentions
  • Metadata (stage, tags, topics, platform, persona)
  • Warehouse or BI-level granularity

Next steps

Responses API overview

Explore the response schema and filtering options.

[Coming soon] ETL best practices

Learn how to sync Responses into BigQuery, Snowflake, or Redshift.

Query API

Use Query for trends, aggregates, comparisons, and dashboards.