Build with AI
The API ships a machine-readable OpenAPI spec. Hand that spec to an AI assistant (Cursor, Claude Code, GitHub Copilot, ChatGPT, Claude) and it can read every endpoint, schema, and auth requirement, then write the integration code for you. No copying request shapes by hand.
The spec URL
This is the one thing your assistant needs. It's the same contract that powers the API Reference, kept in sync automatically.
Two other machine-readable summaries are also published, useful for assistants that prefer plain text over a full OpenAPI document:
That spec lists only the partner-facing endpoints. Everything an assistant needs to call the API is in it:
- Base URL:
https://api.valleyinsllc.com/api/v1 - Auth: a
PartnerKeyheader on every request (see Authentication) - Resources: quote calculations, filing states and rates, filings, invoices
Your key is a secret. Give the assistant the spec URL, not your key. When
it writes code, have it read the key from an environment variable
(PARTNER_KEY), never hardcoded, never in chat history.
Coding assistants
The workflow is the same everywhere: give the assistant the spec, then describe the integration you want.
Cursor
Add the spec as a documentation source so it's available to the model:
- Settings → Features → Docs → Add new doc, paste the spec URL above.
- In chat, reference it with
@Docsand describe what you want:
Claude Code / Copilot / other agents
Most coding agents can fetch a URL directly. Paste the spec URL into your prompt:
Because the assistant works from the real schema, the generated types and field names match the API exactly, and stay correct as you ask follow-ups ("now add the invoice lookup", "handle the error envelope", see Errors).
Asking a chat assistant directly
For a one-off, like figuring out a request shape or debugging a response, give a chat assistant (ChatGPT, Claude) the same context. A prompt that works:
If the assistant can't browse, paste the relevant slice of the spec, or copy the endpoint straight from the API Reference, which shows the request and response schema for each operation.
What's next
- Request a key in Authentication.
- Make your first call by hand in Price a policy or Submit a filing.
- Browse every resource in the API Reference.