UNPKG

@zeplin/sdk

Version:
286 lines (285 loc) 13.6 kB
/** * Zeplin API * Access your resources in Zeplin * * Contact: support@zeplin.io * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech * Do not edit the class manually. */ import { AxiosPromise, AxiosInstance, AxiosResponse } from 'axios'; import { Configuration } from '../configuration'; import { RequestArgs, BaseAPI } from '../base'; import { Color } from '../models'; import { ColorCreateBody } from '../models'; import { ColorUpdateBody } from '../models'; import { EntityReference } from '../models'; /** * ColorsApi - axios parameter creator * @export */ export declare const ColorsApiAxiosParamCreator: (configuration?: Configuration | undefined) => { /** * Create a color in the project\'s local styleguide * @summary Create project color * @param {string} projectId Project id * @param {ColorCreateBody} colorCreateBody * @param {*} [options] Override http request option. * @throws {RequiredError} */ createProjectColor: (projectId: string, colorCreateBody: ColorCreateBody, options?: any) => Promise<RequestArgs>; /** * Create a color in the styleguide\'s local styleguide * @summary Create styleguide color * @param {string} styleguideId Styleguide id * @param {ColorCreateBody} colorCreateBody * @param {*} [options] Override http request option. * @throws {RequiredError} */ createStyleguideColor: (styleguideId: string, colorCreateBody: ColorCreateBody, options?: any) => Promise<RequestArgs>; /** * This endpoint returns all of the colors in a project. You need to be a member of the project or a member of the organization that owns the project. Returns `Not Found` response otherwise. * @summary Get project colors * @param {string} projectId Project id * @param {number} [limit] Pagination limit * @param {number} [offset] Pagination offset * @param {boolean} [includeLinkedStyleguides] Whether to include linked styleguides or not * @param {*} [options] Override http request option. * @throws {RequiredError} */ getProjectColors: (projectId: string, limit?: number | undefined, offset?: number | undefined, includeLinkedStyleguides?: boolean | undefined, options?: any) => Promise<RequestArgs>; /** * Returns colors in a styleguide that user has access. See [Styleguide docs](#getstyleguide) for more details about how `linked_project` and `linked_styleguide` parameters can be used to retrieve resources from styleguides that user is eligible to access. * @summary Get styleguide colors * @param {string} styleguideId Styleguide id * @param {number} [limit] Pagination limit * @param {number} [offset] Pagination offset * @param {string} [linkedProject] Reference project id * @param {string} [linkedStyleguide] Reference styleguide id * @param {boolean} [includeLinkedStyleguides] Whether to include linked styleguides or not * @param {*} [options] Override http request option. * @throws {RequiredError} */ getStyleguideColors: (styleguideId: string, limit?: number | undefined, offset?: number | undefined, linkedProject?: string | undefined, linkedStyleguide?: string | undefined, includeLinkedStyleguides?: boolean | undefined, options?: any) => Promise<RequestArgs>; /** * Update a color in the project\'s local styleguide * @summary Update project color * @param {string} projectId Project id * @param {string} colorId Color id * @param {ColorUpdateBody} colorUpdateBody * @param {*} [options] Override http request option. * @throws {RequiredError} */ updateProjectColor: (projectId: string, colorId: string, colorUpdateBody: ColorUpdateBody, options?: any) => Promise<RequestArgs>; /** * Update a color in the styleguide * @summary Update styleguide color * @param {string} styleguideId Styleguide id * @param {string} colorId Color id * @param {ColorUpdateBody} colorUpdateBody * @param {*} [options] Override http request option. * @throws {RequiredError} */ updateStyleguideColor: (styleguideId: string, colorId: string, colorUpdateBody: ColorUpdateBody, options?: any) => Promise<RequestArgs>; }; /** * ColorsApi - functional programming interface * @export */ export declare const ColorsApiFp: (configuration?: Configuration | undefined) => { /** * Create a color in the project\'s local styleguide * @summary Create project color * @param {string} projectId Project id * @param {ColorCreateBody} colorCreateBody * @param {*} [options] Override http request option. * @throws {RequiredError} */ createProjectColor(projectId: string, colorCreateBody: ColorCreateBody, options?: any): Promise<(axios?: AxiosInstance | undefined, basePath?: string | undefined) => AxiosPromise<any>>; /** * Create a color in the styleguide\'s local styleguide * @summary Create styleguide color * @param {string} styleguideId Styleguide id * @param {ColorCreateBody} colorCreateBody * @param {*} [options] Override http request option. * @throws {RequiredError} */ createStyleguideColor(styleguideId: string, colorCreateBody: ColorCreateBody, options?: any): Promise<(axios?: AxiosInstance | undefined, basePath?: string | undefined) => AxiosPromise<any>>; /** * This endpoint returns all of the colors in a project. You need to be a member of the project or a member of the organization that owns the project. Returns `Not Found` response otherwise. * @summary Get project colors * @param {string} projectId Project id * @param {number} [limit] Pagination limit * @param {number} [offset] Pagination offset * @param {boolean} [includeLinkedStyleguides] Whether to include linked styleguides or not * @param {*} [options] Override http request option. * @throws {RequiredError} */ getProjectColors(projectId: string, limit?: number | undefined, offset?: number | undefined, includeLinkedStyleguides?: boolean | undefined, options?: any): Promise<(axios?: AxiosInstance | undefined, basePath?: string | undefined) => AxiosPromise<any>>; /** * Returns colors in a styleguide that user has access. See [Styleguide docs](#getstyleguide) for more details about how `linked_project` and `linked_styleguide` parameters can be used to retrieve resources from styleguides that user is eligible to access. * @summary Get styleguide colors * @param {string} styleguideId Styleguide id * @param {number} [limit] Pagination limit * @param {number} [offset] Pagination offset * @param {string} [linkedProject] Reference project id * @param {string} [linkedStyleguide] Reference styleguide id * @param {boolean} [includeLinkedStyleguides] Whether to include linked styleguides or not * @param {*} [options] Override http request option. * @throws {RequiredError} */ getStyleguideColors(styleguideId: string, limit?: number | undefined, offset?: number | undefined, linkedProject?: string | undefined, linkedStyleguide?: string | undefined, includeLinkedStyleguides?: boolean | undefined, options?: any): Promise<(axios?: AxiosInstance | undefined, basePath?: string | undefined) => AxiosPromise<any>>; /** * Update a color in the project\'s local styleguide * @summary Update project color * @param {string} projectId Project id * @param {string} colorId Color id * @param {ColorUpdateBody} colorUpdateBody * @param {*} [options] Override http request option. * @throws {RequiredError} */ updateProjectColor(projectId: string, colorId: string, colorUpdateBody: ColorUpdateBody, options?: any): Promise<(axios?: AxiosInstance | undefined, basePath?: string | undefined) => AxiosPromise<any>>; /** * Update a color in the styleguide * @summary Update styleguide color * @param {string} styleguideId Styleguide id * @param {string} colorId Color id * @param {ColorUpdateBody} colorUpdateBody * @param {*} [options] Override http request option. * @throws {RequiredError} */ updateStyleguideColor(styleguideId: string, colorId: string, colorUpdateBody: ColorUpdateBody, options?: any): Promise<(axios?: AxiosInstance | undefined, basePath?: string | undefined) => AxiosPromise<any>>; }; /** * Search parameters for getProjectColors operation in ColorsApi. * @export * @interface ColorsApiGetProjectColorsSearchParams */ export interface ColorsApiGetProjectColorsSearchParams { /** * Pagination limit * @type {number} * @memberof ColorsApiGetProjectColorsSearchParams */ readonly limit?: number; /** * Pagination offset * @type {number} * @memberof ColorsApiGetProjectColorsSearchParams */ readonly offset?: number; /** * Whether to include linked styleguides or not * @type {boolean} * @memberof ColorsApiGetProjectColorsSearchParams */ readonly includeLinkedStyleguides?: boolean; } /** * Search parameters for getStyleguideColors operation in ColorsApi. * @export * @interface ColorsApiGetStyleguideColorsSearchParams */ export interface ColorsApiGetStyleguideColorsSearchParams { /** * Pagination limit * @type {number} * @memberof ColorsApiGetStyleguideColorsSearchParams */ readonly limit?: number; /** * Pagination offset * @type {number} * @memberof ColorsApiGetStyleguideColorsSearchParams */ readonly offset?: number; /** * Reference project id * @type {string} * @memberof ColorsApiGetStyleguideColorsSearchParams */ readonly linkedProject?: string; /** * Reference styleguide id * @type {string} * @memberof ColorsApiGetStyleguideColorsSearchParams */ readonly linkedStyleguide?: string; /** * Whether to include linked styleguides or not * @type {boolean} * @memberof ColorsApiGetStyleguideColorsSearchParams */ readonly includeLinkedStyleguides?: boolean; } /** * ColorsApi - object-oriented interface * @export * @class ColorsApi * @extends {BaseAPI} */ export declare class ColorsApi extends BaseAPI { /** * Create a color in the project\'s local styleguide * @summary Create project color * @param {string} projectId Project id * @param {ColorCreateBody} colorCreateBody * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof ColorsApi */ createProjectColor(projectId: string, colorCreateBody: ColorCreateBody, options?: any): Promise<AxiosResponse<EntityReference>>; /** * Create a color in the styleguide\'s local styleguide * @summary Create styleguide color * @param {string} styleguideId Styleguide id * @param {ColorCreateBody} colorCreateBody * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof ColorsApi */ createStyleguideColor(styleguideId: string, colorCreateBody: ColorCreateBody, options?: any): Promise<AxiosResponse<EntityReference>>; /** * This endpoint returns all of the colors in a project. You need to be a member of the project or a member of the organization that owns the project. Returns `Not Found` response otherwise. * @summary Get project colors * @param {string} projectId Project id * @param {ColorsApiGetProjectColorsSearchParams} [searchParams] Search parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof ColorsApi */ getProjectColors(projectId: string, searchParams?: ColorsApiGetProjectColorsSearchParams, options?: any): Promise<AxiosResponse<Array<Color>>>; /** * Returns colors in a styleguide that user has access. See [Styleguide docs](#getstyleguide) for more details about how `linked_project` and `linked_styleguide` parameters can be used to retrieve resources from styleguides that user is eligible to access. * @summary Get styleguide colors * @param {string} styleguideId Styleguide id * @param {ColorsApiGetStyleguideColorsSearchParams} [searchParams] Search parameters. * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof ColorsApi */ getStyleguideColors(styleguideId: string, searchParams?: ColorsApiGetStyleguideColorsSearchParams, options?: any): Promise<AxiosResponse<Array<Color>>>; /** * Update a color in the project\'s local styleguide * @summary Update project color * @param {string} projectId Project id * @param {string} colorId Color id * @param {ColorUpdateBody} colorUpdateBody * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof ColorsApi */ updateProjectColor(projectId: string, colorId: string, colorUpdateBody: ColorUpdateBody, options?: any): Promise<AxiosResponse<void>>; /** * Update a color in the styleguide * @summary Update styleguide color * @param {string} styleguideId Styleguide id * @param {string} colorId Color id * @param {ColorUpdateBody} colorUpdateBody * @param {*} [options] Override http request option. * @throws {RequiredError} * @memberof ColorsApi */ updateStyleguideColor(styleguideId: string, colorId: string, colorUpdateBody: ColorUpdateBody, options?: any): Promise<AxiosResponse<void>>; }