Welcome to the Plot Twist Creator documentation! This comprehensive guide will help you build powerful Twists that organize and prioritize your work.
Plot Twists are smart automations that connect, organize, and prioritize your work. They implement opinionated workflows, integrate with external services, and help you stay organized across all your apps and messages.
plot-twist.mdCore Concepts - Understanding the Plot architecture
Sync Strategies - Data synchronization patterns
Built-in Tools Guide - Complete reference for all built-in twist tools
Building Connectors - Build external service integrations
CLI Reference - Complete command-line interface documentation
Runtime Environment - Understanding execution constraints
Explore the complete API documentation using the navigation on the left:
Check out these examples to get started:
import { type ToolBuilder, Twist } from "@plotday/twister";
import { Plot, ThreadAccess } from "@plotday/twister/tools/plot";
export default class WelcomeTwist extends Twist<WelcomeTwist> {
build(build: ToolBuilder) {
return {
plot: build(Plot, {
thread: { access: ThreadAccess.Create },
}),
};
}
async activate() {
await this.tools.plot.createThread({
title: "Welcome to Plot! 👋",
notes: [
{
content: "This twist will help you get started with Plot.",
},
],
});
}
}
import { type ToolBuilder, Twist } from "@plotday/twister";
import { Network, type WebhookRequest } from "@plotday/twister/tools/network";
import { Plot, ThreadAccess } from "@plotday/twister/tools/plot";
export default class CalendarTwist extends Twist<CalendarTwist> {
build(build: ToolBuilder) {
return {
plot: build(Plot, {
thread: { access: ThreadAccess.Create },
}),
network: build(Network, {
urls: ["https://www.googleapis.com/calendar/*"],
}),
};
}
async activate() {
// Set up a webhook for calendar updates
const webhookUrl = await this.tools.network.createWebhook(
{},
this.onCalendarUpdate
);
await this.set("webhook_url", webhookUrl);
}
async onCalendarUpdate(request: WebhookRequest) {
// Process the calendar change notification
}
}
MIT © Plot Technologies Inc.