@crosspost/types 0.2.0 → 0.2.2
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 +69 -33
- package/dist/index.d.cts +193 -86
- package/dist/index.d.ts +193 -86
- package/dist/index.js +66 -33
- package/package.json +1 -1
- package/src/activity.ts +87 -28
- package/src/auth.ts +4 -4
- package/src/response.ts +2 -7
package/dist/index.d.ts
CHANGED
@@ -104,32 +104,17 @@ declare const ResponseMetaSchema: z.ZodObject<{
|
|
104
104
|
reset: number;
|
105
105
|
}>>;
|
106
106
|
pagination: z.ZodOptional<z.ZodObject<{
|
107
|
-
page: z.ZodOptional<z.ZodNumber>;
|
108
|
-
perPage: z.ZodOptional<z.ZodNumber>;
|
109
|
-
total: z.ZodOptional<z.ZodNumber>;
|
110
107
|
limit: z.ZodOptional<z.ZodNumber>;
|
111
108
|
offset: z.ZodOptional<z.ZodNumber>;
|
112
|
-
|
113
|
-
nextCursor: z.ZodOptional<z.ZodString>;
|
114
|
-
prevCursor: z.ZodOptional<z.ZodString>;
|
109
|
+
total: z.ZodOptional<z.ZodNumber>;
|
115
110
|
}, "strip", z.ZodTypeAny, {
|
116
111
|
limit?: number | undefined;
|
117
|
-
page?: number | undefined;
|
118
|
-
perPage?: number | undefined;
|
119
|
-
total?: number | undefined;
|
120
112
|
offset?: number | undefined;
|
121
|
-
|
122
|
-
nextCursor?: string | undefined;
|
123
|
-
prevCursor?: string | undefined;
|
113
|
+
total?: number | undefined;
|
124
114
|
}, {
|
125
115
|
limit?: number | undefined;
|
126
|
-
page?: number | undefined;
|
127
|
-
perPage?: number | undefined;
|
128
|
-
total?: number | undefined;
|
129
116
|
offset?: number | undefined;
|
130
|
-
|
131
|
-
nextCursor?: string | undefined;
|
132
|
-
prevCursor?: string | undefined;
|
117
|
+
total?: number | undefined;
|
133
118
|
}>>;
|
134
119
|
}, "strip", z.ZodTypeAny, {
|
135
120
|
requestId: string;
|
@@ -141,13 +126,8 @@ declare const ResponseMetaSchema: z.ZodObject<{
|
|
141
126
|
} | undefined;
|
142
127
|
pagination?: {
|
143
128
|
limit?: number | undefined;
|
144
|
-
page?: number | undefined;
|
145
|
-
perPage?: number | undefined;
|
146
|
-
total?: number | undefined;
|
147
129
|
offset?: number | undefined;
|
148
|
-
|
149
|
-
nextCursor?: string | undefined;
|
150
|
-
prevCursor?: string | undefined;
|
130
|
+
total?: number | undefined;
|
151
131
|
} | undefined;
|
152
132
|
}, {
|
153
133
|
requestId: string;
|
@@ -159,13 +139,8 @@ declare const ResponseMetaSchema: z.ZodObject<{
|
|
159
139
|
} | undefined;
|
160
140
|
pagination?: {
|
161
141
|
limit?: number | undefined;
|
162
|
-
page?: number | undefined;
|
163
|
-
perPage?: number | undefined;
|
164
|
-
total?: number | undefined;
|
165
142
|
offset?: number | undefined;
|
166
|
-
|
167
|
-
nextCursor?: string | undefined;
|
168
|
-
prevCursor?: string | undefined;
|
143
|
+
total?: number | undefined;
|
169
144
|
} | undefined;
|
170
145
|
}>;
|
171
146
|
declare const SuccessDetailSchema: z.ZodObject<{
|
@@ -295,7 +270,7 @@ declare const MultiStatusDataSchema: z.ZodObject<{
|
|
295
270
|
}>;
|
296
271
|
interface ApiResponse<T> {
|
297
272
|
success: boolean;
|
298
|
-
data?: T |
|
273
|
+
data?: T | null;
|
299
274
|
errors?: ErrorDetail[] | null;
|
300
275
|
meta: ResponseMeta;
|
301
276
|
}
|
@@ -610,26 +585,26 @@ declare const ConnectedAccountsResponseSchema: z.ZodObject<{
|
|
610
585
|
}>;
|
611
586
|
declare const NearAuthorizationRequestSchema: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
|
612
587
|
declare const NearAuthorizationResponseSchema: z.ZodObject<{
|
613
|
-
|
614
|
-
|
588
|
+
signerId: z.ZodString;
|
589
|
+
isAuthorized: z.ZodBoolean;
|
615
590
|
}, "strip", z.ZodTypeAny, {
|
616
|
-
|
617
|
-
|
591
|
+
signerId: string;
|
592
|
+
isAuthorized: boolean;
|
618
593
|
}, {
|
619
|
-
|
620
|
-
|
594
|
+
signerId: string;
|
595
|
+
isAuthorized: boolean;
|
621
596
|
}>;
|
622
597
|
declare const NearAuthorizationStatusResponseSchema: z.ZodObject<{
|
623
|
-
|
624
|
-
|
598
|
+
signerId: z.ZodString;
|
599
|
+
isAuthorized: z.ZodBoolean;
|
625
600
|
authorizedAt: z.ZodOptional<z.ZodString>;
|
626
601
|
}, "strip", z.ZodTypeAny, {
|
627
|
-
|
628
|
-
|
602
|
+
signerId: string;
|
603
|
+
isAuthorized: boolean;
|
629
604
|
authorizedAt?: string | undefined;
|
630
605
|
}, {
|
631
|
-
|
632
|
-
|
606
|
+
signerId: string;
|
607
|
+
isAuthorized: boolean;
|
633
608
|
authorizedAt?: string | undefined;
|
634
609
|
}>;
|
635
610
|
type PlatformParam = z.infer<typeof PlatformParamSchema>;
|
@@ -2431,6 +2406,7 @@ declare const RateLimitResponseSchema: z.ZodObject<{
|
|
2431
2406
|
}>>;
|
2432
2407
|
signerId: z.ZodString;
|
2433
2408
|
}, "strip", z.ZodTypeAny, {
|
2409
|
+
signerId: string;
|
2434
2410
|
platformLimits: {
|
2435
2411
|
platform: Platform;
|
2436
2412
|
endpoints: Record<string, {
|
@@ -2449,8 +2425,8 @@ declare const RateLimitResponseSchema: z.ZodObject<{
|
|
2449
2425
|
resetSeconds: number;
|
2450
2426
|
timeWindow: string;
|
2451
2427
|
}>;
|
2452
|
-
signerId: string;
|
2453
2428
|
}, {
|
2429
|
+
signerId: string;
|
2454
2430
|
platformLimits: {
|
2455
2431
|
platform: Platform;
|
2456
2432
|
endpoints: Record<string, {
|
@@ -2469,7 +2445,6 @@ declare const RateLimitResponseSchema: z.ZodObject<{
|
|
2469
2445
|
resetSeconds: number;
|
2470
2446
|
timeWindow: string;
|
2471
2447
|
}>;
|
2472
|
-
signerId: string;
|
2473
2448
|
}>;
|
2474
2449
|
declare const EndpointRateLimitResponseSchema: z.ZodObject<{
|
2475
2450
|
platformLimits: z.ZodArray<z.ZodObject<{
|
@@ -2537,6 +2512,7 @@ declare const EndpointRateLimitResponseSchema: z.ZodObject<{
|
|
2537
2512
|
endpoint: z.ZodString;
|
2538
2513
|
signerId: z.ZodString;
|
2539
2514
|
}, "strip", z.ZodTypeAny, {
|
2515
|
+
signerId: string;
|
2540
2516
|
endpoint: string;
|
2541
2517
|
platformLimits: {
|
2542
2518
|
status: {
|
@@ -2548,7 +2524,6 @@ declare const EndpointRateLimitResponseSchema: z.ZodObject<{
|
|
2548
2524
|
};
|
2549
2525
|
platform: Platform;
|
2550
2526
|
}[];
|
2551
|
-
signerId: string;
|
2552
2527
|
usageLimit: {
|
2553
2528
|
remaining: number;
|
2554
2529
|
limit: number;
|
@@ -2558,6 +2533,7 @@ declare const EndpointRateLimitResponseSchema: z.ZodObject<{
|
|
2558
2533
|
timeWindow: string;
|
2559
2534
|
};
|
2560
2535
|
}, {
|
2536
|
+
signerId: string;
|
2561
2537
|
endpoint: string;
|
2562
2538
|
platformLimits: {
|
2563
2539
|
status: {
|
@@ -2569,7 +2545,6 @@ declare const EndpointRateLimitResponseSchema: z.ZodObject<{
|
|
2569
2545
|
};
|
2570
2546
|
platform: Platform;
|
2571
2547
|
}[];
|
2572
|
-
signerId: string;
|
2573
2548
|
usageLimit: {
|
2574
2549
|
remaining: number;
|
2575
2550
|
limit: number;
|
@@ -2589,6 +2564,15 @@ type AllRateLimitsResponse = z.infer<typeof AllRateLimitsResponseSchema>;
|
|
2589
2564
|
type RateLimitResponse = z.infer<typeof RateLimitResponseSchema>;
|
2590
2565
|
type EndpointRateLimitResponse = z.infer<typeof EndpointRateLimitResponseSchema>;
|
2591
2566
|
|
2567
|
+
declare enum ActivityType {
|
2568
|
+
POST = "post",
|
2569
|
+
REPOST = "repost",
|
2570
|
+
REPLY = "reply",
|
2571
|
+
QUOTE = "quote",
|
2572
|
+
LIKE = "like",
|
2573
|
+
UNLIKE = "unlike",
|
2574
|
+
DELETE = "delete"
|
2575
|
+
}
|
2592
2576
|
declare enum TimePeriod {
|
2593
2577
|
ALL = "all",
|
2594
2578
|
YEARLY = "year",
|
@@ -2596,18 +2580,72 @@ declare enum TimePeriod {
|
|
2596
2580
|
WEEKLY = "week",
|
2597
2581
|
DAILY = "day"
|
2598
2582
|
}
|
2599
|
-
|
2600
|
-
|
2583
|
+
/**
|
2584
|
+
* Schema for filtering by platform, activity type, and timeframe
|
2585
|
+
* Handles comma-separated lists for platforms and types
|
2586
|
+
*/
|
2587
|
+
declare const FilterSchema: z.ZodObject<{
|
2588
|
+
platforms: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodString>, string[] | undefined, string | undefined>, z.ZodOptional<z.ZodArray<z.ZodNativeEnum<typeof Platform>, "many">>>;
|
2589
|
+
types: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodString>, string[] | undefined, string | undefined>, z.ZodOptional<z.ZodArray<z.ZodNativeEnum<typeof ActivityType>, "many">>>;
|
2590
|
+
timeframe: z.ZodEffects<z.ZodOptional<z.ZodNativeEnum<typeof TimePeriod>>, TimePeriod, TimePeriod | undefined>;
|
2591
|
+
}, "strip", z.ZodTypeAny, {
|
2592
|
+
timeframe: TimePeriod;
|
2593
|
+
platforms?: Platform[] | undefined;
|
2594
|
+
types?: ActivityType[] | undefined;
|
2595
|
+
}, {
|
2596
|
+
platforms?: string | undefined;
|
2597
|
+
types?: string | undefined;
|
2598
|
+
timeframe?: TimePeriod | undefined;
|
2599
|
+
}>;
|
2600
|
+
/**
|
2601
|
+
* Common pagination schema used across queries
|
2602
|
+
*/
|
2603
|
+
declare const PaginationSchema: z.ZodObject<{
|
2601
2604
|
limit: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodString>, number | undefined, string | undefined>, z.ZodOptional<z.ZodNumber>>;
|
2602
2605
|
offset: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodString>, number | undefined, string | undefined>, z.ZodOptional<z.ZodNumber>>;
|
2603
2606
|
}, "strip", z.ZodTypeAny, {
|
2604
2607
|
limit?: number | undefined;
|
2605
2608
|
offset?: number | undefined;
|
2606
|
-
timeframe?: TimePeriod | undefined;
|
2607
2609
|
}, {
|
2608
2610
|
limit?: string | undefined;
|
2609
2611
|
offset?: string | undefined;
|
2610
|
-
|
2612
|
+
}>;
|
2613
|
+
/**
|
2614
|
+
* Query schema for leaderboard endpoints
|
2615
|
+
*/
|
2616
|
+
declare const ActivityLeaderboardQuerySchema: z.ZodObject<z.objectUtil.extendShape<{
|
2617
|
+
filter: z.ZodOptional<z.ZodObject<{
|
2618
|
+
platforms: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodString>, string[] | undefined, string | undefined>, z.ZodOptional<z.ZodArray<z.ZodNativeEnum<typeof Platform>, "many">>>;
|
2619
|
+
types: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodString>, string[] | undefined, string | undefined>, z.ZodOptional<z.ZodArray<z.ZodNativeEnum<typeof ActivityType>, "many">>>;
|
2620
|
+
timeframe: z.ZodEffects<z.ZodOptional<z.ZodNativeEnum<typeof TimePeriod>>, TimePeriod, TimePeriod | undefined>;
|
2621
|
+
}, "strip", z.ZodTypeAny, {
|
2622
|
+
timeframe: TimePeriod;
|
2623
|
+
platforms?: Platform[] | undefined;
|
2624
|
+
types?: ActivityType[] | undefined;
|
2625
|
+
}, {
|
2626
|
+
platforms?: string | undefined;
|
2627
|
+
types?: string | undefined;
|
2628
|
+
timeframe?: TimePeriod | undefined;
|
2629
|
+
}>>;
|
2630
|
+
}, {
|
2631
|
+
limit: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodString>, number | undefined, string | undefined>, z.ZodOptional<z.ZodNumber>>;
|
2632
|
+
offset: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodString>, number | undefined, string | undefined>, z.ZodOptional<z.ZodNumber>>;
|
2633
|
+
}>, "strip", z.ZodTypeAny, {
|
2634
|
+
filter?: {
|
2635
|
+
timeframe: TimePeriod;
|
2636
|
+
platforms?: Platform[] | undefined;
|
2637
|
+
types?: ActivityType[] | undefined;
|
2638
|
+
} | undefined;
|
2639
|
+
limit?: number | undefined;
|
2640
|
+
offset?: number | undefined;
|
2641
|
+
}, {
|
2642
|
+
filter?: {
|
2643
|
+
platforms?: string | undefined;
|
2644
|
+
types?: string | undefined;
|
2645
|
+
timeframe?: TimePeriod | undefined;
|
2646
|
+
} | undefined;
|
2647
|
+
limit?: string | undefined;
|
2648
|
+
offset?: string | undefined;
|
2611
2649
|
}>;
|
2612
2650
|
declare const AccountActivityEntrySchema: z.ZodObject<{
|
2613
2651
|
signerId: z.ZodString;
|
@@ -2619,6 +2657,7 @@ declare const AccountActivityEntrySchema: z.ZodObject<{
|
|
2619
2657
|
totalScore: z.ZodNumber;
|
2620
2658
|
rank: z.ZodNumber;
|
2621
2659
|
lastActive: z.ZodString;
|
2660
|
+
firstPostTimestamp: z.ZodString;
|
2622
2661
|
}, "strip", z.ZodTypeAny, {
|
2623
2662
|
signerId: string;
|
2624
2663
|
totalPosts: number;
|
@@ -2629,6 +2668,7 @@ declare const AccountActivityEntrySchema: z.ZodObject<{
|
|
2629
2668
|
totalScore: number;
|
2630
2669
|
rank: number;
|
2631
2670
|
lastActive: string;
|
2671
|
+
firstPostTimestamp: string;
|
2632
2672
|
}, {
|
2633
2673
|
signerId: string;
|
2634
2674
|
totalPosts: number;
|
@@ -2639,6 +2679,7 @@ declare const AccountActivityEntrySchema: z.ZodObject<{
|
|
2639
2679
|
totalScore: number;
|
2640
2680
|
rank: number;
|
2641
2681
|
lastActive: string;
|
2682
|
+
firstPostTimestamp: string;
|
2642
2683
|
}>;
|
2643
2684
|
declare const ActivityLeaderboardResponseSchema: z.ZodObject<{
|
2644
2685
|
timeframe: z.ZodNativeEnum<typeof TimePeriod>;
|
@@ -2652,6 +2693,7 @@ declare const ActivityLeaderboardResponseSchema: z.ZodObject<{
|
|
2652
2693
|
totalScore: z.ZodNumber;
|
2653
2694
|
rank: z.ZodNumber;
|
2654
2695
|
lastActive: z.ZodString;
|
2696
|
+
firstPostTimestamp: z.ZodString;
|
2655
2697
|
}, "strip", z.ZodTypeAny, {
|
2656
2698
|
signerId: string;
|
2657
2699
|
totalPosts: number;
|
@@ -2662,6 +2704,7 @@ declare const ActivityLeaderboardResponseSchema: z.ZodObject<{
|
|
2662
2704
|
totalScore: number;
|
2663
2705
|
rank: number;
|
2664
2706
|
lastActive: string;
|
2707
|
+
firstPostTimestamp: string;
|
2665
2708
|
}, {
|
2666
2709
|
signerId: string;
|
2667
2710
|
totalPosts: number;
|
@@ -2672,9 +2715,10 @@ declare const ActivityLeaderboardResponseSchema: z.ZodObject<{
|
|
2672
2715
|
totalScore: number;
|
2673
2716
|
rank: number;
|
2674
2717
|
lastActive: string;
|
2718
|
+
firstPostTimestamp: string;
|
2675
2719
|
}>, "many">;
|
2676
2720
|
generatedAt: z.ZodString;
|
2677
|
-
|
2721
|
+
platforms: z.ZodOptional<z.ZodArray<z.ZodNativeEnum<typeof Platform>, "many">>;
|
2678
2722
|
}, "strip", z.ZodTypeAny, {
|
2679
2723
|
entries: {
|
2680
2724
|
signerId: string;
|
@@ -2686,10 +2730,11 @@ declare const ActivityLeaderboardResponseSchema: z.ZodObject<{
|
|
2686
2730
|
totalScore: number;
|
2687
2731
|
rank: number;
|
2688
2732
|
lastActive: string;
|
2733
|
+
firstPostTimestamp: string;
|
2689
2734
|
}[];
|
2690
2735
|
timeframe: TimePeriod;
|
2691
2736
|
generatedAt: string;
|
2692
|
-
|
2737
|
+
platforms?: Platform[] | undefined;
|
2693
2738
|
}, {
|
2694
2739
|
entries: {
|
2695
2740
|
signerId: string;
|
@@ -2701,10 +2746,11 @@ declare const ActivityLeaderboardResponseSchema: z.ZodObject<{
|
|
2701
2746
|
totalScore: number;
|
2702
2747
|
rank: number;
|
2703
2748
|
lastActive: string;
|
2749
|
+
firstPostTimestamp: string;
|
2704
2750
|
}[];
|
2705
2751
|
timeframe: TimePeriod;
|
2706
2752
|
generatedAt: string;
|
2707
|
-
|
2753
|
+
platforms?: Platform[] | undefined;
|
2708
2754
|
}>;
|
2709
2755
|
declare const AccountActivityParamsSchema: z.ZodObject<{
|
2710
2756
|
signerId: z.ZodString;
|
@@ -2713,12 +2759,42 @@ declare const AccountActivityParamsSchema: z.ZodObject<{
|
|
2713
2759
|
}, {
|
2714
2760
|
signerId: string;
|
2715
2761
|
}>;
|
2716
|
-
|
2717
|
-
|
2718
|
-
|
2719
|
-
|
2762
|
+
/**
|
2763
|
+
* Query schema for account activity endpoints
|
2764
|
+
*/
|
2765
|
+
declare const AccountActivityQuerySchema: z.ZodObject<z.objectUtil.extendShape<{
|
2766
|
+
filter: z.ZodOptional<z.ZodObject<{
|
2767
|
+
platforms: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodString>, string[] | undefined, string | undefined>, z.ZodOptional<z.ZodArray<z.ZodNativeEnum<typeof Platform>, "many">>>;
|
2768
|
+
types: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodString>, string[] | undefined, string | undefined>, z.ZodOptional<z.ZodArray<z.ZodNativeEnum<typeof ActivityType>, "many">>>;
|
2769
|
+
timeframe: z.ZodEffects<z.ZodOptional<z.ZodNativeEnum<typeof TimePeriod>>, TimePeriod, TimePeriod | undefined>;
|
2770
|
+
}, "strip", z.ZodTypeAny, {
|
2771
|
+
timeframe: TimePeriod;
|
2772
|
+
platforms?: Platform[] | undefined;
|
2773
|
+
types?: ActivityType[] | undefined;
|
2774
|
+
}, {
|
2775
|
+
platforms?: string | undefined;
|
2776
|
+
types?: string | undefined;
|
2777
|
+
timeframe?: TimePeriod | undefined;
|
2778
|
+
}>>;
|
2720
2779
|
}, {
|
2721
|
-
|
2780
|
+
limit: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodString>, number | undefined, string | undefined>, z.ZodOptional<z.ZodNumber>>;
|
2781
|
+
offset: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodString>, number | undefined, string | undefined>, z.ZodOptional<z.ZodNumber>>;
|
2782
|
+
}>, "strip", z.ZodTypeAny, {
|
2783
|
+
filter?: {
|
2784
|
+
timeframe: TimePeriod;
|
2785
|
+
platforms?: Platform[] | undefined;
|
2786
|
+
types?: ActivityType[] | undefined;
|
2787
|
+
} | undefined;
|
2788
|
+
limit?: number | undefined;
|
2789
|
+
offset?: number | undefined;
|
2790
|
+
}, {
|
2791
|
+
filter?: {
|
2792
|
+
platforms?: string | undefined;
|
2793
|
+
types?: string | undefined;
|
2794
|
+
timeframe?: TimePeriod | undefined;
|
2795
|
+
} | undefined;
|
2796
|
+
limit?: string | undefined;
|
2797
|
+
offset?: string | undefined;
|
2722
2798
|
}>;
|
2723
2799
|
declare const PlatformActivitySchema: z.ZodObject<{
|
2724
2800
|
platform: z.ZodNativeEnum<typeof Platform>;
|
@@ -2788,6 +2864,7 @@ declare const AccountActivityResponseSchema: z.ZodObject<{
|
|
2788
2864
|
score: number;
|
2789
2865
|
}>, "many">;
|
2790
2866
|
}, "strip", z.ZodTypeAny, {
|
2867
|
+
signerId: string;
|
2791
2868
|
platforms: {
|
2792
2869
|
platform: Platform;
|
2793
2870
|
quotes: number;
|
@@ -2798,7 +2875,6 @@ declare const AccountActivityResponseSchema: z.ZodObject<{
|
|
2798
2875
|
reposts: number;
|
2799
2876
|
score: number;
|
2800
2877
|
}[];
|
2801
|
-
signerId: string;
|
2802
2878
|
timeframe: TimePeriod;
|
2803
2879
|
totalPosts: number;
|
2804
2880
|
totalLikes: number;
|
@@ -2809,6 +2885,7 @@ declare const AccountActivityResponseSchema: z.ZodObject<{
|
|
2809
2885
|
rank: number;
|
2810
2886
|
lastActive: string;
|
2811
2887
|
}, {
|
2888
|
+
signerId: string;
|
2812
2889
|
platforms: {
|
2813
2890
|
platform: Platform;
|
2814
2891
|
quotes: number;
|
@@ -2819,7 +2896,6 @@ declare const AccountActivityResponseSchema: z.ZodObject<{
|
|
2819
2896
|
reposts: number;
|
2820
2897
|
score: number;
|
2821
2898
|
}[];
|
2822
|
-
signerId: string;
|
2823
2899
|
timeframe: TimePeriod;
|
2824
2900
|
totalPosts: number;
|
2825
2901
|
totalLikes: number;
|
@@ -2837,26 +2913,48 @@ declare const AccountPostsParamsSchema: z.ZodObject<{
|
|
2837
2913
|
}, {
|
2838
2914
|
signerId: string;
|
2839
2915
|
}>;
|
2840
|
-
|
2841
|
-
|
2916
|
+
/**
|
2917
|
+
* Query schema for account posts endpoints
|
2918
|
+
*/
|
2919
|
+
declare const AccountPostsQuerySchema: z.ZodObject<z.objectUtil.extendShape<{
|
2920
|
+
filter: z.ZodOptional<z.ZodObject<{
|
2921
|
+
platforms: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodString>, string[] | undefined, string | undefined>, z.ZodOptional<z.ZodArray<z.ZodNativeEnum<typeof Platform>, "many">>>;
|
2922
|
+
types: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodString>, string[] | undefined, string | undefined>, z.ZodOptional<z.ZodArray<z.ZodNativeEnum<typeof ActivityType>, "many">>>;
|
2923
|
+
timeframe: z.ZodEffects<z.ZodOptional<z.ZodNativeEnum<typeof TimePeriod>>, TimePeriod, TimePeriod | undefined>;
|
2924
|
+
}, "strip", z.ZodTypeAny, {
|
2925
|
+
timeframe: TimePeriod;
|
2926
|
+
platforms?: Platform[] | undefined;
|
2927
|
+
types?: ActivityType[] | undefined;
|
2928
|
+
}, {
|
2929
|
+
platforms?: string | undefined;
|
2930
|
+
types?: string | undefined;
|
2931
|
+
timeframe?: TimePeriod | undefined;
|
2932
|
+
}>>;
|
2933
|
+
}, {
|
2842
2934
|
limit: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodString>, number | undefined, string | undefined>, z.ZodOptional<z.ZodNumber>>;
|
2843
2935
|
offset: z.ZodPipeline<z.ZodEffects<z.ZodOptional<z.ZodString>, number | undefined, string | undefined>, z.ZodOptional<z.ZodNumber>>;
|
2844
|
-
|
2845
|
-
|
2846
|
-
|
2847
|
-
|
2936
|
+
}>, "strip", z.ZodTypeAny, {
|
2937
|
+
filter?: {
|
2938
|
+
timeframe: TimePeriod;
|
2939
|
+
platforms?: Platform[] | undefined;
|
2940
|
+
types?: ActivityType[] | undefined;
|
2941
|
+
} | undefined;
|
2848
2942
|
limit?: number | undefined;
|
2849
2943
|
offset?: number | undefined;
|
2850
2944
|
}, {
|
2851
|
-
|
2852
|
-
|
2945
|
+
filter?: {
|
2946
|
+
platforms?: string | undefined;
|
2947
|
+
types?: string | undefined;
|
2948
|
+
timeframe?: TimePeriod | undefined;
|
2949
|
+
} | undefined;
|
2853
2950
|
limit?: string | undefined;
|
2854
2951
|
offset?: string | undefined;
|
2855
2952
|
}>;
|
2856
2953
|
declare const AccountPostSchema: z.ZodObject<{
|
2857
2954
|
id: z.ZodString;
|
2858
2955
|
platform: z.ZodNativeEnum<typeof Platform>;
|
2859
|
-
|
2956
|
+
userId: z.ZodString;
|
2957
|
+
type: z.ZodNativeEnum<typeof ActivityType>;
|
2860
2958
|
content: z.ZodOptional<z.ZodString>;
|
2861
2959
|
url: z.ZodOptional<z.ZodString>;
|
2862
2960
|
createdAt: z.ZodString;
|
@@ -2879,8 +2977,9 @@ declare const AccountPostSchema: z.ZodObject<{
|
|
2879
2977
|
inReplyToId: z.ZodOptional<z.ZodString>;
|
2880
2978
|
quotedPostId: z.ZodOptional<z.ZodString>;
|
2881
2979
|
}, "strip", z.ZodTypeAny, {
|
2882
|
-
type:
|
2980
|
+
type: ActivityType;
|
2883
2981
|
platform: Platform;
|
2982
|
+
userId: string;
|
2884
2983
|
id: string;
|
2885
2984
|
createdAt: string;
|
2886
2985
|
url?: string | undefined;
|
@@ -2894,8 +2993,9 @@ declare const AccountPostSchema: z.ZodObject<{
|
|
2894
2993
|
quotedPostId?: string | undefined;
|
2895
2994
|
content?: string | undefined;
|
2896
2995
|
}, {
|
2897
|
-
type:
|
2996
|
+
type: ActivityType;
|
2898
2997
|
platform: Platform;
|
2998
|
+
userId: string;
|
2899
2999
|
id: string;
|
2900
3000
|
createdAt: string;
|
2901
3001
|
url?: string | undefined;
|
@@ -2914,7 +3014,8 @@ declare const AccountPostsResponseSchema: z.ZodObject<{
|
|
2914
3014
|
posts: z.ZodArray<z.ZodObject<{
|
2915
3015
|
id: z.ZodString;
|
2916
3016
|
platform: z.ZodNativeEnum<typeof Platform>;
|
2917
|
-
|
3017
|
+
userId: z.ZodString;
|
3018
|
+
type: z.ZodNativeEnum<typeof ActivityType>;
|
2918
3019
|
content: z.ZodOptional<z.ZodString>;
|
2919
3020
|
url: z.ZodOptional<z.ZodString>;
|
2920
3021
|
createdAt: z.ZodString;
|
@@ -2937,8 +3038,9 @@ declare const AccountPostsResponseSchema: z.ZodObject<{
|
|
2937
3038
|
inReplyToId: z.ZodOptional<z.ZodString>;
|
2938
3039
|
quotedPostId: z.ZodOptional<z.ZodString>;
|
2939
3040
|
}, "strip", z.ZodTypeAny, {
|
2940
|
-
type:
|
3041
|
+
type: ActivityType;
|
2941
3042
|
platform: Platform;
|
3043
|
+
userId: string;
|
2942
3044
|
id: string;
|
2943
3045
|
createdAt: string;
|
2944
3046
|
url?: string | undefined;
|
@@ -2952,8 +3054,9 @@ declare const AccountPostsResponseSchema: z.ZodObject<{
|
|
2952
3054
|
quotedPostId?: string | undefined;
|
2953
3055
|
content?: string | undefined;
|
2954
3056
|
}, {
|
2955
|
-
type:
|
3057
|
+
type: ActivityType;
|
2956
3058
|
platform: Platform;
|
3059
|
+
userId: string;
|
2957
3060
|
id: string;
|
2958
3061
|
createdAt: string;
|
2959
3062
|
url?: string | undefined;
|
@@ -2967,12 +3070,14 @@ declare const AccountPostsResponseSchema: z.ZodObject<{
|
|
2967
3070
|
quotedPostId?: string | undefined;
|
2968
3071
|
content?: string | undefined;
|
2969
3072
|
}>, "many">;
|
2970
|
-
|
2971
|
-
|
3073
|
+
platforms: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
3074
|
+
types: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
2972
3075
|
}, "strip", z.ZodTypeAny, {
|
3076
|
+
signerId: string;
|
2973
3077
|
posts: {
|
2974
|
-
type:
|
3078
|
+
type: ActivityType;
|
2975
3079
|
platform: Platform;
|
3080
|
+
userId: string;
|
2976
3081
|
id: string;
|
2977
3082
|
createdAt: string;
|
2978
3083
|
url?: string | undefined;
|
@@ -2986,13 +3091,14 @@ declare const AccountPostsResponseSchema: z.ZodObject<{
|
|
2986
3091
|
quotedPostId?: string | undefined;
|
2987
3092
|
content?: string | undefined;
|
2988
3093
|
}[];
|
2989
|
-
|
2990
|
-
|
2991
|
-
platform?: string | undefined;
|
3094
|
+
platforms?: string[] | undefined;
|
3095
|
+
types?: string[] | undefined;
|
2992
3096
|
}, {
|
3097
|
+
signerId: string;
|
2993
3098
|
posts: {
|
2994
|
-
type:
|
3099
|
+
type: ActivityType;
|
2995
3100
|
platform: Platform;
|
3101
|
+
userId: string;
|
2996
3102
|
id: string;
|
2997
3103
|
createdAt: string;
|
2998
3104
|
url?: string | undefined;
|
@@ -3006,9 +3112,8 @@ declare const AccountPostsResponseSchema: z.ZodObject<{
|
|
3006
3112
|
quotedPostId?: string | undefined;
|
3007
3113
|
content?: string | undefined;
|
3008
3114
|
}[];
|
3009
|
-
|
3010
|
-
|
3011
|
-
platform?: string | undefined;
|
3115
|
+
platforms?: string[] | undefined;
|
3116
|
+
types?: string[] | undefined;
|
3012
3117
|
}>;
|
3013
3118
|
/**
|
3014
3119
|
* Interface for account activity Response
|
@@ -3033,6 +3138,7 @@ interface PostRecord {
|
|
3033
3138
|
p: string;
|
3034
3139
|
t: number;
|
3035
3140
|
u: string;
|
3141
|
+
ty: string;
|
3036
3142
|
}
|
3037
3143
|
type ActivityLeaderboardQuery = z.infer<typeof ActivityLeaderboardQuerySchema>;
|
3038
3144
|
type AccountActivityEntry = z.infer<typeof AccountActivityEntrySchema>;
|
@@ -3045,6 +3151,7 @@ type AccountPostsParams = z.infer<typeof AccountPostsParamsSchema>;
|
|
3045
3151
|
type AccountPostsQuery = z.infer<typeof AccountPostsQuerySchema>;
|
3046
3152
|
type AccountPost = z.infer<typeof AccountPostSchema>;
|
3047
3153
|
type AccountPostsResponse = z.infer<typeof AccountPostsResponseSchema>;
|
3154
|
+
type Filter = z.infer<typeof FilterSchema>;
|
3048
3155
|
|
3049
3156
|
declare const UserProfileSchema: z.ZodObject<{
|
3050
3157
|
userId: z.ZodString;
|
@@ -3121,4 +3228,4 @@ declare const ProfileRefreshResponseSchema: z.ZodObject<{
|
|
3121
3228
|
type UserProfile = z.infer<typeof UserProfileSchema>;
|
3122
3229
|
type ProfileRefreshResponse = z.infer<typeof ProfileRefreshResponseSchema>;
|
3123
3230
|
|
3124
|
-
export { type AccountActivity, type AccountActivityEntry, AccountActivityEntrySchema, type AccountActivityParams, AccountActivityParamsSchema, type AccountActivityQuery, AccountActivityQuerySchema, type AccountActivityResponse, type AccountPost, AccountPostSchema, type AccountPostsParams, AccountPostsParamsSchema, type AccountPostsQuery, AccountPostsQuerySchema, type AccountPostsResponse, type ActivityLeaderboardQuery, ActivityLeaderboardQuerySchema, type ActivityLeaderboardResponse, type AllRateLimitsResponse, AllRateLimitsResponseSchema, ApiErrorCode, ApiErrorCodeSchema, type ApiErrorResponse, type ApiResponse, type AuthCallbackQuery, AuthCallbackQuerySchema, type AuthCallbackResponse, AuthCallbackResponseSchema, type AuthInitRequest, AuthInitRequestSchema, type AuthRevokeResponse, AuthRevokeResponseSchema, type AuthStatus, type AuthStatusParams, AuthStatusParamsSchema, type AuthStatusResponse, AuthStatusResponseSchema, AuthStatusSchema, type AuthTokenRequest, AuthTokenRequestSchema, type AuthUrlResponse, AuthUrlResponseSchema, type ConnectedAccount, ConnectedAccountSchema, type ConnectedAccountsResponse, ConnectedAccountsResponseSchema, type CreatePostRequest, CreatePostRequestSchema, type CreatePostResponse, CreatePostResponseSchema, type DeletePostRequest, DeletePostRequestSchema, type DeletePostResponse, DeletePostResponseSchema, type DeleteResult, DeleteResultSchema, type EndpointRateLimitResponse, EndpointRateLimitResponseSchema, type ErrorDetail, ErrorDetailSchema, type ErrorDetails, type HealthStatus, HealthStatusSchema, type LikePostRequest, LikePostRequestSchema, type LikePostResponse, LikePostResponseSchema, type LikeResult, LikeResultSchema, type Media, type MediaContent, MediaContentSchema, MediaSchema, type MultiStatusData, MultiStatusDataSchema, type MultiStatusSummary, MultiStatusSummarySchema, type NearAuthorizationRequest, NearAuthorizationRequestSchema, type NearAuthorizationResponse, NearAuthorizationResponseSchema, type NearAuthorizationStatusResponse, NearAuthorizationStatusResponseSchema, type NearUnauthorizationResponse, NearUnauthorizationResponseSchema, Platform, type PlatformAccountActivity, type PlatformActivity, PlatformActivitySchema, type PlatformName, type PlatformParam, PlatformParamSchema, type PlatformRateLimit, PlatformRateLimitSchema, PlatformSchema, type Post, type PostContent, PostContentSchema, type PostMetrics, PostMetricsSchema, type PostRecord, PostResponseSchema, type PostResult, PostResultSchema, PostSchema, type PostToDelete, PostToDeleteSchema, type ProfileRefreshResponse, ProfileRefreshResponseSchema, type QuotePostRequest, QuotePostRequestSchema, type QuotePostResponse, QuotePostResponseSchema, type RateLimitEndpoint, type RateLimitEndpointParam, RateLimitEndpointParamSchema, RateLimitEndpointSchema, type RateLimitResponse, RateLimitResponseSchema, type RateLimitStatus, type RateLimitStatusResponse, RateLimitStatusResponseSchema, RateLimitStatusSchema, type ReplyToPostRequest, ReplyToPostRequestSchema, type ReplyToPostResponse, ReplyToPostResponseSchema, type RepostRequest, RepostRequestSchema, type RepostResponse, RepostResponseSchema, type ResponseMeta, ResponseMetaSchema, SUPPORTED_PLATFORMS, type SuccessDetail, SuccessDetailSchema, type SupportedPlatformName, SupportedPlatformSchema, type Target, TargetSchema, TimePeriod, type UnlikePostRequest, UnlikePostRequestSchema, type UnlikePostResponse, UnlikePostResponseSchema, type UsageRateLimit, UsageRateLimitSchema, type UserProfile, UserProfileSchema, errorCodeToStatusCode, isPlatformSupported };
|
3231
|
+
export { type AccountActivity, type AccountActivityEntry, AccountActivityEntrySchema, type AccountActivityParams, AccountActivityParamsSchema, type AccountActivityQuery, AccountActivityQuerySchema, type AccountActivityResponse, type AccountPost, AccountPostSchema, type AccountPostsParams, AccountPostsParamsSchema, type AccountPostsQuery, AccountPostsQuerySchema, type AccountPostsResponse, type ActivityLeaderboardQuery, ActivityLeaderboardQuerySchema, type ActivityLeaderboardResponse, ActivityType, type AllRateLimitsResponse, AllRateLimitsResponseSchema, ApiErrorCode, ApiErrorCodeSchema, type ApiErrorResponse, type ApiResponse, type AuthCallbackQuery, AuthCallbackQuerySchema, type AuthCallbackResponse, AuthCallbackResponseSchema, type AuthInitRequest, AuthInitRequestSchema, type AuthRevokeResponse, AuthRevokeResponseSchema, type AuthStatus, type AuthStatusParams, AuthStatusParamsSchema, type AuthStatusResponse, AuthStatusResponseSchema, AuthStatusSchema, type AuthTokenRequest, AuthTokenRequestSchema, type AuthUrlResponse, AuthUrlResponseSchema, type ConnectedAccount, ConnectedAccountSchema, type ConnectedAccountsResponse, ConnectedAccountsResponseSchema, type CreatePostRequest, CreatePostRequestSchema, type CreatePostResponse, CreatePostResponseSchema, type DeletePostRequest, DeletePostRequestSchema, type DeletePostResponse, DeletePostResponseSchema, type DeleteResult, DeleteResultSchema, type EndpointRateLimitResponse, EndpointRateLimitResponseSchema, type ErrorDetail, ErrorDetailSchema, type ErrorDetails, type Filter, FilterSchema, type HealthStatus, HealthStatusSchema, type LikePostRequest, LikePostRequestSchema, type LikePostResponse, LikePostResponseSchema, type LikeResult, LikeResultSchema, type Media, type MediaContent, MediaContentSchema, MediaSchema, type MultiStatusData, MultiStatusDataSchema, type MultiStatusSummary, MultiStatusSummarySchema, type NearAuthorizationRequest, NearAuthorizationRequestSchema, type NearAuthorizationResponse, NearAuthorizationResponseSchema, type NearAuthorizationStatusResponse, NearAuthorizationStatusResponseSchema, type NearUnauthorizationResponse, NearUnauthorizationResponseSchema, PaginationSchema, Platform, type PlatformAccountActivity, type PlatformActivity, PlatformActivitySchema, type PlatformName, type PlatformParam, PlatformParamSchema, type PlatformRateLimit, PlatformRateLimitSchema, PlatformSchema, type Post, type PostContent, PostContentSchema, type PostMetrics, PostMetricsSchema, type PostRecord, PostResponseSchema, type PostResult, PostResultSchema, PostSchema, type PostToDelete, PostToDeleteSchema, type ProfileRefreshResponse, ProfileRefreshResponseSchema, type QuotePostRequest, QuotePostRequestSchema, type QuotePostResponse, QuotePostResponseSchema, type RateLimitEndpoint, type RateLimitEndpointParam, RateLimitEndpointParamSchema, RateLimitEndpointSchema, type RateLimitResponse, RateLimitResponseSchema, type RateLimitStatus, type RateLimitStatusResponse, RateLimitStatusResponseSchema, RateLimitStatusSchema, type ReplyToPostRequest, ReplyToPostRequestSchema, type ReplyToPostResponse, ReplyToPostResponseSchema, type RepostRequest, RepostRequestSchema, type RepostResponse, RepostResponseSchema, type ResponseMeta, ResponseMetaSchema, SUPPORTED_PLATFORMS, type SuccessDetail, SuccessDetailSchema, type SupportedPlatformName, SupportedPlatformSchema, type Target, TargetSchema, TimePeriod, type UnlikePostRequest, UnlikePostRequestSchema, type UnlikePostResponse, UnlikePostResponseSchema, type UsageRateLimit, UsageRateLimitSchema, type UserProfile, UserProfileSchema, errorCodeToStatusCode, isPlatformSupported };
|