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 metadata and identity

Prev Next

Define metadataSchema, primaryKey, and labelKey so each Business Entity has stable join identity and operator-readable labels.

Prerequisites

Where it lives

Layer Location
Schema metadataSchema.properties — indexed fields for search/ABAC
Identity primaryKey[], required externalId property
Display labelKey[] — human title fields
UI Business Entity Overview / vocabulary tabs

Manifest sections: datasource.metadata, datasource.identity.

Builder MCP

Manifest sections datasource.metadata, datasource.identity
Help topics section, goldenExample, dependencyGraph
Repair hooks fieldMappings

Changing identity bands triggers downstream exposure and RBAC — read dependencyGraph before patch. Example fixture: help topic goldenExample (CRM company pattern).

How to set

  1. Require indexed externalId on record and document storage entities:
{
  "key": "example-customers",
  "entityType": "recordStorage",
  "resourceType": "customer",
  "primaryKey": ["externalId"],
  "labelKey": ["name"],
  "metadataSchema": {
    "type": "object",
    "properties": {
      "externalId": { "type": "string", "index": true },
      "name": { "type": "string", "index": true }
    }
  }
}
  1. Project vendor fields via Configure business vocabulary — schema and mappings must agree.
  2. Validate entity file:
aifabrix datasource validate <datasourceKey>

Validate

System gate: aifabrix validate <systemKey>. Missing externalId fails schema validation before upload.

Common mistakes

Mistake Fix
Composite PK as cross-entity join key Use externalId for joins
Schema properties without field mappings Repair fieldMappings
labelKey pointing at unmapped field Map attribute first