Relate
Open source · Apache 2.0

Model your business.
Give agents context.

A shared, typed view of your business data. Connect objects, relationships, and access rules across the systems you already use.

Defined in TypeScript. Built for applications and AI agents.

business.graphExample model
Customer · Composite object

One customer, fields from Salesforce, Stripe, BigQuery, and S3. Each field keeps its source; the object brings them together.

Select an object to inspect3 objects / 2 relationships

Your systems, connected.

Map APIs and databases to business objects. Your source systems keep ownership of their records.

Access is part of the model.

Define who can read each object and field. Reads carry evidence of where data came from and how fresh it is.

One graph for code and agents.

Use the typed SDK in your application. MCP and HTTP interfaces are in preview for the same model.

From a customer
to their invoices.

A customer lives in your CRM. Their invoices live in a billing database. Describe the relationship once, then traverse it as the authenticated caller.

Relate checks access along the way.

See how to model a graph
customer-invoices.tsTypeScript
// Connect the objects in your graph
const CustomerInvoices = defineRelationship({
  id: 'customer.invoices',
  forward: 'invoices',
  reverse: 'customer',
  via: Invoice.properties.customer,
});

// Read through the caller's access rules
const { objects } = relate.as(principal);

const invoices = await objects.Customer
  .traverse.invoices(customerId, {
    select: ['status'],
  });
Excerpt from a configured graph. Start with a runnable example