Contents
Guided setup
Integrations
Events API
Self hosting
Send your first event
Operational receives events at POST /api/v1/log.
Use the API key from the project you want to track.
SDK example:
import Operational from "@operational.co/sdk";
const ops = new Operational(process.env.OPERATIONAL_API_KEY);
await ops.events.log({
name: "user signed up",
avatar: "🎉",
content: "Signup from pricing page",
});
Direct HTTP example:
const event = {
name: "user signed up",
avatar: "🎉",
content: "Signup from pricing page",
};
await fetch("https://api.operational.co/api/v1/log", {
method: "POST",
headers: {
"Authorization": `Bearer ${process.env.OPERATIONAL_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify(event),
});
A successful request returns 201 with success.