OpenAI supports two CostHawk integration modes.Documentation Index
Fetch the complete documentation index at: https://docs.costhawk.ai/llms.txt
Use this file to discover all available pages before exploring further.
Mode A: Admin API Sync (Recommended start)
Use an OpenAI organization admin key for low-friction reporting.- Endpoint coverage:
/v1/organization/usage/completions/v1/organization/costs
- No app code changes required
- Best for quick organization-wide visibility
Admin API Setup
Use this first for reporting coverage.
Mode B: Proxy + Wrapped Key (Advanced controls)
Use proxy routing when you need strict runtime controls and enforcement.If you are not sure whether you have a wrapped key or a CostHawk access token, read Wrapped Keys first.
Proxy URL
https://api.openai.com/v1/chat/completions.
Python (OpenAI SDK)
Node.js (OpenAI SDK)
curl
Recommended Pattern
- Start with Admin API sync for baseline visibility.
- Keep MCP enabled for assistant-native analysis and operations.
- Add proxy routing for workloads that need policy enforcement or hard-stop limits.
