Skip to main content

Integrations

An integration is a named collection of tools an agent can call. Each tool maps to either an HTTP endpoint (via Liquid-template config) or a custom execute function.

Built-in integrations

OpenMolt ships with 30 integrations pre-registered:

HandleService
airtableAirtable REST API
browserUseHeadless browser / web automation
discordDiscord Bot API
dropboxDropbox API
etsyEtsy API
falfal.ai (image & video generation)
geminiMediaModelsGoogle Gemini media generation
githubGitHub REST API
gmailGmail API (OAuth2)
googleAdsGoogle Ads API
googleCalendarGoogle Calendar API
googleDriveGoogle Drive API
googleSheetsGoogle Sheets API
httpRequestGeneric HTTP requests
instagramInstagram Graph API
metaAdsMeta Ads API
microsoftOutlookMicrosoft Outlook / Graph API
notionNotion API
openAiMediaModelsOpenAI Media Models API (DALL·E)
s3Amazon S3
shopifyShopify Admin API
slackSlack Web API
stripeStripe API
telegramTelegram Bot API
tiktokTikTok API
twilioTwilio REST API
xX (Twitter) API v2
whatsappWhatsApp Business API
youtubeYouTube Data API
fileSystemLocal filesystem (factory — see below)

Assigning integrations to an agent

const agent = om.createAgent({
integrations: [
{
integration: 'slack',
credential: {
type: 'bearer',
config: { apiKey: process.env.SLACK_BOT_TOKEN },
},
scopes: ['messages', 'channels'], // or 'all'
},
],
});

scopes restricts which tools the agent can call. Pass 'all' or omit to allow every scope.

Credential types

TypeRequired fieldsUsed by
bearerconfig.apiKeySlack, Telegram, GitHub, Stripe …
oauth2config.clientId, clientSecret, refreshTokenGmail, Google Drive …
basicconfig.username, config.passwordTwilio
customany config fieldshttpRequest, fileSystem, custom APIs

OAuth2 credentials are automatically refreshed; pass onTokenRefresh to persist the new tokens.

FileSystem integration

The FileSystem integration is a factory — not auto-registered — so you choose which directories are accessible:

om.registerIntegration(
'fileSystem',
OpenMolt.FileSystemIntegration('./output'), // restrict to ./output
);

// or multiple directories
om.registerIntegration(
'fileSystem',
OpenMolt.FileSystemIntegration(['./data', './uploads']),
);

Custom integrations

Register any HTTP API as a custom integration:

om.registerIntegration('myApi', {
name: 'My Service',
apiSetup: {
baseUrl: 'https://api.myservice.com/v1',
headers: { Authorization: 'Bearer {{ config.apiKey }}' },
requestFormat: 'json',
responseFormat: 'json',
},
credentialSetup: [{ type: 'bearer', headers: { Authorization: 'Bearer {{ config.apiKey }}' } }],
scopes: { read: 'Read data', write: 'Write data' },
tools: [
{
handle: 'getUser',
description: 'Get a user by ID.',
scopes: ['read'],
method: 'GET',
endpoint: '/users/{{ input.id }}',
inputSchema: z.object({ id: z.string() }),
},
],
});

For tools that cannot be expressed as a single HTTP call (file uploads, SDK calls, multi-step auth), use an execute function:

{
handle: 'uploadFile',
description: 'Upload a file.',
execute: async (input, context) => {
const apiKey = context.config?.apiKey as string;
// ... custom logic
return { url: '…' };
},
inputSchema: z.object({ path: z.string() }),
}