Integrations

Build an integration.

Connect Caleana to your software with the Integration SDK. Sessions open from your product with the record’s details, your system’s data comes into the session, and finished documents go back.

Building a plugin instead? Start on Plugins

An integration connects your system to every session.

It hears when a session starts, when data needs refreshing, when a template set is used and when a write-back is asked for. Context comes in through it, and finished documents go out.

A session starts

session-created: the session opens from your product for a record, and the integration adds your system’s data with setValues().

Data needs refreshing

data-update-requested: the integration sends your system’s data to the session again.

A template set is used

collection-invoked: the integration is told which template set has been used, with its name and context hints.

A write-back is asked for

writeback-requested: the integration receives the exact bytes of the finished document, as text, RTF or a PDF attachment, and saves them to the record.

The connection

The Integration SDK connects outbound, so your system hosts no endpoint.

  • A launch link opens a session from your product, with the record’s details.
  • Sign-in is single sign-on through SAML or OIDC, or email and Google.
  • Your system’s data comes into the session when it starts, and again when it needs refreshing.
  • Write-back sends a fixed copy of the finished document, and each send is tracked to help prevent accidental duplicate sends.
  • Events are pushed over an outbound TLS connection, with short-lived credentials the SDK renews on its own.
  • An integration is a small TypeScript service beside your system, with an API key and the integration’s ID.

Create a client, and handle the events you need.

The client takes your API key; the listener handles the events you list and sets the session’s values. Write-back, lookups and launch links are in the docs.

# the package
npm install @caleana-ai/integration-sdk

# what the integration needs
CALEANA_API_KEY=api_...           # Settings, API keys
CALEANA_INTEGRATION_ID=...        # the workspace integration
const client = new CaleanaClient({ apiKey })

const listener = client.createEventListener({
  integrationId,
  eventTypes: ["session-created", "data-update-requested"],
})

listener.on("session-created", async (session) => {
  const record = await findRecord(session.subjectIds)  // your system
  await session.setValues({ details: record.details })
})

listener.start()

Caleana sets up each deployment with your team.

The integration is one part of a deployment. The launch, branding, templates and rules, and field plugins are set up for its users, on the platform that already runs.

Launch and sign-on

Sessions open from your software, with its sign-on.

The integration

Your system’s data comes in, and finished documents go back where supported.

Name and branding

Yours, on the product your users see.

Templates and rules

Templates and suggestion rules, set up for the deployment’s users.

Field plugins

Built by Caleana or by your team.

Build a plugin

Where the Integration SDK stands.

PackageOn npm

Install @caleana-ai/integration-sdk from npm.

Write-back

Finished documents go back to your system through the Integration SDK, as text, RTF or a PDF attachment.

ReferenceIn the docs

The connection, events, sessions, lookups, write-back and launch links, for SDK 0.3.0.

Integration SDK reference

Build on your advantage.

Tell us about your platform and the workflows you’re looking to introduce. Let’s explore how Caleana can help bring them to life.

Talk integrations

Integrations

Talk integrations

Tell us about your platform and the workflows you’re looking to introduce.

Details are used to reply. Privacy policy