import type { CreateBranchNeonAuthNewUserRequest, EnableNeonAuthIntegrationRequest, NeonAuthAddDomainToRedirectUriWhitelistRequest, NeonAuthAddOAuthProviderRequest, NeonAuthConfigResponse, NeonAuthConfigUpdate, NeonAuthCreateIntegrationResponse, NeonAuthCreateNewUserResponse, NeonAuthDeleteDomainFromRedirectUriWhitelistRequest, NeonAuthIntegration, NeonAuthOauthProvider, NeonAuthOauthProviderId, NeonAuthRedirectUriWhitelistDomain, NeonAuthUpdateOAuthProviderRequest, UpdateNeonAuthUserRoleResponse } from "../../client/types.gen.js"; import type { CallOptions, RequestContext } from "../context.js"; import type { Outcome } from "../result.js"; type BranchParams = { projectId: string; branchId: string; }; export type AuthOauthProvidersListParams = BranchParams; export type AuthOauthProvidersAddParams = BranchParams & NeonAuthAddOAuthProviderRequest; export type AuthOauthProvidersUpdateParams = BranchParams & { providerId: NeonAuthOauthProviderId; } & NeonAuthUpdateOAuthProviderRequest; export type AuthOauthProvidersDeleteParams = BranchParams & { providerId: NeonAuthOauthProviderId; }; export type AuthTrustedDomainsListParams = BranchParams; export type AuthTrustedDomainsAddParams = BranchParams & NeonAuthAddDomainToRedirectUriWhitelistRequest; export type AuthTrustedDomainsDeleteParams = BranchParams & NeonAuthDeleteDomainFromRedirectUriWhitelistRequest; export type AuthUsersCreateParams = BranchParams & CreateBranchNeonAuthNewUserRequest; export type AuthUsersDeleteParams = BranchParams & { authUserId: string; }; export type AuthUsersUpdateRoleParams = BranchParams & { authUserId: string; roles: string[]; }; export type AuthGetParams = BranchParams; export type AuthCreateParams = BranchParams & EnableNeonAuthIntegrationRequest; export type AuthDisableParams = BranchParams & { deleteData?: boolean; }; export type AuthUpdateConfigParams = BranchParams & NeonAuthConfigUpdate; /** Branch-scoped Neon Auth OAuth providers (Google, GitHub, …). */ export declare class AuthOauthProviders { #private; constructor(ctx: RequestContext); /** @apiCall GET /projects/{project_id}/branches/{branch_id}/auth/oauth_providers */ list(params: AuthOauthProvidersListParams): Promise>; list(params: AuthOauthProvidersListParams, opts: CallOptions): Promise>; /** @apiCall POST /projects/{project_id}/branches/{branch_id}/auth/oauth_providers */ add(params: AuthOauthProvidersAddParams): Promise>; add(params: AuthOauthProvidersAddParams, opts: CallOptions): Promise>; /** @apiCall PATCH …/auth/oauth_providers/{oauth_provider_id} */ update(params: AuthOauthProvidersUpdateParams): Promise>; update(params: AuthOauthProvidersUpdateParams, opts: CallOptions): Promise>; /** @apiCall DELETE …/auth/oauth_providers/{oauth_provider_id} */ delete(params: AuthOauthProvidersDeleteParams): Promise>; delete(params: AuthOauthProvidersDeleteParams, opts: CallOptions): Promise>; } /** Branch-scoped Neon Auth trusted domains (redirect URI whitelist). */ export declare class AuthTrustedDomains { #private; constructor(ctx: RequestContext); /** @apiCall GET …/auth/trusted_domains */ list(params: AuthTrustedDomainsListParams): Promise>; list(params: AuthTrustedDomainsListParams, opts: CallOptions): Promise>; /** @apiCall POST …/auth/trusted_domains */ add(params: AuthTrustedDomainsAddParams): Promise>; add(params: AuthTrustedDomainsAddParams, opts: CallOptions): Promise>; /** @apiCall DELETE …/auth/trusted_domains */ delete(params: AuthTrustedDomainsDeleteParams): Promise>; delete(params: AuthTrustedDomainsDeleteParams, opts: CallOptions): Promise>; } /** Branch-scoped Neon Auth users. */ export declare class AuthUsers { #private; constructor(ctx: RequestContext); /** @apiCall POST …/auth/users */ create(params: AuthUsersCreateParams): Promise>; create(params: AuthUsersCreateParams, opts: CallOptions): Promise>; /** @apiCall DELETE …/auth/users/{auth_user_id} */ delete(params: AuthUsersDeleteParams): Promise>; delete(params: AuthUsersDeleteParams, opts: CallOptions): Promise>; /** @apiCall PATCH …/auth/users/{auth_user_id}/role */ updateRole(params: AuthUsersUpdateRoleParams): Promise>; updateRole(params: AuthUsersUpdateRoleParams, opts: CallOptions): Promise>; } /** * Branch-scoped Neon Auth. Enable/disable the integration, tune its config, and manage * OAuth providers, trusted domains, and users. The legacy project-scoped auth endpoints are * deprecated and stay raw-only. */ export declare class Auth { #private; readonly oauthProviders: AuthOauthProviders; readonly trustedDomains: AuthTrustedDomains; readonly users: AuthUsers; constructor(ctx: RequestContext); /** @apiCall GET /projects/{project_id}/branches/{branch_id}/auth */ get(params: AuthGetParams): Promise>; get(params: AuthGetParams, opts: CallOptions): Promise>; /** @apiCall POST /projects/{project_id}/branches/{branch_id}/auth */ create(params: AuthCreateParams): Promise>; create(params: AuthCreateParams, opts: CallOptions): Promise>; /** @apiCall DELETE /projects/{project_id}/branches/{branch_id}/auth */ disable(params: AuthDisableParams): Promise>; disable(params: AuthDisableParams, opts: CallOptions): Promise>; /** @apiCall PATCH /projects/{project_id}/branches/{branch_id}/auth/config */ updateConfig(params: AuthUpdateConfigParams): Promise>; updateConfig(params: AuthUpdateConfigParams, opts: CallOptions): Promise>; } export {}; //# sourceMappingURL=auth.d.ts.map