/** * Shared credential-form types. * * These describe the *data* a service sends down to say what a credential form * should look like. Keeping them here rather than in a product package is the * point of this module: the integrations service is consumed by more than one * product, and every consumer should render the same description the same way * instead of maintaining its own copy of the renderer. */ /** How the UI collects the credential for an auth method. */ export type AuthMethodFlow = "fields" | "oauth2" | "minted"; /** * One property in a credential form schema. * * A superset of the JSON Schema subset the backend emits: `secret`, `format`, * `showIf` and `placeholder` are ours, and are what let a form be fully * described as data rather than partly as React. */ export interface SchemaProperty { type?: string; title?: string; description?: string; placeholder?: string; /** Render masked, with a reveal toggle, and never echo back into metadata. */ secret?: boolean; /** `textarea` / `json` for multi-line values such as service-account keys. */ format?: string; default?: string | number | boolean; /** Bare strings, or `{label,value}` when the display text differs. */ enum?: Array; /** Show only while every named field holds one of the accepted values. */ showIf?: Record; } export interface FormSchema { type?: string; properties: Record; required: string[]; } /** * One way of authenticating against a provider. * * Structural rather than tied to a generated GraphQL type, so a product can * pass whatever its own client produced without importing this package's * codegen output. */ export interface AuthMethodLike { key: string; displayName: string; description?: string | null; flow: AuthMethodFlow | string; configSchema?: Record | null; /** False when this environment lacks the credentials the method needs. */ isConfigured: boolean; isEnabled: boolean; displayOrder?: number; } //# sourceMappingURL=types.d.ts.map