UNPKG

mastra

Version:
46 lines 2.11 kB
export interface ObservabilityProvisionResult { /** WorkOS organization API key (sk_*) used as MASTRA_PLATFORM_ACCESS_TOKEN. */ token: string; /** Platform project id (UUID) used as MASTRA_PROJECT_ID. */ projectId: string; /** Platform project slug. */ projectSlug: string; /** Platform project name. */ projectName: string; /** Organization display name for messaging. */ orgName: string; /** * Spans endpoint override. Only set when the platform URL is non-default * (e.g., local dev or staging). When omitted, the MastraPlatformExporter * falls back to its built-in `https://observability.mastra.ai` default. */ tracesEndpoint?: string; } /** * Walk the user through enabling Mastra Observability for a freshly-scaffolded * project: log in (via the existing browser flow) if needed, pick or create a * platform project, mint a fresh org-scoped ingest token, and return what the * caller needs to write to `.env`. * * Defaults the project name to `defaultProjectName` (typically the package * name from `package.json`) when creating a new project. */ export declare function provisionObservabilityProject({ defaultProjectName, observabilityProject, mode, token: providedToken, }?: { defaultProjectName?: string; /** * If supplied, skip the interactive picker. Matches an existing project by * name or slug; if no match, creates a new project with this name. Lets the * `create` / `init` commands run fully non-interactively. */ observabilityProject?: string; /** * `'create'` (used by `create-mastra`) always provisions a new platform * project named after the local one — no picker, no extra name prompt. * `'pick'` (used by `mastra init` in an existing project) lets the user * attach to an existing project or create a new one. */ mode?: 'create' | 'pick'; /** Platform auth token already acquired during the observability opt-in prompt. */ token?: string; }): Promise<ObservabilityProvisionResult>; //# sourceMappingURL=observability-provision.d.ts.map