← Developers

Adapter contract

The TypeScript interface every Native and Partner-built adapter implements. Four methods, one canonical schema, a conformance suite that proves your adapter is honest about what it can do.

The npm package @adaptlive/adapter-contract ships with the developer-portal launch. Until then, contact us at partners@adaptlive.app for early access.

The interface

export interface AdapterContract {
  pull(cursor: Cursor): AsyncIterable<CanonicalRecord>;
  push(record: CanonicalRecord): Promise<PushResult>;
  reconcile(local: Record, remote: Record): ReconcileDecision;
  capabilities(): AdapterCapabilities;
}

Methods

pull

pull(cursor: Cursor): AsyncIterable<CanonicalRecord>

Stream the upstream system's entities into adaptlive in canonical shape. Cursor-based — adapter persists where it left off; adaptlive replays on failure.

push

push(record: CanonicalRecord): Promise<PushResult>

Write a canonical change back to the upstream system. Return the upstream id + version so adaptlive can reconcile. Must be idempotent on the adaptlive event id.

reconcile

reconcile(local: Record, remote: Record): ReconcileDecision

Resolve a conflict between an adaptlive-side change and an upstream change. Decision is one of accept-local, accept-remote, or merge with a strategy. Field-level edit history feeds the decision.

capabilities

capabilities(): AdapterCapabilities

Declare what this adapter supports — which entities, which fields, real-time vs batch, webhook vs poll. Drives the UI: adaptlive hides settings the adapter can't honor.

Path to marketplace

  1. 1

    Implement the contract

    Install @adaptlive/adapter-contract. Implement pull / push / reconcile / capabilities. TypeScript-first; thin runtime shim makes Python and Go viable for teams who prefer them.

  2. 2

    Run the conformance suite

    npm run conformance hits your adapter with the canonical entity matrix — every supported type, every edge case (deleted upstream, renamed entity, partial fields, stale cursor). Pass = ready to certify.

  3. 3

    Submit for certification

    Open a PR against the marketplace registry with adapter manifest, OAuth credentials, capability declaration, and conformance run id. We review for security + correctness; typical turnaround is 5 business days.

  4. 4

    Marketplace listing + co-marketing

    On approval your adapter goes live in the adaptlive marketplace. Joint launch post, partner badge, listing in /work-with-us, revenue share on every customer who connects your adapter.

Ready to build?

Apply to the software-partner program. We'll set you up with sandbox access, the conformance kit, and a slack channel with our adapter team.

We use essential cookies to keep the app secure. Optional cookies help us improve reliability and measure campaigns. Cookie policy