@oxy.so/contracts 3.0.0 → 4.0.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.
|
@@ -1,22 +1,28 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
+
/**
|
|
3
|
+
* How Oxy observed an external account. `instagram-graph` is Meta's Graph API
|
|
4
|
+
* Business Discovery, a fallback transport for Business/Creator Instagram
|
|
5
|
+
* accounts when the ActivityPub bridge is unavailable.
|
|
6
|
+
*/
|
|
7
|
+
export declare const externalIdentityProtocolSchema: z.ZodEnum<["activitypub", "atproto", "instagram-graph"]>;
|
|
2
8
|
export declare const externalIdentityReferenceSchema: z.ZodObject<{
|
|
3
9
|
canonicalAcct: z.ZodString;
|
|
4
10
|
network: z.ZodString;
|
|
5
|
-
protocol: z.ZodEnum<["activitypub", "atproto"]>;
|
|
11
|
+
protocol: z.ZodEnum<["activitypub", "atproto", "instagram-graph"]>;
|
|
6
12
|
actorUri: z.ZodString;
|
|
7
13
|
transportAcct: z.ZodString;
|
|
8
14
|
sourceUserId: z.ZodString;
|
|
9
15
|
}, "strip", z.ZodTypeAny, {
|
|
10
16
|
canonicalAcct: string;
|
|
11
17
|
network: string;
|
|
12
|
-
protocol: "activitypub" | "atproto";
|
|
18
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
13
19
|
actorUri: string;
|
|
14
20
|
transportAcct: string;
|
|
15
21
|
sourceUserId: string;
|
|
16
22
|
}, {
|
|
17
23
|
canonicalAcct: string;
|
|
18
24
|
network: string;
|
|
19
|
-
protocol: "activitypub" | "atproto";
|
|
25
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
20
26
|
actorUri: string;
|
|
21
27
|
transportAcct: string;
|
|
22
28
|
sourceUserId: string;
|
|
@@ -25,24 +31,24 @@ export declare const resolveExternalIdentityRequestSchema: z.ZodEffects<z.ZodObj
|
|
|
25
31
|
actorUri: z.ZodOptional<z.ZodString>;
|
|
26
32
|
handle: z.ZodOptional<z.ZodString>;
|
|
27
33
|
transportAcct: z.ZodOptional<z.ZodString>;
|
|
28
|
-
protocol: z.ZodOptional<z.ZodEnum<["activitypub", "atproto"]>>;
|
|
34
|
+
protocol: z.ZodOptional<z.ZodEnum<["activitypub", "atproto", "instagram-graph"]>>;
|
|
29
35
|
}, "strip", z.ZodTypeAny, {
|
|
30
|
-
protocol?: "activitypub" | "atproto" | undefined;
|
|
36
|
+
protocol?: "activitypub" | "atproto" | "instagram-graph" | undefined;
|
|
31
37
|
actorUri?: string | undefined;
|
|
32
38
|
transportAcct?: string | undefined;
|
|
33
39
|
handle?: string | undefined;
|
|
34
40
|
}, {
|
|
35
|
-
protocol?: "activitypub" | "atproto" | undefined;
|
|
41
|
+
protocol?: "activitypub" | "atproto" | "instagram-graph" | undefined;
|
|
36
42
|
actorUri?: string | undefined;
|
|
37
43
|
transportAcct?: string | undefined;
|
|
38
44
|
handle?: string | undefined;
|
|
39
45
|
}>, {
|
|
40
|
-
protocol?: "activitypub" | "atproto" | undefined;
|
|
46
|
+
protocol?: "activitypub" | "atproto" | "instagram-graph" | undefined;
|
|
41
47
|
actorUri?: string | undefined;
|
|
42
48
|
transportAcct?: string | undefined;
|
|
43
49
|
handle?: string | undefined;
|
|
44
50
|
}, {
|
|
45
|
-
protocol?: "activitypub" | "atproto" | undefined;
|
|
51
|
+
protocol?: "activitypub" | "atproto" | "instagram-graph" | undefined;
|
|
46
52
|
actorUri?: string | undefined;
|
|
47
53
|
transportAcct?: string | undefined;
|
|
48
54
|
handle?: string | undefined;
|
|
@@ -75,21 +81,21 @@ export declare const resolveExternalIdentityResponseSchema: z.ZodEffects<z.ZodOb
|
|
|
75
81
|
externalIdentities: z.ZodArray<z.ZodObject<{
|
|
76
82
|
canonicalAcct: z.ZodString;
|
|
77
83
|
network: z.ZodString;
|
|
78
|
-
protocol: z.ZodEnum<["activitypub", "atproto"]>;
|
|
84
|
+
protocol: z.ZodEnum<["activitypub", "atproto", "instagram-graph"]>;
|
|
79
85
|
actorUri: z.ZodString;
|
|
80
86
|
transportAcct: z.ZodString;
|
|
81
87
|
sourceUserId: z.ZodString;
|
|
82
88
|
}, "strip", z.ZodTypeAny, {
|
|
83
89
|
canonicalAcct: string;
|
|
84
90
|
network: string;
|
|
85
|
-
protocol: "activitypub" | "atproto";
|
|
91
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
86
92
|
actorUri: string;
|
|
87
93
|
transportAcct: string;
|
|
88
94
|
sourceUserId: string;
|
|
89
95
|
}, {
|
|
90
96
|
canonicalAcct: string;
|
|
91
97
|
network: string;
|
|
92
|
-
protocol: "activitypub" | "atproto";
|
|
98
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
93
99
|
actorUri: string;
|
|
94
100
|
transportAcct: string;
|
|
95
101
|
sourceUserId: string;
|
|
@@ -122,21 +128,21 @@ export declare const resolveExternalIdentityResponseSchema: z.ZodEffects<z.ZodOb
|
|
|
122
128
|
externalIdentities: z.ZodArray<z.ZodObject<{
|
|
123
129
|
canonicalAcct: z.ZodString;
|
|
124
130
|
network: z.ZodString;
|
|
125
|
-
protocol: z.ZodEnum<["activitypub", "atproto"]>;
|
|
131
|
+
protocol: z.ZodEnum<["activitypub", "atproto", "instagram-graph"]>;
|
|
126
132
|
actorUri: z.ZodString;
|
|
127
133
|
transportAcct: z.ZodString;
|
|
128
134
|
sourceUserId: z.ZodString;
|
|
129
135
|
}, "strip", z.ZodTypeAny, {
|
|
130
136
|
canonicalAcct: string;
|
|
131
137
|
network: string;
|
|
132
|
-
protocol: "activitypub" | "atproto";
|
|
138
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
133
139
|
actorUri: string;
|
|
134
140
|
transportAcct: string;
|
|
135
141
|
sourceUserId: string;
|
|
136
142
|
}, {
|
|
137
143
|
canonicalAcct: string;
|
|
138
144
|
network: string;
|
|
139
|
-
protocol: "activitypub" | "atproto";
|
|
145
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
140
146
|
actorUri: string;
|
|
141
147
|
transportAcct: string;
|
|
142
148
|
sourceUserId: string;
|
|
@@ -169,21 +175,21 @@ export declare const resolveExternalIdentityResponseSchema: z.ZodEffects<z.ZodOb
|
|
|
169
175
|
externalIdentities: z.ZodArray<z.ZodObject<{
|
|
170
176
|
canonicalAcct: z.ZodString;
|
|
171
177
|
network: z.ZodString;
|
|
172
|
-
protocol: z.ZodEnum<["activitypub", "atproto"]>;
|
|
178
|
+
protocol: z.ZodEnum<["activitypub", "atproto", "instagram-graph"]>;
|
|
173
179
|
actorUri: z.ZodString;
|
|
174
180
|
transportAcct: z.ZodString;
|
|
175
181
|
sourceUserId: z.ZodString;
|
|
176
182
|
}, "strip", z.ZodTypeAny, {
|
|
177
183
|
canonicalAcct: string;
|
|
178
184
|
network: string;
|
|
179
|
-
protocol: "activitypub" | "atproto";
|
|
185
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
180
186
|
actorUri: string;
|
|
181
187
|
transportAcct: string;
|
|
182
188
|
sourceUserId: string;
|
|
183
189
|
}, {
|
|
184
190
|
canonicalAcct: string;
|
|
185
191
|
network: string;
|
|
186
|
-
protocol: "activitypub" | "atproto";
|
|
192
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
187
193
|
actorUri: string;
|
|
188
194
|
transportAcct: string;
|
|
189
195
|
sourceUserId: string;
|
|
@@ -193,7 +199,7 @@ export declare const resolveExternalIdentityResponseSchema: z.ZodEffects<z.ZodOb
|
|
|
193
199
|
externalIdentity: z.ZodObject<{
|
|
194
200
|
canonicalAcct: z.ZodString;
|
|
195
201
|
network: z.ZodString;
|
|
196
|
-
protocol: z.ZodEnum<["activitypub", "atproto"]>;
|
|
202
|
+
protocol: z.ZodEnum<["activitypub", "atproto", "instagram-graph"]>;
|
|
197
203
|
actorUri: z.ZodString;
|
|
198
204
|
transportAcct: z.ZodString;
|
|
199
205
|
sourceUserId: z.ZodString;
|
|
@@ -203,7 +209,7 @@ export declare const resolveExternalIdentityResponseSchema: z.ZodEffects<z.ZodOb
|
|
|
203
209
|
userId: string;
|
|
204
210
|
canonicalAcct: string;
|
|
205
211
|
network: string;
|
|
206
|
-
protocol: "activitypub" | "atproto";
|
|
212
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
207
213
|
actorUri: string;
|
|
208
214
|
transportAcct: string;
|
|
209
215
|
sourceUserId: string;
|
|
@@ -211,7 +217,7 @@ export declare const resolveExternalIdentityResponseSchema: z.ZodEffects<z.ZodOb
|
|
|
211
217
|
userId: string;
|
|
212
218
|
canonicalAcct: string;
|
|
213
219
|
network: string;
|
|
214
|
-
protocol: "activitypub" | "atproto";
|
|
220
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
215
221
|
actorUri: string;
|
|
216
222
|
transportAcct: string;
|
|
217
223
|
sourceUserId: string;
|
|
@@ -219,21 +225,21 @@ export declare const resolveExternalIdentityResponseSchema: z.ZodEffects<z.ZodOb
|
|
|
219
225
|
externalIdentities: z.ZodArray<z.ZodObject<{
|
|
220
226
|
canonicalAcct: z.ZodString;
|
|
221
227
|
network: z.ZodString;
|
|
222
|
-
protocol: z.ZodEnum<["activitypub", "atproto"]>;
|
|
228
|
+
protocol: z.ZodEnum<["activitypub", "atproto", "instagram-graph"]>;
|
|
223
229
|
actorUri: z.ZodString;
|
|
224
230
|
transportAcct: z.ZodString;
|
|
225
231
|
sourceUserId: z.ZodString;
|
|
226
232
|
}, "strip", z.ZodTypeAny, {
|
|
227
233
|
canonicalAcct: string;
|
|
228
234
|
network: string;
|
|
229
|
-
protocol: "activitypub" | "atproto";
|
|
235
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
230
236
|
actorUri: string;
|
|
231
237
|
transportAcct: string;
|
|
232
238
|
sourceUserId: string;
|
|
233
239
|
}, {
|
|
234
240
|
canonicalAcct: string;
|
|
235
241
|
network: string;
|
|
236
|
-
protocol: "activitypub" | "atproto";
|
|
242
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
237
243
|
actorUri: string;
|
|
238
244
|
transportAcct: string;
|
|
239
245
|
sourceUserId: string;
|
|
@@ -247,7 +253,7 @@ export declare const resolveExternalIdentityResponseSchema: z.ZodEffects<z.ZodOb
|
|
|
247
253
|
externalIdentities: {
|
|
248
254
|
canonicalAcct: string;
|
|
249
255
|
network: string;
|
|
250
|
-
protocol: "activitypub" | "atproto";
|
|
256
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
251
257
|
actorUri: string;
|
|
252
258
|
transportAcct: string;
|
|
253
259
|
sourceUserId: string;
|
|
@@ -278,7 +284,7 @@ export declare const resolveExternalIdentityResponseSchema: z.ZodEffects<z.ZodOb
|
|
|
278
284
|
externalIdentities: {
|
|
279
285
|
canonicalAcct: string;
|
|
280
286
|
network: string;
|
|
281
|
-
protocol: "activitypub" | "atproto";
|
|
287
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
282
288
|
actorUri: string;
|
|
283
289
|
transportAcct: string;
|
|
284
290
|
sourceUserId: string;
|
|
@@ -288,7 +294,7 @@ export declare const resolveExternalIdentityResponseSchema: z.ZodEffects<z.ZodOb
|
|
|
288
294
|
userId: string;
|
|
289
295
|
canonicalAcct: string;
|
|
290
296
|
network: string;
|
|
291
|
-
protocol: "activitypub" | "atproto";
|
|
297
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
292
298
|
actorUri: string;
|
|
293
299
|
transportAcct: string;
|
|
294
300
|
sourceUserId: string;
|
|
@@ -301,7 +307,7 @@ export declare const resolveExternalIdentityResponseSchema: z.ZodEffects<z.ZodOb
|
|
|
301
307
|
externalIdentities: {
|
|
302
308
|
canonicalAcct: string;
|
|
303
309
|
network: string;
|
|
304
|
-
protocol: "activitypub" | "atproto";
|
|
310
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
305
311
|
actorUri: string;
|
|
306
312
|
transportAcct: string;
|
|
307
313
|
sourceUserId: string;
|
|
@@ -332,7 +338,7 @@ export declare const resolveExternalIdentityResponseSchema: z.ZodEffects<z.ZodOb
|
|
|
332
338
|
externalIdentities: {
|
|
333
339
|
canonicalAcct: string;
|
|
334
340
|
network: string;
|
|
335
|
-
protocol: "activitypub" | "atproto";
|
|
341
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
336
342
|
actorUri: string;
|
|
337
343
|
transportAcct: string;
|
|
338
344
|
sourceUserId: string;
|
|
@@ -342,7 +348,7 @@ export declare const resolveExternalIdentityResponseSchema: z.ZodEffects<z.ZodOb
|
|
|
342
348
|
userId: string;
|
|
343
349
|
canonicalAcct: string;
|
|
344
350
|
network: string;
|
|
345
|
-
protocol: "activitypub" | "atproto";
|
|
351
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
346
352
|
actorUri: string;
|
|
347
353
|
transportAcct: string;
|
|
348
354
|
sourceUserId: string;
|
|
@@ -355,7 +361,7 @@ export declare const resolveExternalIdentityResponseSchema: z.ZodEffects<z.ZodOb
|
|
|
355
361
|
externalIdentities: {
|
|
356
362
|
canonicalAcct: string;
|
|
357
363
|
network: string;
|
|
358
|
-
protocol: "activitypub" | "atproto";
|
|
364
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
359
365
|
actorUri: string;
|
|
360
366
|
transportAcct: string;
|
|
361
367
|
sourceUserId: string;
|
|
@@ -386,7 +392,7 @@ export declare const resolveExternalIdentityResponseSchema: z.ZodEffects<z.ZodOb
|
|
|
386
392
|
externalIdentities: {
|
|
387
393
|
canonicalAcct: string;
|
|
388
394
|
network: string;
|
|
389
|
-
protocol: "activitypub" | "atproto";
|
|
395
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
390
396
|
actorUri: string;
|
|
391
397
|
transportAcct: string;
|
|
392
398
|
sourceUserId: string;
|
|
@@ -396,7 +402,7 @@ export declare const resolveExternalIdentityResponseSchema: z.ZodEffects<z.ZodOb
|
|
|
396
402
|
userId: string;
|
|
397
403
|
canonicalAcct: string;
|
|
398
404
|
network: string;
|
|
399
|
-
protocol: "activitypub" | "atproto";
|
|
405
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
400
406
|
actorUri: string;
|
|
401
407
|
transportAcct: string;
|
|
402
408
|
sourceUserId: string;
|
|
@@ -409,7 +415,7 @@ export declare const resolveExternalIdentityResponseSchema: z.ZodEffects<z.ZodOb
|
|
|
409
415
|
externalIdentities: {
|
|
410
416
|
canonicalAcct: string;
|
|
411
417
|
network: string;
|
|
412
|
-
protocol: "activitypub" | "atproto";
|
|
418
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
413
419
|
actorUri: string;
|
|
414
420
|
transportAcct: string;
|
|
415
421
|
sourceUserId: string;
|
|
@@ -440,7 +446,7 @@ export declare const resolveExternalIdentityResponseSchema: z.ZodEffects<z.ZodOb
|
|
|
440
446
|
externalIdentities: {
|
|
441
447
|
canonicalAcct: string;
|
|
442
448
|
network: string;
|
|
443
|
-
protocol: "activitypub" | "atproto";
|
|
449
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
444
450
|
actorUri: string;
|
|
445
451
|
transportAcct: string;
|
|
446
452
|
sourceUserId: string;
|
|
@@ -450,7 +456,7 @@ export declare const resolveExternalIdentityResponseSchema: z.ZodEffects<z.ZodOb
|
|
|
450
456
|
userId: string;
|
|
451
457
|
canonicalAcct: string;
|
|
452
458
|
network: string;
|
|
453
|
-
protocol: "activitypub" | "atproto";
|
|
459
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
454
460
|
actorUri: string;
|
|
455
461
|
transportAcct: string;
|
|
456
462
|
sourceUserId: string;
|
|
@@ -470,21 +476,21 @@ export declare const lookupExternalIdentitiesResponseSchema: z.ZodObject<{
|
|
|
470
476
|
externalIdentities: z.ZodArray<z.ZodObject<{
|
|
471
477
|
canonicalAcct: z.ZodString;
|
|
472
478
|
network: z.ZodString;
|
|
473
|
-
protocol: z.ZodEnum<["activitypub", "atproto"]>;
|
|
479
|
+
protocol: z.ZodEnum<["activitypub", "atproto", "instagram-graph"]>;
|
|
474
480
|
actorUri: z.ZodString;
|
|
475
481
|
transportAcct: z.ZodString;
|
|
476
482
|
sourceUserId: z.ZodString;
|
|
477
483
|
}, "strip", z.ZodTypeAny, {
|
|
478
484
|
canonicalAcct: string;
|
|
479
485
|
network: string;
|
|
480
|
-
protocol: "activitypub" | "atproto";
|
|
486
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
481
487
|
actorUri: string;
|
|
482
488
|
transportAcct: string;
|
|
483
489
|
sourceUserId: string;
|
|
484
490
|
}, {
|
|
485
491
|
canonicalAcct: string;
|
|
486
492
|
network: string;
|
|
487
|
-
protocol: "activitypub" | "atproto";
|
|
493
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
488
494
|
actorUri: string;
|
|
489
495
|
transportAcct: string;
|
|
490
496
|
sourceUserId: string;
|
|
@@ -495,7 +501,7 @@ export declare const lookupExternalIdentitiesResponseSchema: z.ZodObject<{
|
|
|
495
501
|
externalIdentities: {
|
|
496
502
|
canonicalAcct: string;
|
|
497
503
|
network: string;
|
|
498
|
-
protocol: "activitypub" | "atproto";
|
|
504
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
499
505
|
actorUri: string;
|
|
500
506
|
transportAcct: string;
|
|
501
507
|
sourceUserId: string;
|
|
@@ -507,7 +513,7 @@ export declare const lookupExternalIdentitiesResponseSchema: z.ZodObject<{
|
|
|
507
513
|
externalIdentities: {
|
|
508
514
|
canonicalAcct: string;
|
|
509
515
|
network: string;
|
|
510
|
-
protocol: "activitypub" | "atproto";
|
|
516
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
511
517
|
actorUri: string;
|
|
512
518
|
transportAcct: string;
|
|
513
519
|
sourceUserId: string;
|
|
@@ -521,7 +527,7 @@ export declare const lookupExternalIdentitiesResponseSchema: z.ZodObject<{
|
|
|
521
527
|
externalIdentities: {
|
|
522
528
|
canonicalAcct: string;
|
|
523
529
|
network: string;
|
|
524
|
-
protocol: "activitypub" | "atproto";
|
|
530
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
525
531
|
actorUri: string;
|
|
526
532
|
transportAcct: string;
|
|
527
533
|
sourceUserId: string;
|
|
@@ -535,7 +541,7 @@ export declare const lookupExternalIdentitiesResponseSchema: z.ZodObject<{
|
|
|
535
541
|
externalIdentities: {
|
|
536
542
|
canonicalAcct: string;
|
|
537
543
|
network: string;
|
|
538
|
-
protocol: "activitypub" | "atproto";
|
|
544
|
+
protocol: "activitypub" | "atproto" | "instagram-graph";
|
|
539
545
|
actorUri: string;
|
|
540
546
|
transportAcct: string;
|
|
541
547
|
sourceUserId: string;
|
|
@@ -544,6 +550,7 @@ export declare const lookupExternalIdentitiesResponseSchema: z.ZodObject<{
|
|
|
544
550
|
identifier: string;
|
|
545
551
|
}[];
|
|
546
552
|
}>;
|
|
553
|
+
export type ExternalIdentityProtocol = z.infer<typeof externalIdentityProtocolSchema>;
|
|
547
554
|
export type ExternalIdentityReference = z.infer<typeof externalIdentityReferenceSchema>;
|
|
548
555
|
export type ResolveExternalIdentityRequest = z.infer<typeof resolveExternalIdentityRequestSchema>;
|
|
549
556
|
export type ResolveExternalIdentityResponse = z.infer<typeof resolveExternalIdentityResponseSchema>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@oxy.so/contracts",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "4.0.0",
|
|
4
4
|
"description": "OxyHQ API contracts — single source of truth for request/response Zod schemas and inferred types, shared by the backend and the client SDKs",
|
|
5
5
|
"main": "dist/cjs/index.js",
|
|
6
6
|
"module": "dist/esm/index.js",
|