The ai_integrations functions are currently in ALPHA. The API may change without notice. A one-time warning is emitted on first use.
List AI Integrations
import { listAiIntegrations } from "@arizeai/ax-client";
const { data: integrations, pagination } = await listAiIntegrations({
space: "your_space_id",
});
Create an AI Integration
import { createAiIntegration } from "@arizeai/ax-client";
const integration = await createAiIntegration({
name: "Production OpenAI",
provider: "openAI",
apiKey: "sk-...",
modelNames: ["gpt-4o", "gpt-4o-mini"],
enableDefaultModels: true,
});
// Store the returned integrationId — use it when creating evaluators
import { createAiIntegration } from "@arizeai/ax-client";
const integration = await createAiIntegration({
name: "Proxied OpenAI",
provider: "openAI",
authType: "proxy_with_headers",
baseUrl: "https://your-proxy.example.com",
headers: { "X-Custom-Header": "value" },
modelNames: ["gpt-4o"],
enableDefaultModels: false,
functionCallingEnabled: true,
});
Get an AI Integration
import { getAiIntegration } from "@arizeai/ax-client";
const integration = await getAiIntegration({
integration: "your_integration_id",
});
Update an AI Integration
import { updateAiIntegration } from "@arizeai/ax-client";
const updated = await updateAiIntegration({
integration: "your_integration_id",
name: "Updated OpenAI",
modelNames: ["gpt-4o"],
});
Delete an AI Integration
import { deleteAiIntegration } from "@arizeai/ax-client";
await deleteAiIntegration({ integration: "your_integration_id" });