Make & Zapier Setup
Both Make and Zapier can connect to TokenSense using an HTTP module pointed at your TokenSense endpoint. No custom app or plugin is needed — just an HTTP request with the right URL, auth header, and body.
Make setup
Add an HTTP module
In your Make scenario, add an HTTP → Make a request module.
Set the URL
Set the URL to your TokenSense endpoint followed by the path for your provider. For OpenAI-format requests:
https://api.tokensense.io/chat/completionsYour endpoint URL is shown on your dashboard home page.
Set the Authorization header
Add a header: Authorization: Bearer YOUR_TOKENSENSE_KEY. Use your TokenSense API key (not your provider key directly).
Set the request body
Set the body type to JSON and use the same format as your provider's API. For example, an OpenAI chat completion request:
{
"model": "gpt-5-mini",
"messages": [
{ "role": "user", "content": "Summarize this document..." }
]
}TokenSense detects the provider from the model name and routes automatically.
Zapier setup
Add a Webhooks by Zapier action
Use the Webhooks by Zapier → Custom Request action. The setup is the same as Make — set the URL to your TokenSense endpoint, add the Authorization header, and set the JSON body matching your provider's format.
Adding attribution
To track costs per workflow and step, add these optional headers to your HTTP request:
| Header | Purpose | Example |
|---|---|---|
x-workflow-tag | Identifies the workflow in your dashboard | lead-enrichment |
x-step | Identifies the step within the workflow | summarize |
x-execution-id | Groups requests from the same execution | exec-12345 |
x-source | Identifies the tool or platform | make |
x-project | Associates with a project | client-a |
Tip: TokenSense auto-detects Make and Zapier from the User-Agent header and tags the source field automatically. You don't need to set x-source manually — but you can override it if you want a custom value.
See Cost Attribution for more details.
Troubleshooting
| Error | Cause | Fix |
|---|---|---|
400 | Invalid request body or missing fields | Check JSON body format |
401 | Wrong or missing TokenSense API key | Check the key in your dashboard and update the Authorization header |
402 | Budget exceeded or subscription locked | Increase budget in dashboard or update billing |
403 | Missing provider key for the requested model | Add the provider key in Settings → Providers |
429 | Rate limit exceeded (tiered by plan) | Slow down requests, check Retry-After header |
See the full Error Codes reference for all error types.
