captchasonic 2.0.0 → 2.1.0
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/README.md +16 -10
- package/dist/client.d.ts +21 -4
- package/dist/client.d.ts.map +1 -1
- package/dist/client.js +26 -12
- package/dist/client.js.map +1 -1
- package/dist/gen/{captchasonicai → captchasonic}/v1/sonic_pb.d.ts +218 -113
- package/dist/gen/captchasonic/v1/sonic_pb.d.ts.map +1 -0
- package/dist/gen/captchasonic/v1/sonic_pb.js +103 -0
- package/dist/gen/captchasonic/v1/sonic_pb.js.map +1 -0
- package/package.json +2 -1
- package/src/gen/captchasonic/v1/sonic_pb.ts +731 -0
- package/dist/gen/captchasonicai/v1/sonic_connect.d.ts +0 -46
- package/dist/gen/captchasonicai/v1/sonic_connect.d.ts.map +0 -1
- package/dist/gen/captchasonicai/v1/sonic_connect.js +0 -51
- package/dist/gen/captchasonicai/v1/sonic_connect.js.map +0 -1
- package/dist/gen/captchasonicai/v1/sonic_pb.d.ts.map +0 -1
- package/dist/gen/captchasonicai/v1/sonic_pb.js +0 -98
- package/dist/gen/captchasonicai/v1/sonic_pb.js.map +0 -1
- package/src/gen/captchasonicai/v1/sonic_connect.ts +0 -54
- package/src/gen/captchasonicai/v1/sonic_pb.ts +0 -603
|
@@ -0,0 +1,731 @@
|
|
|
1
|
+
// @generated by protoc-gen-es v2.12.0 with parameter "target=ts"
|
|
2
|
+
// @generated from file captchasonic/v1/sonic.proto (package captchasonic.v1, syntax proto3)
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
|
|
5
|
+
import type { GenFile, GenMessage, GenService } from "@bufbuild/protobuf/codegenv2";
|
|
6
|
+
import { fileDesc, messageDesc, serviceDesc } from "@bufbuild/protobuf/codegenv2";
|
|
7
|
+
import type { Message } from "@bufbuild/protobuf";
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* Describes the file captchasonic/v1/sonic.proto.
|
|
11
|
+
*/
|
|
12
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iIuY2FwdGNoYXNvbmljLnYxLkNyZWF0ZVRhc2tSZXF1ZXN0GiMuY2FwdGNoYXNvbmljLnYxLkNyZWF0ZVRhc2tSZXNwb25zZRJeCg1HZXRUYXNrUmVzdWx0EiUuY2FwdGNoYXNvbmljLnYxLkdldFRhc2tSZXN1bHRSZXF1ZXN0GiYuY2FwdGNoYXNvbmljLnYxLkdldFRhc2tSZXN1bHRSZXNwb25zZRJVCgpHZXRCYWxhbmNlEiIuY2FwdGNoYXNvbmljLnYxLkdldEJhbGFuY2VSZXF1ZXN0GiMuY2FwdGNoYXNvbmljLnYxLkdldEJhbGFuY2VSZXNwb25zZRJdCgtIZWFsdGhDaGVjaxIjLmNhcHRjaGFzb25pYy52MS5IZWFsdGhDaGVja1JlcXVlc3QaJC5jYXB0Y2hhc29uaWMudjEuSGVhbHRoQ2hlY2tSZXNwb25zZSIDkAIBQnoKE2NvbS5jYXB0Y2hhc29uaWMudjFCC1NvbmljUHJvdG9zUAFaQmdpdGh1Yi5jb20vY2FwdGNoYXNvbmljL2NhcHRjaGFzb25pYy1nby9pbnRlcm5hbC9wYjtjYXB0Y2hhc29uaWN2MaoCD0NhcHRjaGFTb25pYy5WMWIGcHJvdG8z");
|
|
14
|
+
|
|
15
|
+
/**
|
|
16
|
+
* @generated from message captchasonic.v1.Task
|
|
17
|
+
*/
|
|
18
|
+
export type Task = Message<"captchasonic.v1.Task"> & {
|
|
19
|
+
/**
|
|
20
|
+
* @generated from field: string type = 1;
|
|
21
|
+
*/
|
|
22
|
+
type: string;
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
* raw binary — no base64 overhead
|
|
26
|
+
*
|
|
27
|
+
* @generated from field: repeated bytes images = 2;
|
|
28
|
+
*/
|
|
29
|
+
images: Uint8Array[];
|
|
30
|
+
|
|
31
|
+
/**
|
|
32
|
+
* @generated from field: string question = 3;
|
|
33
|
+
*/
|
|
34
|
+
question: string;
|
|
35
|
+
|
|
36
|
+
/**
|
|
37
|
+
* @generated from field: string questionType = 4;
|
|
38
|
+
*/
|
|
39
|
+
questionType: string;
|
|
40
|
+
|
|
41
|
+
/**
|
|
42
|
+
* @generated from field: bool screenshot = 5;
|
|
43
|
+
*/
|
|
44
|
+
screenshot: boolean;
|
|
45
|
+
|
|
46
|
+
/**
|
|
47
|
+
* @generated from field: bytes image = 6;
|
|
48
|
+
*/
|
|
49
|
+
image: Uint8Array;
|
|
50
|
+
|
|
51
|
+
/**
|
|
52
|
+
* @generated from field: repeated bytes examples = 7;
|
|
53
|
+
*/
|
|
54
|
+
examples: Uint8Array[];
|
|
55
|
+
|
|
56
|
+
/**
|
|
57
|
+
* @generated from field: string websiteURL = 8;
|
|
58
|
+
*/
|
|
59
|
+
websiteURL: string;
|
|
60
|
+
|
|
61
|
+
/**
|
|
62
|
+
* @generated from field: string websiteKey = 9;
|
|
63
|
+
*/
|
|
64
|
+
websiteKey: string;
|
|
65
|
+
|
|
66
|
+
/**
|
|
67
|
+
* OCR
|
|
68
|
+
*
|
|
69
|
+
* @generated from field: string module = 10;
|
|
70
|
+
*/
|
|
71
|
+
module: string;
|
|
72
|
+
|
|
73
|
+
/**
|
|
74
|
+
* @generated from field: bool numeric = 11;
|
|
75
|
+
*/
|
|
76
|
+
numeric: boolean;
|
|
77
|
+
|
|
78
|
+
/**
|
|
79
|
+
* @generated from field: bool case_sensitive = 12;
|
|
80
|
+
*/
|
|
81
|
+
caseSensitive: boolean;
|
|
82
|
+
|
|
83
|
+
/**
|
|
84
|
+
* @generated from field: int32 minLength = 13;
|
|
85
|
+
*/
|
|
86
|
+
minLength: number;
|
|
87
|
+
|
|
88
|
+
/**
|
|
89
|
+
* @generated from field: int32 maxLength = 14;
|
|
90
|
+
*/
|
|
91
|
+
maxLength: number;
|
|
92
|
+
|
|
93
|
+
/**
|
|
94
|
+
* Geetest
|
|
95
|
+
*
|
|
96
|
+
* @generated from field: int32 gtv = 15;
|
|
97
|
+
*/
|
|
98
|
+
gtv: number;
|
|
99
|
+
|
|
100
|
+
/**
|
|
101
|
+
* @generated from field: string gt = 16;
|
|
102
|
+
*/
|
|
103
|
+
gt: string;
|
|
104
|
+
|
|
105
|
+
/**
|
|
106
|
+
* @generated from field: string challenge = 17;
|
|
107
|
+
*/
|
|
108
|
+
challenge: string;
|
|
109
|
+
|
|
110
|
+
/**
|
|
111
|
+
* @generated from field: string captchaId = 18;
|
|
112
|
+
*/
|
|
113
|
+
captchaId: string;
|
|
114
|
+
|
|
115
|
+
/**
|
|
116
|
+
* Common
|
|
117
|
+
*
|
|
118
|
+
* @generated from field: string proxy = 19;
|
|
119
|
+
*/
|
|
120
|
+
proxy: string;
|
|
121
|
+
|
|
122
|
+
/**
|
|
123
|
+
* Video captcha (PopularCaptcha canvasVideo negotiation)
|
|
124
|
+
*
|
|
125
|
+
* true when sending video payload
|
|
126
|
+
*
|
|
127
|
+
* @generated from field: bool canvasVideo = 20;
|
|
128
|
+
*/
|
|
129
|
+
canvasVideo: boolean;
|
|
130
|
+
|
|
131
|
+
/**
|
|
132
|
+
* "framecount", "frameMerge", "frame", "video"
|
|
133
|
+
*
|
|
134
|
+
* @generated from field: string format = 21;
|
|
135
|
+
*/
|
|
136
|
+
format: string;
|
|
137
|
+
|
|
138
|
+
/**
|
|
139
|
+
* raw video/frame blobs (binary, no base64)
|
|
140
|
+
*
|
|
141
|
+
* @generated from field: repeated bytes video = 22;
|
|
142
|
+
*/
|
|
143
|
+
video: Uint8Array[];
|
|
144
|
+
|
|
145
|
+
/**
|
|
146
|
+
* frame indices from previous response
|
|
147
|
+
*
|
|
148
|
+
* @generated from field: repeated int32 frames = 23;
|
|
149
|
+
*/
|
|
150
|
+
frames: number[];
|
|
151
|
+
|
|
152
|
+
/**
|
|
153
|
+
* total frame count
|
|
154
|
+
*
|
|
155
|
+
* @generated from field: optional int32 framecount = 24;
|
|
156
|
+
*/
|
|
157
|
+
framecount?: number | undefined;
|
|
158
|
+
|
|
159
|
+
/**
|
|
160
|
+
* multi-choice answers (if any)
|
|
161
|
+
*
|
|
162
|
+
* @generated from field: repeated string choices = 25;
|
|
163
|
+
*/
|
|
164
|
+
choices: string[];
|
|
165
|
+
};
|
|
166
|
+
|
|
167
|
+
/**
|
|
168
|
+
* Describes the message captchasonic.v1.Task.
|
|
169
|
+
* Use `create(TaskSchema)` to create a new message.
|
|
170
|
+
*/
|
|
171
|
+
export const TaskSchema: GenMessage<Task> = /*@__PURE__*/
|
|
172
|
+
messageDesc(file_captchasonic_v1_sonic, 0);
|
|
173
|
+
|
|
174
|
+
/**
|
|
175
|
+
* @generated from message captchasonic.v1.CreateTaskRequest
|
|
176
|
+
*/
|
|
177
|
+
export type CreateTaskRequest = Message<"captchasonic.v1.CreateTaskRequest"> & {
|
|
178
|
+
/**
|
|
179
|
+
* @generated from field: string apiKey = 1;
|
|
180
|
+
*/
|
|
181
|
+
apiKey: string;
|
|
182
|
+
|
|
183
|
+
/**
|
|
184
|
+
* @generated from field: captchasonic.v1.Task task = 2;
|
|
185
|
+
*/
|
|
186
|
+
task?: Task | undefined;
|
|
187
|
+
};
|
|
188
|
+
|
|
189
|
+
/**
|
|
190
|
+
* Describes the message captchasonic.v1.CreateTaskRequest.
|
|
191
|
+
* Use `create(CreateTaskRequestSchema)` to create a new message.
|
|
192
|
+
*/
|
|
193
|
+
export const CreateTaskRequestSchema: GenMessage<CreateTaskRequest> = /*@__PURE__*/
|
|
194
|
+
messageDesc(file_captchasonic_v1_sonic, 1);
|
|
195
|
+
|
|
196
|
+
/**
|
|
197
|
+
* @generated from message captchasonic.v1.CreateTaskResponse
|
|
198
|
+
*/
|
|
199
|
+
export type CreateTaskResponse = Message<"captchasonic.v1.CreateTaskResponse"> & {
|
|
200
|
+
/**
|
|
201
|
+
* @generated from field: int32 errorId = 1;
|
|
202
|
+
*/
|
|
203
|
+
errorId: number;
|
|
204
|
+
|
|
205
|
+
/**
|
|
206
|
+
* @generated from field: string errorDescription = 2;
|
|
207
|
+
*/
|
|
208
|
+
errorDescription: string;
|
|
209
|
+
|
|
210
|
+
/**
|
|
211
|
+
* @generated from field: string taskId = 3;
|
|
212
|
+
*/
|
|
213
|
+
taskId: string;
|
|
214
|
+
|
|
215
|
+
/**
|
|
216
|
+
* @generated from field: map<string, string> solution = 4;
|
|
217
|
+
*/
|
|
218
|
+
solution: { [key: string]: string };
|
|
219
|
+
|
|
220
|
+
/**
|
|
221
|
+
* @generated from field: string status = 5;
|
|
222
|
+
*/
|
|
223
|
+
status: string;
|
|
224
|
+
|
|
225
|
+
/**
|
|
226
|
+
* @generated from field: captchasonic.v1.SolutionPayload typed_solution = 6;
|
|
227
|
+
*/
|
|
228
|
+
typedSolution?: SolutionPayload | undefined;
|
|
229
|
+
|
|
230
|
+
/**
|
|
231
|
+
* ── REST parity fields ──────────────────────────────────────────────
|
|
232
|
+
* Extension expects same response shape as HTTP endpoint.
|
|
233
|
+
*
|
|
234
|
+
* 200 on success, error code on failure
|
|
235
|
+
*
|
|
236
|
+
* @generated from field: int32 code = 7;
|
|
237
|
+
*/
|
|
238
|
+
code: number;
|
|
239
|
+
|
|
240
|
+
/**
|
|
241
|
+
* empty on success, error message on failure
|
|
242
|
+
*
|
|
243
|
+
* @generated from field: string msg = 8;
|
|
244
|
+
*/
|
|
245
|
+
msg: string;
|
|
246
|
+
|
|
247
|
+
/**
|
|
248
|
+
* parsed target (only for internal users)
|
|
249
|
+
*
|
|
250
|
+
* @generated from field: string question = 9;
|
|
251
|
+
*/
|
|
252
|
+
question: string;
|
|
253
|
+
|
|
254
|
+
/**
|
|
255
|
+
* solver sub-type (objectClick, 33, etc.)
|
|
256
|
+
*
|
|
257
|
+
* @generated from field: string questionType = 10;
|
|
258
|
+
*/
|
|
259
|
+
questionType: string;
|
|
260
|
+
|
|
261
|
+
/**
|
|
262
|
+
* ── Video negotiation (ERROR_VIDEO_PAYLOAD_REQUIRED) ────────────────
|
|
263
|
+
* Returned when a video captcha target is detected but the client has
|
|
264
|
+
* not yet sent video frame data. Must match REST JSON shape exactly.
|
|
265
|
+
*
|
|
266
|
+
* "canvasvideo"
|
|
267
|
+
*
|
|
268
|
+
* @generated from field: string questionVariant = 11;
|
|
269
|
+
*/
|
|
270
|
+
questionVariant: string;
|
|
271
|
+
|
|
272
|
+
/**
|
|
273
|
+
* 0
|
|
274
|
+
*
|
|
275
|
+
* @generated from field: int32 retryAfterSec = 12;
|
|
276
|
+
*/
|
|
277
|
+
retryAfterSec: number;
|
|
278
|
+
|
|
279
|
+
/**
|
|
280
|
+
* true when video data needed
|
|
281
|
+
*
|
|
282
|
+
* @generated from field: bool video = 13;
|
|
283
|
+
*/
|
|
284
|
+
video: boolean;
|
|
285
|
+
|
|
286
|
+
/**
|
|
287
|
+
* format/duration/frames spec
|
|
288
|
+
*
|
|
289
|
+
* @generated from field: captchasonic.v1.VideoCanvasParams canvasParams = 14;
|
|
290
|
+
*/
|
|
291
|
+
canvasParams?: VideoCanvasParams | undefined;
|
|
292
|
+
|
|
293
|
+
/**
|
|
294
|
+
* echoed frame indices (top-level)
|
|
295
|
+
*
|
|
296
|
+
* @generated from field: repeated int32 frames = 15;
|
|
297
|
+
*/
|
|
298
|
+
frames: number[];
|
|
299
|
+
|
|
300
|
+
/**
|
|
301
|
+
* total frame count (top-level)
|
|
302
|
+
*
|
|
303
|
+
* @generated from field: optional int32 framecount = 16;
|
|
304
|
+
*/
|
|
305
|
+
framecount?: number | undefined;
|
|
306
|
+
};
|
|
307
|
+
|
|
308
|
+
/**
|
|
309
|
+
* Describes the message captchasonic.v1.CreateTaskResponse.
|
|
310
|
+
* Use `create(CreateTaskResponseSchema)` to create a new message.
|
|
311
|
+
*/
|
|
312
|
+
export const CreateTaskResponseSchema: GenMessage<CreateTaskResponse> = /*@__PURE__*/
|
|
313
|
+
messageDesc(file_captchasonic_v1_sonic, 2);
|
|
314
|
+
|
|
315
|
+
/**
|
|
316
|
+
* VideoCanvasParams tells the client what video format to send back.
|
|
317
|
+
*
|
|
318
|
+
* @generated from message captchasonic.v1.VideoCanvasParams
|
|
319
|
+
*/
|
|
320
|
+
export type VideoCanvasParams = Message<"captchasonic.v1.VideoCanvasParams"> & {
|
|
321
|
+
/**
|
|
322
|
+
* seconds (2 or 4)
|
|
323
|
+
*
|
|
324
|
+
* @generated from field: int32 duration = 1;
|
|
325
|
+
*/
|
|
326
|
+
duration: number;
|
|
327
|
+
|
|
328
|
+
/**
|
|
329
|
+
* ["avif","png","webm","gif"]
|
|
330
|
+
*
|
|
331
|
+
* @generated from field: repeated string format = 2;
|
|
332
|
+
*/
|
|
333
|
+
format: string[];
|
|
334
|
+
|
|
335
|
+
/**
|
|
336
|
+
* frame indices to extract (may be empty)
|
|
337
|
+
*
|
|
338
|
+
* @generated from field: repeated int32 frames = 3;
|
|
339
|
+
*/
|
|
340
|
+
frames: number[];
|
|
341
|
+
|
|
342
|
+
/**
|
|
343
|
+
* total frame count (null when not applicable)
|
|
344
|
+
*
|
|
345
|
+
* @generated from field: optional int32 framecount = 4;
|
|
346
|
+
*/
|
|
347
|
+
framecount?: number | undefined;
|
|
348
|
+
|
|
349
|
+
/**
|
|
350
|
+
* true when full video blob needed
|
|
351
|
+
*
|
|
352
|
+
* @generated from field: bool video = 5;
|
|
353
|
+
*/
|
|
354
|
+
video: boolean;
|
|
355
|
+
};
|
|
356
|
+
|
|
357
|
+
/**
|
|
358
|
+
* Describes the message captchasonic.v1.VideoCanvasParams.
|
|
359
|
+
* Use `create(VideoCanvasParamsSchema)` to create a new message.
|
|
360
|
+
*/
|
|
361
|
+
export const VideoCanvasParamsSchema: GenMessage<VideoCanvasParams> = /*@__PURE__*/
|
|
362
|
+
messageDesc(file_captchasonic_v1_sonic, 3);
|
|
363
|
+
|
|
364
|
+
/**
|
|
365
|
+
* @generated from message captchasonic.v1.SolutionPayload
|
|
366
|
+
*/
|
|
367
|
+
export type SolutionPayload = Message<"captchasonic.v1.SolutionPayload"> & {
|
|
368
|
+
/**
|
|
369
|
+
* @generated from oneof captchasonic.v1.SolutionPayload.kind
|
|
370
|
+
*/
|
|
371
|
+
kind: {
|
|
372
|
+
/**
|
|
373
|
+
* @generated from field: captchasonic.v1.GridSolution grid = 1;
|
|
374
|
+
*/
|
|
375
|
+
value: GridSolution;
|
|
376
|
+
case: "grid";
|
|
377
|
+
} | {
|
|
378
|
+
/**
|
|
379
|
+
* @generated from field: captchasonic.v1.SingleSolution single = 2;
|
|
380
|
+
*/
|
|
381
|
+
value: SingleSolution;
|
|
382
|
+
case: "single";
|
|
383
|
+
} | {
|
|
384
|
+
/**
|
|
385
|
+
* @generated from field: captchasonic.v1.ClickSolution click = 3;
|
|
386
|
+
*/
|
|
387
|
+
value: ClickSolution;
|
|
388
|
+
case: "click";
|
|
389
|
+
} | {
|
|
390
|
+
/**
|
|
391
|
+
* @generated from field: captchasonic.v1.SlideSolution slide = 4;
|
|
392
|
+
*/
|
|
393
|
+
value: SlideSolution;
|
|
394
|
+
case: "slide";
|
|
395
|
+
} | {
|
|
396
|
+
/**
|
|
397
|
+
* @generated from field: captchasonic.v1.TextSolution text = 5;
|
|
398
|
+
*/
|
|
399
|
+
value: TextSolution;
|
|
400
|
+
case: "text";
|
|
401
|
+
} | { case: undefined; value?: undefined };
|
|
402
|
+
};
|
|
403
|
+
|
|
404
|
+
/**
|
|
405
|
+
* Describes the message captchasonic.v1.SolutionPayload.
|
|
406
|
+
* Use `create(SolutionPayloadSchema)` to create a new message.
|
|
407
|
+
*/
|
|
408
|
+
export const SolutionPayloadSchema: GenMessage<SolutionPayload> = /*@__PURE__*/
|
|
409
|
+
messageDesc(file_captchasonic_v1_sonic, 4);
|
|
410
|
+
|
|
411
|
+
/**
|
|
412
|
+
* @generated from message captchasonic.v1.GridSolution
|
|
413
|
+
*/
|
|
414
|
+
export type GridSolution = Message<"captchasonic.v1.GridSolution"> & {
|
|
415
|
+
/**
|
|
416
|
+
* @generated from field: repeated int32 objects = 1;
|
|
417
|
+
*/
|
|
418
|
+
objects: number[];
|
|
419
|
+
|
|
420
|
+
/**
|
|
421
|
+
* @generated from field: int32 size = 2;
|
|
422
|
+
*/
|
|
423
|
+
size: number;
|
|
424
|
+
|
|
425
|
+
/**
|
|
426
|
+
* @generated from field: string type = 3;
|
|
427
|
+
*/
|
|
428
|
+
type: string;
|
|
429
|
+
};
|
|
430
|
+
|
|
431
|
+
/**
|
|
432
|
+
* Describes the message captchasonic.v1.GridSolution.
|
|
433
|
+
* Use `create(GridSolutionSchema)` to create a new message.
|
|
434
|
+
*/
|
|
435
|
+
export const GridSolutionSchema: GenMessage<GridSolution> = /*@__PURE__*/
|
|
436
|
+
messageDesc(file_captchasonic_v1_sonic, 5);
|
|
437
|
+
|
|
438
|
+
/**
|
|
439
|
+
* @generated from message captchasonic.v1.SingleSolution
|
|
440
|
+
*/
|
|
441
|
+
export type SingleSolution = Message<"captchasonic.v1.SingleSolution"> & {
|
|
442
|
+
/**
|
|
443
|
+
* @generated from field: repeated bool has_object = 1;
|
|
444
|
+
*/
|
|
445
|
+
hasObject: boolean[];
|
|
446
|
+
|
|
447
|
+
/**
|
|
448
|
+
* @generated from field: int32 size = 2;
|
|
449
|
+
*/
|
|
450
|
+
size: number;
|
|
451
|
+
|
|
452
|
+
/**
|
|
453
|
+
* @generated from field: string type = 3;
|
|
454
|
+
*/
|
|
455
|
+
type: string;
|
|
456
|
+
};
|
|
457
|
+
|
|
458
|
+
/**
|
|
459
|
+
* Describes the message captchasonic.v1.SingleSolution.
|
|
460
|
+
* Use `create(SingleSolutionSchema)` to create a new message.
|
|
461
|
+
*/
|
|
462
|
+
export const SingleSolutionSchema: GenMessage<SingleSolution> = /*@__PURE__*/
|
|
463
|
+
messageDesc(file_captchasonic_v1_sonic, 6);
|
|
464
|
+
|
|
465
|
+
/**
|
|
466
|
+
* @generated from message captchasonic.v1.ClickCoord
|
|
467
|
+
*/
|
|
468
|
+
export type ClickCoord = Message<"captchasonic.v1.ClickCoord"> & {
|
|
469
|
+
/**
|
|
470
|
+
* @generated from field: int32 x = 1;
|
|
471
|
+
*/
|
|
472
|
+
x: number;
|
|
473
|
+
|
|
474
|
+
/**
|
|
475
|
+
* @generated from field: int32 y = 2;
|
|
476
|
+
*/
|
|
477
|
+
y: number;
|
|
478
|
+
};
|
|
479
|
+
|
|
480
|
+
/**
|
|
481
|
+
* Describes the message captchasonic.v1.ClickCoord.
|
|
482
|
+
* Use `create(ClickCoordSchema)` to create a new message.
|
|
483
|
+
*/
|
|
484
|
+
export const ClickCoordSchema: GenMessage<ClickCoord> = /*@__PURE__*/
|
|
485
|
+
messageDesc(file_captchasonic_v1_sonic, 7);
|
|
486
|
+
|
|
487
|
+
/**
|
|
488
|
+
* @generated from message captchasonic.v1.ClickGroup
|
|
489
|
+
*/
|
|
490
|
+
export type ClickGroup = Message<"captchasonic.v1.ClickGroup"> & {
|
|
491
|
+
/**
|
|
492
|
+
* @generated from field: repeated captchasonic.v1.ClickCoord coords = 1;
|
|
493
|
+
*/
|
|
494
|
+
coords: ClickCoord[];
|
|
495
|
+
};
|
|
496
|
+
|
|
497
|
+
/**
|
|
498
|
+
* Describes the message captchasonic.v1.ClickGroup.
|
|
499
|
+
* Use `create(ClickGroupSchema)` to create a new message.
|
|
500
|
+
*/
|
|
501
|
+
export const ClickGroupSchema: GenMessage<ClickGroup> = /*@__PURE__*/
|
|
502
|
+
messageDesc(file_captchasonic_v1_sonic, 8);
|
|
503
|
+
|
|
504
|
+
/**
|
|
505
|
+
* @generated from message captchasonic.v1.ClickSolution
|
|
506
|
+
*/
|
|
507
|
+
export type ClickSolution = Message<"captchasonic.v1.ClickSolution"> & {
|
|
508
|
+
/**
|
|
509
|
+
* @generated from field: repeated captchasonic.v1.ClickGroup groups = 1;
|
|
510
|
+
*/
|
|
511
|
+
groups: ClickGroup[];
|
|
512
|
+
};
|
|
513
|
+
|
|
514
|
+
/**
|
|
515
|
+
* Describes the message captchasonic.v1.ClickSolution.
|
|
516
|
+
* Use `create(ClickSolutionSchema)` to create a new message.
|
|
517
|
+
*/
|
|
518
|
+
export const ClickSolutionSchema: GenMessage<ClickSolution> = /*@__PURE__*/
|
|
519
|
+
messageDesc(file_captchasonic_v1_sonic, 9);
|
|
520
|
+
|
|
521
|
+
/**
|
|
522
|
+
* @generated from message captchasonic.v1.SlideSolution
|
|
523
|
+
*/
|
|
524
|
+
export type SlideSolution = Message<"captchasonic.v1.SlideSolution"> & {
|
|
525
|
+
/**
|
|
526
|
+
* @generated from field: int32 x = 1;
|
|
527
|
+
*/
|
|
528
|
+
x: number;
|
|
529
|
+
|
|
530
|
+
/**
|
|
531
|
+
* @generated from field: string raw_json = 2;
|
|
532
|
+
*/
|
|
533
|
+
rawJson: string;
|
|
534
|
+
};
|
|
535
|
+
|
|
536
|
+
/**
|
|
537
|
+
* Describes the message captchasonic.v1.SlideSolution.
|
|
538
|
+
* Use `create(SlideSolutionSchema)` to create a new message.
|
|
539
|
+
*/
|
|
540
|
+
export const SlideSolutionSchema: GenMessage<SlideSolution> = /*@__PURE__*/
|
|
541
|
+
messageDesc(file_captchasonic_v1_sonic, 10);
|
|
542
|
+
|
|
543
|
+
/**
|
|
544
|
+
* @generated from message captchasonic.v1.TextSolution
|
|
545
|
+
*/
|
|
546
|
+
export type TextSolution = Message<"captchasonic.v1.TextSolution"> & {
|
|
547
|
+
/**
|
|
548
|
+
* @generated from field: repeated string texts = 1;
|
|
549
|
+
*/
|
|
550
|
+
texts: string[];
|
|
551
|
+
};
|
|
552
|
+
|
|
553
|
+
/**
|
|
554
|
+
* Describes the message captchasonic.v1.TextSolution.
|
|
555
|
+
* Use `create(TextSolutionSchema)` to create a new message.
|
|
556
|
+
*/
|
|
557
|
+
export const TextSolutionSchema: GenMessage<TextSolution> = /*@__PURE__*/
|
|
558
|
+
messageDesc(file_captchasonic_v1_sonic, 11);
|
|
559
|
+
|
|
560
|
+
/**
|
|
561
|
+
* @generated from message captchasonic.v1.GetTaskResultRequest
|
|
562
|
+
*/
|
|
563
|
+
export type GetTaskResultRequest = Message<"captchasonic.v1.GetTaskResultRequest"> & {
|
|
564
|
+
/**
|
|
565
|
+
* @generated from field: string apiKey = 1;
|
|
566
|
+
*/
|
|
567
|
+
apiKey: string;
|
|
568
|
+
|
|
569
|
+
/**
|
|
570
|
+
* @generated from field: string taskId = 2;
|
|
571
|
+
*/
|
|
572
|
+
taskId: string;
|
|
573
|
+
};
|
|
574
|
+
|
|
575
|
+
/**
|
|
576
|
+
* Describes the message captchasonic.v1.GetTaskResultRequest.
|
|
577
|
+
* Use `create(GetTaskResultRequestSchema)` to create a new message.
|
|
578
|
+
*/
|
|
579
|
+
export const GetTaskResultRequestSchema: GenMessage<GetTaskResultRequest> = /*@__PURE__*/
|
|
580
|
+
messageDesc(file_captchasonic_v1_sonic, 12);
|
|
581
|
+
|
|
582
|
+
/**
|
|
583
|
+
* @generated from message captchasonic.v1.GetTaskResultResponse
|
|
584
|
+
*/
|
|
585
|
+
export type GetTaskResultResponse = Message<"captchasonic.v1.GetTaskResultResponse"> & {
|
|
586
|
+
/**
|
|
587
|
+
* @generated from field: int32 errorId = 1;
|
|
588
|
+
*/
|
|
589
|
+
errorId: number;
|
|
590
|
+
|
|
591
|
+
/**
|
|
592
|
+
* @generated from field: string status = 2;
|
|
593
|
+
*/
|
|
594
|
+
status: string;
|
|
595
|
+
|
|
596
|
+
/**
|
|
597
|
+
* @generated from field: map<string, string> solution = 3;
|
|
598
|
+
*/
|
|
599
|
+
solution: { [key: string]: string };
|
|
600
|
+
|
|
601
|
+
/**
|
|
602
|
+
* @generated from field: captchasonic.v1.SolutionPayload typed_solution = 4;
|
|
603
|
+
*/
|
|
604
|
+
typedSolution?: SolutionPayload | undefined;
|
|
605
|
+
};
|
|
606
|
+
|
|
607
|
+
/**
|
|
608
|
+
* Describes the message captchasonic.v1.GetTaskResultResponse.
|
|
609
|
+
* Use `create(GetTaskResultResponseSchema)` to create a new message.
|
|
610
|
+
*/
|
|
611
|
+
export const GetTaskResultResponseSchema: GenMessage<GetTaskResultResponse> = /*@__PURE__*/
|
|
612
|
+
messageDesc(file_captchasonic_v1_sonic, 13);
|
|
613
|
+
|
|
614
|
+
/**
|
|
615
|
+
* @generated from message captchasonic.v1.GetBalanceRequest
|
|
616
|
+
*/
|
|
617
|
+
export type GetBalanceRequest = Message<"captchasonic.v1.GetBalanceRequest"> & {
|
|
618
|
+
/**
|
|
619
|
+
* @generated from field: string apiKey = 1;
|
|
620
|
+
*/
|
|
621
|
+
apiKey: string;
|
|
622
|
+
};
|
|
623
|
+
|
|
624
|
+
/**
|
|
625
|
+
* Describes the message captchasonic.v1.GetBalanceRequest.
|
|
626
|
+
* Use `create(GetBalanceRequestSchema)` to create a new message.
|
|
627
|
+
*/
|
|
628
|
+
export const GetBalanceRequestSchema: GenMessage<GetBalanceRequest> = /*@__PURE__*/
|
|
629
|
+
messageDesc(file_captchasonic_v1_sonic, 14);
|
|
630
|
+
|
|
631
|
+
/**
|
|
632
|
+
* @generated from message captchasonic.v1.GetBalanceResponse
|
|
633
|
+
*/
|
|
634
|
+
export type GetBalanceResponse = Message<"captchasonic.v1.GetBalanceResponse"> & {
|
|
635
|
+
/**
|
|
636
|
+
* @generated from field: double balance = 1;
|
|
637
|
+
*/
|
|
638
|
+
balance: number;
|
|
639
|
+
|
|
640
|
+
/**
|
|
641
|
+
* @generated from field: int32 errorId = 2;
|
|
642
|
+
*/
|
|
643
|
+
errorId: number;
|
|
644
|
+
|
|
645
|
+
/**
|
|
646
|
+
* @generated from field: string status = 3;
|
|
647
|
+
*/
|
|
648
|
+
status: string;
|
|
649
|
+
};
|
|
650
|
+
|
|
651
|
+
/**
|
|
652
|
+
* Describes the message captchasonic.v1.GetBalanceResponse.
|
|
653
|
+
* Use `create(GetBalanceResponseSchema)` to create a new message.
|
|
654
|
+
*/
|
|
655
|
+
export const GetBalanceResponseSchema: GenMessage<GetBalanceResponse> = /*@__PURE__*/
|
|
656
|
+
messageDesc(file_captchasonic_v1_sonic, 15);
|
|
657
|
+
|
|
658
|
+
/**
|
|
659
|
+
* @generated from message captchasonic.v1.HealthCheckRequest
|
|
660
|
+
*/
|
|
661
|
+
export type HealthCheckRequest = Message<"captchasonic.v1.HealthCheckRequest"> & {
|
|
662
|
+
};
|
|
663
|
+
|
|
664
|
+
/**
|
|
665
|
+
* Describes the message captchasonic.v1.HealthCheckRequest.
|
|
666
|
+
* Use `create(HealthCheckRequestSchema)` to create a new message.
|
|
667
|
+
*/
|
|
668
|
+
export const HealthCheckRequestSchema: GenMessage<HealthCheckRequest> = /*@__PURE__*/
|
|
669
|
+
messageDesc(file_captchasonic_v1_sonic, 16);
|
|
670
|
+
|
|
671
|
+
/**
|
|
672
|
+
* @generated from message captchasonic.v1.HealthCheckResponse
|
|
673
|
+
*/
|
|
674
|
+
export type HealthCheckResponse = Message<"captchasonic.v1.HealthCheckResponse"> & {
|
|
675
|
+
/**
|
|
676
|
+
* @generated from field: bool healthy = 1;
|
|
677
|
+
*/
|
|
678
|
+
healthy: boolean;
|
|
679
|
+
|
|
680
|
+
/**
|
|
681
|
+
* @generated from field: string version = 2;
|
|
682
|
+
*/
|
|
683
|
+
version: string;
|
|
684
|
+
};
|
|
685
|
+
|
|
686
|
+
/**
|
|
687
|
+
* Describes the message captchasonic.v1.HealthCheckResponse.
|
|
688
|
+
* Use `create(HealthCheckResponseSchema)` to create a new message.
|
|
689
|
+
*/
|
|
690
|
+
export const HealthCheckResponseSchema: GenMessage<HealthCheckResponse> = /*@__PURE__*/
|
|
691
|
+
messageDesc(file_captchasonic_v1_sonic, 17);
|
|
692
|
+
|
|
693
|
+
/**
|
|
694
|
+
* @generated from service captchasonic.v1.SonicService
|
|
695
|
+
*/
|
|
696
|
+
export const SonicService: GenService<{
|
|
697
|
+
/**
|
|
698
|
+
* @generated from rpc captchasonic.v1.SonicService.CreateTask
|
|
699
|
+
*/
|
|
700
|
+
createTask: {
|
|
701
|
+
methodKind: "unary";
|
|
702
|
+
input: typeof CreateTaskRequestSchema;
|
|
703
|
+
output: typeof CreateTaskResponseSchema;
|
|
704
|
+
},
|
|
705
|
+
/**
|
|
706
|
+
* @generated from rpc captchasonic.v1.SonicService.GetTaskResult
|
|
707
|
+
*/
|
|
708
|
+
getTaskResult: {
|
|
709
|
+
methodKind: "unary";
|
|
710
|
+
input: typeof GetTaskResultRequestSchema;
|
|
711
|
+
output: typeof GetTaskResultResponseSchema;
|
|
712
|
+
},
|
|
713
|
+
/**
|
|
714
|
+
* @generated from rpc captchasonic.v1.SonicService.GetBalance
|
|
715
|
+
*/
|
|
716
|
+
getBalance: {
|
|
717
|
+
methodKind: "unary";
|
|
718
|
+
input: typeof GetBalanceRequestSchema;
|
|
719
|
+
output: typeof GetBalanceResponseSchema;
|
|
720
|
+
},
|
|
721
|
+
/**
|
|
722
|
+
* @generated from rpc captchasonic.v1.SonicService.HealthCheck
|
|
723
|
+
*/
|
|
724
|
+
healthCheck: {
|
|
725
|
+
methodKind: "unary";
|
|
726
|
+
input: typeof HealthCheckRequestSchema;
|
|
727
|
+
output: typeof HealthCheckResponseSchema;
|
|
728
|
+
},
|
|
729
|
+
}> = /*@__PURE__*/
|
|
730
|
+
serviceDesc(file_captchasonic_v1_sonic, 0);
|
|
731
|
+
|