Skip to content
Rolling out

REST API guide

Authenticate with API keys and use scopes, errors, rate limits, idempotency, pagination and the OpenAPI document.

Who can do this
The account owner makes API keys in IA Compa with a fresh two-step code. A key acts as the person who made it.
On this page

The REST API lets your other software read and change an account's CRM: contacts, companies, opportunities, pipelines, tasks, notes and tags. A key acts as the person who made it, reaches only what they can, and stops working when they lose access.

Base URL and OpenAPI

https://iac.manage.iacompa.com/api/v1
https://iac.manage.iacompa.com/api/v1/openapi.json

The OpenAPI 3.1 document is generated from the same operation list the server uses, so it can't drift.

API keys

  • A key is iac_live_ (or iac_demo_ in a demo account) followed by 43 random characters.
  • It is shown once, to the person who made it. IA Compa stores only its SHA-256 and never logs it.
  • Expiry: 30, 90 or 365 days, or never. Revoking takes effect at the next request.
  • A key is refused when it is unknown, revoked or expired, when its maker lost access, or when the account is on hold. When the plan ends, keys are paused (plan_ended), not revoked.
  • An account can hold up to 10 active keys; plans set how many apps and keys you may use (see security and limits).
Authentication header
GET /api/v1/workspace HTTP/1.1
Host: iac.manage.iacompa.com
Authorization: Bearer iac_live_…

Scopes

Key scopes
ScopeAllows
workspace:readThe account's name, features and this key's limits.
crm:readContacts, companies, opportunities, pipelines, tasks and tags.
crm:writeCreate and update contacts, companies and opportunities, move stages, add tasks and notes, apply tags. Needs crm:read.

Requests and answers

  • Bodies are application/json, at most 32 KiB, and strict: unknown fields are refused.
  • Field names are snake_case. Every id is a UUID. Times are ISO 8601 with an offset.
  • One record answers {"data": {…}}; a list answers {"data": […], "next_cursor": …}.
  • Every answer carries X-Request-Id (quote it when asking for help) and Cache-Control: no-store.
  • Updates take the version you read; if someone changed the record since, you get 409 conflict.

Pagination

Lists return 25 records by default and at most 100 (limit). Pass next_cursor back as cursor for the next page; it is null on the last page. An invalid cursor answers invalid_cursor: start again without it.

Idempotency

Writes may send Idempotency-Key (1 to 128 of A-Z a-z 0-9 _ . : -). The same key with the same request within 24 hours answers the first result again with Idempotent-Replayed: true (showing the record as it is now). The same key with a different request answers 409 idempotency_conflict.

Rate limits

REST limits
LimitValueAnswer
Requests per client address600 a minute429 rate_limited
Requests per key300 a minute429 rate_limited
Changes per key60 a minute429 rate_limited
Changes per key2,000 a day (midnight UTC)429 daily_limit_reached
Records read per key50,000 a day (midnight UTC)429 daily_limit_reached
Body size32 KiB413 body_too_large

Errors

Every error is {"error": {"code", "message", "request_id", "issues"?}}. Codes are stable; branch on code, not on message.

Error codes
CodeStatusMeaning
invalid_request400The request doesn't fit the endpoint; issues lists the paths.
invalid_json400The body isn't valid JSON.
invalid_cursor400The cursor isn't valid. Start again without it.
invalid_idempotency_key400Idempotency-Key must be 1 to 128 of A–Z a–z 0–9 _ . : -
unauthorized401No key sent. Send Authorization: Bearer <key>.
invalid_api_key401Unknown, revoked or expired key.
insufficient_scope403The key lacks the scope this endpoint needs.
key_maker_lost_access403The person who made the key can no longer use it in this account. Make a new key.
account_unavailable403The account can't be reached with a key right now (for example, on hold).
plan_ended403The account's plan has ended. Keys are paused, not revoked, and work again when a plan is chosen.
feature_off403CRM isn't turned on for this account.
access_denied403The key's maker doesn't have access to this area here.
not_allowed403A key can't do that here.
not_found404The record wasn't found (or isn't visible to the key's maker).
method_not_allowed405The endpoint doesn't take that method.
conflict409The record changed. Read it again, then retry with its current version.
idempotency_conflict409That Idempotency-Key was used for a different request.
body_too_large413The body is larger than 32 KiB.
unsupported_media_type415Send the body as application/json.
rate_limited429Too many requests. Wait Retry-After seconds.
daily_limit_reached429The key reached today's allowance. It resets at midnight UTC.
internal_error500Something went wrong. Retry with the same Idempotency-Key.
temporarily_unavailable503Not available right now. Retry with the same Idempotency-Key.
Example error
{
  "error": {
    "code": "invalid_request",
    "message": "The request doesn't fit this endpoint. See issues and the OpenAPI document.",
    "request_id": "req_…",
    "issues": [{ "path": "email", "message": "Invalid email address" }]
  }
}