1 | import { BaseRequestOptions, BaseService, PaginatedRequestOptions, Sudo } from '../infrastructure';
|
2 | import { DeploymentSchema } from './Deployments';
|
3 | import { ProjectSchema } from './Projects';
|
4 | export interface EnvironmentSchema {
|
5 | id: number;
|
6 | name: string;
|
7 | slug?: string;
|
8 | external_url?: string;
|
9 | project?: ProjectSchema;
|
10 | state?: string;
|
11 | }
|
12 | export interface EnvironmentDetailSchema extends EnvironmentSchema {
|
13 | last_deployment?: DeploymentSchema;
|
14 | deployable?: DeploymentSchema;
|
15 | }
|
16 | export declare class Environments extends BaseService {
|
17 | all(projectId: string | number, options?: PaginatedRequestOptions): Promise<EnvironmentSchema[]>;
|
18 | show(projectId: string | number, environmentId: number, options?: Sudo): Promise<EnvironmentDetailSchema>;
|
19 | create(projectId: string | number, options?: BaseRequestOptions): Promise<object>;
|
20 | edit(projectId: string | number, environmentId: number, options?: BaseRequestOptions): Promise<object>;
|
21 | remove(projectId: string | number, environmentId: number, options?: Sudo): Promise<object>;
|
22 | stop(projectId: string | number, environmentId: number, options?: Sudo): Promise<object>;
|
23 | }
|