Connectors API

The connectors API provides CRUD operations and lifecycle management for external system integrations. All procedures require organization-level authentication (orgProcedure).

connectors.create

Create a new connector instance for the organization.

Input Schema:

{
  name: string;          // Connector display name
  type: string;          // "sap_erp" | "mes" | "qms" | "rest_generic" | "webhook"
  config: object;        // Type-specific configuration (JSONB)
  syncFrequency: string; // "realtime" | "hourly" | "daily" | "weekly" | "manual"
}

Output: Returns the created connector record with generated id and default status: "pending_setup".

connectors.update

Update an existing connector’s config, name, or sync frequency.

Input Schema:

{
  id: string;                    // Connector ID
  name?: string;                 // Updated display name
  type?: string;                 // Updated connector type
  config?: object;               // Updated configuration (JSONB)
  syncFrequency?: string;        // Updated sync schedule
}

Output: Returns the updated connector record.

connectors.delete

Remove a connector and cascade-delete all sync history records.

Input Schema:

{
  id: string;  // Connector ID to delete
}

connectors.list

List all connectors for the organization with pagination.

Input Schema:

{
  limit?: number;   // Max results (default: 50, max: 100)
  offset?: number;  // Pagination offset (default: 0)
  type?: string;    // Optional filter by connector type
}

Output:

{
  items: Connector[];  // Array of connector records
  total: number;       // Total count for pagination
}

connectors.getById

Get a single connector with full config and last 10 sync history entries.

Input Schema:

{
  id: string;  // Connector ID
}

Output: Connector record with recentSyncs array (last 10 sync history entries).

connectors.testConnection

Verify connectivity to the external system without persisting data.

Input Schema:

{
  id: string;  // Connector ID to test
}

Output:

{
  success: boolean;      // Whether the connection test passed
  error: string | null;  // Error message if test failed
}

connectors.getSyncHistory

Paginated list of sync executions for a specific connector.

Input Schema:

{
  connectorId: string;  // Connector whose history to retrieve
  limit?: number;       // Max results (default: 20, max: 100)
  offset?: number;      // Pagination offset (default: 0)
}

Output:

{
  items: SyncHistoryRecord[];  // Array of sync records
  total: number;               // Total count for pagination
}

connectors.triggerSync

Manually trigger a sync for a connector.

Input Schema:

{
  id: string;  // Connector ID to sync
}

Output: Sync result with syncHistoryId, status, and record counts.


Kaizen API

kaizen.submit

Submit a new improvement idea to the kaizen board.

kaizen.list

List kaizen ideas for a board with filtering and pagination.

kaizen.evaluate

Score and evaluate a submitted kaizen idea.

kaizen.recordResults

Record implementation results with before/after KPI comparison.


A3 Reports API

a3Reports.create

Create a new A3 structured problem-solving report.

a3Reports.getById

Get an A3 report with all 9 sections and linked actions.

a3Reports.update

Update A3 report sections.

a3Reports.exportPdf

Generate a PDF export of the A3 report.


OEE API

oee.getEquipmentList

List all equipment with current OEE values.

oee.createRecord

Create a manual OEE record for an equipment.

oee.getEquipmentTrend

Get OEE trend data for an equipment over a date range.

oee.setTarget

Configure OEE improvement targets per equipment.


VSM API

vsm.list

List all value stream maps for a board.

vsm.create

Create a new value stream map (current or future state).

vsm.getById

Get a VSM with all nodes and edges.

vsm.updateNodes

Update node positions and properties.


Shift Handover API

shiftHandover.create

Create a new shift handover record.

shiftHandover.submit

Submit a completed handover for acknowledgment.

shiftHandover.acknowledge

Incoming leader acknowledges the handover.

shiftHandover.getAutoCompiled

Get auto-compiled data (open actions, KPI anomalies, recent events).