# Subscription & Entitlements

## Get licenses (subscription)

> Returns the licenses associated with the current account.\
> \
> AI guidance:\
> \- Use this to determine the subscription type (\`platform\`, \`integrator\`, \`endpoint\`, \`connector\`, etc.) and high-level entitlement flags.

```json
{"openapi":"3.1.0","info":{"title":"Subscription & Entitlements","version":"1.0.0"},"servers":[{"url":"https://api.integrator.io","description":"Production (US / default region)"},{"url":"https://api.eu.integrator.io","description":"Production (EU region)"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer"}},"schemas":{"License":{"type":"object","description":"A license object representing the account's subscription plan.\n\nIMPORTANT: Every field on this object describes what the **plan entitles**\n(allows), NOT what is actually configured or in use on the account. For\nexample, `sso: true` means the plan includes SSO capability — it does not\nmean SSO is configured. To know what is actually configured, use the\nappropriate domain tools (e.g., `get_account_settings` for SSO/MFA status).\n\nLicenses may represent:\n- an account-level subscription (`type` is `integrator`, `platform`, or `endpoint`)\n- a connector-specific license (`type` is `connector`, includes `_connectorId` / `_integrationId`)","properties":{"_id":{"type":"string","format":"objectId","readOnly":true,"description":"License identifier."},"created":{"type":"string","format":"date-time","readOnly":true,"description":"License creation timestamp."},"lastModified":{"type":"string","format":"date-time","readOnly":true,"description":"Last modification timestamp."},"expires":{"type":"string","format":"date-time","description":"License expiration timestamp."},"type":{"type":"string","description":"License type (subscription category).\n\nValues: `integrator`, `platform`, `endpoint`, `connector`.\n\nOnly the account-level license (non-connector) describes the\nsubscription plan. Connector licenses are per-integration-app."},"tier":{"type":"string","description":"Subscription tier name — the plan level the account is on.\n\nExamples: `free`, `standard`, `professional`, `enterprise`,\n`enterprise (2024)`."},"supportTier":{"type":"string","description":"Support plan level.\n\nExamples: `essential`, `preferred`, `premier`."},"trialEndDate":{"type":"string","format":"date-time","description":"Trial end timestamp (present only for trial accounts)."},"_connectorId":{"type":"string","format":"objectId","description":"Connector id — present only on connector-specific licenses."},"_integrationId":{"type":"string","format":"objectId","description":"Integration id — present only on connector-specific licenses."},"opts":{"type":"object","description":"Connector/license options (connector edition, add-on licenses, etc.). Present only on connector-specific licenses."},"endpoint":{"type":"object","description":"Entitlements for endpoint-style licenses. Present only when `type` is `endpoint`.","properties":{"production":{"$ref":"#/components/schemas/LicenseEntitlementCounts"},"numEnvironments":{"type":"number","description":"Maximum number of environments the plan allows."}}},"integrator":{"type":"object","description":"Entitlements for integrator-style licenses. Present only when `type` is `integrator`.","properties":{"production":{"$ref":"#/components/schemas/LicenseEntitlementCounts"},"numEnvironments":{"type":"number","description":"Maximum number of environments the plan allows."}}},"platform":{"type":"object","description":"Entitlements for platform-style licenses. Present only when `type` is `platform`.","properties":{"production":{"$ref":"#/components/schemas/LicenseEntitlementCounts"},"numEnvironments":{"type":"number","description":"Maximum number of environments the plan allows."}}},"sso":{"type":"boolean","description":"Whether the plan entitles the account to use SSO (Single Sign-On)."},"van":{"type":"boolean","description":"Whether the plan entitles the account to use VAN (Value Added Network) for EDI."},"lookupCache":{"type":"boolean","description":"Whether the plan entitles the account to use Lookup Caches (in-memory lookups)."},"abstractFlows":{"type":"boolean","description":"Whether the plan entitles the account to use Abstract Flows (multi-instance templates)."},"apiManagement":{"type":"boolean","description":"Whether the plan entitles the account to use API Management (APIM)."},"concurrency":{"type":"number","description":"Maximum number of concurrent flow executions the plan allows."},"maxAllowedDataRetention":{"type":"number","description":"Maximum data retention period (in days) the plan allows."},"auditLogRetentionYears":{"type":"number","description":"Maximum audit log retention (in years) the plan allows."},"aiConversationsPrepaidBalance":{"type":"number","description":"Remaining prepaid credit balance for Ora (Celigo's AI assistant).\nCustomers purchase credits up front and usage costs are deducted\nas they interact with Ora."},"aiAgentsPrepaidBalance":{"type":"number","description":"Remaining prepaid credit balance for AI Agents — LLM/AI capabilities\nused within flows, APIs, and automations (e.g., AI-powered transforms,\nhooks). Customers purchase credits up front and usage costs are\ndeducted as AI agents run. This balance is separate from Ora credits."},"api":{"type":"object","description":"API Builder plan entitlements and invocation limits.","properties":{"builder":{"type":"boolean","description":"Whether the plan entitles the account to use API Builder (building custom HTTP APIs on the Celigo platform)."},"numInvocations":{"type":"number","description":"Base number of API calls per month included with the plan."},"apimNumInvocations":{"type":"number","description":"Base number of APIM API calls per month included with the plan."},"numAddOnInvocations":{"type":"number","description":"Additional API calls per month the customer purchased as add-ons."}}},"edi":{"type":"object","description":"EDI (Electronic Data Interchange) plan entitlements.","properties":{"enabled":{"type":"boolean","description":"Whether the plan entitles the account to use EDI (B2B Manager)."},"tier":{"type":"string","description":"B2B Manager subscription tier. Determines base limits for trading\npartners, document types, and VAN service.\n\nValues:\n- `free` — 1 trading partner, 5 document types, no VAN service\n- `basic` — 3 trading partners, 5 document types, up to 1000 VDU/mo VAN\n- `advanced` — 10 trading partners, 5 document types, up to 1000 VDU/mo VAN\n- `expert` — 25 trading partners, 5 document types, up to 1000 VDU/mo VAN\n\nTrading partner count is based on unique EDI Profile IDs in active flows.\nDocument types are counted by normalized category (e.g., all \"Purchase Order\"\nvariations count as one; EDI 997 Functional Acknowledgements are excluded).\nCustomers can purchase add-on packs for additional trading partners and\ndocument types beyond the base tier."},"numTradingPartners":{"type":"number","description":"Base number of EDI trading partners included with the plan."},"numAddOnTradingPartners":{"type":"number","description":"Additional EDI trading partners the customer purchased as add-ons."},"numDocumentTypes":{"type":"number","description":"Base number of EDI document types included with the plan."},"numAddOnDocumentTypes":{"type":"number","description":"Additional EDI document types the customer purchased as add-ons."}}},"logging":{"type":"object","description":"Execution logging plan entitlements.","properties":{"enabled":{"type":"boolean","description":"Whether the plan entitles the account to use execution logging."},"maxLogMode":{"type":"string","description":"Maximum logging detail level the plan allows.\n\nValues: `brief`, `detailed`."},"maxDebugDuration":{"type":"number","description":"Maximum time (in minutes) the plan allows a user to enable debug logging for."},"maxRetentionPeriod":{"type":"number","description":"Maximum execution log retention period (in days) the plan allows."}}}}},"LicenseEntitlementCounts":{"type":"object","description":"Entitlement counts for a given environment.\n\nFor each resource type there are two fields:\n- `num*` — the base count included with the plan. A value of 0 means\n  the plan does not include a base allocation (the customer may still\n  have capacity via add-ons), or the limit is contract-based / unlimited.\n- `numAddOn*` — additional capacity purchased as add-ons on top of\n  the base plan.","properties":{"numEndpoints":{"type":"number","description":"Base number of endpoints included with the plan."},"numAddOnEndpoints":{"type":"number","description":"Additional endpoints the customer purchased as add-ons."},"numFlows":{"type":"number","description":"Base number of flows included with the plan."},"numAddOnFlows":{"type":"number","description":"Additional flows the customer purchased as add-ons."},"numTradingPartners":{"type":"number","description":"Base number of trading partners included with the plan."},"numAddOnTradingPartners":{"type":"number","description":"Additional trading partners the customer purchased as add-ons."},"numAgents":{"type":"number","description":"Base number of on-premise agents included with the plan."},"numAddOnAgents":{"type":"number","description":"Additional on-premise agents the customer purchased as add-ons."}}}},"responses":{"401-unauthorized":{"description":"Unauthorized. The request lacks a valid bearer token, or the provided token\nfailed to authenticate.\n\nNote: the 401 response is produced by the auth middleware **before** the\nrequest reaches the endpoint handler, so it does **not** follow the\nstandard `{errors: [...]}` envelope. Instead the body is a bare\n`{message: string}` object with no `code`, no `errors` array. Callers\nhandling 401s should key off the HTTP status and the `message` string,\nnot try to destructure an `errors[]`.","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string","description":"Human-readable description of the auth failure. Known values:\n- `\"Unauthorized\"` — no `Authorization` header on the request.\n- `\"Bearer Authentication Failed\"` — header present but token\n  is invalid, revoked, or expired."}},"required":["message"]}}}}}},"paths":{"/v1/licenses":{"get":{"summary":"Get licenses (subscription)","operationId":"getLicenses","tags":["Subscription & Entitlements"],"description":"Returns the licenses associated with the current account.\n\nAI guidance:\n- Use this to determine the subscription type (`platform`, `integrator`, `endpoint`, `connector`, etc.) and high-level entitlement flags.","responses":{"200":{"description":"List of licenses","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/License"}}}}},"401":{"$ref":"#/components/responses/401-unauthorized"}}}}}}
```

## Get license entitlement usage

> Returns entitlement usage for the current account/license.\
> \
> The response includes counts such as:\
> \- endpoints consumed\
> \- flows enabled\
> \- agents active\
> \- trading partners consumed\
> \- environments enabled (for multi-environment licensing)

```json
{"openapi":"3.1.0","info":{"title":"Subscription & Entitlements","version":"1.0.0"},"servers":[{"url":"https://api.integrator.io","description":"Production (US / default region)"},{"url":"https://api.eu.integrator.io","description":"Production (EU region)"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer"}},"schemas":{"LicenseEntitlementUsage":{"type":"object","description":"Entitlement usage information for the account/license.\n\nThe response is a flat object keyed by usage category (verified live 2026-04-24).","properties":{"flowUsage":{"$ref":"#/components/schemas/FlowUsage"},"endpointUsage":{"$ref":"#/components/schemas/EndpointUsage"},"agentUsage":{"$ref":"#/components/schemas/AgentUsage"},"environmentUsage":{"$ref":"#/components/schemas/EnvironmentUsage"},"ediTradingPartnerUsage":{"$ref":"#/components/schemas/EDITradingPartnerUsage"},"ediDocumentTypeUsage":{"$ref":"#/components/schemas/EDIDocumentTypeUsage"},"apiUsage":{"type":"object","description":"API invocation counts for the current billing period.","properties":{"ioInvocationCount":{"type":"number","description":"Number of integrator.io API invocations."},"apimInvocationCount":{"type":"number","description":"Number of APIM (API Management add-on) invocations."}}},"syncUsage":{"type":"object","description":"Sync-volume entitlement usage.","properties":{"entitlement":{"type":"number","description":"Provisioned sync entitlement."},"volume":{"type":"number","description":"Sync volume consumed against the entitlement."}}},"mcpUsage":{"type":"object","description":"MCP server invocation counts.","properties":{"numInvocations":{"type":"number","description":"Number of MCP invocations for the current period."}}},"aiAgentsActionsUsage":{"type":"number","description":"Number of AI agent actions consumed for the current period."}}},"FlowUsage":{"type":"object","description":"Flow entitlement usage.","properties":{"numEnabled":{"type":"number","description":"Number of enabled flows."},"flows":{"type":"array","description":"List of flows contributing to usage (if provided).","items":{"type":"object","properties":{"_id":{"type":"string","format":"objectId","description":"Flow id."},"integration":{"type":"object","description":"Parent integration summary (if provided).","properties":{"name":{"type":"string","description":"Integration name."}}}}}}}},"EndpointUsage":{"type":"object","description":"Endpoint entitlement usage.","properties":{"numConsumed":{"type":"number","description":"Number of endpoints currently consumed."},"endpoints":{"type":"array","description":"Detailed breakdown of endpoints by type (if provided).","items":{"type":"object","properties":{"type":{"type":"string","description":"Endpoint type/category."},"connections":{"type":"array","description":"Connections contributing to endpoint usage.","items":{"type":"object","properties":{"_id":{"type":"string","format":"objectId","description":"Connection id."}}}}}}}}},"AgentUsage":{"type":"object","description":"Agent entitlement usage.","properties":{"numActive":{"type":"number","description":"Number of active agents."},"agents":{"type":"array","description":"List of agents contributing to usage (if provided).","items":{"type":"object","properties":{"_id":{"type":"string","format":"objectId","description":"Agent id."},"name":{"type":"string","description":"Agent name."}}}}}},"EnvironmentUsage":{"type":"object","description":"Environment entitlement usage (multi-environment licensing).","properties":{"numEnabled":{"type":"number","description":"Number of enabled environments."},"environments":{"type":"array","description":"List of environments contributing to usage (if provided).","items":{"type":"object","properties":{"_id":{"type":"string","format":"objectId","description":"Environment id."},"name":{"type":"string","description":"Environment name."},"_userId":{"type":"string","format":"objectId","description":"Owner user id (if provided)."},"_envUserId":{"type":"string","format":"objectId","description":"Environment user id (if provided)."},"enabled":{"type":"boolean","description":"Whether the environment is enabled."}}}}}},"EDITradingPartnerUsage":{"type":"object","description":"EDI trading partner entitlement usage (EDI add-on/licensing).","properties":{"numConsumed":{"type":"number","description":"Number of EDI trading partners consumed."}}},"EDIDocumentTypeUsage":{"type":"object","description":"EDI document type entitlement usage (EDI add-on/licensing).","properties":{"numConsumed":{"type":"number","description":"Number of EDI document types consumed."}}}},"responses":{"401-unauthorized":{"description":"Unauthorized. The request lacks a valid bearer token, or the provided token\nfailed to authenticate.\n\nNote: the 401 response is produced by the auth middleware **before** the\nrequest reaches the endpoint handler, so it does **not** follow the\nstandard `{errors: [...]}` envelope. Instead the body is a bare\n`{message: string}` object with no `code`, no `errors` array. Callers\nhandling 401s should key off the HTTP status and the `message` string,\nnot try to destructure an `errors[]`.","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string","description":"Human-readable description of the auth failure. Known values:\n- `\"Unauthorized\"` — no `Authorization` header on the request.\n- `\"Bearer Authentication Failed\"` — header present but token\n  is invalid, revoked, or expired."}},"required":["message"]}}}}}},"paths":{"/v1/licenseEntitlementUsage":{"get":{"summary":"Get license entitlement usage","operationId":"getLicenseEntitlementUsage","tags":["Subscription & Entitlements"],"description":"Returns entitlement usage for the current account/license.\n\nThe response includes counts such as:\n- endpoints consumed\n- flows enabled\n- agents active\n- trading partners consumed\n- environments enabled (for multi-environment licensing)","responses":{"200":{"description":"Entitlement usage","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LicenseEntitlementUsage"}}}},"401":{"$ref":"#/components/responses/401-unauthorized"}}}}}}
```

## Get historical monthly entitlement usage

> Returns historical monthly usage for accounts on flow-run pricing models (primarily platform licenses).\
> \
> AI guidance:\
> \- Use this for trend analysis (month-by-month usage vs allocation).

```json
{"openapi":"3.1.0","info":{"title":"Subscription & Entitlements","version":"1.0.0"},"servers":[{"url":"https://api.integrator.io","description":"Production (US / default region)"},{"url":"https://api.eu.integrator.io","description":"Production (EU region)"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer"}},"schemas":{"MonthlyUsage":{"type":"object","description":"Month-by-month usage vs allocation.","properties":{"year":{"type":"integer","description":"The year of the usage data."},"month":{"type":"integer","description":"The month of the usage data (1-12)."},"usage":{"type":"object","description":"Actual usage numbers for the month.","properties":{"flows":{"type":"integer"},"endpoints":{"type":"integer"},"agents":{"type":"integer"}}},"allocated":{"type":"object","description":"Allocated/entitled numbers for the month.","properties":{"flows":{"type":"integer"},"endpoints":{"type":"integer"},"agents":{"type":"integer"}}}}}},"responses":{"401-unauthorized":{"description":"Unauthorized. The request lacks a valid bearer token, or the provided token\nfailed to authenticate.\n\nNote: the 401 response is produced by the auth middleware **before** the\nrequest reaches the endpoint handler, so it does **not** follow the\nstandard `{errors: [...]}` envelope. Instead the body is a bare\n`{message: string}` object with no `code`, no `errors` array. Callers\nhandling 401s should key off the HTTP status and the `message` string,\nnot try to destructure an `errors[]`.","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string","description":"Human-readable description of the auth failure. Known values:\n- `\"Unauthorized\"` — no `Authorization` header on the request.\n- `\"Bearer Authentication Failed\"` — header present but token\n  is invalid, revoked, or expired."}},"required":["message"]}}}}}},"paths":{"/v1/historicalMonthlyUsage":{"get":{"summary":"Get historical monthly entitlement usage","operationId":"getHistoricalMonthlyUsage","tags":["Subscription & Entitlements"],"description":"Returns historical monthly usage for accounts on flow-run pricing models (primarily platform licenses).\n\nAI guidance:\n- Use this for trend analysis (month-by-month usage vs allocation).","responses":{"200":{"description":"Historical monthly usage","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/MonthlyUsage"}}}}},"401":{"$ref":"#/components/responses/401-unauthorized"}}}}}}
```

## Get usage records (legacy)

> Returns historical usage records for the current account (legacy usage series).\
> \
> The response is an array of monthly records with a duration field (\`milliseconds\`).

```json
{"openapi":"3.1.0","info":{"title":"Subscription & Entitlements","version":"1.0.0"},"servers":[{"url":"https://api.integrator.io","description":"Production (US / default region)"},{"url":"https://api.eu.integrator.io","description":"Production (EU region)"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer"}},"schemas":{"UsageRecord":{"type":"object","description":"A monthly usage record returned by `GET /v1/usage`.","properties":{"year":{"type":"integer","description":"Calendar year."},"month":{"type":"integer","description":"Calendar month (1-12)."},"milliseconds":{"type":"integer","description":"Usage duration value in milliseconds (legacy metric)."}}}},"responses":{"401-unauthorized":{"description":"Unauthorized. The request lacks a valid bearer token, or the provided token\nfailed to authenticate.\n\nNote: the 401 response is produced by the auth middleware **before** the\nrequest reaches the endpoint handler, so it does **not** follow the\nstandard `{errors: [...]}` envelope. Instead the body is a bare\n`{message: string}` object with no `code`, no `errors` array. Callers\nhandling 401s should key off the HTTP status and the `message` string,\nnot try to destructure an `errors[]`.","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string","description":"Human-readable description of the auth failure. Known values:\n- `\"Unauthorized\"` — no `Authorization` header on the request.\n- `\"Bearer Authentication Failed\"` — header present but token\n  is invalid, revoked, or expired."}},"required":["message"]}}}}}},"paths":{"/v1/usage":{"get":{"summary":"Get usage records (legacy)","operationId":"getUsage","tags":["Subscription & Entitlements"],"description":"Returns historical usage records for the current account (legacy usage series).\n\nThe response is an array of monthly records with a duration field (`milliseconds`).","responses":{"200":{"description":"Usage records","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/UsageRecord"}}}}},"401":{"$ref":"#/components/responses/401-unauthorized"}}}}}}
```

## Start a trial license

> Upgrades the account from the free tier to a trial license. The\
> account's current license must be on the "free" tier — calling this\
> on any other tier returns \*\*400 \`invalid\_license\`\*\*.\
> \
> AI guidance:\
> \- Only callable when the account is on the free tier. Check\
> &#x20; \`GET /v1/licenses\` first to confirm the current tier.\
> \- After a successful call, \`GET /v1/licenses\` will reflect the\
> &#x20; new trial status.

```json
{"openapi":"3.1.0","info":{"title":"Subscription & Entitlements","version":"1.0.0"},"servers":[{"url":"https://api.integrator.io","description":"Production (US / default region)"},{"url":"https://api.eu.integrator.io","description":"Production (EU region)"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer"}},"schemas":{"Error":{"type":"object","description":"Standard error response envelope returned by integrator.io APIs.","properties":{"errors":{"type":"array","description":"List of errors that occurred while processing the request.","items":{"type":"object","properties":{"code":{"oneOf":[{"type":"string"},{"type":"integer"}],"description":"Machine-readable error code. Usually a string like\n`invalid_ref`, `missing_required_field`, or `unauthorized`;\nmay be an **integer** when the error mirrors an upstream HTTP\nstatus (e.g. `500`) — most commonly returned by connection-ping\nand adaptor-proxy responses."},"message":{"type":"string","description":"Human-readable description of the error."},"field":{"type":"string","description":"Optional pointer to the document field that caused the error.\nUsed by structural validation errors (`missing_required_field`,\n`invalid_ref`) to indicate which field is at fault\n(e.g. `_id`, `type`, `http.baseURI`)."},"source":{"type":"string","description":"Optional origin layer for the error — e.g. `application` when\nthe error came from the remote system the adaptor called,\n`connector` when the adaptor itself rejected the request."}},"required":["message"]}}},"required":["errors"]}},"responses":{"401-unauthorized":{"description":"Unauthorized. The request lacks a valid bearer token, or the provided token\nfailed to authenticate.\n\nNote: the 401 response is produced by the auth middleware **before** the\nrequest reaches the endpoint handler, so it does **not** follow the\nstandard `{errors: [...]}` envelope. Instead the body is a bare\n`{message: string}` object with no `code`, no `errors` array. Callers\nhandling 401s should key off the HTTP status and the `message` string,\nnot try to destructure an `errors[]`.","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string","description":"Human-readable description of the auth failure. Known values:\n- `\"Unauthorized\"` — no `Authorization` header on the request.\n- `\"Bearer Authentication Failed\"` — header present but token\n  is invalid, revoked, or expired."}},"required":["message"]}}}}}},"paths":{"/v1/licenses/startTrial":{"post":{"operationId":"startLicenseTrial","tags":["Subscription & Entitlements"],"summary":"Start a trial license","description":"Upgrades the account from the free tier to a trial license. The\naccount's current license must be on the \"free\" tier — calling this\non any other tier returns **400 `invalid_license`**.\n\nAI guidance:\n- Only callable when the account is on the free tier. Check\n  `GET /v1/licenses` first to confirm the current tier.\n- After a successful call, `GET /v1/licenses` will reflect the\n  new trial status.","responses":{"200":{"description":"Trial started successfully.","content":{"application/json":{"schema":{"type":"object","description":"Updated license information.","additionalProperties":true}}}},"400":{"description":"License is not on the free tier.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"401":{"$ref":"#/components/responses/401-unauthorized"}}}}}}
```

## Resume a suspended account

> Resumes a suspended account. This is a \*\*PUT\*\*, not POST.\
> \
> The server validates that the account is in a resumable state. If the\
> account cannot be resumed (e.g. it is not suspended, or the suspension\
> type doesn't allow self-service resume), the server returns\
> \*\*422 \`account\_not\_resumed\`\*\* with \`source: "internal"\`.\
> \
> AI guidance:\
> \- Only works on accounts that are currently suspended and eligible for\
> &#x20; self-service resume.\
> \- The \`source: "internal"\` on the 422 error indicates the validation\
> &#x20; is server-side, not a field-level issue.

```json
{"openapi":"3.1.0","info":{"title":"Subscription & Entitlements","version":"1.0.0"},"servers":[{"url":"https://api.integrator.io","description":"Production (US / default region)"},{"url":"https://api.eu.integrator.io","description":"Production (EU region)"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"type":"http","scheme":"bearer"}},"responses":{"401-unauthorized":{"description":"Unauthorized. The request lacks a valid bearer token, or the provided token\nfailed to authenticate.\n\nNote: the 401 response is produced by the auth middleware **before** the\nrequest reaches the endpoint handler, so it does **not** follow the\nstandard `{errors: [...]}` envelope. Instead the body is a bare\n`{message: string}` object with no `code`, no `errors` array. Callers\nhandling 401s should key off the HTTP status and the `message` string,\nnot try to destructure an `errors[]`.","content":{"application/json":{"schema":{"type":"object","properties":{"message":{"type":"string","description":"Human-readable description of the auth failure. Known values:\n- `\"Unauthorized\"` — no `Authorization` header on the request.\n- `\"Bearer Authentication Failed\"` — header present but token\n  is invalid, revoked, or expired."}},"required":["message"]}}}}},"schemas":{"Error":{"type":"object","description":"Standard error response envelope returned by integrator.io APIs.","properties":{"errors":{"type":"array","description":"List of errors that occurred while processing the request.","items":{"type":"object","properties":{"code":{"oneOf":[{"type":"string"},{"type":"integer"}],"description":"Machine-readable error code. Usually a string like\n`invalid_ref`, `missing_required_field`, or `unauthorized`;\nmay be an **integer** when the error mirrors an upstream HTTP\nstatus (e.g. `500`) — most commonly returned by connection-ping\nand adaptor-proxy responses."},"message":{"type":"string","description":"Human-readable description of the error."},"field":{"type":"string","description":"Optional pointer to the document field that caused the error.\nUsed by structural validation errors (`missing_required_field`,\n`invalid_ref`) to indicate which field is at fault\n(e.g. `_id`, `type`, `http.baseURI`)."},"source":{"type":"string","description":"Optional origin layer for the error — e.g. `application` when\nthe error came from the remote system the adaptor called,\n`connector` when the adaptor itself rejected the request."}},"required":["message"]}}},"required":["errors"]}}},"paths":{"/v1/resume":{"put":{"operationId":"resumeAccount","tags":["Subscription & Entitlements"],"summary":"Resume a suspended account","description":"Resumes a suspended account. This is a **PUT**, not POST.\n\nThe server validates that the account is in a resumable state. If the\naccount cannot be resumed (e.g. it is not suspended, or the suspension\ntype doesn't allow self-service resume), the server returns\n**422 `account_not_resumed`** with `source: \"internal\"`.\n\nAI guidance:\n- Only works on accounts that are currently suspended and eligible for\n  self-service resume.\n- The `source: \"internal\"` on the 422 error indicates the validation\n  is server-side, not a field-level issue.","responses":{"200":{"description":"Account resumed successfully.","content":{"application/json":{"schema":{"type":"object","description":"Updated account state.","additionalProperties":true}}}},"401":{"$ref":"#/components/responses/401-unauthorized"},"422":{"description":"Account cannot be resumed.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}}}}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://developer.celigo.com/api/api-reference/subscription-and-entitlements.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
