@hatchet-dev/typescript-sdk 0.0.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/.eslintrc.json +36 -0
- package/.prettierrc.json +6 -0
- package/README.md +4 -0
- package/dist/hatchet/clients/admin/admin-client.d.ts +14 -0
- package/dist/hatchet/clients/admin/admin-client.js +50 -0
- package/dist/hatchet/clients/admin/admin-client.test.d.ts +1 -0
- package/dist/hatchet/clients/admin/admin-client.test.js +101 -0
- package/dist/hatchet/clients/dispatcher/action-listener.d.ts +24 -0
- package/dist/hatchet/clients/dispatcher/action-listener.js +113 -0
- package/dist/hatchet/clients/dispatcher/action-listener.test.d.ts +4 -0
- package/dist/hatchet/clients/dispatcher/action-listener.test.js +277 -0
- package/dist/hatchet/clients/dispatcher/dispatcher-client.d.ts +17 -0
- package/dist/hatchet/clients/dispatcher/dispatcher-client.js +46 -0
- package/dist/hatchet/clients/dispatcher/dispatcher-client.test.d.ts +1 -0
- package/dist/hatchet/clients/dispatcher/dispatcher-client.test.js +99 -0
- package/dist/hatchet/clients/event/event-client.d.ts +9 -0
- package/dist/hatchet/clients/event/event-client.js +28 -0
- package/dist/hatchet/clients/event/event-client.test.d.ts +1 -0
- package/dist/hatchet/clients/event/event-client.test.js +60 -0
- package/dist/hatchet/clients/hatchet-client/client-config.d.ts +72 -0
- package/dist/hatchet/clients/hatchet-client/client-config.js +17 -0
- package/dist/hatchet/clients/hatchet-client/hatchet-client.d.ts +26 -0
- package/dist/hatchet/clients/hatchet-client/hatchet-client.js +133 -0
- package/dist/hatchet/clients/hatchet-client/hatchet-client.test.d.ts +2 -0
- package/dist/hatchet/clients/hatchet-client/hatchet-client.test.js +135 -0
- package/dist/hatchet/clients/hatchet-client/index.d.ts +2 -0
- package/dist/hatchet/clients/hatchet-client/index.js +18 -0
- package/dist/hatchet/clients/worker/index.d.ts +1 -0
- package/dist/hatchet/clients/worker/index.js +17 -0
- package/dist/hatchet/clients/worker/worker.d.ts +31 -0
- package/dist/hatchet/clients/worker/worker.js +228 -0
- package/dist/hatchet/clients/worker/worker.test.d.ts +1 -0
- package/dist/hatchet/clients/worker/worker.test.js +256 -0
- package/dist/hatchet/index.d.ts +2 -0
- package/dist/hatchet/index.js +4 -0
- package/dist/hatchet/sdk.d.ts +2 -0
- package/dist/hatchet/sdk.js +4 -0
- package/dist/hatchet/step.d.ts +30 -0
- package/dist/hatchet/step.js +63 -0
- package/dist/hatchet/util/config-loader/config-loader.d.ts +13 -0
- package/dist/hatchet/util/config-loader/config-loader.js +85 -0
- package/dist/hatchet/util/config-loader/config-loader.test.d.ts +1 -0
- package/dist/hatchet/util/config-loader/config-loader.test.js +72 -0
- package/dist/hatchet/util/config-loader/index.d.ts +1 -0
- package/dist/hatchet/util/config-loader/index.js +17 -0
- package/dist/hatchet/util/errors/hatchet-error.d.ts +4 -0
- package/dist/hatchet/util/errors/hatchet-error.js +9 -0
- package/dist/hatchet/util/hatchet-promise/hatchet-promise.d.ts +6 -0
- package/dist/hatchet/util/hatchet-promise/hatchet-promise.js +12 -0
- package/dist/hatchet/util/hatchet-promise/hatchet-promise.test.d.ts +1 -0
- package/dist/hatchet/util/hatchet-promise/hatchet-promise.test.js +40 -0
- package/dist/hatchet/util/logger/index.d.ts +1 -0
- package/dist/hatchet/util/logger/index.js +17 -0
- package/dist/hatchet/util/logger/logger.d.ts +12 -0
- package/dist/hatchet/util/logger/logger.js +37 -0
- package/dist/hatchet/util/sleep.d.ts +2 -0
- package/dist/hatchet/util/sleep.js +6 -0
- package/dist/hatchet/workflow.d.ts +78 -0
- package/dist/hatchet/workflow.js +44 -0
- package/dist/protoc/dispatcher/dispatcher.d.ts +273 -0
- package/dist/protoc/dispatcher/dispatcher.js +918 -0
- package/dist/protoc/dispatcher/index.d.ts +1 -0
- package/dist/protoc/dispatcher/index.js +17 -0
- package/dist/protoc/events/events.d.ts +165 -0
- package/dist/protoc/events/events.js +443 -0
- package/dist/protoc/google/protobuf/timestamp.d.ts +121 -0
- package/dist/protoc/google/protobuf/timestamp.js +110 -0
- package/dist/protoc/google/protobuf/wrappers.d.ts +160 -0
- package/dist/protoc/google/protobuf/wrappers.js +527 -0
- package/dist/protoc/workflows/index.d.ts +1 -0
- package/dist/protoc/workflows/index.js +17 -0
- package/dist/protoc/workflows/workflows.d.ts +438 -0
- package/dist/protoc/workflows/workflows.js +1814 -0
- package/examples/dag-worker.ts +55 -0
- package/examples/example-event.ts +7 -0
- package/examples/simple-worker.ts +39 -0
- package/generate-protoc.sh +10 -0
- package/hatchet/clients/admin/admin-client.test.ts +116 -0
- package/hatchet/clients/admin/admin-client.ts +43 -0
- package/hatchet/clients/dispatcher/action-listener.test.ts +270 -0
- package/hatchet/clients/dispatcher/action-listener.ts +91 -0
- package/hatchet/clients/dispatcher/dispatcher-client.test.ts +111 -0
- package/hatchet/clients/dispatcher/dispatcher-client.ts +47 -0
- package/hatchet/clients/event/event-client.test.ts +72 -0
- package/hatchet/clients/event/event-client.ts +32 -0
- package/hatchet/clients/hatchet-client/client-config.ts +22 -0
- package/hatchet/clients/hatchet-client/fixtures/.hatchet-invalid.yaml +6 -0
- package/hatchet/clients/hatchet-client/fixtures/.hatchet.yaml +8 -0
- package/hatchet/clients/hatchet-client/hatchet-client.test.ts +162 -0
- package/hatchet/clients/hatchet-client/hatchet-client.ts +136 -0
- package/hatchet/clients/hatchet-client/index.ts +2 -0
- package/hatchet/clients/worker/index.ts +1 -0
- package/hatchet/clients/worker/worker.test.ts +347 -0
- package/hatchet/clients/worker/worker.ts +229 -0
- package/hatchet/index.ts +3 -0
- package/hatchet/sdk.ts +3 -0
- package/hatchet/step.ts +48 -0
- package/hatchet/util/config-loader/config-loader.test.ts +79 -0
- package/hatchet/util/config-loader/config-loader.ts +91 -0
- package/hatchet/util/config-loader/fixtures/.hatchet-invalid.yaml +6 -0
- package/hatchet/util/config-loader/fixtures/.hatchet.yaml +8 -0
- package/hatchet/util/config-loader/index.ts +1 -0
- package/hatchet/util/errors/hatchet-error.ts +8 -0
- package/hatchet/util/hatchet-promise/hatchet-promise.test.ts +32 -0
- package/hatchet/util/hatchet-promise/hatchet-promise.ts +13 -0
- package/hatchet/util/logger/index.ts +1 -0
- package/hatchet/util/logger/logger.ts +44 -0
- package/hatchet/util/sleep.ts +6 -0
- package/hatchet/workflow.ts +30 -0
- package/jest.config.ts +205 -0
- package/package.json +65 -0
- package/protoc/dispatcher/dispatcher.ts +1101 -0
- package/protoc/dispatcher/index.ts +1 -0
- package/protoc/events/events.ts +519 -0
- package/protoc/events/index.ts +1 -0
- package/protoc/google/protobuf/timestamp.ts +210 -0
- package/protoc/google/protobuf/wrappers.ts +657 -0
- package/protoc/workflows/index.ts +1 -0
- package/protoc/workflows/workflows.ts +2158 -0
- package/tsconfig.json +120 -0
|
@@ -0,0 +1,273 @@
|
|
|
1
|
+
import type { CallContext, CallOptions } from "nice-grpc-common";
|
|
2
|
+
import * as _m0 from "protobufjs/minimal";
|
|
3
|
+
export declare const protobufPackage = "";
|
|
4
|
+
export declare enum ActionType {
|
|
5
|
+
START_STEP_RUN = 0,
|
|
6
|
+
CANCEL_STEP_RUN = 1,
|
|
7
|
+
UNRECOGNIZED = -1
|
|
8
|
+
}
|
|
9
|
+
export declare function actionTypeFromJSON(object: any): ActionType;
|
|
10
|
+
export declare function actionTypeToJSON(object: ActionType): string;
|
|
11
|
+
export declare enum ActionEventType {
|
|
12
|
+
STEP_EVENT_TYPE_UNKNOWN = 0,
|
|
13
|
+
STEP_EVENT_TYPE_STARTED = 1,
|
|
14
|
+
STEP_EVENT_TYPE_COMPLETED = 2,
|
|
15
|
+
STEP_EVENT_TYPE_FAILED = 3,
|
|
16
|
+
UNRECOGNIZED = -1
|
|
17
|
+
}
|
|
18
|
+
export declare function actionEventTypeFromJSON(object: any): ActionEventType;
|
|
19
|
+
export declare function actionEventTypeToJSON(object: ActionEventType): string;
|
|
20
|
+
export interface WorkerRegisterRequest {
|
|
21
|
+
/** the name of the worker */
|
|
22
|
+
workerName: string;
|
|
23
|
+
/** a list of actions that this worker can run */
|
|
24
|
+
actions: string[];
|
|
25
|
+
/** (optional) the services for this worker */
|
|
26
|
+
services: string[];
|
|
27
|
+
}
|
|
28
|
+
export interface WorkerRegisterResponse {
|
|
29
|
+
/** the tenant id */
|
|
30
|
+
tenantId: string;
|
|
31
|
+
/** the id of the worker */
|
|
32
|
+
workerId: string;
|
|
33
|
+
/** the name of the worker */
|
|
34
|
+
workerName: string;
|
|
35
|
+
}
|
|
36
|
+
export interface AssignedAction {
|
|
37
|
+
/** the tenant id */
|
|
38
|
+
tenantId: string;
|
|
39
|
+
/** the job id */
|
|
40
|
+
jobId: string;
|
|
41
|
+
/** the job name */
|
|
42
|
+
jobName: string;
|
|
43
|
+
/** the job run id */
|
|
44
|
+
jobRunId: string;
|
|
45
|
+
/** the step id */
|
|
46
|
+
stepId: string;
|
|
47
|
+
/** the step run id */
|
|
48
|
+
stepRunId: string;
|
|
49
|
+
/** the action id */
|
|
50
|
+
actionId: string;
|
|
51
|
+
/** the action type */
|
|
52
|
+
actionType: ActionType;
|
|
53
|
+
/** the action payload */
|
|
54
|
+
actionPayload: string;
|
|
55
|
+
}
|
|
56
|
+
export interface WorkerListenRequest {
|
|
57
|
+
/** the id of the worker */
|
|
58
|
+
workerId: string;
|
|
59
|
+
}
|
|
60
|
+
export interface WorkerUnsubscribeRequest {
|
|
61
|
+
/** the id of the worker */
|
|
62
|
+
workerId: string;
|
|
63
|
+
}
|
|
64
|
+
export interface WorkerUnsubscribeResponse {
|
|
65
|
+
/** the tenant id to unsubscribe from */
|
|
66
|
+
tenantId: string;
|
|
67
|
+
/** the id of the worker */
|
|
68
|
+
workerId: string;
|
|
69
|
+
}
|
|
70
|
+
export interface ActionEvent {
|
|
71
|
+
/** the id of the worker */
|
|
72
|
+
workerId: string;
|
|
73
|
+
/** the id of the job */
|
|
74
|
+
jobId: string;
|
|
75
|
+
/** the job run id */
|
|
76
|
+
jobRunId: string;
|
|
77
|
+
/** the id of the step */
|
|
78
|
+
stepId: string;
|
|
79
|
+
/** the step run id */
|
|
80
|
+
stepRunId: string;
|
|
81
|
+
/** the action id */
|
|
82
|
+
actionId: string;
|
|
83
|
+
eventTimestamp: Date | undefined;
|
|
84
|
+
/** the step event type */
|
|
85
|
+
eventType: ActionEventType;
|
|
86
|
+
/** the event payload */
|
|
87
|
+
eventPayload: string;
|
|
88
|
+
}
|
|
89
|
+
export interface ActionEventResponse {
|
|
90
|
+
/** the tenant id */
|
|
91
|
+
tenantId: string;
|
|
92
|
+
/** the id of the worker */
|
|
93
|
+
workerId: string;
|
|
94
|
+
}
|
|
95
|
+
export declare const WorkerRegisterRequest: {
|
|
96
|
+
encode(message: WorkerRegisterRequest, writer?: _m0.Writer): _m0.Writer;
|
|
97
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): WorkerRegisterRequest;
|
|
98
|
+
fromJSON(object: any): WorkerRegisterRequest;
|
|
99
|
+
toJSON(message: WorkerRegisterRequest): unknown;
|
|
100
|
+
create(base?: DeepPartial<WorkerRegisterRequest>): WorkerRegisterRequest;
|
|
101
|
+
fromPartial(object: DeepPartial<WorkerRegisterRequest>): WorkerRegisterRequest;
|
|
102
|
+
};
|
|
103
|
+
export declare const WorkerRegisterResponse: {
|
|
104
|
+
encode(message: WorkerRegisterResponse, writer?: _m0.Writer): _m0.Writer;
|
|
105
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): WorkerRegisterResponse;
|
|
106
|
+
fromJSON(object: any): WorkerRegisterResponse;
|
|
107
|
+
toJSON(message: WorkerRegisterResponse): unknown;
|
|
108
|
+
create(base?: DeepPartial<WorkerRegisterResponse>): WorkerRegisterResponse;
|
|
109
|
+
fromPartial(object: DeepPartial<WorkerRegisterResponse>): WorkerRegisterResponse;
|
|
110
|
+
};
|
|
111
|
+
export declare const AssignedAction: {
|
|
112
|
+
encode(message: AssignedAction, writer?: _m0.Writer): _m0.Writer;
|
|
113
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): AssignedAction;
|
|
114
|
+
fromJSON(object: any): AssignedAction;
|
|
115
|
+
toJSON(message: AssignedAction): unknown;
|
|
116
|
+
create(base?: DeepPartial<AssignedAction>): AssignedAction;
|
|
117
|
+
fromPartial(object: DeepPartial<AssignedAction>): AssignedAction;
|
|
118
|
+
};
|
|
119
|
+
export declare const WorkerListenRequest: {
|
|
120
|
+
encode(message: WorkerListenRequest, writer?: _m0.Writer): _m0.Writer;
|
|
121
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): WorkerListenRequest;
|
|
122
|
+
fromJSON(object: any): WorkerListenRequest;
|
|
123
|
+
toJSON(message: WorkerListenRequest): unknown;
|
|
124
|
+
create(base?: DeepPartial<WorkerListenRequest>): WorkerListenRequest;
|
|
125
|
+
fromPartial(object: DeepPartial<WorkerListenRequest>): WorkerListenRequest;
|
|
126
|
+
};
|
|
127
|
+
export declare const WorkerUnsubscribeRequest: {
|
|
128
|
+
encode(message: WorkerUnsubscribeRequest, writer?: _m0.Writer): _m0.Writer;
|
|
129
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): WorkerUnsubscribeRequest;
|
|
130
|
+
fromJSON(object: any): WorkerUnsubscribeRequest;
|
|
131
|
+
toJSON(message: WorkerUnsubscribeRequest): unknown;
|
|
132
|
+
create(base?: DeepPartial<WorkerUnsubscribeRequest>): WorkerUnsubscribeRequest;
|
|
133
|
+
fromPartial(object: DeepPartial<WorkerUnsubscribeRequest>): WorkerUnsubscribeRequest;
|
|
134
|
+
};
|
|
135
|
+
export declare const WorkerUnsubscribeResponse: {
|
|
136
|
+
encode(message: WorkerUnsubscribeResponse, writer?: _m0.Writer): _m0.Writer;
|
|
137
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): WorkerUnsubscribeResponse;
|
|
138
|
+
fromJSON(object: any): WorkerUnsubscribeResponse;
|
|
139
|
+
toJSON(message: WorkerUnsubscribeResponse): unknown;
|
|
140
|
+
create(base?: DeepPartial<WorkerUnsubscribeResponse>): WorkerUnsubscribeResponse;
|
|
141
|
+
fromPartial(object: DeepPartial<WorkerUnsubscribeResponse>): WorkerUnsubscribeResponse;
|
|
142
|
+
};
|
|
143
|
+
export declare const ActionEvent: {
|
|
144
|
+
encode(message: ActionEvent, writer?: _m0.Writer): _m0.Writer;
|
|
145
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): ActionEvent;
|
|
146
|
+
fromJSON(object: any): ActionEvent;
|
|
147
|
+
toJSON(message: ActionEvent): unknown;
|
|
148
|
+
create(base?: DeepPartial<ActionEvent>): ActionEvent;
|
|
149
|
+
fromPartial(object: DeepPartial<ActionEvent>): ActionEvent;
|
|
150
|
+
};
|
|
151
|
+
export declare const ActionEventResponse: {
|
|
152
|
+
encode(message: ActionEventResponse, writer?: _m0.Writer): _m0.Writer;
|
|
153
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): ActionEventResponse;
|
|
154
|
+
fromJSON(object: any): ActionEventResponse;
|
|
155
|
+
toJSON(message: ActionEventResponse): unknown;
|
|
156
|
+
create(base?: DeepPartial<ActionEventResponse>): ActionEventResponse;
|
|
157
|
+
fromPartial(object: DeepPartial<ActionEventResponse>): ActionEventResponse;
|
|
158
|
+
};
|
|
159
|
+
export type DispatcherDefinition = typeof DispatcherDefinition;
|
|
160
|
+
export declare const DispatcherDefinition: {
|
|
161
|
+
readonly name: "Dispatcher";
|
|
162
|
+
readonly fullName: "Dispatcher";
|
|
163
|
+
readonly methods: {
|
|
164
|
+
readonly register: {
|
|
165
|
+
readonly name: "Register";
|
|
166
|
+
readonly requestType: {
|
|
167
|
+
encode(message: WorkerRegisterRequest, writer?: _m0.Writer): _m0.Writer;
|
|
168
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): WorkerRegisterRequest;
|
|
169
|
+
fromJSON(object: any): WorkerRegisterRequest;
|
|
170
|
+
toJSON(message: WorkerRegisterRequest): unknown;
|
|
171
|
+
create(base?: DeepPartial<WorkerRegisterRequest>): WorkerRegisterRequest;
|
|
172
|
+
fromPartial(object: DeepPartial<WorkerRegisterRequest>): WorkerRegisterRequest;
|
|
173
|
+
};
|
|
174
|
+
readonly requestStream: false;
|
|
175
|
+
readonly responseType: {
|
|
176
|
+
encode(message: WorkerRegisterResponse, writer?: _m0.Writer): _m0.Writer;
|
|
177
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): WorkerRegisterResponse;
|
|
178
|
+
fromJSON(object: any): WorkerRegisterResponse;
|
|
179
|
+
toJSON(message: WorkerRegisterResponse): unknown;
|
|
180
|
+
create(base?: DeepPartial<WorkerRegisterResponse>): WorkerRegisterResponse;
|
|
181
|
+
fromPartial(object: DeepPartial<WorkerRegisterResponse>): WorkerRegisterResponse;
|
|
182
|
+
};
|
|
183
|
+
readonly responseStream: false;
|
|
184
|
+
readonly options: {};
|
|
185
|
+
};
|
|
186
|
+
readonly listen: {
|
|
187
|
+
readonly name: "Listen";
|
|
188
|
+
readonly requestType: {
|
|
189
|
+
encode(message: WorkerListenRequest, writer?: _m0.Writer): _m0.Writer;
|
|
190
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): WorkerListenRequest;
|
|
191
|
+
fromJSON(object: any): WorkerListenRequest;
|
|
192
|
+
toJSON(message: WorkerListenRequest): unknown;
|
|
193
|
+
create(base?: DeepPartial<WorkerListenRequest>): WorkerListenRequest;
|
|
194
|
+
fromPartial(object: DeepPartial<WorkerListenRequest>): WorkerListenRequest;
|
|
195
|
+
};
|
|
196
|
+
readonly requestStream: false;
|
|
197
|
+
readonly responseType: {
|
|
198
|
+
encode(message: AssignedAction, writer?: _m0.Writer): _m0.Writer;
|
|
199
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): AssignedAction;
|
|
200
|
+
fromJSON(object: any): AssignedAction;
|
|
201
|
+
toJSON(message: AssignedAction): unknown;
|
|
202
|
+
create(base?: DeepPartial<AssignedAction>): AssignedAction;
|
|
203
|
+
fromPartial(object: DeepPartial<AssignedAction>): AssignedAction;
|
|
204
|
+
};
|
|
205
|
+
readonly responseStream: true;
|
|
206
|
+
readonly options: {};
|
|
207
|
+
};
|
|
208
|
+
readonly sendActionEvent: {
|
|
209
|
+
readonly name: "SendActionEvent";
|
|
210
|
+
readonly requestType: {
|
|
211
|
+
encode(message: ActionEvent, writer?: _m0.Writer): _m0.Writer;
|
|
212
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): ActionEvent;
|
|
213
|
+
fromJSON(object: any): ActionEvent;
|
|
214
|
+
toJSON(message: ActionEvent): unknown;
|
|
215
|
+
create(base?: DeepPartial<ActionEvent>): ActionEvent;
|
|
216
|
+
fromPartial(object: DeepPartial<ActionEvent>): ActionEvent;
|
|
217
|
+
};
|
|
218
|
+
readonly requestStream: false;
|
|
219
|
+
readonly responseType: {
|
|
220
|
+
encode(message: ActionEventResponse, writer?: _m0.Writer): _m0.Writer;
|
|
221
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): ActionEventResponse;
|
|
222
|
+
fromJSON(object: any): ActionEventResponse;
|
|
223
|
+
toJSON(message: ActionEventResponse): unknown;
|
|
224
|
+
create(base?: DeepPartial<ActionEventResponse>): ActionEventResponse;
|
|
225
|
+
fromPartial(object: DeepPartial<ActionEventResponse>): ActionEventResponse;
|
|
226
|
+
};
|
|
227
|
+
readonly responseStream: false;
|
|
228
|
+
readonly options: {};
|
|
229
|
+
};
|
|
230
|
+
readonly unsubscribe: {
|
|
231
|
+
readonly name: "Unsubscribe";
|
|
232
|
+
readonly requestType: {
|
|
233
|
+
encode(message: WorkerUnsubscribeRequest, writer?: _m0.Writer): _m0.Writer;
|
|
234
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): WorkerUnsubscribeRequest;
|
|
235
|
+
fromJSON(object: any): WorkerUnsubscribeRequest;
|
|
236
|
+
toJSON(message: WorkerUnsubscribeRequest): unknown;
|
|
237
|
+
create(base?: DeepPartial<WorkerUnsubscribeRequest>): WorkerUnsubscribeRequest;
|
|
238
|
+
fromPartial(object: DeepPartial<WorkerUnsubscribeRequest>): WorkerUnsubscribeRequest;
|
|
239
|
+
};
|
|
240
|
+
readonly requestStream: false;
|
|
241
|
+
readonly responseType: {
|
|
242
|
+
encode(message: WorkerUnsubscribeResponse, writer?: _m0.Writer): _m0.Writer;
|
|
243
|
+
decode(input: _m0.Reader | Uint8Array, length?: number): WorkerUnsubscribeResponse;
|
|
244
|
+
fromJSON(object: any): WorkerUnsubscribeResponse;
|
|
245
|
+
toJSON(message: WorkerUnsubscribeResponse): unknown;
|
|
246
|
+
create(base?: DeepPartial<WorkerUnsubscribeResponse>): WorkerUnsubscribeResponse;
|
|
247
|
+
fromPartial(object: DeepPartial<WorkerUnsubscribeResponse>): WorkerUnsubscribeResponse;
|
|
248
|
+
};
|
|
249
|
+
readonly responseStream: false;
|
|
250
|
+
readonly options: {};
|
|
251
|
+
};
|
|
252
|
+
};
|
|
253
|
+
};
|
|
254
|
+
export interface DispatcherServiceImplementation<CallContextExt = {}> {
|
|
255
|
+
register(request: WorkerRegisterRequest, context: CallContext & CallContextExt): Promise<DeepPartial<WorkerRegisterResponse>>;
|
|
256
|
+
listen(request: WorkerListenRequest, context: CallContext & CallContextExt): ServerStreamingMethodResult<DeepPartial<AssignedAction>>;
|
|
257
|
+
sendActionEvent(request: ActionEvent, context: CallContext & CallContextExt): Promise<DeepPartial<ActionEventResponse>>;
|
|
258
|
+
unsubscribe(request: WorkerUnsubscribeRequest, context: CallContext & CallContextExt): Promise<DeepPartial<WorkerUnsubscribeResponse>>;
|
|
259
|
+
}
|
|
260
|
+
export interface DispatcherClient<CallOptionsExt = {}> {
|
|
261
|
+
register(request: DeepPartial<WorkerRegisterRequest>, options?: CallOptions & CallOptionsExt): Promise<WorkerRegisterResponse>;
|
|
262
|
+
listen(request: DeepPartial<WorkerListenRequest>, options?: CallOptions & CallOptionsExt): AsyncIterable<AssignedAction>;
|
|
263
|
+
sendActionEvent(request: DeepPartial<ActionEvent>, options?: CallOptions & CallOptionsExt): Promise<ActionEventResponse>;
|
|
264
|
+
unsubscribe(request: DeepPartial<WorkerUnsubscribeRequest>, options?: CallOptions & CallOptionsExt): Promise<WorkerUnsubscribeResponse>;
|
|
265
|
+
}
|
|
266
|
+
type Builtin = Date | Function | Uint8Array | string | number | boolean | undefined;
|
|
267
|
+
export type DeepPartial<T> = T extends Builtin ? T : T extends globalThis.Array<infer U> ? globalThis.Array<DeepPartial<U>> : T extends ReadonlyArray<infer U> ? ReadonlyArray<DeepPartial<U>> : T extends {} ? {
|
|
268
|
+
[K in keyof T]?: DeepPartial<T[K]>;
|
|
269
|
+
} : Partial<T>;
|
|
270
|
+
export type ServerStreamingMethodResult<Response> = {
|
|
271
|
+
[Symbol.asyncIterator](): AsyncIterator<Response, void>;
|
|
272
|
+
};
|
|
273
|
+
export {};
|