/* generated using openapi-typescript-codegen -- do not edit */
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { CreateProjectRequest } from '../models/CreateProjectRequest';
import type { CreateProjectResponse } from '../models/CreateProjectResponse';
import type { DeleteProjectResponse } from '../models/DeleteProjectResponse';
import type { GetAllModulesResponse } from '../models/GetAllModulesResponse';
import type { GetProjectsResponse } from '../models/GetProjectsResponse';
import type { UpdateAttributesRequest } from '../models/UpdateAttributesRequest';
import type { UpdateAttributesResponse } from '../models/UpdateAttributesResponse';
import type { UpdateModulesRequest } from '../models/UpdateModulesRequest';
import type { UpdateModulesResponse } from '../models/UpdateModulesResponse';
import type { UpdateProjectRequest } from '../models/UpdateProjectRequest';
import type { UpdateProjectResponse } from '../models/UpdateProjectResponse';
import type { CancelablePromise } from '../core/CancelablePromise';
import { OpenAPI } from '../core/OpenAPI';
import { request as __request } from '../core/request';
export class ProjectService {
    /**
     * Get Projects
     * @returns GetProjectsResponse Successful Response
     * @throws ApiError
     */
    public static getProjects(): CancelablePromise<GetProjectsResponse> {
        return __request(OpenAPI, {
            method: 'GET',
            url: '/project/',
        });
    }
    /**
     * Create Project
     * @returns CreateProjectResponse Successful Response
     * @throws ApiError
     */
    public static createProject({
        requestBody,
    }: {
        requestBody: CreateProjectRequest,
    }): CancelablePromise<CreateProjectResponse> {
        return __request(OpenAPI, {
            method: 'POST',
            url: '/project/',
            body: requestBody,
            mediaType: 'application/json',
            errors: {
                422: `Validation Error`,
            },
        });
    }
    /**
     * Update Project
     * @returns UpdateProjectResponse Successful Response
     * @throws ApiError
     */
    public static updateProject({
        requestBody,
    }: {
        requestBody: UpdateProjectRequest,
    }): CancelablePromise<UpdateProjectResponse> {
        return __request(OpenAPI, {
            method: 'PATCH',
            url: '/project/',
            body: requestBody,
            mediaType: 'application/json',
            errors: {
                422: `Validation Error`,
            },
        });
    }
    /**
     * Delete Project
     * @returns DeleteProjectResponse Successful Response
     * @throws ApiError
     */
    public static deleteProject({
        projectId,
    }: {
        projectId: number,
    }): CancelablePromise<DeleteProjectResponse> {
        return __request(OpenAPI, {
            method: 'DELETE',
            url: '/project/{project_id}',
            path: {
                'project_id': projectId,
            },
            errors: {
                422: `Validation Error`,
            },
        });
    }
    /**
     * Get All Modules
     * @returns GetAllModulesResponse Successful Response
     * @throws ApiError
     */
    public static getAllModules(): CancelablePromise<GetAllModulesResponse> {
        return __request(OpenAPI, {
            method: 'GET',
            url: '/project/modules',
        });
    }
    /**
     * Update Project Modules
     * @returns UpdateModulesResponse Successful Response
     * @throws ApiError
     */
    public static updateProjectModules({
        requestBody,
    }: {
        requestBody: UpdateModulesRequest,
    }): CancelablePromise<UpdateModulesResponse> {
        return __request(OpenAPI, {
            method: 'POST',
            url: '/project/modules',
            body: requestBody,
            mediaType: 'application/json',
            errors: {
                422: `Validation Error`,
            },
        });
    }
    /**
     * Update Project Attributes
     * @returns UpdateAttributesResponse Successful Response
     * @throws ApiError
     */
    public static updateProjectAttributes({
        requestBody,
    }: {
        requestBody: UpdateAttributesRequest,
    }): CancelablePromise<UpdateAttributesResponse> {
        return __request(OpenAPI, {
            method: 'POST',
            url: '/project/attributes',
            body: requestBody,
            mediaType: 'application/json',
            errors: {
                422: `Validation Error`,
            },
        });
    }
}
