@zyphr-dev/node-sdk 0.1.17 → 0.1.19
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/dist/index.cjs +548 -0
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +622 -1
- package/dist/index.d.ts +622 -1
- package/dist/index.js +497 -0
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/src/.openapi-generator/FILES +10 -0
- package/src/src/apis/ExecutionsApi.ts +225 -0
- package/src/src/apis/index.ts +1 -0
- package/src/src/models/ExecutionCancelResponse.ts +88 -0
- package/src/src/models/ExecutionCancelResponseData.ts +83 -0
- package/src/src/models/ExecutionResponse.ts +88 -0
- package/src/src/models/ExecutionRetryResponse.ts +88 -0
- package/src/src/models/ExecutionRetryResponseData.ts +94 -0
- package/src/src/models/WorkflowExecution.ts +201 -0
- package/src/src/models/WorkflowExecutionStatus.ts +56 -0
- package/src/src/models/WorkflowStepExecution.ts +184 -0
- package/src/src/models/WorkflowStepExecutionStatus.ts +57 -0
- package/src/src/models/index.ts +9 -0
package/package.json
CHANGED
|
@@ -15,6 +15,7 @@ src/apis/AuthUserProfileApi.ts
|
|
|
15
15
|
src/apis/AuthWebAuthnApi.ts
|
|
16
16
|
src/apis/DevicesApi.ts
|
|
17
17
|
src/apis/EmailsApi.ts
|
|
18
|
+
src/apis/ExecutionsApi.ts
|
|
18
19
|
src/apis/InboxApi.ts
|
|
19
20
|
src/apis/PushApi.ts
|
|
20
21
|
src/apis/SMSApi.ts
|
|
@@ -96,6 +97,11 @@ src/models/EmailTrackingOpens.ts
|
|
|
96
97
|
src/models/EmailTrackingResponse.ts
|
|
97
98
|
src/models/EndUserDeleteResponse.ts
|
|
98
99
|
src/models/EndUserDeleteResponseData.ts
|
|
100
|
+
src/models/ExecutionCancelResponse.ts
|
|
101
|
+
src/models/ExecutionCancelResponseData.ts
|
|
102
|
+
src/models/ExecutionResponse.ts
|
|
103
|
+
src/models/ExecutionRetryResponse.ts
|
|
104
|
+
src/models/ExecutionRetryResponseData.ts
|
|
99
105
|
src/models/ForgotPasswordRequest.ts
|
|
100
106
|
src/models/GenerateSubscriberToken200Response.ts
|
|
101
107
|
src/models/GenerateSubscriberToken200ResponseData.ts
|
|
@@ -366,6 +372,10 @@ src/models/WebhookVersion.ts
|
|
|
366
372
|
src/models/WebhookVersionsResponse.ts
|
|
367
373
|
src/models/WebhookVersionsResponseData.ts
|
|
368
374
|
src/models/WithdrawSubscriberConsentRequest.ts
|
|
375
|
+
src/models/WorkflowExecution.ts
|
|
376
|
+
src/models/WorkflowExecutionStatus.ts
|
|
377
|
+
src/models/WorkflowStepExecution.ts
|
|
378
|
+
src/models/WorkflowStepExecutionStatus.ts
|
|
369
379
|
src/models/index.ts
|
|
370
380
|
src/runtime.ts
|
|
371
381
|
tsconfig.esm.json
|
|
@@ -0,0 +1,225 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Zyphr API
|
|
5
|
+
* Zyphr is a multi-channel notification platform that enables developers to send emails, push notifications, SMS, and in-app messages through a unified API. ## Authentication All API requests require authentication using an API key. Include your API key in the `X-API-Key` header: ``` X-API-Key: zy_live_xxxxxxxxxxxx ``` API keys can be created in the Zyphr Dashboard. Use `zy_test_*` keys for testing and `zy_live_*` keys for production. ## Rate Limiting The API implements rate limiting to ensure fair usage. Rate limit information is included in response headers: - `X-RateLimit-Limit`: Maximum requests per window - `X-RateLimit-Remaining`: Remaining requests in current window - `X-RateLimit-Reset`: Unix timestamp when the window resets ## Errors All errors follow a consistent format: ```json { \"error\": { \"code\": \"error_code\", \"message\": \"Human readable message\", \"details\": {} }, \"meta\": { \"request_id\": \"req_xxxx\" } } ```
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.0
|
|
8
|
+
* Contact: support@zyphr.dev
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
import * as runtime from '../runtime';
|
|
17
|
+
import type {
|
|
18
|
+
ApiError,
|
|
19
|
+
ExecutionCancelResponse,
|
|
20
|
+
ExecutionResponse,
|
|
21
|
+
ExecutionRetryResponse,
|
|
22
|
+
} from '../models/index';
|
|
23
|
+
import {
|
|
24
|
+
ApiErrorFromJSON,
|
|
25
|
+
ApiErrorToJSON,
|
|
26
|
+
ExecutionCancelResponseFromJSON,
|
|
27
|
+
ExecutionCancelResponseToJSON,
|
|
28
|
+
ExecutionResponseFromJSON,
|
|
29
|
+
ExecutionResponseToJSON,
|
|
30
|
+
ExecutionRetryResponseFromJSON,
|
|
31
|
+
ExecutionRetryResponseToJSON,
|
|
32
|
+
} from '../models/index';
|
|
33
|
+
|
|
34
|
+
export interface ExecutionsApiCancelExecutionRequest {
|
|
35
|
+
id: string;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
export interface ExecutionsApiGetExecutionRequest {
|
|
39
|
+
id: string;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
export interface ExecutionsApiRetryExecutionRequest {
|
|
43
|
+
id: string;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
/**
|
|
47
|
+
* ExecutionsApi - interface
|
|
48
|
+
*
|
|
49
|
+
* @export
|
|
50
|
+
* @interface ExecutionsApiInterface
|
|
51
|
+
*/
|
|
52
|
+
export interface ExecutionsApiInterface {
|
|
53
|
+
/**
|
|
54
|
+
* Cancel a workflow execution that is still pending or running. Already-terminal executions cannot be cancelled.
|
|
55
|
+
* @summary Cancel a running execution
|
|
56
|
+
* @param {string} id Execution ID
|
|
57
|
+
* @param {*} [options] Override http request option.
|
|
58
|
+
* @throws {RequiredError}
|
|
59
|
+
* @memberof ExecutionsApiInterface
|
|
60
|
+
*/
|
|
61
|
+
cancelExecutionRaw(requestParameters: ExecutionsApiCancelExecutionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ExecutionCancelResponse>>;
|
|
62
|
+
|
|
63
|
+
/**
|
|
64
|
+
* Cancel a workflow execution that is still pending or running. Already-terminal executions cannot be cancelled.
|
|
65
|
+
* Cancel a running execution
|
|
66
|
+
*/
|
|
67
|
+
cancelExecution(id: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ExecutionCancelResponse>;
|
|
68
|
+
|
|
69
|
+
/**
|
|
70
|
+
* Retrieve a workflow execution by ID, including its step execution details.
|
|
71
|
+
* @summary Get a workflow execution
|
|
72
|
+
* @param {string} id Execution ID
|
|
73
|
+
* @param {*} [options] Override http request option.
|
|
74
|
+
* @throws {RequiredError}
|
|
75
|
+
* @memberof ExecutionsApiInterface
|
|
76
|
+
*/
|
|
77
|
+
getExecutionRaw(requestParameters: ExecutionsApiGetExecutionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ExecutionResponse>>;
|
|
78
|
+
|
|
79
|
+
/**
|
|
80
|
+
* Retrieve a workflow execution by ID, including its step execution details.
|
|
81
|
+
* Get a workflow execution
|
|
82
|
+
*/
|
|
83
|
+
getExecution(id: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ExecutionResponse>;
|
|
84
|
+
|
|
85
|
+
/**
|
|
86
|
+
* Create a new workflow execution that re-runs the same workflow with the original subscriber, payload, and sender. Only `failed` or `cancelled` executions can be retried.
|
|
87
|
+
* @summary Retry a failed or cancelled execution
|
|
88
|
+
* @param {string} id ID of the execution to retry
|
|
89
|
+
* @param {*} [options] Override http request option.
|
|
90
|
+
* @throws {RequiredError}
|
|
91
|
+
* @memberof ExecutionsApiInterface
|
|
92
|
+
*/
|
|
93
|
+
retryExecutionRaw(requestParameters: ExecutionsApiRetryExecutionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ExecutionRetryResponse>>;
|
|
94
|
+
|
|
95
|
+
/**
|
|
96
|
+
* Create a new workflow execution that re-runs the same workflow with the original subscriber, payload, and sender. Only `failed` or `cancelled` executions can be retried.
|
|
97
|
+
* Retry a failed or cancelled execution
|
|
98
|
+
*/
|
|
99
|
+
retryExecution(id: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ExecutionRetryResponse>;
|
|
100
|
+
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
/**
|
|
104
|
+
*
|
|
105
|
+
*/
|
|
106
|
+
export class ExecutionsApi extends runtime.BaseAPI implements ExecutionsApiInterface {
|
|
107
|
+
|
|
108
|
+
/**
|
|
109
|
+
* Cancel a workflow execution that is still pending or running. Already-terminal executions cannot be cancelled.
|
|
110
|
+
* Cancel a running execution
|
|
111
|
+
*/
|
|
112
|
+
async cancelExecutionRaw(requestParameters: ExecutionsApiCancelExecutionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ExecutionCancelResponse>> {
|
|
113
|
+
if (requestParameters['id'] == null) {
|
|
114
|
+
throw new runtime.RequiredError(
|
|
115
|
+
'id',
|
|
116
|
+
'Required parameter "id" was null or undefined when calling cancelExecution().'
|
|
117
|
+
);
|
|
118
|
+
}
|
|
119
|
+
|
|
120
|
+
const queryParameters: any = {};
|
|
121
|
+
|
|
122
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
123
|
+
|
|
124
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
125
|
+
headerParameters["X-API-Key"] = await this.configuration.apiKey("X-API-Key"); // ApiKeyAuth authentication
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
const response = await this.request({
|
|
129
|
+
path: `/executions/{id}/cancel`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters['id']))),
|
|
130
|
+
method: 'POST',
|
|
131
|
+
headers: headerParameters,
|
|
132
|
+
query: queryParameters,
|
|
133
|
+
}, initOverrides);
|
|
134
|
+
|
|
135
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => ExecutionCancelResponseFromJSON(jsonValue));
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
/**
|
|
139
|
+
* Cancel a workflow execution that is still pending or running. Already-terminal executions cannot be cancelled.
|
|
140
|
+
* Cancel a running execution
|
|
141
|
+
*/
|
|
142
|
+
async cancelExecution(id: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ExecutionCancelResponse> {
|
|
143
|
+
const response = await this.cancelExecutionRaw({ id: id }, initOverrides);
|
|
144
|
+
return await response.value();
|
|
145
|
+
}
|
|
146
|
+
|
|
147
|
+
/**
|
|
148
|
+
* Retrieve a workflow execution by ID, including its step execution details.
|
|
149
|
+
* Get a workflow execution
|
|
150
|
+
*/
|
|
151
|
+
async getExecutionRaw(requestParameters: ExecutionsApiGetExecutionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ExecutionResponse>> {
|
|
152
|
+
if (requestParameters['id'] == null) {
|
|
153
|
+
throw new runtime.RequiredError(
|
|
154
|
+
'id',
|
|
155
|
+
'Required parameter "id" was null or undefined when calling getExecution().'
|
|
156
|
+
);
|
|
157
|
+
}
|
|
158
|
+
|
|
159
|
+
const queryParameters: any = {};
|
|
160
|
+
|
|
161
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
162
|
+
|
|
163
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
164
|
+
headerParameters["X-API-Key"] = await this.configuration.apiKey("X-API-Key"); // ApiKeyAuth authentication
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
const response = await this.request({
|
|
168
|
+
path: `/executions/{id}`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters['id']))),
|
|
169
|
+
method: 'GET',
|
|
170
|
+
headers: headerParameters,
|
|
171
|
+
query: queryParameters,
|
|
172
|
+
}, initOverrides);
|
|
173
|
+
|
|
174
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => ExecutionResponseFromJSON(jsonValue));
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
/**
|
|
178
|
+
* Retrieve a workflow execution by ID, including its step execution details.
|
|
179
|
+
* Get a workflow execution
|
|
180
|
+
*/
|
|
181
|
+
async getExecution(id: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ExecutionResponse> {
|
|
182
|
+
const response = await this.getExecutionRaw({ id: id }, initOverrides);
|
|
183
|
+
return await response.value();
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
/**
|
|
187
|
+
* Create a new workflow execution that re-runs the same workflow with the original subscriber, payload, and sender. Only `failed` or `cancelled` executions can be retried.
|
|
188
|
+
* Retry a failed or cancelled execution
|
|
189
|
+
*/
|
|
190
|
+
async retryExecutionRaw(requestParameters: ExecutionsApiRetryExecutionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ExecutionRetryResponse>> {
|
|
191
|
+
if (requestParameters['id'] == null) {
|
|
192
|
+
throw new runtime.RequiredError(
|
|
193
|
+
'id',
|
|
194
|
+
'Required parameter "id" was null or undefined when calling retryExecution().'
|
|
195
|
+
);
|
|
196
|
+
}
|
|
197
|
+
|
|
198
|
+
const queryParameters: any = {};
|
|
199
|
+
|
|
200
|
+
const headerParameters: runtime.HTTPHeaders = {};
|
|
201
|
+
|
|
202
|
+
if (this.configuration && this.configuration.apiKey) {
|
|
203
|
+
headerParameters["X-API-Key"] = await this.configuration.apiKey("X-API-Key"); // ApiKeyAuth authentication
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
const response = await this.request({
|
|
207
|
+
path: `/executions/{id}/retry`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters['id']))),
|
|
208
|
+
method: 'POST',
|
|
209
|
+
headers: headerParameters,
|
|
210
|
+
query: queryParameters,
|
|
211
|
+
}, initOverrides);
|
|
212
|
+
|
|
213
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => ExecutionRetryResponseFromJSON(jsonValue));
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
/**
|
|
217
|
+
* Create a new workflow execution that re-runs the same workflow with the original subscriber, payload, and sender. Only `failed` or `cancelled` executions can be retried.
|
|
218
|
+
* Retry a failed or cancelled execution
|
|
219
|
+
*/
|
|
220
|
+
async retryExecution(id: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ExecutionRetryResponse> {
|
|
221
|
+
const response = await this.retryExecutionRaw({ id: id }, initOverrides);
|
|
222
|
+
return await response.value();
|
|
223
|
+
}
|
|
224
|
+
|
|
225
|
+
}
|
package/src/src/apis/index.ts
CHANGED
|
@@ -13,6 +13,7 @@ export * from './AuthUserProfileApi';
|
|
|
13
13
|
export * from './AuthWebAuthnApi';
|
|
14
14
|
export * from './DevicesApi';
|
|
15
15
|
export * from './EmailsApi';
|
|
16
|
+
export * from './ExecutionsApi';
|
|
16
17
|
export * from './InboxApi';
|
|
17
18
|
export * from './PushApi';
|
|
18
19
|
export * from './SMSApi';
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Zyphr API
|
|
5
|
+
* Zyphr is a multi-channel notification platform that enables developers to send emails, push notifications, SMS, and in-app messages through a unified API. ## Authentication All API requests require authentication using an API key. Include your API key in the `X-API-Key` header: ``` X-API-Key: zy_live_xxxxxxxxxxxx ``` API keys can be created in the Zyphr Dashboard. Use `zy_test_*` keys for testing and `zy_live_*` keys for production. ## Rate Limiting The API implements rate limiting to ensure fair usage. Rate limit information is included in response headers: - `X-RateLimit-Limit`: Maximum requests per window - `X-RateLimit-Remaining`: Remaining requests in current window - `X-RateLimit-Reset`: Unix timestamp when the window resets ## Errors All errors follow a consistent format: ```json { \"error\": { \"code\": \"error_code\", \"message\": \"Human readable message\", \"details\": {} }, \"meta\": { \"request_id\": \"req_xxxx\" } } ```
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.0
|
|
8
|
+
* Contact: support@zyphr.dev
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
import type { ExecutionCancelResponseData } from './ExecutionCancelResponseData';
|
|
17
|
+
import {
|
|
18
|
+
ExecutionCancelResponseDataFromJSON,
|
|
19
|
+
ExecutionCancelResponseDataFromJSONTyped,
|
|
20
|
+
ExecutionCancelResponseDataToJSON,
|
|
21
|
+
ExecutionCancelResponseDataToJSONTyped,
|
|
22
|
+
} from './ExecutionCancelResponseData';
|
|
23
|
+
import type { RequestMeta } from './RequestMeta';
|
|
24
|
+
import {
|
|
25
|
+
RequestMetaFromJSON,
|
|
26
|
+
RequestMetaFromJSONTyped,
|
|
27
|
+
RequestMetaToJSON,
|
|
28
|
+
RequestMetaToJSONTyped,
|
|
29
|
+
} from './RequestMeta';
|
|
30
|
+
|
|
31
|
+
/**
|
|
32
|
+
*
|
|
33
|
+
* @export
|
|
34
|
+
* @interface ExecutionCancelResponse
|
|
35
|
+
*/
|
|
36
|
+
export interface ExecutionCancelResponse {
|
|
37
|
+
/**
|
|
38
|
+
*
|
|
39
|
+
* @type {ExecutionCancelResponseData}
|
|
40
|
+
* @memberof ExecutionCancelResponse
|
|
41
|
+
*/
|
|
42
|
+
data?: ExecutionCancelResponseData;
|
|
43
|
+
/**
|
|
44
|
+
*
|
|
45
|
+
* @type {RequestMeta}
|
|
46
|
+
* @memberof ExecutionCancelResponse
|
|
47
|
+
*/
|
|
48
|
+
meta?: RequestMeta;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
/**
|
|
52
|
+
* Check if a given object implements the ExecutionCancelResponse interface.
|
|
53
|
+
*/
|
|
54
|
+
export function instanceOfExecutionCancelResponse(value: object): value is ExecutionCancelResponse {
|
|
55
|
+
return true;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
export function ExecutionCancelResponseFromJSON(json: any): ExecutionCancelResponse {
|
|
59
|
+
return ExecutionCancelResponseFromJSONTyped(json, false);
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
export function ExecutionCancelResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): ExecutionCancelResponse {
|
|
63
|
+
if (json == null) {
|
|
64
|
+
return json;
|
|
65
|
+
}
|
|
66
|
+
return {
|
|
67
|
+
|
|
68
|
+
'data': json['data'] == null ? undefined : ExecutionCancelResponseDataFromJSON(json['data']),
|
|
69
|
+
'meta': json['meta'] == null ? undefined : RequestMetaFromJSON(json['meta']),
|
|
70
|
+
};
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
export function ExecutionCancelResponseToJSON(json: any): ExecutionCancelResponse {
|
|
74
|
+
return ExecutionCancelResponseToJSONTyped(json, false);
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
export function ExecutionCancelResponseToJSONTyped(value?: ExecutionCancelResponse | null, ignoreDiscriminator: boolean = false): any {
|
|
78
|
+
if (value == null) {
|
|
79
|
+
return value;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
return {
|
|
83
|
+
|
|
84
|
+
'data': ExecutionCancelResponseDataToJSON(value['data']),
|
|
85
|
+
'meta': RequestMetaToJSON(value['meta']),
|
|
86
|
+
};
|
|
87
|
+
}
|
|
88
|
+
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Zyphr API
|
|
5
|
+
* Zyphr is a multi-channel notification platform that enables developers to send emails, push notifications, SMS, and in-app messages through a unified API. ## Authentication All API requests require authentication using an API key. Include your API key in the `X-API-Key` header: ``` X-API-Key: zy_live_xxxxxxxxxxxx ``` API keys can be created in the Zyphr Dashboard. Use `zy_test_*` keys for testing and `zy_live_*` keys for production. ## Rate Limiting The API implements rate limiting to ensure fair usage. Rate limit information is included in response headers: - `X-RateLimit-Limit`: Maximum requests per window - `X-RateLimit-Remaining`: Remaining requests in current window - `X-RateLimit-Reset`: Unix timestamp when the window resets ## Errors All errors follow a consistent format: ```json { \"error\": { \"code\": \"error_code\", \"message\": \"Human readable message\", \"details\": {} }, \"meta\": { \"request_id\": \"req_xxxx\" } } ```
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.0
|
|
8
|
+
* Contact: support@zyphr.dev
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
/**
|
|
17
|
+
*
|
|
18
|
+
* @export
|
|
19
|
+
* @interface ExecutionCancelResponseData
|
|
20
|
+
*/
|
|
21
|
+
export interface ExecutionCancelResponseData {
|
|
22
|
+
/**
|
|
23
|
+
*
|
|
24
|
+
* @type {string}
|
|
25
|
+
* @memberof ExecutionCancelResponseData
|
|
26
|
+
*/
|
|
27
|
+
id?: string;
|
|
28
|
+
/**
|
|
29
|
+
*
|
|
30
|
+
* @type {string}
|
|
31
|
+
* @memberof ExecutionCancelResponseData
|
|
32
|
+
*/
|
|
33
|
+
status?: ExecutionCancelResponseDataStatusEnum;
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
/**
|
|
38
|
+
* @export
|
|
39
|
+
*/
|
|
40
|
+
export const ExecutionCancelResponseDataStatusEnum = {
|
|
41
|
+
CANCELLED: 'cancelled'
|
|
42
|
+
} as const;
|
|
43
|
+
export type ExecutionCancelResponseDataStatusEnum = typeof ExecutionCancelResponseDataStatusEnum[keyof typeof ExecutionCancelResponseDataStatusEnum];
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
/**
|
|
47
|
+
* Check if a given object implements the ExecutionCancelResponseData interface.
|
|
48
|
+
*/
|
|
49
|
+
export function instanceOfExecutionCancelResponseData(value: object): value is ExecutionCancelResponseData {
|
|
50
|
+
return true;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
export function ExecutionCancelResponseDataFromJSON(json: any): ExecutionCancelResponseData {
|
|
54
|
+
return ExecutionCancelResponseDataFromJSONTyped(json, false);
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
export function ExecutionCancelResponseDataFromJSONTyped(json: any, ignoreDiscriminator: boolean): ExecutionCancelResponseData {
|
|
58
|
+
if (json == null) {
|
|
59
|
+
return json;
|
|
60
|
+
}
|
|
61
|
+
return {
|
|
62
|
+
|
|
63
|
+
'id': json['id'] == null ? undefined : json['id'],
|
|
64
|
+
'status': json['status'] == null ? undefined : json['status'],
|
|
65
|
+
};
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
export function ExecutionCancelResponseDataToJSON(json: any): ExecutionCancelResponseData {
|
|
69
|
+
return ExecutionCancelResponseDataToJSONTyped(json, false);
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
export function ExecutionCancelResponseDataToJSONTyped(value?: ExecutionCancelResponseData | null, ignoreDiscriminator: boolean = false): any {
|
|
73
|
+
if (value == null) {
|
|
74
|
+
return value;
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
return {
|
|
78
|
+
|
|
79
|
+
'id': value['id'],
|
|
80
|
+
'status': value['status'],
|
|
81
|
+
};
|
|
82
|
+
}
|
|
83
|
+
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Zyphr API
|
|
5
|
+
* Zyphr is a multi-channel notification platform that enables developers to send emails, push notifications, SMS, and in-app messages through a unified API. ## Authentication All API requests require authentication using an API key. Include your API key in the `X-API-Key` header: ``` X-API-Key: zy_live_xxxxxxxxxxxx ``` API keys can be created in the Zyphr Dashboard. Use `zy_test_*` keys for testing and `zy_live_*` keys for production. ## Rate Limiting The API implements rate limiting to ensure fair usage. Rate limit information is included in response headers: - `X-RateLimit-Limit`: Maximum requests per window - `X-RateLimit-Remaining`: Remaining requests in current window - `X-RateLimit-Reset`: Unix timestamp when the window resets ## Errors All errors follow a consistent format: ```json { \"error\": { \"code\": \"error_code\", \"message\": \"Human readable message\", \"details\": {} }, \"meta\": { \"request_id\": \"req_xxxx\" } } ```
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.0
|
|
8
|
+
* Contact: support@zyphr.dev
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
import type { RequestMeta } from './RequestMeta';
|
|
17
|
+
import {
|
|
18
|
+
RequestMetaFromJSON,
|
|
19
|
+
RequestMetaFromJSONTyped,
|
|
20
|
+
RequestMetaToJSON,
|
|
21
|
+
RequestMetaToJSONTyped,
|
|
22
|
+
} from './RequestMeta';
|
|
23
|
+
import type { WorkflowExecution } from './WorkflowExecution';
|
|
24
|
+
import {
|
|
25
|
+
WorkflowExecutionFromJSON,
|
|
26
|
+
WorkflowExecutionFromJSONTyped,
|
|
27
|
+
WorkflowExecutionToJSON,
|
|
28
|
+
WorkflowExecutionToJSONTyped,
|
|
29
|
+
} from './WorkflowExecution';
|
|
30
|
+
|
|
31
|
+
/**
|
|
32
|
+
*
|
|
33
|
+
* @export
|
|
34
|
+
* @interface ExecutionResponse
|
|
35
|
+
*/
|
|
36
|
+
export interface ExecutionResponse {
|
|
37
|
+
/**
|
|
38
|
+
*
|
|
39
|
+
* @type {WorkflowExecution}
|
|
40
|
+
* @memberof ExecutionResponse
|
|
41
|
+
*/
|
|
42
|
+
data?: WorkflowExecution;
|
|
43
|
+
/**
|
|
44
|
+
*
|
|
45
|
+
* @type {RequestMeta}
|
|
46
|
+
* @memberof ExecutionResponse
|
|
47
|
+
*/
|
|
48
|
+
meta?: RequestMeta;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
/**
|
|
52
|
+
* Check if a given object implements the ExecutionResponse interface.
|
|
53
|
+
*/
|
|
54
|
+
export function instanceOfExecutionResponse(value: object): value is ExecutionResponse {
|
|
55
|
+
return true;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
export function ExecutionResponseFromJSON(json: any): ExecutionResponse {
|
|
59
|
+
return ExecutionResponseFromJSONTyped(json, false);
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
export function ExecutionResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): ExecutionResponse {
|
|
63
|
+
if (json == null) {
|
|
64
|
+
return json;
|
|
65
|
+
}
|
|
66
|
+
return {
|
|
67
|
+
|
|
68
|
+
'data': json['data'] == null ? undefined : WorkflowExecutionFromJSON(json['data']),
|
|
69
|
+
'meta': json['meta'] == null ? undefined : RequestMetaFromJSON(json['meta']),
|
|
70
|
+
};
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
export function ExecutionResponseToJSON(json: any): ExecutionResponse {
|
|
74
|
+
return ExecutionResponseToJSONTyped(json, false);
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
export function ExecutionResponseToJSONTyped(value?: ExecutionResponse | null, ignoreDiscriminator: boolean = false): any {
|
|
78
|
+
if (value == null) {
|
|
79
|
+
return value;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
return {
|
|
83
|
+
|
|
84
|
+
'data': WorkflowExecutionToJSON(value['data']),
|
|
85
|
+
'meta': RequestMetaToJSON(value['meta']),
|
|
86
|
+
};
|
|
87
|
+
}
|
|
88
|
+
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Zyphr API
|
|
5
|
+
* Zyphr is a multi-channel notification platform that enables developers to send emails, push notifications, SMS, and in-app messages through a unified API. ## Authentication All API requests require authentication using an API key. Include your API key in the `X-API-Key` header: ``` X-API-Key: zy_live_xxxxxxxxxxxx ``` API keys can be created in the Zyphr Dashboard. Use `zy_test_*` keys for testing and `zy_live_*` keys for production. ## Rate Limiting The API implements rate limiting to ensure fair usage. Rate limit information is included in response headers: - `X-RateLimit-Limit`: Maximum requests per window - `X-RateLimit-Remaining`: Remaining requests in current window - `X-RateLimit-Reset`: Unix timestamp when the window resets ## Errors All errors follow a consistent format: ```json { \"error\": { \"code\": \"error_code\", \"message\": \"Human readable message\", \"details\": {} }, \"meta\": { \"request_id\": \"req_xxxx\" } } ```
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.0
|
|
8
|
+
* Contact: support@zyphr.dev
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
import type { RequestMeta } from './RequestMeta';
|
|
17
|
+
import {
|
|
18
|
+
RequestMetaFromJSON,
|
|
19
|
+
RequestMetaFromJSONTyped,
|
|
20
|
+
RequestMetaToJSON,
|
|
21
|
+
RequestMetaToJSONTyped,
|
|
22
|
+
} from './RequestMeta';
|
|
23
|
+
import type { ExecutionRetryResponseData } from './ExecutionRetryResponseData';
|
|
24
|
+
import {
|
|
25
|
+
ExecutionRetryResponseDataFromJSON,
|
|
26
|
+
ExecutionRetryResponseDataFromJSONTyped,
|
|
27
|
+
ExecutionRetryResponseDataToJSON,
|
|
28
|
+
ExecutionRetryResponseDataToJSONTyped,
|
|
29
|
+
} from './ExecutionRetryResponseData';
|
|
30
|
+
|
|
31
|
+
/**
|
|
32
|
+
*
|
|
33
|
+
* @export
|
|
34
|
+
* @interface ExecutionRetryResponse
|
|
35
|
+
*/
|
|
36
|
+
export interface ExecutionRetryResponse {
|
|
37
|
+
/**
|
|
38
|
+
*
|
|
39
|
+
* @type {ExecutionRetryResponseData}
|
|
40
|
+
* @memberof ExecutionRetryResponse
|
|
41
|
+
*/
|
|
42
|
+
data?: ExecutionRetryResponseData;
|
|
43
|
+
/**
|
|
44
|
+
*
|
|
45
|
+
* @type {RequestMeta}
|
|
46
|
+
* @memberof ExecutionRetryResponse
|
|
47
|
+
*/
|
|
48
|
+
meta?: RequestMeta;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
/**
|
|
52
|
+
* Check if a given object implements the ExecutionRetryResponse interface.
|
|
53
|
+
*/
|
|
54
|
+
export function instanceOfExecutionRetryResponse(value: object): value is ExecutionRetryResponse {
|
|
55
|
+
return true;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
export function ExecutionRetryResponseFromJSON(json: any): ExecutionRetryResponse {
|
|
59
|
+
return ExecutionRetryResponseFromJSONTyped(json, false);
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
export function ExecutionRetryResponseFromJSONTyped(json: any, ignoreDiscriminator: boolean): ExecutionRetryResponse {
|
|
63
|
+
if (json == null) {
|
|
64
|
+
return json;
|
|
65
|
+
}
|
|
66
|
+
return {
|
|
67
|
+
|
|
68
|
+
'data': json['data'] == null ? undefined : ExecutionRetryResponseDataFromJSON(json['data']),
|
|
69
|
+
'meta': json['meta'] == null ? undefined : RequestMetaFromJSON(json['meta']),
|
|
70
|
+
};
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
export function ExecutionRetryResponseToJSON(json: any): ExecutionRetryResponse {
|
|
74
|
+
return ExecutionRetryResponseToJSONTyped(json, false);
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
export function ExecutionRetryResponseToJSONTyped(value?: ExecutionRetryResponse | null, ignoreDiscriminator: boolean = false): any {
|
|
78
|
+
if (value == null) {
|
|
79
|
+
return value;
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
return {
|
|
83
|
+
|
|
84
|
+
'data': ExecutionRetryResponseDataToJSON(value['data']),
|
|
85
|
+
'meta': RequestMetaToJSON(value['meta']),
|
|
86
|
+
};
|
|
87
|
+
}
|
|
88
|
+
|