--- title: "Configure Connected System authentication" slug: "build-ai-ready-systems-connected-systems-configure-authentication" description: "Configure Connected System authentication with usage slots, kv:// secrets, and validate plus E2E proof steps for integrators before go-live." tags: ["Integration", "Developer", "Integrator"] updated: 2026-11-30T18:59:56Z published: 2026-11-17T07:08:17Z canonical: "docs.aifabrix.ai/build-ai-ready-systems-connected-systems-configure-authentication" --- > ## Documentation Index > Fetch the complete documentation index at: https://docs.aifabrix.ai/llms.txt > Use this file to discover all available pages before exploring further. # Configure Connected System authentication Connected Systems need **trusted credentials** before sync, webhooks, CIP, or AI-assisted capabilities can run. Authentication is declared on the **Connected System** manifest as **`authentications[]`** — one or more credential slots, each with a **usage** that tells the platform when to apply it. Secrets resolve at deploy/upload time via **`kv://`** references only — never hardcoded in docs or committed JSON. ## Why it matters Operational Trust requires enterprise-approved auth patterns (API key, OAuth2, client credentials) — not bypass security. Wrong or conflated auth blocks upload, integration tests, webhook validation, sync-bridge propagation, and every certification pillar that touches live APIs. **Separate usages exist on purpose:** user-scoped **`api`** credentials must not power background sync workers or inbound webhook signature checks. Keep outbound vendor tokens on **`api`** and inbound signing/OIDC on **`webhookInbound`**. Enterprise Synchronization Fabrix depends on **`webhookInbound`** and **`syncExecution`** slots in addition to **`api`**. ## Authentication layers | Layer | What it authenticates | Where to configure | | --- | --- | --- | | **Vendor API (`api`)** | CIP, capabilities, integration tests, user-context calls | `authentications[]` with `usage: api` | | **Inbound webhooks (`webhookInbound`)** | Signature/token validation on every POST `/webhooks/{systemKey}/…` (change-signal refresh and capability-named events) | `authentications[]` with `usage: webhookInbound` | | **Sync worker (`syncExecution`)** | Scheduled sync, webhook-triggered **`get`**/**`update`**, sync-bridge propagation | `authentications[]` with `usage: syncExecution` | | **Platform CLI** | Builder upload, test, certify | `aifabrix login` + controller roles | Do not confuse vendor slots with platform login — a green `aifabrix auth status` does not fix vendor 401 errors. See [Platform developer access](/docs/build-ai-ready-systems-build-reference-platform-developer-access). ## The `authentications[]` model Each Connected System declares an array of authentication entries. Every item reuses the same credential structure (`authType`, `credential.method`, `variables`, `security` kv paths) and adds: | Field | Role | | --- | --- | | **`key`** | Stable slot id (e.g. `default`, `webhook`, `sync-worker`) | | **`usage`** | Runtime selector — which code path loads this credential | ### Usage values (Connected System) | `usage` | When the platform uses it | | --- | --- | | **`api`** | Normal API calls, CIP execution, integration/E2E, Role Assistant capabilities | | **`webhookInbound`** | Validate incoming POST `/webhooks/…` deliveries (HMAC, bearer, OIDC). Same credential types as `api`, but a **separate slot** — do not put the signing secret on **`api`**. | | **`syncExecution`** | Background sync: inbound **`sync`** jobs, webhook-triggered refresh, **`syncBridge`** propagation | | **`callback`** | OAuth authorization-code / callback flows (when applicable) | | **`messageInbound`** / **`messageOutbound`** | Assistant channel ingress/egress when `systemKind: communication` | | **`provisioning`** | Provisioning hooks | There is **no webhook-specific auth schema** — each slot uses the same `credential` / `apiProvider` shapes as today. ### Single `authentication` (API only) A single root **`authentication`** block on the Connected System covers normal **`api`** usage. Validate compiles it as the default API slot when multi-usage arrays are present in your toolchain. When you add webhooks or sync bridge, **extend** with additional credential entries using the same shape and explicit **`usage`** values — do not duplicate secrets in datasource JSON. ## Prerequisites - `<systemKey>-system.json` from **`aifabrix create`** or copied fixture - Builder secret store paths in `env.template` for **each** slot’s `security` keys - [Authentication methods catalog](/docs/build-ai-ready-systems-build-reference-authentication-methods-catalog) - [Edit Connected Systems with Builder API](/docs/build-ai-ready-systems-get-started-build-with-builder-mcp) for post-upload Authentication UI - When enabling webhooks or sync bridge: [Enterprise sync bridge — technical guide](/docs/enterprise-knowledge-enterprise-sync-bridge-technical) ## Where it lives | Layer | Configuration | | --- | --- | | Multi-credential auth | `<systemKey>-system.json` → **`authentication`** and/or **`authentications[]`** with **`usage`** | | API-only (common) | Root **`authentication`** → treated as **`usage: api`** | | Secrets | `env.template` → **`kv://`** per slot | | Webhook / sync bridge | Business Entity `<datasourceKey>.json` → **`webhook`**, **`syncBridge`** (require matching auth usages on the **system**) | | CLI session | `aifabrix login` | ## Builder MCP | | | | --- | --- | | **Manifest section** | `system.authentication` / `system.authentications` | | **UI tab** | Authentication (`?tab=authentication`) — one card per `authentications[]` item | | **Help topics** | `connectedSystemUi`, `section`, `workflow`, authentication catalog | | **Patch policy** | Section is **blocked** for blind API patch — read first; assign secrets via UI or secret store | Use help topic **`connectedSystemUi`** for post-upload Authentication URL and required secret keys per **usage**. Safe edit loop: [Edit Connected Systems with Builder API](/docs/build-ai-ready-systems-get-started-build-with-builder-mcp). ## How to set ### 1. Default API slot Detect vendor reality — OpenAPI import often classifies CRM specs as OAuth2; private apps often need API key. ``` aifabrix repair --auth apikey aifabrix validate ``` **`repair --auth`** updates the default **`api`** credential block (or the default slot in **`authentications[]`** when present). ### 2. Add webhook and sync slots (when needed) When a Business Entity enables **`webhook.enabled`** or **`syncBridge`** other than `disabled`, the **Connected System** must expose matching auth usages: | Feature on datasource | Required system auth | | --- | --- | | `webhook.enabled: true` | `authentications[]` with **`usage: webhookInbound`** | | `syncBridge: master` or `bidirectional` | **`usage: syncExecution`** (or service-capable **`api`** fallback where policy allows) | | Inbound **`sync.enabled`** (background pull) | **`syncExecution`** recommended | **On-behalf-of user OAuth alone is invalid** for `syncExecution` — use service account, client credentials, or API key suited to background workers. ### 3. Example — three usage slots ``` { "key": "example-crm", "displayName": "Example CRM", "type": "openapi", "authentications": [ { "key": "default", "usage": "api", "authType": "credential", "credential": { "method": "apikey", "variables": { "baseUrl": "https://api.example.com", "headerName": "X-API-Key" }, "security": { "apiKey": "kv://example-crm/apiKey" } } }, { "key": "webhook", "usage": "webhookInbound", "authType": "credential", "credential": { "method": "apikey", "variables": { "headerName": "X-Hub-Signature" }, "security": { "apiKey": "kv://example-crm/webhookSecret" } } }, { "key": "sync-worker", "usage": "syncExecution", "authType": "credential", "credential": { "method": "apikey", "variables": { "baseUrl": "https://api.example.com", "headerName": "X-API-Key" }, "security": { "apiKey": "kv://example-crm/syncApiKey" } } } ] } ``` `syncExecution` may reuse the same kv path as `api` when one service credential is appropriate — keep **separate slots** so validation and audit stay explicit. ### 4. Communication channel credentials (`systemKind: communication`) Assistant delivery uses Connected Systems with **`systemKind: communication`**. They share the **Authentication tab** with vendor integrations — same UI surface, **one card per usage**. Split inbound Request URL validation from outbound bot calls. Prefill non-secret header/algorithm/OIDC discovery fields in each slot’s `credential.variables`. Declare secrets as **`kv://`** in `credential.security` only. Upload creates **pending** credentials; operators complete them in the UI. | Usage | Typical `credential.method` | Operator completes | | --- | --- | --- | | **`api`** | `bearerToken` (or vendor bot token fields) | Outbound bot token | | **`webhookInbound`** | `hmac` or `oidc` | Signing secret (HMAC) or OIDC client credentials | Do **not** put the inbound signing secret on the **`api`** slot. Vendor Request URLs POST to `/webhooks/{systemKey}/{datasourceKey}` and authenticate with **`webhookInbound`** — the same door used for CRM change signals. Event names that match a capability key run that operation; see [Configure webhook change signals](/docs/build-ai-ready-systems-business-entities-configure-webhook-change-signals). Probe and delivery steps: [Deliver assistant channels](/docs/build-ai-ready-systems-operate-deliver-assistant-channels). Per-channel: [Slack](/docs/build-ai-ready-systems-operate-install-slack-channel), [Teams](/docs/build-ai-ready-systems-operate-install-microsoft-teams-channel), [Copilot](/docs/build-ai-ready-systems-operate-install-microsoft-copilot-channel), [ChatGPT](/docs/build-ai-ready-systems-operate-install-chatgpt-channel), [Claude](/docs/build-ai-ready-systems-operate-install-claude-channel). ### 5. Resolve secrets and prove auth ``` aifabrix auth status aifabrix login aifabrix validate aifabrix test-integration aifabrix datasource test-e2e --app ``` Confirm every **`kv://`** path in `env.template` exists (`secret get … --exists`). After upload, operators assign live secrets on **Connected Systems → Authentication** — one form per usage card. ### Authentication edit, test, and save precedence On the Authentication tab, a non-empty secret the operator enters is authoritative for both **Test Connection** and save. A blank or omitted masked field keeps the secured value already saved in the draft or online credential; it does not erase that value or silently substitute another key. Only when neither an entered nor a saved value exists does the platform try the declared manifest or installation reference as a fallback. If that reference cannot be resolved, the credential remains pending or the test fails rather than sending a literal reference as vendor authentication. Entered values are persisted under a Connected System- or credential-scoped **`kv://`** reference. The platform does not persist a plaintext secret in the manifest, or create a generic field-name placeholder shared across systems. To rotate a value, enter the replacement, test it, and save; leaving a masked field blank means “keep the existing value,” not “rotate to the declared fallback.” Upload pushes credential **references** only. If denied, fix platform permissions and re-upload rather than embedding secrets in JSON. ## Auth types and on-behalf-of | Pattern | When | Manifest | | --- | --- | --- | | **API key / bearer token** | Private apps, static tokens, webhook HMAC secrets | `authType: credential` with `method: apikey` or `bearerToken` | | **OAuth2 client credentials** | Server-to-server SaaS, **`syncExecution`** | `method: oauth2`, `variables.tokenUrl`, secrets in `security` | | **API Provider (delegated)** | Enterprise IdP or delegated provider key | `authType: apiProvider` with `apiProviderKey` | | **System (platform-managed downstream)** | Platform shells / facades — AI Fabrix owns acquiring the downstream token | `authType: system` — **no** credential form, secrets, or `apiProvider`. Not an autonomous system actor; inbound callers still use governed real-user OAuth2 authorization code. | | **No authentication (`none`)** | Vendor truly accepts anonymous downstream calls | `authType: none` — injects **no** auth. Do **not** equate with forwarding the caller’s inbound bearer token. | | **On-behalf-of / user context** | User-scoped vendor APIs via **`api`** usage only | Platform API Provider or OAuth authorization code — **not** `syncExecution` or `webhookInbound` | ## Runtime selection (summary) ``` CIP / capabilities / outbound bot calls → authentications[usage=api] POST /webhooks/{systemKey}/… → authentications[usage=webhookInbound] Sync job / SyncIntent / syncBridge write → authentications[usage=syncExecution] ``` Detail: [Enterprise webhooks](/docs/enterprise-knowledge-enterprise-webhooks), [Configure sync](/docs/build-ai-ready-systems-business-entities-configure-sync). ## Defaults and examples | Situation | Action | | --- | --- | | Wizard chose OAuth, you use API key | **`aifabrix repair <systemKey> --auth apikey`** (default `api` slot) | | Webhook enabled, validation fails on auth | Add **`webhookInbound`** credential; set webhook secret kv path | | Sync bridge enabled, propagation blocked | Add **`syncExecution`**; avoid user-delegated OAuth | | Missing shared secret | **`secret get`** / **`secret set`**; re-run resolve | | Masked UI field left blank | Preserve the secured saved draft/online value; use the declared reference only if none exists | ## Validate ``` aifabrix validate aifabrix verify-trust aifabrix test-integration aifabrix datasource test-e2e --app ``` Certification checks webhook shape against **`webhookInbound`**. Change-signal `events[]` still require CIP **`get`** (and **`idPath`**). When every `events[]` entry is a capability key on that entity, **`get`** / **`idPath`** are not required — prove the named operation instead. Sync bridge still requires **`syncExecution`** and **`get`**/**`update`** — see [Enterprise sync bridge — technical guide](/docs/enterprise-knowledge-enterprise-sync-bridge-technical). Auth failures surface earliest at integration or E2E. Rotate credentials in the secret store; re-upload after rotation if connection settings change. ## Common mistakes | Mistake | Fix | | --- | --- | | Secrets pasted into committed JSON | **`kv://`** only | | Assuming a blank Authentication field clears a saved secret | Blank preserves it; enter a replacement to rotate | | One OAuth user token for everything | Split **`api`**, **`webhookInbound`**, **`syncExecution`** | | Webhook enabled without `webhookInbound` | Add slot on **system** manifest; validate | | Sync bridge without `syncExecution` | Add worker credential; not end-user OAuth | | CLI login OK but integration fails | Fix vendor **`authentications[]`**, not platform token | | Confusing platform token with vendor API key | Two layers — see [Platform developer access](/docs/build-ai-ready-systems-build-reference-platform-developer-access) | | Skipping repair after OpenAPI import | **`repair --auth apikey`** for private apps | | Live secrets in communication manifest | **`kv://`** in `security`; complete pending credentials on Authentication tab | | Signing secret on the communication **`api`** slot | Split **`api`** (bot token) vs **`webhookInbound`** (`hmac` / `oidc`) | | Putting secrets on `authType: system` | Remove credential/`security`; system forbids vendor secrets | | Using `none` to mean “forward inbound token” | Use **`system`** for platform-managed downstream auth; `none` is anonymous only | ## Limits Do not grant Role Assistants or models direct credential access — capabilities mediate execution. Vendor-specific OAuth scopes, webhook signature schemes, and certificate rotation vary — confirm against vendor docs and [Authentication methods catalog](/docs/build-ai-ready-systems-build-reference-authentication-methods-catalog). Capability-named webhook events use the same **`webhookInbound`** slot and generated POST `/webhooks/…` URL as change signals. Confirm with your operator that capability dispatch is live before registering vendor Request URLs. Change-signal events still need CIP **`get`**; capability-only `events[]` do not. Datasource manifests still require root **`key`**, **`displayName`**, **`systemKey`**, **`entityType`**, **`resourceType`**, **`primaryKey`**, and indexed **`externalId`** — system auth does not replace those bands. **`validate`** alone can stay green while live calls fail if secrets are stale — re-run **`test-integration`** after every rotation. ## Related reading - [Configure webhook change signals](/docs/build-ai-ready-systems-business-entities-configure-webhook-change-signals) - [Enterprise sync bridge — technical guide](/docs/enterprise-knowledge-enterprise-sync-bridge-technical) - [Enterprise webhooks](/docs/enterprise-knowledge-enterprise-webhooks) - [Configure sync](/docs/build-ai-ready-systems-business-entities-configure-sync) - [Deliver assistant channels](/docs/build-ai-ready-systems-operate-deliver-assistant-channels) - [Operational trust — authentication](/docs/operational-trust-authentication-for-trust) ## Related - [Configure system configuration](/build-ai-ready-systems-connected-systems-configure-system-configuration.md) - [Configure sync](/build-ai-ready-systems-business-entities-configure-sync.md) - [Configure webhook change signals](/build-ai-ready-systems-business-entities-configure-webhook-change-signals.md) - [Enterprise sync bridge — technical guide](/enterprise-knowledge-enterprise-sync-bridge-technical.md) - [Enterprise webhooks](/enterprise-knowledge-enterprise-webhooks.md) - [Deliver assistant channels](/build-ai-ready-systems-operate-deliver-assistant-channels.md) - [Edit Connected Systems with Builder API](/build-ai-ready-systems-get-started-build-with-builder-mcp.md) - [Authentication for trust](/operational-trust-authentication-for-trust.md) - [Authentication methods catalog](/build-ai-ready-systems-build-reference-authentication-methods-catalog.md)