Get started
Quickstart
Key to first live response in about five minutes. Credits are bought up front, packs from $20, or a plan from $29/mo. 1 credit = $0.01 and a call is charged only when it succeeds, so a failed call always costs nothing.
1. Create an API key
One key reaches all 39 endpoints and draws from your shared credit wallet. We store only a hash, you see the secret exactly once, right here.
Sign in
Sign in to create a key from this page, then buy credits to call it. The snippets below will pick the key up automatically.
2. Make your first call
POST /v1/sentiment is the cheapest real call (2 credits). Export your key as COMPOUND_API_KEY and run any of these, if you just minted a key above, it's already substituted in.
curl https://api.thecompound.tech/v1/sentiment \
-H "Authorization: Bearer $COMPOUND_API_KEY" \
-H "Content-Type: application/json" \
-d '{"text":"Love the product but support took days to reply.","aspects":["product","support"]}'3. Read the response
Every success carries your result plus usage (what it cost, what's left) and a requestId you can quote at us. Only successful calls are billed, a failure costs nothing.
{
"sentiment": "neutral",
"score": 0.1,
"confidence": 0.88,
"aspects": [
{
"aspect": "product",
"sentiment": "positive",
"score": 0.8
},
{
"aspect": "support",
"sentiment": "negative",
"score": -0.6
}
],
"themes": [
"slow support response"
],
"usage": {
"credits": 2,
"balanceRemaining": 476
}
}