Skip to content
Build your own business

Partner API

Bring companies into Colby, get crews recording, and follow each company through quality review and settlement from your own software.

Base URL https://colby.ing/api/partner/v1

Make your first request

Use a signed Colby partner account. The Node.js 20+ quickstart registers a local client, opens a loopback listener, and gives you a link to authorize in your browser. It reads your workspace ID and role, then revokes its grant.

curl -fsS https://colby.ing/api/partner/v1/examples/quickstart.mjs -o colby-partner-quickstart.mjs
node colby-partner-quickstart.mjs

For an existing integration, make the same identity request with your current access token. Use a product User-Agent so Colby can identify your service.

curl --fail-with-body https://colby.ing/api/partner/v1/me \
  -H "Authorization: Bearer $COLBY_ACCESS_TOKEN" \
  -H "User-Agent: FieldOperations/1.0"

Authenticate your integration

  1. Register your client with your approved HTTPS callback or a local HTTP loopback callback. Store the returned client ID. Confidential clients also receive a secret.
  2. For each login, generate a cryptographically random state and PKCE verifier. Compute the unpadded base64url SHA-256 challenge. Store the verifier and state for that login. Then open the authorize URL with scope=partner.lifecycle, resource=https://colby.ing/api/partner/v1 and code_challenge_method=S256.
  3. Validate the returned state and iss=https://colby.ing at your callback. Exchange the code within five minutes using the original verifier. Access tokens last one hour. Refresh tokens rotate and expire after 30 days of disuse. Store each new pair atomically and serialize refreshes for a connection.
  4. Read your workspace permissions. Check permissions.request_agreements before offering to request a company agreement. It is true only for an owner whose workspace enables that action. Owners can also request closure, manage webhooks and read settlement. Team seats can operate permitted company and crew resources. Company access follows current referral credit.

Discovery is available through the resource metadata and issuer metadata. The Claude and ChatGPT connector uses its own resource and scope.

Onboard a company

Choose a stable ID from your system. Before creating a registration, look it up with GET /companies?external_id=field-104. The example below creates a real pipeline record when sent with an authorized token. Substitute your company’s details.

curl --fail-with-body https://colby.ing/api/partner/v1/companies \
  -H "Authorization: Bearer $COLBY_ACCESS_TOKEN" \
  -H "User-Agent: FieldOperations/1.0" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: register-field-104" \
  -d '{"external_id":"field-104","legal_name":"Example Field Services",
       "state":"AZ","site_lead":{"name":"Example Lead","email":"lead@example.com"}}'
  1. Keep the returned Colby ID. If GET /me returns permissions.request_agreements: true, the owner requests the company agreement. When the permission is false, check onboarding for the next action and who handles it. Registration establishes the pipeline relationship. Completed signing and verified credit establish the operating company.
  2. Read onboarding progress for the signing stage, responsible party, crew materials, next action and follow-ups. At awaiting_credit, Colby is verifying credit after signature. Continue polling. A signed, credited company receives its own reusable Minute code. Ensure enrollment and poll that resource until the code is ready. Track its delivery to the verified site contact.
  3. Order kits and read the order and individual shipments. Invite recorders in their preferred language and confirm the company kit and recorder assignment. A delivered invitation, completed setup, first linked upload and first buyer acceptance each have separate evidence.

Crew handoff materials include the kit guide, English crew guide, Spanish crew guide, accepted tasks and video acceptance criteria.

Review recordings and close feedback

  1. List attributable recordings by company, recorder, or period. Use the opaque recording ID across QA and feedback. Company and recorder assignments at capture determine attribution.
  2. Request a Jev check when needed. Poll the request ID. Read the recording for the buyer’s pending, accepted or flagged status and the separate Jev observations. Only buyer-accepted work contributes eligible hours.
  3. Create feedback with a recording ID, a recorder or site-lead recipient, and a specific adjustment. Request delivery separately. Record acknowledgement and resolve with a follow-up recording or a resolution note.
  4. Group performance by partner, company or recorder. Preserve filters when paging. Report acceptance as accepted minutes divided by accepted plus flagged minutes. An empty denominator means the crew is awaiting buyer review.

Track payments and closure

Owners can request hosted payee setup for themselves or send a verified company contact its setup notice. Read earnings for the service month, statements for locked totals and payouts for remittance progress. Currency amounts use integer minor units. A transfer and a confirmed bank deposit are separate events. Colby releases funds through its existing payment process.

Recorder allocations explain the partner’s share. Unmatched work or adjustments can remain unallocated. A late buyer decision can enter the next open batch. Track the individual payout ID across state changes.

Record kit returns and request closure. Follow receipt of the equipment and outstanding settlement. Earlier records retain their original attribution.

Handle retries and events

Send one Idempotency-Key per intended write and save X-Request-Id. If the response is lost, retry with the identical request and key. A replay can return a receipt instead of the original response. Read http_status and fetch the resource for its current state. Reusing a key with different input returns 409.

A receipt in processing is still underway. For reconcile, check the resource before taking further action. The bearer connection is limited to 300 lifecycle requests per minute, and individual actions may have lower limits. Back off on 429. For reporting lists use the documented cursor. The company directory uses after.

Poll the ordered event feed or register an HTTPS receiver on your authorized callback host. Registration starts at the current cursor. Take a resource snapshot and replay from a saved cursor to cover gaps. Store the signing secret privately.

Verify the raw POST body before parsing it. The example allows five minutes of clock skew. Persist the events by sequence and return 2xx after accepting the batch. Retries may include previously delivered events.

import { createHmac, timingSafeEqual } from "node:crypto";

export function verifyColbyWebhook(rawBody, headers, signingSecret) {
  const ts = headers.get("x-colby-timestamp");
  const signature = headers.get("x-colby-signature") || "";
  if (!/^\d+$/.test(ts || "") ||
      Math.abs(Date.now() / 1000 - Number(ts)) > 300 ||
      !/^v1=[0-9a-f]{64}$/.test(signature)) return false;

  const expected = createHmac("sha256", signingSecret)
    .update(ts + ".").update(rawBody).digest();
  return timingSafeEqual(expected, Buffer.from(signature.slice(3), "hex"));
}

Changes to watch

  • company.registered, agreement.status, company.credited and minute.enrollment tell you when to re-read registration, signing and the dedicated code. minute.code_delivery carries delivery state.
  • kit.order, kit.shipment, kit.assignment, recorder.invitation and recorder.joined track equipment and crew activation. recording.first_upload and recording.first_acceptance identify qualifying footage.
  • recording.review, qa.result, qa.request, feedback.status and coaching.delivery report review and coaching changes. Re-read the named resource for its current state.
  • followup.verify_setup flags setup or first-upload checks after delivery. followup.review_open_feedback flags unresolved coaching after the first week. Use the company ID and event type as the reminder identity and read onboarding progress for the action.
  • statement.status, payout.status and payee_setup.delivery notify authorized owners. kit_return.status, enrollment.status and closure.status track return, pause or resumption, and closure.

Subscription status shows the acknowledged cursor and failures. Ten consecutive failures pause a subscription. After fixing the receiver, register the same URL on the same grant with a fresh request key to resume from its saved cursor.

Endpoint reference

Access

Companies

Equipment

Recording and QA

Feedback

Payments

Events and retries