Capitol Zapier Integration

Connect Capitol to thousands of apps with Zapier. Trigger Zaps on new CRM contacts, bill status changes, roll-call votes, and Follow alerts — and write contacts back into your CRM. All endpoints are served from https://app.oneclickpolitics.com over HTTPS and authenticated with your Capitol API key. Reference for the Zapier App Directory and any direct API client.

Authentication

Every request carries your Capitol API key as a bearer token in the Authorization header. Create or find your key in the Developer portal (/developers/dashboard).

Authorization: Bearer <your API key>
Content-Type: application/json

Connection test — Zapier calls this during “Connect account” to validate the key and label the connection with your account name:

GET /api/v1/zapier/me
→ 200 { "client_id": 1, "client": "Acme", "account": "Acme Advocacy" }

Actions (write into Capitol)

POST /api/v1/contacts

Create or Update Contact. Upserts a contact (matched on email) into your account's CRM.

Body fields: email (required), first_name, last_name, phone, company_name, source.

{ "email": "jane@example.com", "first_name": "Jane", "source": "Zapier" }
→ 201 { "ok": true, "contact_id": 456, "created": true }

Triggers (REST hooks)

Triggers use Zapier’s REST-hook pattern. Turning a Zap on subscribes a target URL to one event; Capitol then POSTs that event to the URL when it happens. Deliveries are HMAC-SHA256 signed (X-Capitol-Signature) and retried with backoff.

POST   /api/v1/zapier/subscriptions   { "event": "contact.created", "target_url": "https://hooks.zapier.com/..." }  → { "id": 12 }
DELETE /api/v1/zapier/subscriptions/:id
GET    /api/v1/zapier/triggers?event=contact.created   → [ { ...sample payload... } ]

No competitor data, no confidential breakdowns, and no consent state beyond the contact's own opt-out flag is ever included in a webhook payload.