Developer reference · v1
Proposal API & webhooks
Native connections, expanded API, MCP & bulk guideConnect a CRM or automation using a workspace-scoped API key. Native CRM connections, event automations, bulk creation and MCP are documented in the connection guide below.
Create an API key
A workspace owner or administrator can create a key in Integrations. Copy its secret once and store it on your server. Keys expire, can be revoked, and recheck the creator’s current workspace membership on every request. Never put a key in browser code or share a session cookie.
Authorization: Bearer ln_live_YOUR_SECRET Content-Type: application/json
Supported operations
GET /api/v1/proposals?limit=25&cursor=UUID— requiresproposals:read. Returns{data, nextCursor}. Continue using the returned cursor; maximum 100 items. Archived proposals are excluded.GET /api/v1/proposals/:id— requiresproposals:read. Returns the current draft snapshot and revision indata, limited to the key’s workspace. Premium snapshots remain incontent; canonical proposals usedocument.POST /api/v1/proposals— requiresproposals:createand current owner, admin or editor membership. Supply a stableIdempotency-Key. Create a blank draft with a name, use one of the catalog’slibrary_template_idvalues, or supply a validated canonical document or premium content snapshot. This endpoint does not run AI or publish a proposal.
POST /api/v1/proposals
Idempotency-Key: crm-opportunity-482-draft-v1
{"name":"Implementation proposal","client_name":"Example client"}Keep the same key and exact body after a timeout. Replaying returns the original proposal; changed input with the same key returns 409. A deleted proposal is not recreated by a replay. The workspace comes from the API key; a different supplied workspace is rejected.
Errors use {error:{code,message}}. Expect 401 for invalid, expired or revoked keys; 403 for scope or membership; 404 for unavailable proposal; 409 for conflicting idempotency; 422 for invalid content; 429 for rate limit; and 503 if storage is unavailable. Limit: 60 requests per minute per key. Retry 429 and transient 503 with backoff; do not change a creation key to bypass an uncertain result.
Signed outgoing webhooks
Create a public HTTPS webhook on port 443 in Integrations. Subscribe to proposal.created, proposal.updated, proposal.published, proposal.accepted, or proposal.signature_recorded. The final event describes one signature record, not all required signatures.
Payloads contain id, type, occurred_at, and data with proposal ID, workspace ID, current revision, status and published revision. No client contact details or proposal content are included. Use the scoped read API if your integration needs the current draft.
X-LightNote-Event-ID: event UUID X-LightNote-Timestamp: Unix seconds X-LightNote-Signature: v1=hex HMAC-SHA256 signed = timestamp + "." + rawRequestBody expected = HMAC_SHA256(webhookSecret, signed)
Verify the signature using the raw body and a constant-time comparison before parsing or acting. Reject timestamps more than five minutes old. Save event IDs and return a 2xx response for duplicates. Processing can be repeated and out of order; fetch the current state when needed.
Delivery is queued. Delivery latency depends on the authenticated worker schedule; run it frequently enough for your notification needs. Failures retry up to eight attempts within seven days with backoff; most 4xx responses stop retries. Redirects are refused. Private network targets are blocked and DNS is revalidated for every attempt. Integrations shows recent delivery results and allows an administrator to retry a dead delivery with the same event ID.
Rotate a secret only after coordinating the change with your receiver: queued attempts use the new secret, while an attempt already leased may still use the previous secret. Revoking a subscription stops future and unclaimed deliveries; a request already in flight may finish. Removing its creator’s administrator access also stops delivery.
CRM and Zapier setup
Use your automation platform’s generic HTTP action to call the API. For webhook triggers, use a receiver capable of verifying HMAC signatures, or place a verification service in front of the automation. Map stored proposal IDs to your CRM’s opportunity IDs. A successful proposal creation is a saved draft, not a sent proposal, accepted contract or payment.
Deployment requires the proposal, integration and governance migrations, a server-side service credential, webhook encryption key, and a scheduled delivery worker. A missing configuration returns a visible unavailable state. There are no live delivery or paid AI calls in the local verification tests.