@amp-labs/react 1.3.0 → 1.4.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.
Files changed (106) hide show
  1. package/build/generated-sources/api/src/apis/APIKeyApi.d.ts +158 -0
  2. package/build/generated-sources/api/src/apis/APIKeyApi.js +188 -0
  3. package/build/generated-sources/api/src/apis/DestinationApi.d.ts +62 -8
  4. package/build/generated-sources/api/src/apis/DestinationApi.js +62 -3
  5. package/build/generated-sources/api/src/apis/OperationApi.d.ts +27 -1
  6. package/build/generated-sources/api/src/apis/OperationApi.js +27 -0
  7. package/build/generated-sources/api/src/apis/OperationEventApi.d.ts +84 -0
  8. package/build/generated-sources/api/src/apis/OperationEventApi.js +110 -0
  9. package/build/generated-sources/api/src/apis/ProviderApi.d.ts +78 -0
  10. package/build/generated-sources/api/src/apis/{OperationLogApi.js → ProviderApi.js} +33 -17
  11. package/build/generated-sources/api/src/apis/index.d.ts +3 -1
  12. package/build/generated-sources/api/src/apis/index.js +3 -1
  13. package/build/generated-sources/api/src/models/ApiKey.d.ts +49 -0
  14. package/build/generated-sources/api/src/models/ApiKey.js +59 -0
  15. package/build/generated-sources/api/src/models/ApiKeyRequest.d.ts +31 -0
  16. package/build/generated-sources/api/src/models/ApiKeyRequest.js +50 -0
  17. package/build/generated-sources/api/src/models/AuthType.d.ts +22 -0
  18. package/build/generated-sources/api/src/models/AuthType.js +35 -0
  19. package/build/generated-sources/api/src/models/CreateDestinationRequest.d.ts +44 -0
  20. package/build/generated-sources/api/src/models/CreateDestinationRequest.js +57 -0
  21. package/build/generated-sources/api/src/models/CreateDestinationRequestMetadata.d.ts +39 -0
  22. package/build/generated-sources/api/src/models/{DestinationMetadata.js → CreateDestinationRequestMetadata.js} +11 -11
  23. package/build/generated-sources/api/src/models/Destination.d.ts +22 -4
  24. package/build/generated-sources/api/src/models/Destination.js +12 -3
  25. package/build/generated-sources/api/src/models/{OperationLog.d.ts → Log.d.ts} +12 -12
  26. package/build/generated-sources/api/src/models/{OperationLog.js → Log.js} +11 -11
  27. package/build/generated-sources/api/src/models/OauthOpts.d.ts +56 -0
  28. package/build/generated-sources/api/src/models/OauthOpts.js +63 -0
  29. package/build/generated-sources/api/src/models/OperationEvent.d.ts +61 -0
  30. package/build/generated-sources/api/src/models/OperationEvent.js +64 -0
  31. package/build/generated-sources/api/src/models/PatchApiKeyRequest.d.ts +38 -0
  32. package/build/generated-sources/api/src/models/PatchApiKeyRequest.js +54 -0
  33. package/build/generated-sources/api/src/models/PatchApiKeyRequestApiKey.d.ts +37 -0
  34. package/build/generated-sources/api/src/models/PatchApiKeyRequestApiKey.js +52 -0
  35. package/build/generated-sources/api/src/models/ProviderInfo.d.ts +60 -0
  36. package/build/generated-sources/api/src/models/ProviderInfo.js +65 -0
  37. package/build/generated-sources/api/src/models/Support.d.ts +55 -0
  38. package/build/generated-sources/api/src/models/Support.js +62 -0
  39. package/build/generated-sources/api/src/models/TokenMetadataFields.d.ts +43 -0
  40. package/build/generated-sources/api/src/models/TokenMetadataFields.js +54 -0
  41. package/build/generated-sources/api/src/models/UpdateDestinationRequest.d.ts +38 -0
  42. package/build/generated-sources/api/src/models/UpdateDestinationRequest.js +54 -0
  43. package/build/generated-sources/api/src/models/UpdateDestinationRequestDestination.d.ts +38 -0
  44. package/build/generated-sources/api/src/models/UpdateDestinationRequestDestination.js +53 -0
  45. package/build/generated-sources/api/src/models/index.d.ts +15 -2
  46. package/build/generated-sources/api/src/models/index.js +15 -2
  47. package/build/src/components/Configure/actions/{createInstallationReducer.d.ts → mutateAndSetState/createInstallationAndSetState.d.ts} +3 -3
  48. package/build/src/components/Configure/actions/{createInstallationReducer.js → mutateAndSetState/createInstallationAndSetState.js} +4 -4
  49. package/build/src/components/Configure/actions/mutateAndSetState/updateInstallationAndSetState.d.ts +15 -0
  50. package/build/src/components/Configure/actions/mutateAndSetState/updateInstallationAndSetState.js +33 -0
  51. package/build/src/components/Configure/actions/proxy/isProxyEnabled.d.ts +2 -0
  52. package/build/src/components/Configure/actions/proxy/isProxyEnabled.js +8 -0
  53. package/build/src/components/Configure/actions/proxy/onCreateInstallationProxyOnly.d.ts +8 -0
  54. package/build/src/components/Configure/actions/proxy/{createInstallationProxyOnly.js → onCreateInstallationProxyOnly.js} +5 -5
  55. package/build/src/components/Configure/actions/{onSaveReadCreateInstallation.d.ts → read/onSaveReadCreateInstallation.d.ts} +2 -2
  56. package/build/src/components/Configure/actions/{onSaveReadCreateInstallation.js → read/onSaveReadCreateInstallation.js} +9 -3
  57. package/build/src/components/Configure/actions/read/onSaveReadUpdateInstallation.d.ts +3 -0
  58. package/build/src/components/Configure/actions/{onSaveReadUpdateInstallation.js → read/onSaveReadUpdateInstallation.js} +20 -28
  59. package/build/src/components/Configure/actions/write/onSaveWriteCreateInstallation.js +10 -3
  60. package/build/src/components/Configure/actions/write/onSaveWriteUpdateInstallation.d.ts +2 -2
  61. package/build/src/components/Configure/actions/write/onSaveWriteUpdateInstallation.js +11 -3
  62. package/build/src/components/Configure/content/CreateInstallation.js +1 -1
  63. package/build/src/components/Configure/content/UpdateInstallation.js +5 -5
  64. package/build/src/components/Configure/layout/ConditionalProxyLayout/ConditionalProxyLayout.js +2 -2
  65. package/build/src/components/Configure/layout/ProtectedConnectionLayout.js +2 -7
  66. package/build/src/components/Configure/nav/ObjectManagementNav/index.js +1 -1
  67. package/build/src/components/Configure/state/utils.js +5 -5
  68. package/build/src/components/ErrorTextBox.js +1 -1
  69. package/build/src/components/Oauth/NoWorkspaceEntry/LandingContent.js +12 -0
  70. package/build/src/components/Oauth/{NoSubdomainEntry/NoSubdomainOauthFlow.d.ts → NoWorkspaceEntry/NoWorkspaceOauthFlow.d.ts} +4 -4
  71. package/build/src/components/Oauth/{NoSubdomainEntry/NoSubdomainOauthFlow.js → NoWorkspaceEntry/NoWorkspaceOauthFlow.js} +13 -17
  72. package/build/src/components/Oauth/OAuthPopup.js +1 -5
  73. package/build/src/components/Oauth/OauthCardLayout.d.ts +6 -0
  74. package/build/src/components/Oauth/OauthCardLayout.js +9 -0
  75. package/build/src/components/Oauth/OauthFlow/OauthFlow.d.ts +9 -0
  76. package/build/src/components/Oauth/OauthFlow/OauthFlow.js +33 -0
  77. package/build/src/components/Oauth/Salesforce/SalesforceSubdomainEntry.d.ts +13 -0
  78. package/build/src/components/Oauth/Salesforce/SalesforceSubdomainEntry.js +18 -0
  79. package/build/src/components/Oauth/WorkspaceEntry/WorkspaceEntry.d.ts +9 -0
  80. package/build/src/components/Oauth/WorkspaceEntry/WorkspaceEntry.js +12 -0
  81. package/build/src/components/Oauth/WorkspaceEntry/WorkspaceOauthFlow.d.ts +14 -0
  82. package/build/src/components/Oauth/WorkspaceEntry/WorkspaceOauthFlow.js +56 -0
  83. package/build/src/components/Oauth/fetchOAuthCallbackURL.d.ts +1 -1
  84. package/build/src/components/Oauth/fetchOAuthCallbackURL.js +1 -1
  85. package/build/src/components/SuccessTextBox.js +1 -1
  86. package/build/src/components/ThemeProvider/Button/buttonTheme.js +3 -3
  87. package/build/src/components/ThemeProvider/index.js +6 -6
  88. package/build/src/services/ApiService.d.ts +2 -2
  89. package/build/src/services/ApiService.js +1 -1
  90. package/build/src/services/api.d.ts +2 -2
  91. package/build/src/services/api.js +5 -0
  92. package/build/src/services/version.d.ts +1 -0
  93. package/build/src/services/version.js +4 -0
  94. package/package.json +3 -3
  95. package/build/generated-sources/api/src/apis/OperationLogApi.d.ts +0 -55
  96. package/build/generated-sources/api/src/models/DestinationMetadata.d.ts +0 -39
  97. package/build/src/components/Configure/actions/onSaveReadUpdateInstallation.d.ts +0 -3
  98. package/build/src/components/Configure/actions/proxy/createInstallationProxyOnly.d.ts +0 -8
  99. package/build/src/components/Oauth/NoSubdomainEntry/LandingContent.js +0 -11
  100. package/build/src/components/Oauth/Salesforce/SalesforceOauthFlow.d.ts +0 -16
  101. package/build/src/components/Oauth/Salesforce/SalesforceOauthFlow.js +0 -57
  102. package/build/src/components/Oauth/Salesforce/SubdomainEntry.d.ts +0 -8
  103. package/build/src/components/Oauth/Salesforce/SubdomainEntry.js +0 -12
  104. package/build/src/constants.d.ts +0 -2
  105. package/build/src/constants.js +0 -5
  106. /package/build/src/components/Oauth/{NoSubdomainEntry → NoWorkspaceEntry}/LandingContent.d.ts +0 -0
@@ -0,0 +1,158 @@
1
+ /**
2
+ * Ampersand public API
3
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
4
+ *
5
+ * The version of the OpenAPI document: 1.0.0
6
+ *
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import * as runtime from '../runtime';
13
+ import type { ApiKey, ApiKeyRequest, PatchApiKeyRequest } from '../models';
14
+ export interface CreateApiKeyRequest {
15
+ projectId: string;
16
+ apiKey: ApiKeyRequest;
17
+ }
18
+ export interface DeleteApiKeyRequest {
19
+ projectId: string;
20
+ apiKey: string;
21
+ }
22
+ export interface GetApiKeyRequest {
23
+ projectId: string;
24
+ apiKey: string;
25
+ }
26
+ export interface ListApiKeysRequest {
27
+ projectId: string;
28
+ active?: boolean;
29
+ }
30
+ export interface UpdateApiKeyRequest {
31
+ projectId: string;
32
+ apiKey: string;
33
+ patchApiKeyRequest: PatchApiKeyRequest;
34
+ }
35
+ /**
36
+ * APIKeyApi - interface
37
+ *
38
+ * @export
39
+ * @interface APIKeyApiInterface
40
+ */
41
+ export interface APIKeyApiInterface {
42
+ /**
43
+ *
44
+ * @summary Create a new API key
45
+ * @param {string} projectId
46
+ * @param {ApiKeyRequest} apiKey
47
+ * @param {*} [options] Override http request option.
48
+ * @throws {RequiredError}
49
+ * @memberof APIKeyApiInterface
50
+ */
51
+ createApiKeyRaw(requestParameters: CreateApiKeyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ApiKey>>;
52
+ /**
53
+ * Create a new API key
54
+ */
55
+ createApiKey(requestParameters: CreateApiKeyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ApiKey>;
56
+ /**
57
+ *
58
+ * @summary Delete an API key
59
+ * @param {string} projectId
60
+ * @param {string} apiKey
61
+ * @param {*} [options] Override http request option.
62
+ * @throws {RequiredError}
63
+ * @memberof APIKeyApiInterface
64
+ */
65
+ deleteApiKeyRaw(requestParameters: DeleteApiKeyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
66
+ /**
67
+ * Delete an API key
68
+ */
69
+ deleteApiKey(requestParameters: DeleteApiKeyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
70
+ /**
71
+ *
72
+ * @summary Get an API key
73
+ * @param {string} projectId
74
+ * @param {string} apiKey
75
+ * @param {*} [options] Override http request option.
76
+ * @throws {RequiredError}
77
+ * @memberof APIKeyApiInterface
78
+ */
79
+ getApiKeyRaw(requestParameters: GetApiKeyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ApiKey>>;
80
+ /**
81
+ * Get an API key
82
+ */
83
+ getApiKey(requestParameters: GetApiKeyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ApiKey>;
84
+ /**
85
+ *
86
+ * @summary List API keys
87
+ * @param {string} projectId
88
+ * @param {boolean} [active] Whether to include only active API keys. If false, all API keys are included.
89
+ * @param {*} [options] Override http request option.
90
+ * @throws {RequiredError}
91
+ * @memberof APIKeyApiInterface
92
+ */
93
+ listApiKeysRaw(requestParameters: ListApiKeysRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<ApiKey>>>;
94
+ /**
95
+ * List API keys
96
+ */
97
+ listApiKeys(requestParameters: ListApiKeysRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<ApiKey>>;
98
+ /**
99
+ *
100
+ * @summary Update an API key
101
+ * @param {string} projectId
102
+ * @param {string} apiKey
103
+ * @param {PatchApiKeyRequest} patchApiKeyRequest
104
+ * @param {*} [options] Override http request option.
105
+ * @throws {RequiredError}
106
+ * @memberof APIKeyApiInterface
107
+ */
108
+ updateApiKeyRaw(requestParameters: UpdateApiKeyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ApiKey>>;
109
+ /**
110
+ * Update an API key
111
+ */
112
+ updateApiKey(requestParameters: UpdateApiKeyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ApiKey>;
113
+ }
114
+ /**
115
+ *
116
+ */
117
+ export declare class APIKeyApi extends runtime.BaseAPI implements APIKeyApiInterface {
118
+ /**
119
+ * Create a new API key
120
+ */
121
+ createApiKeyRaw(requestParameters: CreateApiKeyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ApiKey>>;
122
+ /**
123
+ * Create a new API key
124
+ */
125
+ createApiKey(requestParameters: CreateApiKeyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ApiKey>;
126
+ /**
127
+ * Delete an API key
128
+ */
129
+ deleteApiKeyRaw(requestParameters: DeleteApiKeyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
130
+ /**
131
+ * Delete an API key
132
+ */
133
+ deleteApiKey(requestParameters: DeleteApiKeyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
134
+ /**
135
+ * Get an API key
136
+ */
137
+ getApiKeyRaw(requestParameters: GetApiKeyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ApiKey>>;
138
+ /**
139
+ * Get an API key
140
+ */
141
+ getApiKey(requestParameters: GetApiKeyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ApiKey>;
142
+ /**
143
+ * List API keys
144
+ */
145
+ listApiKeysRaw(requestParameters: ListApiKeysRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<ApiKey>>>;
146
+ /**
147
+ * List API keys
148
+ */
149
+ listApiKeys(requestParameters: ListApiKeysRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<ApiKey>>;
150
+ /**
151
+ * Update an API key
152
+ */
153
+ updateApiKeyRaw(requestParameters: UpdateApiKeyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ApiKey>>;
154
+ /**
155
+ * Update an API key
156
+ */
157
+ updateApiKey(requestParameters: UpdateApiKeyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ApiKey>;
158
+ }
@@ -0,0 +1,188 @@
1
+ "use strict";
2
+ /* tslint:disable */
3
+ /* eslint-disable */
4
+ /**
5
+ * Ampersand public API
6
+ * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
7
+ *
8
+ * The version of the OpenAPI document: 1.0.0
9
+ *
10
+ *
11
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
12
+ * https://openapi-generator.tech
13
+ * Do not edit the class manually.
14
+ */
15
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
16
+ if (k2 === undefined) k2 = k;
17
+ var desc = Object.getOwnPropertyDescriptor(m, k);
18
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
19
+ desc = { enumerable: true, get: function() { return m[k]; } };
20
+ }
21
+ Object.defineProperty(o, k2, desc);
22
+ }) : (function(o, m, k, k2) {
23
+ if (k2 === undefined) k2 = k;
24
+ o[k2] = m[k];
25
+ }));
26
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
27
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
28
+ }) : function(o, v) {
29
+ o["default"] = v;
30
+ });
31
+ var __importStar = (this && this.__importStar) || function (mod) {
32
+ if (mod && mod.__esModule) return mod;
33
+ var result = {};
34
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
35
+ __setModuleDefault(result, mod);
36
+ return result;
37
+ };
38
+ Object.defineProperty(exports, "__esModule", { value: true });
39
+ exports.APIKeyApi = void 0;
40
+ const runtime = __importStar(require("../runtime"));
41
+ const models_1 = require("../models");
42
+ /**
43
+ *
44
+ */
45
+ class APIKeyApi extends runtime.BaseAPI {
46
+ /**
47
+ * Create a new API key
48
+ */
49
+ async createApiKeyRaw(requestParameters, initOverrides) {
50
+ if (requestParameters.projectId === null || requestParameters.projectId === undefined) {
51
+ throw new runtime.RequiredError('projectId', 'Required parameter requestParameters.projectId was null or undefined when calling createApiKey.');
52
+ }
53
+ if (requestParameters.apiKey === null || requestParameters.apiKey === undefined) {
54
+ throw new runtime.RequiredError('apiKey', 'Required parameter requestParameters.apiKey was null or undefined when calling createApiKey.');
55
+ }
56
+ const queryParameters = {};
57
+ const headerParameters = {};
58
+ headerParameters['Content-Type'] = 'application/json';
59
+ const response = await this.request({
60
+ path: `/projects/{projectId}/api-keys`.replace(`{${"projectId"}}`, encodeURIComponent(String(requestParameters.projectId))),
61
+ method: 'POST',
62
+ headers: headerParameters,
63
+ query: queryParameters,
64
+ body: (0, models_1.ApiKeyRequestToJSON)(requestParameters.apiKey),
65
+ }, initOverrides);
66
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, models_1.ApiKeyFromJSON)(jsonValue));
67
+ }
68
+ /**
69
+ * Create a new API key
70
+ */
71
+ async createApiKey(requestParameters, initOverrides) {
72
+ const response = await this.createApiKeyRaw(requestParameters, initOverrides);
73
+ return await response.value();
74
+ }
75
+ /**
76
+ * Delete an API key
77
+ */
78
+ async deleteApiKeyRaw(requestParameters, initOverrides) {
79
+ if (requestParameters.projectId === null || requestParameters.projectId === undefined) {
80
+ throw new runtime.RequiredError('projectId', 'Required parameter requestParameters.projectId was null or undefined when calling deleteApiKey.');
81
+ }
82
+ if (requestParameters.apiKey === null || requestParameters.apiKey === undefined) {
83
+ throw new runtime.RequiredError('apiKey', 'Required parameter requestParameters.apiKey was null or undefined when calling deleteApiKey.');
84
+ }
85
+ const queryParameters = {};
86
+ const headerParameters = {};
87
+ const response = await this.request({
88
+ path: `/projects/{projectId}/api-keys/{apiKey}`.replace(`{${"projectId"}}`, encodeURIComponent(String(requestParameters.projectId))).replace(`{${"apiKey"}}`, encodeURIComponent(String(requestParameters.apiKey))),
89
+ method: 'DELETE',
90
+ headers: headerParameters,
91
+ query: queryParameters,
92
+ }, initOverrides);
93
+ return new runtime.VoidApiResponse(response);
94
+ }
95
+ /**
96
+ * Delete an API key
97
+ */
98
+ async deleteApiKey(requestParameters, initOverrides) {
99
+ await this.deleteApiKeyRaw(requestParameters, initOverrides);
100
+ }
101
+ /**
102
+ * Get an API key
103
+ */
104
+ async getApiKeyRaw(requestParameters, initOverrides) {
105
+ if (requestParameters.projectId === null || requestParameters.projectId === undefined) {
106
+ throw new runtime.RequiredError('projectId', 'Required parameter requestParameters.projectId was null or undefined when calling getApiKey.');
107
+ }
108
+ if (requestParameters.apiKey === null || requestParameters.apiKey === undefined) {
109
+ throw new runtime.RequiredError('apiKey', 'Required parameter requestParameters.apiKey was null or undefined when calling getApiKey.');
110
+ }
111
+ const queryParameters = {};
112
+ const headerParameters = {};
113
+ const response = await this.request({
114
+ path: `/projects/{projectId}/api-keys/{apiKey}`.replace(`{${"projectId"}}`, encodeURIComponent(String(requestParameters.projectId))).replace(`{${"apiKey"}}`, encodeURIComponent(String(requestParameters.apiKey))),
115
+ method: 'GET',
116
+ headers: headerParameters,
117
+ query: queryParameters,
118
+ }, initOverrides);
119
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, models_1.ApiKeyFromJSON)(jsonValue));
120
+ }
121
+ /**
122
+ * Get an API key
123
+ */
124
+ async getApiKey(requestParameters, initOverrides) {
125
+ const response = await this.getApiKeyRaw(requestParameters, initOverrides);
126
+ return await response.value();
127
+ }
128
+ /**
129
+ * List API keys
130
+ */
131
+ async listApiKeysRaw(requestParameters, initOverrides) {
132
+ if (requestParameters.projectId === null || requestParameters.projectId === undefined) {
133
+ throw new runtime.RequiredError('projectId', 'Required parameter requestParameters.projectId was null or undefined when calling listApiKeys.');
134
+ }
135
+ const queryParameters = {};
136
+ if (requestParameters.active !== undefined) {
137
+ queryParameters['active'] = requestParameters.active;
138
+ }
139
+ const headerParameters = {};
140
+ const response = await this.request({
141
+ path: `/projects/{projectId}/api-keys`.replace(`{${"projectId"}}`, encodeURIComponent(String(requestParameters.projectId))),
142
+ method: 'GET',
143
+ headers: headerParameters,
144
+ query: queryParameters,
145
+ }, initOverrides);
146
+ return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(models_1.ApiKeyFromJSON));
147
+ }
148
+ /**
149
+ * List API keys
150
+ */
151
+ async listApiKeys(requestParameters, initOverrides) {
152
+ const response = await this.listApiKeysRaw(requestParameters, initOverrides);
153
+ return await response.value();
154
+ }
155
+ /**
156
+ * Update an API key
157
+ */
158
+ async updateApiKeyRaw(requestParameters, initOverrides) {
159
+ if (requestParameters.projectId === null || requestParameters.projectId === undefined) {
160
+ throw new runtime.RequiredError('projectId', 'Required parameter requestParameters.projectId was null or undefined when calling updateApiKey.');
161
+ }
162
+ if (requestParameters.apiKey === null || requestParameters.apiKey === undefined) {
163
+ throw new runtime.RequiredError('apiKey', 'Required parameter requestParameters.apiKey was null or undefined when calling updateApiKey.');
164
+ }
165
+ if (requestParameters.patchApiKeyRequest === null || requestParameters.patchApiKeyRequest === undefined) {
166
+ throw new runtime.RequiredError('patchApiKeyRequest', 'Required parameter requestParameters.patchApiKeyRequest was null or undefined when calling updateApiKey.');
167
+ }
168
+ const queryParameters = {};
169
+ const headerParameters = {};
170
+ headerParameters['Content-Type'] = 'application/json';
171
+ const response = await this.request({
172
+ path: `/projects/{projectId}/api-keys/{apiKey}`.replace(`{${"projectId"}}`, encodeURIComponent(String(requestParameters.projectId))).replace(`{${"apiKey"}}`, encodeURIComponent(String(requestParameters.apiKey))),
173
+ method: 'PATCH',
174
+ headers: headerParameters,
175
+ query: queryParameters,
176
+ body: (0, models_1.PatchApiKeyRequestToJSON)(requestParameters.patchApiKeyRequest),
177
+ }, initOverrides);
178
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, models_1.ApiKeyFromJSON)(jsonValue));
179
+ }
180
+ /**
181
+ * Update an API key
182
+ */
183
+ async updateApiKey(requestParameters, initOverrides) {
184
+ const response = await this.updateApiKeyRaw(requestParameters, initOverrides);
185
+ return await response.value();
186
+ }
187
+ }
188
+ exports.APIKeyApi = APIKeyApi;
@@ -10,10 +10,14 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  import * as runtime from '../runtime';
13
- import type { Destination } from '../models';
14
- export interface CreateDestinationRequest {
13
+ import type { CreateDestinationRequest, Destination, UpdateDestinationRequest } from '../models';
14
+ export interface CreateDestinationOperationRequest {
15
15
  projectId: string;
16
- destination: Destination;
16
+ destination: CreateDestinationRequest;
17
+ }
18
+ export interface DeleteDestinationRequest {
19
+ projectId: string;
20
+ destinationId: string;
17
21
  }
18
22
  export interface GetDestinationRequest {
19
23
  projectId: string;
@@ -22,6 +26,11 @@ export interface GetDestinationRequest {
22
26
  export interface ListDestinationsRequest {
23
27
  projectId: string;
24
28
  }
29
+ export interface UpdateDestinationOperationRequest {
30
+ projectId: string;
31
+ destinationId: string;
32
+ destinationUpdate: UpdateDestinationRequest;
33
+ }
25
34
  /**
26
35
  * DestinationApi - interface
27
36
  *
@@ -33,16 +42,30 @@ export interface DestinationApiInterface {
33
42
  *
34
43
  * @summary Create a new destination
35
44
  * @param {string} projectId
36
- * @param {Destination} destination
45
+ * @param {CreateDestinationRequest} destination
37
46
  * @param {*} [options] Override http request option.
38
47
  * @throws {RequiredError}
39
48
  * @memberof DestinationApiInterface
40
49
  */
41
- createDestinationRaw(requestParameters: CreateDestinationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
50
+ createDestinationRaw(requestParameters: CreateDestinationOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Destination>>;
42
51
  /**
43
52
  * Create a new destination
44
53
  */
45
- createDestination(requestParameters: CreateDestinationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
54
+ createDestination(requestParameters: CreateDestinationOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Destination>;
55
+ /**
56
+ *
57
+ * @summary Delete a destination
58
+ * @param {string} projectId
59
+ * @param {string} destinationId
60
+ * @param {*} [options] Override http request option.
61
+ * @throws {RequiredError}
62
+ * @memberof DestinationApiInterface
63
+ */
64
+ deleteDestinationRaw(requestParameters: DeleteDestinationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
65
+ /**
66
+ * Delete a destination
67
+ */
68
+ deleteDestination(requestParameters: DeleteDestinationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
46
69
  /**
47
70
  *
48
71
  * @summary Get a destination
@@ -70,6 +93,21 @@ export interface DestinationApiInterface {
70
93
  * List destinations
71
94
  */
72
95
  listDestinations(requestParameters: ListDestinationsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<Destination>>;
96
+ /**
97
+ *
98
+ * @summary Update a destination
99
+ * @param {string} projectId
100
+ * @param {string} destinationId
101
+ * @param {UpdateDestinationRequest} destinationUpdate
102
+ * @param {*} [options] Override http request option.
103
+ * @throws {RequiredError}
104
+ * @memberof DestinationApiInterface
105
+ */
106
+ updateDestinationRaw(requestParameters: UpdateDestinationOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Destination>>;
107
+ /**
108
+ * Update a destination
109
+ */
110
+ updateDestination(requestParameters: UpdateDestinationOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Destination>;
73
111
  }
74
112
  /**
75
113
  *
@@ -78,11 +116,19 @@ export declare class DestinationApi extends runtime.BaseAPI implements Destinati
78
116
  /**
79
117
  * Create a new destination
80
118
  */
81
- createDestinationRaw(requestParameters: CreateDestinationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
119
+ createDestinationRaw(requestParameters: CreateDestinationOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Destination>>;
82
120
  /**
83
121
  * Create a new destination
84
122
  */
85
- createDestination(requestParameters: CreateDestinationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
123
+ createDestination(requestParameters: CreateDestinationOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Destination>;
124
+ /**
125
+ * Delete a destination
126
+ */
127
+ deleteDestinationRaw(requestParameters: DeleteDestinationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
128
+ /**
129
+ * Delete a destination
130
+ */
131
+ deleteDestination(requestParameters: DeleteDestinationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
86
132
  /**
87
133
  * Get a destination
88
134
  */
@@ -99,4 +145,12 @@ export declare class DestinationApi extends runtime.BaseAPI implements Destinati
99
145
  * List destinations
100
146
  */
101
147
  listDestinations(requestParameters: ListDestinationsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<Destination>>;
148
+ /**
149
+ * Update a destination
150
+ */
151
+ updateDestinationRaw(requestParameters: UpdateDestinationOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Destination>>;
152
+ /**
153
+ * Update a destination
154
+ */
155
+ updateDestination(requestParameters: UpdateDestinationOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Destination>;
102
156
  }
@@ -61,15 +61,42 @@ class DestinationApi extends runtime.BaseAPI {
61
61
  method: 'POST',
62
62
  headers: headerParameters,
63
63
  query: queryParameters,
64
- body: (0, models_1.DestinationToJSON)(requestParameters.destination),
64
+ body: (0, models_1.CreateDestinationRequestToJSON)(requestParameters.destination),
65
65
  }, initOverrides);
66
- return new runtime.VoidApiResponse(response);
66
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, models_1.DestinationFromJSON)(jsonValue));
67
67
  }
68
68
  /**
69
69
  * Create a new destination
70
70
  */
71
71
  async createDestination(requestParameters, initOverrides) {
72
- await this.createDestinationRaw(requestParameters, initOverrides);
72
+ const response = await this.createDestinationRaw(requestParameters, initOverrides);
73
+ return await response.value();
74
+ }
75
+ /**
76
+ * Delete a destination
77
+ */
78
+ async deleteDestinationRaw(requestParameters, initOverrides) {
79
+ if (requestParameters.projectId === null || requestParameters.projectId === undefined) {
80
+ throw new runtime.RequiredError('projectId', 'Required parameter requestParameters.projectId was null or undefined when calling deleteDestination.');
81
+ }
82
+ if (requestParameters.destinationId === null || requestParameters.destinationId === undefined) {
83
+ throw new runtime.RequiredError('destinationId', 'Required parameter requestParameters.destinationId was null or undefined when calling deleteDestination.');
84
+ }
85
+ const queryParameters = {};
86
+ const headerParameters = {};
87
+ const response = await this.request({
88
+ path: `/projects/{projectId}/destinations/{destinationId}`.replace(`{${"projectId"}}`, encodeURIComponent(String(requestParameters.projectId))).replace(`{${"destinationId"}}`, encodeURIComponent(String(requestParameters.destinationId))),
89
+ method: 'DELETE',
90
+ headers: headerParameters,
91
+ query: queryParameters,
92
+ }, initOverrides);
93
+ return new runtime.VoidApiResponse(response);
94
+ }
95
+ /**
96
+ * Delete a destination
97
+ */
98
+ async deleteDestination(requestParameters, initOverrides) {
99
+ await this.deleteDestinationRaw(requestParameters, initOverrides);
73
100
  }
74
101
  /**
75
102
  * Get a destination
@@ -122,5 +149,37 @@ class DestinationApi extends runtime.BaseAPI {
122
149
  const response = await this.listDestinationsRaw(requestParameters, initOverrides);
123
150
  return await response.value();
124
151
  }
152
+ /**
153
+ * Update a destination
154
+ */
155
+ async updateDestinationRaw(requestParameters, initOverrides) {
156
+ if (requestParameters.projectId === null || requestParameters.projectId === undefined) {
157
+ throw new runtime.RequiredError('projectId', 'Required parameter requestParameters.projectId was null or undefined when calling updateDestination.');
158
+ }
159
+ if (requestParameters.destinationId === null || requestParameters.destinationId === undefined) {
160
+ throw new runtime.RequiredError('destinationId', 'Required parameter requestParameters.destinationId was null or undefined when calling updateDestination.');
161
+ }
162
+ if (requestParameters.destinationUpdate === null || requestParameters.destinationUpdate === undefined) {
163
+ throw new runtime.RequiredError('destinationUpdate', 'Required parameter requestParameters.destinationUpdate was null or undefined when calling updateDestination.');
164
+ }
165
+ const queryParameters = {};
166
+ const headerParameters = {};
167
+ headerParameters['Content-Type'] = 'application/json';
168
+ const response = await this.request({
169
+ path: `/projects/{projectId}/destinations/{destinationId}`.replace(`{${"projectId"}}`, encodeURIComponent(String(requestParameters.projectId))).replace(`{${"destinationId"}}`, encodeURIComponent(String(requestParameters.destinationId))),
170
+ method: 'PATCH',
171
+ headers: headerParameters,
172
+ query: queryParameters,
173
+ body: (0, models_1.UpdateDestinationRequestToJSON)(requestParameters.destinationUpdate),
174
+ }, initOverrides);
175
+ return new runtime.JSONApiResponse(response, (jsonValue) => (0, models_1.DestinationFromJSON)(jsonValue));
176
+ }
177
+ /**
178
+ * Update a destination
179
+ */
180
+ async updateDestination(requestParameters, initOverrides) {
181
+ const response = await this.updateDestinationRaw(requestParameters, initOverrides);
182
+ return await response.value();
183
+ }
125
184
  }
126
185
  exports.DestinationApi = DestinationApi;
@@ -10,11 +10,15 @@
10
10
  * Do not edit the class manually.
11
11
  */
12
12
  import * as runtime from '../runtime';
13
- import type { Operation } from '../models';
13
+ import type { Log, Operation } from '../models';
14
14
  export interface GetOperationRequest {
15
15
  projectId: string;
16
16
  operationId: string;
17
17
  }
18
+ export interface ListOperationLogsRequest {
19
+ projectId: string;
20
+ operationId: string;
21
+ }
18
22
  export interface ListOperationsRequest {
19
23
  projectId: string;
20
24
  integrationId: string;
@@ -41,6 +45,20 @@ export interface OperationApiInterface {
41
45
  * Get an operation
42
46
  */
43
47
  getOperation(requestParameters: GetOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Operation>;
48
+ /**
49
+ *
50
+ * @summary List logs for an operation
51
+ * @param {string} projectId
52
+ * @param {string} operationId
53
+ * @param {*} [options] Override http request option.
54
+ * @throws {RequiredError}
55
+ * @memberof OperationApiInterface
56
+ */
57
+ listOperationLogsRaw(requestParameters: ListOperationLogsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<Log>>>;
58
+ /**
59
+ * List logs for an operation
60
+ */
61
+ listOperationLogs(requestParameters: ListOperationLogsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<Log>>;
44
62
  /**
45
63
  *
46
64
  * @summary List operations
@@ -69,6 +87,14 @@ export declare class OperationApi extends runtime.BaseAPI implements OperationAp
69
87
  * Get an operation
70
88
  */
71
89
  getOperation(requestParameters: GetOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Operation>;
90
+ /**
91
+ * List logs for an operation
92
+ */
93
+ listOperationLogsRaw(requestParameters: ListOperationLogsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<Array<Log>>>;
94
+ /**
95
+ * List logs for an operation
96
+ */
97
+ listOperationLogs(requestParameters: ListOperationLogsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<Array<Log>>;
72
98
  /**
73
99
  * List operations
74
100
  */
@@ -70,6 +70,33 @@ class OperationApi extends runtime.BaseAPI {
70
70
  const response = await this.getOperationRaw(requestParameters, initOverrides);
71
71
  return await response.value();
72
72
  }
73
+ /**
74
+ * List logs for an operation
75
+ */
76
+ async listOperationLogsRaw(requestParameters, initOverrides) {
77
+ if (requestParameters.projectId === null || requestParameters.projectId === undefined) {
78
+ throw new runtime.RequiredError('projectId', 'Required parameter requestParameters.projectId was null or undefined when calling listOperationLogs.');
79
+ }
80
+ if (requestParameters.operationId === null || requestParameters.operationId === undefined) {
81
+ throw new runtime.RequiredError('operationId', 'Required parameter requestParameters.operationId was null or undefined when calling listOperationLogs.');
82
+ }
83
+ const queryParameters = {};
84
+ const headerParameters = {};
85
+ const response = await this.request({
86
+ path: `/projects/{projectId}/operations/{operationId}/logs`.replace(`{${"projectId"}}`, encodeURIComponent(String(requestParameters.projectId))).replace(`{${"operationId"}}`, encodeURIComponent(String(requestParameters.operationId))),
87
+ method: 'GET',
88
+ headers: headerParameters,
89
+ query: queryParameters,
90
+ }, initOverrides);
91
+ return new runtime.JSONApiResponse(response, (jsonValue) => jsonValue.map(models_1.LogFromJSON));
92
+ }
93
+ /**
94
+ * List logs for an operation
95
+ */
96
+ async listOperationLogs(requestParameters, initOverrides) {
97
+ const response = await this.listOperationLogsRaw(requestParameters, initOverrides);
98
+ return await response.value();
99
+ }
73
100
  /**
74
101
  * List operations
75
102
  */