Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.corsair.dev/llms.txt

Use this file to discover all available pages before exploring further.

You can use OpenAI with Corsair through the dashboard or in code.

In the dashboard

  1. Sign in at app.corsair.dev.
  2. Open Dashboard and click New instance.
  3. Open your instance and click Add Plugin to enable an integration (e.g. GitHub, Slack).
  4. Click New User to add a tenant — enter a tenant ID and click Save.
  5. Connect the integration for that tenant: click the cell where the tenant row meets the plugin column, then sign in with OAuth or enter credentials.
  6. Click the tenant name in the first column to open the side panel.
  7. Copy the MCP URL and create an API key (New key → name → Create → copy the secret once).
Quick Start under SDK → OpenAI Agents copies a full starter if you want a guided demo.
npm install @corsair-dev/app openai @openai/agents

In code

Responses API

import OpenAI from "openai";
import { createClient, getOpenAiMcpConfig } from "@corsair-dev/app";

const corsair = createClient({ apiKey: process.env.CORSAIR_DEV_KEY! });
const key = await corsair
  .instance(process.env.CORSAIR_INSTANCE_ID!)
  .tenant("alice")
  .mcpKeys.create("openai-agent");

const openai = new OpenAI({ apiKey: process.env.OPENAI_API_KEY! });

const response = await openai.responses.create({
  model: "gpt-4.1",
  tools: [getOpenAiMcpConfig({ url: key.mcpHttpUrl, apiKey: key.secret })],
  input: "Star the corsairdev/corsair repo on GitHub",
});

console.log(response.output_text);

OpenAI Agents SDK

import { Agent, run } from "@openai/agents";
import { createOpenAiMcpServer } from "@corsair-dev/app";

const corsairServer = await createOpenAiMcpServer({
  url: key.mcpHttpUrl,
  apiKey: key.secret,
});

const agent = new Agent({
  name: "corsair-agent",
  instructions: "Use Corsair tools to complete the user's request.",
  mcpServers: [corsairServer],
});

const result = await run(agent, "Star the corsairdev/corsair repo on GitHub");
console.log(result.finalOutput);

Run it

Call your API or agent with any prompt. If you connected GitHub, try:
Use Corsair to star the Corsair repo on GitHub