← dataPalatable™ Interactive OpenAPI explorer →

dataPalatable™ API

One call in, perspectives out: send a number (or a sentence containing one) and get back sourced, human-scale comparisons.

Base URL

https://app.datapalatable.ai/api/v1

Authentication

Anonymous calls work for trying things out. Authenticated calls get your daily quota, your library, and personalization. Get a bearer token from POST /auth/login and send it as:

Authorization: Bearer <token>

Generate perspectives

POST /perspectives — the main endpoint. Provide free text containing a number, or a structured value + unit pair.

FieldTypeNotes
textstring Free text with a number ("The data center will consume 2.7 GW"), or a question ("what is Disney's revenue?").
value + unitnumber, string Structured alternative to text (e.g. 2.7, "GW").
dimensionstring Optional hint: money, length, mass, area, volume, power, energy, population, co2_emissions, …
num_resultsint 1–4 on Free, up to 6 on Pro.
creativebool PRO AI-generated extra perspectives + AI-rewritten phrasing.

Example

curl -X POST https://app.datapalatable.ai/api/v1/perspectives \
  -H "Content-Type: application/json" \
  -d '{"text": "The data center will consume 2.7 GW of electricity"}'

Response (abridged)

{
  "input": { "value": 2.7, "unit": "GW", "dimension": "power" },
  "perspectives": [
    {
      "strategy": "rule",
      "text": "That's enough to power about 2.2 million average US homes at once.",
      "reference": { "name": "average US home electricity draw",
                     "source_url": "https://www.eia.gov/..." },
      "ratio": 2250000.0,
      "formatted_ratio": "2.2 million homes"
    },
    {
      "strategy": "proportional",
      "text": "That's about 46% the power output of the Hanul Nuclear Power Plant (5.9 GW).",
      "reference": { "name": "Hanul Nuclear Power Plant", "source_url": "..." }
    }
  ],
  "resolved": null
}
Every engine perspective carries a reference.source_url citation. Question inputs ("what is Disney's revenue?") also return a resolved object with the verified figure, its year, and its source.

Other endpoints

EndpointWhat it does
POST /share Publish a perspective as a share card page (/p/<id>) with an OG image for social previews. 5/minute.
POST /feedback Thumbs up/down on a perspective — feeds the ranking loop.
POST /auth/signup, POST /auth/login Account + bearer token.

Rate limits & quotas

Full reference

The complete, always-current schema lives in the interactive OpenAPI explorer (also as raw JSON at openapi.json).

← Back to dataPalatable™