import { CollaboratorRole, CollaboratorUpdate, Project, ProjectTypes, ProjectCreateOptions, ProjectCreateResponse, ProjectDeleteResponse, UserCollaborator, UserCollaboratorCreate, GetProjectOptions } from '../types/project.types'; /** * Projects class for managing projects in the Galileo platform. * Delegates to the internal GalileoApiClient for API interactions. */ export declare class Projects { private shouldContinue; /** * Lists every user collaborator for a project, exhausting pagination tokens. * @param projectId - (Optional) The project ID to list collaborators for. * @returns A promise that resolves to all collaborators for the project. */ getAllUserCollaborators(projectId?: string): Promise; /** * Lists projects available to the authenticated user. * @param projectType - (Optional) Project type filter to apply. * @returns A promise that resolves to the matching projects. */ list(projectType?: ProjectTypes): Promise; /** * Creates a new project. * @param name - Name of the project. * @param options - (Optional) Additional project creation settings. * @param options.type - (Optional) Project type to assign. * @param options.createdBy - (Optional) Identifier of the creator. * @param options.createExampleTemplates - (Optional) Whether example templates should be created. * @returns A promise that resolves to the created project. */ create(name: string, options?: ProjectCreateOptions): Promise; /** * Gets a project by ID or name, falling back to environment configuration when omitted. * @param options - The lookup options. * @param options.projectId - (Optional) Explicit project ID override. * @param options.name - (Optional) Explicit project name override. * @param options.projectType - (Optional) Project type hint when resolving by name. * @returns A promise that resolves to the matching project. */ getWithEnvFallbacks({ projectId, name, projectType }: GetProjectOptions): Promise; /** * Gets a project by ID or name. * @param options - The lookup options. * @param options.projectId - (Optional) ID of the project to fetch. * @param options.name - (Optional) Name of the project to fetch. * @param options.projectType - (Optional) Project type hint when resolving by name. * @returns A promise that resolves to the matching project. */ get({ projectId, name, projectType }: GetProjectOptions): Promise; /** * Deletes a project by ID or name without falling back to defaults. * @param options - The deletion options. * @param options.projectId - (Optional) ID of the project to delete. * @param options.name - (Optional) Name of the project to delete. * @param options.projectType - (Optional) Project type hint when resolving by name. * @returns A promise that resolves to the delete response payload. */ delete({ projectId, name, projectType }: GetProjectOptions): Promise; /** * Adds user collaborators to a project. * @param collaborators - Collaborator payloads to create. * @param collaborators[].userId - ID of the user receiving access. * @param collaborators[].role - (Optional) Role assigned to the user. * @param projectId - (Optional) Project ID override when client is not project-scoped. * @returns A promise that resolves to the created collaborators. */ addUserCollaborators(collaborators: UserCollaboratorCreate[], projectId?: string): Promise; /** * Updates a user collaborator assignment. * @param userId - ID of the collaborator to update. * @param update - Update payload describing the collaborator changes. * @param update.role - (Optional) Updated role for the collaborator. * @param projectId - (Optional) Project ID override when client is not project-scoped. * @returns A promise that resolves to the updated collaborator. */ updateUserCollaborator(userId: string, update: CollaboratorUpdate, projectId?: string): Promise; /** * Removes a user collaborator from a project. * @param userId - ID of the collaborator to remove. * @param projectId - Project ID that the collaborator belongs to. * @returns A promise that resolves when removal succeeds. */ removeUserCollaborator(userId: string, projectId: string): Promise; /** * Shares a project with a single user. * @param projectId - ID of the project to share. * @param userId - ID of the user receiving access. * @param role - (Optional) Role to assign to the user (defaults to viewer). * @returns A promise that resolves to the created collaborator record. */ shareWithUser(projectId: string, userId: string, role?: CollaboratorRole): Promise; /** * Removes a user's access to a project. * @param projectId - ID of the project to unshare. * @param userId - ID of the user losing access. * @returns A promise that resolves when the user is unshared. */ unshareWithUser(projectId: string, userId: string): Promise; } /** * Lists projects available to the authenticated user. * @returns A promise that resolves to the accessible projects. */ export declare const getProjects: () => Promise; /** * Creates a new project. * @param name - Name of the project to create. * @param options - (Optional) Additional create options. * @param options.type - (Optional) Project type to assign. * @param options.createdBy - (Optional) Identifier of the creator. * @param options.createExampleTemplates - (Optional) Whether example templates should be created. * @returns A promise that resolves to the created project. */ export declare const createProject: (name: string, options?: ProjectCreateOptions) => Promise; export declare const getProjectWithEnvFallbacks: ({ projectId, name, projectType }: GetProjectOptions) => Promise; /** * Gets a project by ID or name. * @param options - The lookup options. * @param options.projectId - (Optional) ID of the project to fetch. * @param options.name - (Optional) Name of the project to fetch. * @param options.projectType - (Optional) Project type hint when resolving by name. * @returns A promise that resolves to the matching project. */ export declare const getProject: ({ projectId, name, projectType }: GetProjectOptions) => Promise; /** * Deletes a project by ID or name without falling back to defaults. * @param options - The deletion options. * @param options.projectId - (Optional) ID of the project to delete. * @param options.name - (Optional) Name of the project to delete. * @param options.projectType - (Optional) Project type hint when resolving by name. * @returns A promise that resolves to the delete response payload. */ export declare const deleteProject: ({ projectId, name, projectType }: GetProjectOptions) => Promise; /** * Lists every user collaborator for a project, handling pagination automatically. * @param projectId - (Optional) Project ID to list collaborators for. * @returns A promise that resolves to every user collaborator. */ export declare const listProjectUserCollaborators: (projectId?: string) => Promise; /** * Adds multiple user collaborators to a project. * @param collaborators - Collaborator payloads to create. * @param collaborators[].userId - ID of the user receiving access. * @param collaborators[].role - (Optional) Role assigned to the user. * @param projectId - (Optional) Project ID override when client is not project-scoped. * @returns A promise that resolves to the created collaborators. * @internal Use the `Projects` class instead; not part of the public API. */ export declare const addProjectUserCollaborators: (collaborators: UserCollaboratorCreate[], projectId?: string) => Promise; /** * Updates a user collaborator assignment. * @param userId - ID of the collaborator to update. * @param update - Update payload describing the collaborator changes. * @param update.role - (Optional) Updated role for the collaborator. * @param projectId - (Optional) Project ID override when client is not project-scoped. * @returns A promise that resolves to the updated collaborator. */ export declare const updateProjectUserCollaborator: (userId: string, update: CollaboratorUpdate, projectId?: string) => Promise; /** * Removes a user collaborator from a project. * @param userId - ID of the collaborator to remove. * @param projectId - ID of the project the collaborator belongs to. * @returns A promise that resolves when removal succeeds. * @internal Use the `Projects` class instead; not part of the public API. */ export declare const removeProjectUserCollaborator: (userId: string, projectId: string) => Promise; /** * Shares a project with a single user. * @param projectId - ID of the project to share. * @param userId - ID of the user receiving access. * @param role - (Optional) Role to assign to the user (defaults to viewer). * @returns A promise that resolves to the created collaborator record. */ export declare const shareProjectWithUser: (projectId: string, userId: string, role?: CollaboratorRole) => Promise; /** * Removes a user's access to a project. * @param projectId - ID of the project to unshare. * @param userId - ID of the user losing access. * @returns A promise that resolves when the user is unshared. */ export declare const unshareProjectWithUser: (projectId: string, userId: string) => Promise;