import { APIResource } from "../core/resource.js"; import * as Shared from "./shared.js"; import { APIPromise } from "../core/api-promise.js"; import { RequestOptions } from "../internal/request-options.js"; export declare class Company extends APIResource { /** * Get organization by name */ retrieve(name: string, params?: CompanyRetrieveParams | null | undefined, options?: RequestOptions): APIPromise; /** * Get organization by tenant id header. * * Args: organization_slug_query (str | None): Optional organization slug query * parameter. service (AdminOrganizationService): Admin organization service. * subscription_service (AdminSubscriptionService): Admin subscription service. * current_user (CurrentUser | None): The current user (None for guests). * * Returns: OrganizationResponse | AdminCompanyOrganizationResponse: Organization * response. Returns OrganizationResponse (with admin_username/admin_email) when * `organization_slug` is provided (global admin), and * AdminCompanyOrganizationResponse (excluding those fields) when called via tenant * header (admin page). * * Raises: HTTPException: - 400: If organization_slug is not provided and not found * in context. - 401: If organization_slug is provided but user is not * authenticated. - 403: If user is not a global_admin and attempts to specify * organization_slug. - 404: If organization_slug is provided but organization not * found. */ list(params?: CompanyListParams | null | undefined, options?: RequestOptions): APIPromise; /** * Typeahead search for active members of the current organization (tenant from * X-Tenant-ID). Matches display name, email, or username with partial * case-insensitive match. */ retrieveMembers(params?: CompanyRetrieveMembersParams | null | undefined, options?: RequestOptions): APIPromise; } export type CompanyListResponse = unknown; export type CompanyRetrieveMembersResponse = Array; export declare namespace CompanyRetrieveMembersResponse { /** * Member row for organization-scoped typeahead (public API). */ interface CompanyRetrieveMembersResponseItem { /** * User ID */ id: string; /** * Username (often email) */ username: string; /** * Display name */ display_name?: string | null; /** * Email when stored separately from username */ email?: string | null; } } export interface CompanyRetrieveParams { 'Accept-Language'?: string; /** * Set to `structured` to receive errors in the structured envelope. Omit it to * keep the legacy error body. */ 'X-Error-Format'?: string; } export interface CompanyListParams { /** * Query param: Organization slug. Required for global_admin to access other * organizations. */ organization_slug?: string | null; /** * Header param */ 'Accept-Language'?: string; /** * Header param: Set to `structured` to receive errors in the structured envelope. * Omit it to keep the legacy error body. */ 'X-Error-Format'?: string; } export interface CompanyRetrieveMembersParams { /** * Query param: Maximum number of results (1–20) */ limit?: number; /** * Query param: Search substring (display name, email, or username). Omit or * whitespace-only for no results. */ q?: string | null; /** * Header param */ 'Accept-Language'?: string; /** * Header param: Set to `structured` to receive errors in the structured envelope. * Omit it to keep the legacy error body. */ 'X-Error-Format'?: string; } export declare namespace Company { export { type CompanyListResponse as CompanyListResponse, type CompanyRetrieveMembersResponse as CompanyRetrieveMembersResponse, type CompanyRetrieveParams as CompanyRetrieveParams, type CompanyListParams as CompanyListParams, type CompanyRetrieveMembersParams as CompanyRetrieveMembersParams, }; } //# sourceMappingURL=company.d.ts.map