@contentful/experience-design-system-client 2.26.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/dist/package.json +56 -0
- package/dist/src/generated/client/client.gen.d.ts +2 -0
- package/dist/src/generated/client/client.gen.js +148 -0
- package/dist/src/generated/client/index.d.ts +7 -0
- package/dist/src/generated/client/index.js +5 -0
- package/dist/src/generated/client/types.gen.d.ts +122 -0
- package/dist/src/generated/client/types.gen.js +2 -0
- package/dist/src/generated/client/utils.gen.d.ts +45 -0
- package/dist/src/generated/client/utils.gen.js +298 -0
- package/dist/src/generated/client.gen.d.ts +12 -0
- package/dist/src/generated/client.gen.js +3 -0
- package/dist/src/generated/core/auth.gen.d.ts +18 -0
- package/dist/src/generated/core/auth.gen.js +14 -0
- package/dist/src/generated/core/bodySerializer.gen.d.ts +17 -0
- package/dist/src/generated/core/bodySerializer.gen.js +57 -0
- package/dist/src/generated/core/params.gen.d.ts +33 -0
- package/dist/src/generated/core/params.gen.js +88 -0
- package/dist/src/generated/core/pathSerializer.gen.d.ts +33 -0
- package/dist/src/generated/core/pathSerializer.gen.js +114 -0
- package/dist/src/generated/core/types.gen.d.ts +78 -0
- package/dist/src/generated/core/types.gen.js +2 -0
- package/dist/src/generated/index.d.ts +2 -0
- package/dist/src/generated/index.js +3 -0
- package/dist/src/generated/sdk.gen.d.ts +83 -0
- package/dist/src/generated/sdk.gen.js +179 -0
- package/dist/src/generated/types.gen.d.ts +4736 -0
- package/dist/src/generated/types.gen.js +2 -0
- package/dist/src/index.d.ts +3 -0
- package/dist/src/index.js +2 -0
- package/dist/src/index.spec.d.ts +1 -0
- package/dist/src/index.spec.js +6 -0
- package/package.json +56 -0
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
import type { Auth, AuthToken } from './auth.gen.js';
|
|
2
|
+
import type { BodySerializer, QuerySerializer, QuerySerializerOptions } from './bodySerializer.gen.js';
|
|
3
|
+
export interface Client<RequestFn = never, Config = unknown, MethodFn = never, BuildUrlFn = never> {
|
|
4
|
+
/**
|
|
5
|
+
* Returns the final request URL.
|
|
6
|
+
*/
|
|
7
|
+
buildUrl: BuildUrlFn;
|
|
8
|
+
connect: MethodFn;
|
|
9
|
+
delete: MethodFn;
|
|
10
|
+
get: MethodFn;
|
|
11
|
+
getConfig: () => Config;
|
|
12
|
+
head: MethodFn;
|
|
13
|
+
options: MethodFn;
|
|
14
|
+
patch: MethodFn;
|
|
15
|
+
post: MethodFn;
|
|
16
|
+
put: MethodFn;
|
|
17
|
+
request: RequestFn;
|
|
18
|
+
setConfig: (config: Config) => Config;
|
|
19
|
+
trace: MethodFn;
|
|
20
|
+
}
|
|
21
|
+
export interface Config {
|
|
22
|
+
/**
|
|
23
|
+
* Auth token or a function returning auth token. The resolved value will be
|
|
24
|
+
* added to the request payload as defined by its `security` array.
|
|
25
|
+
*/
|
|
26
|
+
auth?: ((auth: Auth) => Promise<AuthToken> | AuthToken) | AuthToken;
|
|
27
|
+
/**
|
|
28
|
+
* A function for serializing request body parameter. By default,
|
|
29
|
+
* {@link JSON.stringify()} will be used.
|
|
30
|
+
*/
|
|
31
|
+
bodySerializer?: BodySerializer | null;
|
|
32
|
+
/**
|
|
33
|
+
* An object containing any HTTP headers that you want to pre-populate your
|
|
34
|
+
* `Headers` object with.
|
|
35
|
+
*
|
|
36
|
+
* {@link https://developer.mozilla.org/docs/Web/API/Headers/Headers#init See more}
|
|
37
|
+
*/
|
|
38
|
+
headers?: RequestInit['headers'] | Record<string, string | number | boolean | (string | number | boolean)[] | null | undefined | unknown>;
|
|
39
|
+
/**
|
|
40
|
+
* The request method.
|
|
41
|
+
*
|
|
42
|
+
* {@link https://developer.mozilla.org/docs/Web/API/fetch#method See more}
|
|
43
|
+
*/
|
|
44
|
+
method?: 'CONNECT' | 'DELETE' | 'GET' | 'HEAD' | 'OPTIONS' | 'PATCH' | 'POST' | 'PUT' | 'TRACE';
|
|
45
|
+
/**
|
|
46
|
+
* A function for serializing request query parameters. By default, arrays
|
|
47
|
+
* will be exploded in form style, objects will be exploded in deepObject
|
|
48
|
+
* style, and reserved characters are percent-encoded.
|
|
49
|
+
*
|
|
50
|
+
* This method will have no effect if the native `paramsSerializer()` Axios
|
|
51
|
+
* API function is used.
|
|
52
|
+
*
|
|
53
|
+
* {@link https://swagger.io/docs/specification/serialization/#query View examples}
|
|
54
|
+
*/
|
|
55
|
+
querySerializer?: QuerySerializer | QuerySerializerOptions;
|
|
56
|
+
/**
|
|
57
|
+
* A function validating request data. This is useful if you want to ensure
|
|
58
|
+
* the request conforms to the desired shape, so it can be safely sent to
|
|
59
|
+
* the server.
|
|
60
|
+
*/
|
|
61
|
+
requestValidator?: (data: unknown) => Promise<unknown>;
|
|
62
|
+
/**
|
|
63
|
+
* A function transforming response data before it's returned. This is useful
|
|
64
|
+
* for post-processing data, e.g. converting ISO strings into Date objects.
|
|
65
|
+
*/
|
|
66
|
+
responseTransformer?: (data: unknown) => Promise<unknown>;
|
|
67
|
+
/**
|
|
68
|
+
* A function validating response data. This is useful if you want to ensure
|
|
69
|
+
* the response conforms to the desired shape, so it can be safely passed to
|
|
70
|
+
* the transformers and returned to the user.
|
|
71
|
+
*/
|
|
72
|
+
responseValidator?: (data: unknown) => Promise<unknown>;
|
|
73
|
+
}
|
|
74
|
+
type IsExactlyNeverOrNeverUndefined<T> = [T] extends [never] ? true : [T] extends [never | undefined] ? [undefined] extends [T] ? false : true : false;
|
|
75
|
+
export type OmitNever<T extends Record<string, unknown>> = {
|
|
76
|
+
[K in keyof T as IsExactlyNeverOrNeverUndefined<T[K]> extends true ? never : K]: T[K];
|
|
77
|
+
};
|
|
78
|
+
export {};
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
import type { Options as ClientOptions, TDataShape, Client } from './client/index.js';
|
|
2
|
+
import type { DesignSystemSourceDeleteData, DesignSystemSourceDeleteResponses, DesignSystemSourceDeleteErrors, DesignSystemSourceReadData, DesignSystemSourceReadResponses, DesignSystemSourceReadErrors, DesignSystemSourceUpsertData, DesignSystemSourceUpsertResponses, DesignSystemSourceUpsertErrors, DesignSystemSourceListData, DesignSystemSourceListResponses, DesignSystemSourceListErrors, DesignSystemSourceDisconnectData, DesignSystemSourceDisconnectResponses, DesignSystemSourceDisconnectErrors, DesignSystemSourceReconnectData, DesignSystemSourceReconnectResponses, DesignSystemSourceReconnectErrors, DesignSystemImportCreateData, DesignSystemImportCreateResponses, DesignSystemImportCreateErrors, DesignSystemImportSourcelessPreviewData, DesignSystemImportSourcelessPreviewResponses, DesignSystemImportSourcelessPreviewErrors, DesignSystemImportApplyData, DesignSystemImportApplyResponses, DesignSystemImportApplyErrors, DesignSystemImportGetOperationData, DesignSystemImportGetOperationResponses, DesignSystemImportGetOperationErrors, DesignSystemImportPreflightData, DesignSystemImportPreflightResponses, DesignSystemImportPreflightErrors, GitHubInstallationsGenerateData, GitHubInstallationsGenerateResponses, GitHubInstallationsGenerateErrors, GitHubInstallationsListData, GitHubInstallationsListResponses, GitHubInstallationsListErrors, GitHubInstallationsExchangeData, GitHubInstallationsExchangeResponses, GitHubInstallationsExchangeErrors, GitHubInstallationRepositoriesListData, GitHubInstallationRepositoriesListResponses, GitHubInstallationRepositoriesListErrors, GitHubRepositoryBranchesListData, GitHubRepositoryBranchesListResponses, GitHubRepositoryBranchesListErrors, GitHubInstallationStatusReadData, GitHubInstallationStatusReadResponses, GitHubInstallationStatusReadErrors } from './types.gen.js';
|
|
3
|
+
export type Options<TData extends TDataShape = TDataShape, ThrowOnError extends boolean = boolean> = ClientOptions<TData, ThrowOnError> & {
|
|
4
|
+
/**
|
|
5
|
+
* You can provide a client instance returned by `createClient()` instead of
|
|
6
|
+
* individual options. This might be also useful if you want to implement a
|
|
7
|
+
* custom client.
|
|
8
|
+
*/
|
|
9
|
+
client?: Client;
|
|
10
|
+
/**
|
|
11
|
+
* You can pass arbitrary values through the `meta` object. This can be
|
|
12
|
+
* used to access values that aren't defined as part of the SDK function.
|
|
13
|
+
*/
|
|
14
|
+
meta?: Record<string, unknown>;
|
|
15
|
+
};
|
|
16
|
+
/**
|
|
17
|
+
* Delete a design system source
|
|
18
|
+
*/
|
|
19
|
+
export declare const designSystemSourceDelete: <ThrowOnError extends boolean = false>(options: Options<DesignSystemSourceDeleteData, ThrowOnError>) => import("./client/types.gen.js").RequestResult<DesignSystemSourceDeleteResponses, DesignSystemSourceDeleteErrors, ThrowOnError, "fields">;
|
|
20
|
+
/**
|
|
21
|
+
* Get a design system source
|
|
22
|
+
*/
|
|
23
|
+
export declare const designSystemSourceRead: <ThrowOnError extends boolean = false>(options: Options<DesignSystemSourceReadData, ThrowOnError>) => import("./client/types.gen.js").RequestResult<DesignSystemSourceReadResponses, DesignSystemSourceReadErrors, ThrowOnError, "fields">;
|
|
24
|
+
/**
|
|
25
|
+
* Create or update a design system source
|
|
26
|
+
*/
|
|
27
|
+
export declare const designSystemSourceUpsert: <ThrowOnError extends boolean = false>(options: Options<DesignSystemSourceUpsertData, ThrowOnError>) => import("./client/types.gen.js").RequestResult<DesignSystemSourceUpsertResponses, DesignSystemSourceUpsertErrors, ThrowOnError, "fields">;
|
|
28
|
+
/**
|
|
29
|
+
* List design system sources
|
|
30
|
+
*/
|
|
31
|
+
export declare const designSystemSourceList: <ThrowOnError extends boolean = false>(options: Options<DesignSystemSourceListData, ThrowOnError>) => import("./client/types.gen.js").RequestResult<DesignSystemSourceListResponses, DesignSystemSourceListErrors, ThrowOnError, "fields">;
|
|
32
|
+
/**
|
|
33
|
+
* Soft-disconnect a design system source (space-scoped; never touches GitHub)
|
|
34
|
+
*/
|
|
35
|
+
export declare const designSystemSourceDisconnect: <ThrowOnError extends boolean = false>(options: Options<DesignSystemSourceDisconnectData, ThrowOnError>) => import("./client/types.gen.js").RequestResult<DesignSystemSourceDisconnectResponses, DesignSystemSourceDisconnectErrors, ThrowOnError, "fields">;
|
|
36
|
+
/**
|
|
37
|
+
* Reconnect a design system source after a fresh liveness re-check
|
|
38
|
+
*/
|
|
39
|
+
export declare const designSystemSourceReconnect: <ThrowOnError extends boolean = false>(options: Options<DesignSystemSourceReconnectData, ThrowOnError>) => import("./client/types.gen.js").RequestResult<DesignSystemSourceReconnectResponses, DesignSystemSourceReconnectErrors, ThrowOnError, "fields">;
|
|
40
|
+
/**
|
|
41
|
+
* Preview the import diff from a design system source
|
|
42
|
+
*/
|
|
43
|
+
export declare const designSystemImportCreate: <ThrowOnError extends boolean = false>(options: Options<DesignSystemImportCreateData, ThrowOnError>) => import("./client/types.gen.js").RequestResult<DesignSystemImportCreateResponses, DesignSystemImportCreateErrors, ThrowOnError, "fields">;
|
|
44
|
+
/**
|
|
45
|
+
* Preview import diff from a manifest payload (no source required)
|
|
46
|
+
*/
|
|
47
|
+
export declare const designSystemImportSourcelessPreview: <ThrowOnError extends boolean = false>(options: Options<DesignSystemImportSourcelessPreviewData, ThrowOnError>) => import("./client/types.gen.js").RequestResult<DesignSystemImportSourcelessPreviewResponses, DesignSystemImportSourcelessPreviewErrors, ThrowOnError, "fields">;
|
|
48
|
+
/**
|
|
49
|
+
* Submit selected import changes for asynchronous apply
|
|
50
|
+
*/
|
|
51
|
+
export declare const designSystemImportApply: <ThrowOnError extends boolean = false>(options: Options<DesignSystemImportApplyData, ThrowOnError>) => import("./client/types.gen.js").RequestResult<DesignSystemImportApplyResponses, DesignSystemImportApplyErrors, ThrowOnError, "fields">;
|
|
52
|
+
/**
|
|
53
|
+
* Get the current status of an async apply operation
|
|
54
|
+
*/
|
|
55
|
+
export declare const designSystemImportGetOperation: <ThrowOnError extends boolean = false>(options: Options<DesignSystemImportGetOperationData, ThrowOnError>) => import("./client/types.gen.js").RequestResult<DesignSystemImportGetOperationResponses, DesignSystemImportGetOperationErrors, ThrowOnError, "fields">;
|
|
56
|
+
/**
|
|
57
|
+
* Check whether the caller can preview or apply design system imports
|
|
58
|
+
*/
|
|
59
|
+
export declare const designSystemImportPreflight: <ThrowOnError extends boolean = false>(options: Options<DesignSystemImportPreflightData, ThrowOnError>) => import("./client/types.gen.js").RequestResult<DesignSystemImportPreflightResponses, DesignSystemImportPreflightErrors, ThrowOnError, "fields">;
|
|
60
|
+
/**
|
|
61
|
+
* Generate a GitHub App installation URL
|
|
62
|
+
*/
|
|
63
|
+
export declare const gitHubInstallationsGenerate: <ThrowOnError extends boolean = false>(options: Options<GitHubInstallationsGenerateData, ThrowOnError>) => import("./client/types.gen.js").RequestResult<GitHubInstallationsGenerateResponses, GitHubInstallationsGenerateErrors, ThrowOnError, "fields">;
|
|
64
|
+
/**
|
|
65
|
+
* List GitHub App installations visible to the service
|
|
66
|
+
*/
|
|
67
|
+
export declare const gitHubInstallationsList: <ThrowOnError extends boolean = false>(options: Options<GitHubInstallationsListData, ThrowOnError>) => import("./client/types.gen.js").RequestResult<GitHubInstallationsListResponses, GitHubInstallationsListErrors, ThrowOnError, "fields">;
|
|
68
|
+
/**
|
|
69
|
+
* Finalize a GitHub install callback into validated provider metadata
|
|
70
|
+
*/
|
|
71
|
+
export declare const gitHubInstallationsExchange: <ThrowOnError extends boolean = false>(options: Options<GitHubInstallationsExchangeData, ThrowOnError>) => import("./client/types.gen.js").RequestResult<GitHubInstallationsExchangeResponses, GitHubInstallationsExchangeErrors, ThrowOnError, "fields">;
|
|
72
|
+
/**
|
|
73
|
+
* List repositories accessible to a GitHub App installation
|
|
74
|
+
*/
|
|
75
|
+
export declare const gitHubInstallationRepositoriesList: <ThrowOnError extends boolean = false>(options: Options<GitHubInstallationRepositoriesListData, ThrowOnError>) => import("./client/types.gen.js").RequestResult<GitHubInstallationRepositoriesListResponses, GitHubInstallationRepositoriesListErrors, ThrowOnError, "fields">;
|
|
76
|
+
/**
|
|
77
|
+
* List branches for a repository accessible to an installation
|
|
78
|
+
*/
|
|
79
|
+
export declare const gitHubRepositoryBranchesList: <ThrowOnError extends boolean = false>(options: Options<GitHubRepositoryBranchesListData, ThrowOnError>) => import("./client/types.gen.js").RequestResult<GitHubRepositoryBranchesListResponses, GitHubRepositoryBranchesListErrors, ThrowOnError, "fields">;
|
|
80
|
+
/**
|
|
81
|
+
* Read the current GitHub App installation status for an organization
|
|
82
|
+
*/
|
|
83
|
+
export declare const gitHubInstallationStatusRead: <ThrowOnError extends boolean = false>(options: Options<GitHubInstallationStatusReadData, ThrowOnError>) => import("./client/types.gen.js").RequestResult<GitHubInstallationStatusReadResponses, GitHubInstallationStatusReadErrors, ThrowOnError, "fields">;
|
|
@@ -0,0 +1,179 @@
|
|
|
1
|
+
// This file is auto-generated by @hey-api/openapi-ts
|
|
2
|
+
import { client as _heyApiClient } from './client.gen.js';
|
|
3
|
+
/**
|
|
4
|
+
* Delete a design system source
|
|
5
|
+
*/
|
|
6
|
+
export const designSystemSourceDelete = (options) => {
|
|
7
|
+
return (options.client ?? _heyApiClient).delete({
|
|
8
|
+
url: '/spaces/{spaceId}/environments/{environmentId}/design_systems/sources/{sourceId}',
|
|
9
|
+
...options
|
|
10
|
+
});
|
|
11
|
+
};
|
|
12
|
+
/**
|
|
13
|
+
* Get a design system source
|
|
14
|
+
*/
|
|
15
|
+
export const designSystemSourceRead = (options) => {
|
|
16
|
+
return (options.client ?? _heyApiClient).get({
|
|
17
|
+
url: '/spaces/{spaceId}/environments/{environmentId}/design_systems/sources/{sourceId}',
|
|
18
|
+
...options
|
|
19
|
+
});
|
|
20
|
+
};
|
|
21
|
+
/**
|
|
22
|
+
* Create or update a design system source
|
|
23
|
+
*/
|
|
24
|
+
export const designSystemSourceUpsert = (options) => {
|
|
25
|
+
return (options.client ?? _heyApiClient).put({
|
|
26
|
+
url: '/spaces/{spaceId}/environments/{environmentId}/design_systems/sources/{sourceId}',
|
|
27
|
+
...options,
|
|
28
|
+
headers: {
|
|
29
|
+
'Content-Type': 'application/json',
|
|
30
|
+
...options.headers
|
|
31
|
+
}
|
|
32
|
+
});
|
|
33
|
+
};
|
|
34
|
+
/**
|
|
35
|
+
* List design system sources
|
|
36
|
+
*/
|
|
37
|
+
export const designSystemSourceList = (options) => {
|
|
38
|
+
return (options.client ?? _heyApiClient).get({
|
|
39
|
+
url: '/spaces/{spaceId}/environments/{environmentId}/design_systems/sources',
|
|
40
|
+
...options
|
|
41
|
+
});
|
|
42
|
+
};
|
|
43
|
+
/**
|
|
44
|
+
* Soft-disconnect a design system source (space-scoped; never touches GitHub)
|
|
45
|
+
*/
|
|
46
|
+
export const designSystemSourceDisconnect = (options) => {
|
|
47
|
+
return (options.client ?? _heyApiClient).post({
|
|
48
|
+
url: '/spaces/{spaceId}/environments/{environmentId}/design_systems/sources/{sourceId}/disconnect',
|
|
49
|
+
...options
|
|
50
|
+
});
|
|
51
|
+
};
|
|
52
|
+
/**
|
|
53
|
+
* Reconnect a design system source after a fresh liveness re-check
|
|
54
|
+
*/
|
|
55
|
+
export const designSystemSourceReconnect = (options) => {
|
|
56
|
+
return (options.client ?? _heyApiClient).post({
|
|
57
|
+
url: '/spaces/{spaceId}/environments/{environmentId}/design_systems/sources/{sourceId}/reconnect',
|
|
58
|
+
...options
|
|
59
|
+
});
|
|
60
|
+
};
|
|
61
|
+
/**
|
|
62
|
+
* Preview the import diff from a design system source
|
|
63
|
+
*/
|
|
64
|
+
export const designSystemImportCreate = (options) => {
|
|
65
|
+
return (options.client ?? _heyApiClient).post({
|
|
66
|
+
url: '/spaces/{spaceId}/environments/{environmentId}/design_systems/sources/{sourceId}/preview',
|
|
67
|
+
...options,
|
|
68
|
+
headers: {
|
|
69
|
+
'Content-Type': 'application/json',
|
|
70
|
+
...options.headers
|
|
71
|
+
}
|
|
72
|
+
});
|
|
73
|
+
};
|
|
74
|
+
/**
|
|
75
|
+
* Preview import diff from a manifest payload (no source required)
|
|
76
|
+
*/
|
|
77
|
+
export const designSystemImportSourcelessPreview = (options) => {
|
|
78
|
+
return (options.client ?? _heyApiClient).post({
|
|
79
|
+
url: '/spaces/{spaceId}/environments/{environmentId}/design_systems/imports/preview',
|
|
80
|
+
...options,
|
|
81
|
+
headers: {
|
|
82
|
+
'Content-Type': 'application/json',
|
|
83
|
+
...options.headers
|
|
84
|
+
}
|
|
85
|
+
});
|
|
86
|
+
};
|
|
87
|
+
/**
|
|
88
|
+
* Submit selected import changes for asynchronous apply
|
|
89
|
+
*/
|
|
90
|
+
export const designSystemImportApply = (options) => {
|
|
91
|
+
return (options.client ?? _heyApiClient).post({
|
|
92
|
+
url: '/spaces/{spaceId}/environments/{environmentId}/design_systems/imports/apply',
|
|
93
|
+
...options,
|
|
94
|
+
headers: {
|
|
95
|
+
'Content-Type': 'application/json',
|
|
96
|
+
...options.headers
|
|
97
|
+
}
|
|
98
|
+
});
|
|
99
|
+
};
|
|
100
|
+
/**
|
|
101
|
+
* Get the current status of an async apply operation
|
|
102
|
+
*/
|
|
103
|
+
export const designSystemImportGetOperation = (options) => {
|
|
104
|
+
return (options.client ?? _heyApiClient).get({
|
|
105
|
+
url: '/spaces/{spaceId}/environments/{environmentId}/design_systems/imports/apply/{operationId}',
|
|
106
|
+
...options
|
|
107
|
+
});
|
|
108
|
+
};
|
|
109
|
+
/**
|
|
110
|
+
* Check whether the caller can preview or apply design system imports
|
|
111
|
+
*/
|
|
112
|
+
export const designSystemImportPreflight = (options) => {
|
|
113
|
+
return (options.client ?? _heyApiClient).get({
|
|
114
|
+
url: '/spaces/{spaceId}/environments/{environmentId}/design_systems/preflight',
|
|
115
|
+
...options
|
|
116
|
+
});
|
|
117
|
+
};
|
|
118
|
+
/**
|
|
119
|
+
* Generate a GitHub App installation URL
|
|
120
|
+
*/
|
|
121
|
+
export const gitHubInstallationsGenerate = (options) => {
|
|
122
|
+
return (options.client ?? _heyApiClient).post({
|
|
123
|
+
url: '/spaces/{spaceId}/environments/{environmentId}/design_systems/providers/github/installations/url',
|
|
124
|
+
...options,
|
|
125
|
+
headers: {
|
|
126
|
+
'Content-Type': 'application/json',
|
|
127
|
+
...options.headers
|
|
128
|
+
}
|
|
129
|
+
});
|
|
130
|
+
};
|
|
131
|
+
/**
|
|
132
|
+
* List GitHub App installations visible to the service
|
|
133
|
+
*/
|
|
134
|
+
export const gitHubInstallationsList = (options) => {
|
|
135
|
+
return (options.client ?? _heyApiClient).get({
|
|
136
|
+
url: '/spaces/{spaceId}/environments/{environmentId}/design_systems/providers/github/installations',
|
|
137
|
+
...options
|
|
138
|
+
});
|
|
139
|
+
};
|
|
140
|
+
/**
|
|
141
|
+
* Finalize a GitHub install callback into validated provider metadata
|
|
142
|
+
*/
|
|
143
|
+
export const gitHubInstallationsExchange = (options) => {
|
|
144
|
+
return (options.client ?? _heyApiClient).post({
|
|
145
|
+
url: '/spaces/{spaceId}/environments/{environmentId}/design_systems/providers/github/callbacks/install/exchange',
|
|
146
|
+
...options,
|
|
147
|
+
headers: {
|
|
148
|
+
'Content-Type': 'application/json',
|
|
149
|
+
...options.headers
|
|
150
|
+
}
|
|
151
|
+
});
|
|
152
|
+
};
|
|
153
|
+
/**
|
|
154
|
+
* List repositories accessible to a GitHub App installation
|
|
155
|
+
*/
|
|
156
|
+
export const gitHubInstallationRepositoriesList = (options) => {
|
|
157
|
+
return (options.client ?? _heyApiClient).get({
|
|
158
|
+
url: '/spaces/{spaceId}/environments/{environmentId}/design_systems/providers/github/installations/{installationId}/repositories',
|
|
159
|
+
...options
|
|
160
|
+
});
|
|
161
|
+
};
|
|
162
|
+
/**
|
|
163
|
+
* List branches for a repository accessible to an installation
|
|
164
|
+
*/
|
|
165
|
+
export const gitHubRepositoryBranchesList = (options) => {
|
|
166
|
+
return (options.client ?? _heyApiClient).get({
|
|
167
|
+
url: '/spaces/{spaceId}/environments/{environmentId}/design_systems/providers/github/installations/{installationId}/repositories/{owner}/{repo}/branches',
|
|
168
|
+
...options
|
|
169
|
+
});
|
|
170
|
+
};
|
|
171
|
+
/**
|
|
172
|
+
* Read the current GitHub App installation status for an organization
|
|
173
|
+
*/
|
|
174
|
+
export const gitHubInstallationStatusRead = (options) => {
|
|
175
|
+
return (options.client ?? _heyApiClient).get({
|
|
176
|
+
url: '/organizations/{orgId}/design_systems/providers/github/installations/status',
|
|
177
|
+
...options
|
|
178
|
+
});
|
|
179
|
+
};
|