@getlatedev/node 0.1.3 → 0.1.5
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 +4 -1
- package/dist/index.d.mts +950 -17
- package/dist/index.d.ts +950 -17
- package/dist/index.js +138 -0
- package/dist/index.mjs +138 -0
- package/package.json +1 -1
- package/src/client.ts +44 -0
- package/src/generated/sdk.gen.ts +260 -5
- package/src/generated/types.gen.ts +987 -16
|
@@ -1276,7 +1276,7 @@ export type Webhook = {
|
|
|
1276
1276
|
/**
|
|
1277
1277
|
* Events subscribed to
|
|
1278
1278
|
*/
|
|
1279
|
-
events?: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'account.connected' | 'account.disconnected')>;
|
|
1279
|
+
events?: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'account.connected' | 'account.disconnected' | 'message.received')>;
|
|
1280
1280
|
/**
|
|
1281
1281
|
* Whether webhook delivery is enabled
|
|
1282
1282
|
*/
|
|
@@ -1310,7 +1310,7 @@ export type WebhookLog = {
|
|
|
1310
1310
|
* Name of the webhook that was triggered
|
|
1311
1311
|
*/
|
|
1312
1312
|
webhookName?: string;
|
|
1313
|
-
event?: 'post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'account.connected' | 'account.disconnected' | 'webhook.test';
|
|
1313
|
+
event?: 'post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'account.connected' | 'account.disconnected' | 'message.received' | 'webhook.test';
|
|
1314
1314
|
url?: string;
|
|
1315
1315
|
status?: 'success' | 'failed';
|
|
1316
1316
|
/**
|
|
@@ -1342,7 +1342,7 @@ export type WebhookLog = {
|
|
|
1342
1342
|
createdAt?: string;
|
|
1343
1343
|
};
|
|
1344
1344
|
|
|
1345
|
-
export type event = 'post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'account.connected' | 'account.disconnected' | 'webhook.test';
|
|
1345
|
+
export type event = 'post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'account.connected' | 'account.disconnected' | 'message.received' | 'webhook.test';
|
|
1346
1346
|
|
|
1347
1347
|
export type status5 = 'success' | 'failed';
|
|
1348
1348
|
|
|
@@ -1405,6 +1405,84 @@ export type event3 = 'account.disconnected';
|
|
|
1405
1405
|
*/
|
|
1406
1406
|
export type disconnectionType = 'intentional' | 'unintentional';
|
|
1407
1407
|
|
|
1408
|
+
/**
|
|
1409
|
+
* Webhook payload for message received events (DMs from Instagram, Facebook, Telegram)
|
|
1410
|
+
*/
|
|
1411
|
+
export type WebhookPayloadMessage = {
|
|
1412
|
+
event?: 'message.received';
|
|
1413
|
+
message?: {
|
|
1414
|
+
/**
|
|
1415
|
+
* Internal message ID
|
|
1416
|
+
*/
|
|
1417
|
+
id?: string;
|
|
1418
|
+
/**
|
|
1419
|
+
* Internal conversation ID
|
|
1420
|
+
*/
|
|
1421
|
+
conversationId?: string;
|
|
1422
|
+
platform?: 'instagram' | 'facebook' | 'telegram';
|
|
1423
|
+
/**
|
|
1424
|
+
* Platform's message ID
|
|
1425
|
+
*/
|
|
1426
|
+
platformMessageId?: string;
|
|
1427
|
+
direction?: 'incoming';
|
|
1428
|
+
/**
|
|
1429
|
+
* Message text content
|
|
1430
|
+
*/
|
|
1431
|
+
text?: (string) | null;
|
|
1432
|
+
attachments?: Array<{
|
|
1433
|
+
/**
|
|
1434
|
+
* Attachment type (image, video, file, sticker, audio)
|
|
1435
|
+
*/
|
|
1436
|
+
type?: string;
|
|
1437
|
+
/**
|
|
1438
|
+
* Attachment URL (may expire for Meta platforms)
|
|
1439
|
+
*/
|
|
1440
|
+
url?: string;
|
|
1441
|
+
/**
|
|
1442
|
+
* Additional attachment metadata
|
|
1443
|
+
*/
|
|
1444
|
+
payload?: {
|
|
1445
|
+
[key: string]: unknown;
|
|
1446
|
+
};
|
|
1447
|
+
}>;
|
|
1448
|
+
sender?: {
|
|
1449
|
+
id?: string;
|
|
1450
|
+
name?: string;
|
|
1451
|
+
username?: string;
|
|
1452
|
+
picture?: string;
|
|
1453
|
+
};
|
|
1454
|
+
sentAt?: string;
|
|
1455
|
+
isRead?: boolean;
|
|
1456
|
+
};
|
|
1457
|
+
conversation?: {
|
|
1458
|
+
id?: string;
|
|
1459
|
+
platformConversationId?: string;
|
|
1460
|
+
participantId?: string;
|
|
1461
|
+
participantName?: string;
|
|
1462
|
+
participantUsername?: string;
|
|
1463
|
+
participantPicture?: string;
|
|
1464
|
+
status?: 'active' | 'archived';
|
|
1465
|
+
};
|
|
1466
|
+
account?: {
|
|
1467
|
+
/**
|
|
1468
|
+
* Social account ID
|
|
1469
|
+
*/
|
|
1470
|
+
id?: string;
|
|
1471
|
+
platform?: string;
|
|
1472
|
+
username?: string;
|
|
1473
|
+
displayName?: string;
|
|
1474
|
+
};
|
|
1475
|
+
timestamp?: string;
|
|
1476
|
+
};
|
|
1477
|
+
|
|
1478
|
+
export type event4 = 'message.received';
|
|
1479
|
+
|
|
1480
|
+
export type platform2 = 'instagram' | 'facebook' | 'telegram';
|
|
1481
|
+
|
|
1482
|
+
export type direction = 'incoming';
|
|
1483
|
+
|
|
1484
|
+
export type status6 = 'active' | 'archived';
|
|
1485
|
+
|
|
1408
1486
|
/**
|
|
1409
1487
|
* Webhook payload for post events
|
|
1410
1488
|
*/
|
|
@@ -1426,7 +1504,7 @@ export type WebhookPayloadPost = {
|
|
|
1426
1504
|
timestamp?: string;
|
|
1427
1505
|
};
|
|
1428
1506
|
|
|
1429
|
-
export type
|
|
1507
|
+
export type event5 = 'post.scheduled' | 'post.published' | 'post.failed' | 'post.partial';
|
|
1430
1508
|
|
|
1431
1509
|
export type YouTubeDailyViewsResponse = {
|
|
1432
1510
|
success?: boolean;
|
|
@@ -1473,6 +1551,7 @@ export type YouTubeDailyViewsResponse = {
|
|
|
1473
1551
|
* - Custom thumbnails NOT supported for Shorts via API
|
|
1474
1552
|
* - Scheduled videos are uploaded immediately as the specified visibility and published at scheduled time
|
|
1475
1553
|
* - Visibility defaults to "public" if not specified
|
|
1554
|
+
* - madeForKids defaults to false (not child-directed)
|
|
1476
1555
|
* - Set containsSyntheticMedia: true if your video contains AI-generated content
|
|
1477
1556
|
*
|
|
1478
1557
|
*/
|
|
@@ -1489,6 +1568,19 @@ export type YouTubePlatformData = {
|
|
|
1489
1568
|
*
|
|
1490
1569
|
*/
|
|
1491
1570
|
visibility?: 'public' | 'private' | 'unlisted';
|
|
1571
|
+
/**
|
|
1572
|
+
* COPPA compliance: Audience designation for the video.
|
|
1573
|
+
* - true: Video is made for kids (child-directed content)
|
|
1574
|
+
* - false: Video is NOT made for kids (default)
|
|
1575
|
+
*
|
|
1576
|
+
* This field maps to YouTube's `selfDeclaredMadeForKids` setting. Videos marked as made for kids
|
|
1577
|
+
* have restricted features (no comments, no notifications, limited ad targeting).
|
|
1578
|
+
*
|
|
1579
|
+
* IMPORTANT: If not specified, defaults to false. YouTube requires this to be explicitly set,
|
|
1580
|
+
* otherwise the video may be blocked from views until configured in YouTube Studio.
|
|
1581
|
+
*
|
|
1582
|
+
*/
|
|
1583
|
+
madeForKids?: boolean;
|
|
1492
1584
|
/**
|
|
1493
1585
|
* Optional first comment to post immediately after video upload. Up to 10,000 characters (YouTube's comment limit).
|
|
1494
1586
|
*/
|
|
@@ -2049,9 +2141,13 @@ export type CreatePostData = {
|
|
|
2049
2141
|
[key: string]: unknown;
|
|
2050
2142
|
};
|
|
2051
2143
|
/**
|
|
2052
|
-
* Profile ID to schedule via queue.
|
|
2053
|
-
*
|
|
2054
|
-
*
|
|
2144
|
+
* Profile ID to schedule via queue.
|
|
2145
|
+
*
|
|
2146
|
+
* When provided (without `scheduledFor`), the post will be automatically assigned
|
|
2147
|
+
* to the next available slot from the profile's queue. The system uses distributed
|
|
2148
|
+
* locking to prevent race conditions when multiple posts are scheduled concurrently.
|
|
2149
|
+
* Do not call `/v1/queue/next-slot` and then use that time in `scheduledFor`.
|
|
2150
|
+
* That bypasses the queue system and can cause duplicate slot assignments.
|
|
2055
2151
|
*
|
|
2056
2152
|
*/
|
|
2057
2153
|
queuedFromProfile?: string;
|
|
@@ -2069,6 +2165,21 @@ export type CreatePostResponse = (PostCreateResponse);
|
|
|
2069
2165
|
|
|
2070
2166
|
export type CreatePostError = ({
|
|
2071
2167
|
error?: string;
|
|
2168
|
+
} | {
|
|
2169
|
+
error?: string;
|
|
2170
|
+
details?: {
|
|
2171
|
+
accountId?: string;
|
|
2172
|
+
platform?: string;
|
|
2173
|
+
existingPostId?: string;
|
|
2174
|
+
};
|
|
2175
|
+
} | {
|
|
2176
|
+
error?: string;
|
|
2177
|
+
/**
|
|
2178
|
+
* Additional context about the rate limit
|
|
2179
|
+
*/
|
|
2180
|
+
details?: {
|
|
2181
|
+
[key: string]: unknown;
|
|
2182
|
+
};
|
|
2072
2183
|
});
|
|
2073
2184
|
|
|
2074
2185
|
export type GetPostData = {
|
|
@@ -2133,6 +2244,11 @@ export type BulkUploadPostsResponse = ({
|
|
|
2133
2244
|
|
|
2134
2245
|
export type BulkUploadPostsError = (unknown | {
|
|
2135
2246
|
error?: string;
|
|
2247
|
+
} | {
|
|
2248
|
+
error?: string;
|
|
2249
|
+
details?: {
|
|
2250
|
+
[key: string]: unknown;
|
|
2251
|
+
};
|
|
2136
2252
|
});
|
|
2137
2253
|
|
|
2138
2254
|
export type RetryPostData = {
|
|
@@ -2145,6 +2261,11 @@ export type RetryPostResponse = (PostRetryResponse | unknown);
|
|
|
2145
2261
|
|
|
2146
2262
|
export type RetryPostError = (unknown | {
|
|
2147
2263
|
error?: string;
|
|
2264
|
+
} | {
|
|
2265
|
+
error?: string;
|
|
2266
|
+
details?: {
|
|
2267
|
+
[key: string]: unknown;
|
|
2268
|
+
};
|
|
2148
2269
|
});
|
|
2149
2270
|
|
|
2150
2271
|
export type ListUsersResponse = ({
|
|
@@ -2732,6 +2853,10 @@ export type SelectFacebookPageResponse = ({
|
|
|
2732
2853
|
*/
|
|
2733
2854
|
redirect_url?: string;
|
|
2734
2855
|
account?: {
|
|
2856
|
+
/**
|
|
2857
|
+
* ID of the created SocialAccount
|
|
2858
|
+
*/
|
|
2859
|
+
accountId?: string;
|
|
2735
2860
|
platform?: 'facebook';
|
|
2736
2861
|
username?: string;
|
|
2737
2862
|
displayName?: string;
|
|
@@ -2840,6 +2965,10 @@ export type SelectGoogleBusinessLocationResponse = ({
|
|
|
2840
2965
|
*/
|
|
2841
2966
|
redirect_url?: string;
|
|
2842
2967
|
account?: {
|
|
2968
|
+
/**
|
|
2969
|
+
* ID of the created SocialAccount
|
|
2970
|
+
*/
|
|
2971
|
+
accountId?: string;
|
|
2843
2972
|
platform?: 'googlebusiness';
|
|
2844
2973
|
username?: string;
|
|
2845
2974
|
displayName?: string;
|
|
@@ -3046,7 +3175,26 @@ export type SelectLinkedInOrganizationData = {
|
|
|
3046
3175
|
|
|
3047
3176
|
export type SelectLinkedInOrganizationResponse = ({
|
|
3048
3177
|
message?: string;
|
|
3049
|
-
|
|
3178
|
+
/**
|
|
3179
|
+
* The redirect URL with connection params appended (only if redirect_url was provided in request)
|
|
3180
|
+
*/
|
|
3181
|
+
redirect_url?: string;
|
|
3182
|
+
account?: {
|
|
3183
|
+
/**
|
|
3184
|
+
* ID of the created SocialAccount
|
|
3185
|
+
*/
|
|
3186
|
+
accountId?: string;
|
|
3187
|
+
platform?: 'linkedin';
|
|
3188
|
+
username?: string;
|
|
3189
|
+
displayName?: string;
|
|
3190
|
+
profilePicture?: string;
|
|
3191
|
+
isActive?: boolean;
|
|
3192
|
+
accountType?: 'personal' | 'organization';
|
|
3193
|
+
};
|
|
3194
|
+
bulkRefresh?: {
|
|
3195
|
+
updatedCount?: number;
|
|
3196
|
+
errors?: number;
|
|
3197
|
+
};
|
|
3050
3198
|
});
|
|
3051
3199
|
|
|
3052
3200
|
export type SelectLinkedInOrganizationError = (unknown | {
|
|
@@ -3143,6 +3291,10 @@ export type SelectPinterestBoardResponse = ({
|
|
|
3143
3291
|
*/
|
|
3144
3292
|
redirect_url?: string;
|
|
3145
3293
|
account?: {
|
|
3294
|
+
/**
|
|
3295
|
+
* ID of the created SocialAccount
|
|
3296
|
+
*/
|
|
3297
|
+
accountId?: string;
|
|
3146
3298
|
platform?: 'pinterest';
|
|
3147
3299
|
username?: string;
|
|
3148
3300
|
displayName?: string;
|
|
@@ -3273,6 +3425,10 @@ export type SelectSnapchatProfileResponse = ({
|
|
|
3273
3425
|
*/
|
|
3274
3426
|
redirect_url?: string;
|
|
3275
3427
|
account?: {
|
|
3428
|
+
/**
|
|
3429
|
+
* ID of the created SocialAccount
|
|
3430
|
+
*/
|
|
3431
|
+
accountId?: string;
|
|
3276
3432
|
platform?: 'snapchat';
|
|
3277
3433
|
username?: string;
|
|
3278
3434
|
displayName?: string;
|
|
@@ -3423,6 +3579,28 @@ export type CompleteTelegramConnectError = ({
|
|
|
3423
3579
|
error?: string;
|
|
3424
3580
|
} | unknown);
|
|
3425
3581
|
|
|
3582
|
+
export type GetFacebookPagesData = {
|
|
3583
|
+
path: {
|
|
3584
|
+
accountId: string;
|
|
3585
|
+
};
|
|
3586
|
+
};
|
|
3587
|
+
|
|
3588
|
+
export type GetFacebookPagesResponse = ({
|
|
3589
|
+
pages?: Array<{
|
|
3590
|
+
id?: string;
|
|
3591
|
+
name?: string;
|
|
3592
|
+
username?: string;
|
|
3593
|
+
category?: string;
|
|
3594
|
+
fan_count?: number;
|
|
3595
|
+
}>;
|
|
3596
|
+
selectedPageId?: string;
|
|
3597
|
+
cached?: boolean;
|
|
3598
|
+
});
|
|
3599
|
+
|
|
3600
|
+
export type GetFacebookPagesError = ({
|
|
3601
|
+
error?: string;
|
|
3602
|
+
} | unknown);
|
|
3603
|
+
|
|
3426
3604
|
export type UpdateFacebookPageData = {
|
|
3427
3605
|
body: {
|
|
3428
3606
|
selectedPageId: string;
|
|
@@ -3705,6 +3883,51 @@ export type UpdatePinterestBoardsError = (unknown | {
|
|
|
3705
3883
|
error?: string;
|
|
3706
3884
|
});
|
|
3707
3885
|
|
|
3886
|
+
export type GetGmbLocationsData = {
|
|
3887
|
+
path: {
|
|
3888
|
+
accountId: string;
|
|
3889
|
+
};
|
|
3890
|
+
};
|
|
3891
|
+
|
|
3892
|
+
export type GetGmbLocationsResponse = ({
|
|
3893
|
+
locations?: Array<{
|
|
3894
|
+
id?: string;
|
|
3895
|
+
name?: string;
|
|
3896
|
+
accountId?: string;
|
|
3897
|
+
accountName?: string;
|
|
3898
|
+
address?: string;
|
|
3899
|
+
category?: string;
|
|
3900
|
+
websiteUrl?: string;
|
|
3901
|
+
}>;
|
|
3902
|
+
selectedLocationId?: string;
|
|
3903
|
+
cached?: boolean;
|
|
3904
|
+
});
|
|
3905
|
+
|
|
3906
|
+
export type GetGmbLocationsError = ({
|
|
3907
|
+
error?: string;
|
|
3908
|
+
} | unknown);
|
|
3909
|
+
|
|
3910
|
+
export type UpdateGmbLocationData = {
|
|
3911
|
+
body: {
|
|
3912
|
+
selectedLocationId: string;
|
|
3913
|
+
};
|
|
3914
|
+
path: {
|
|
3915
|
+
accountId: string;
|
|
3916
|
+
};
|
|
3917
|
+
};
|
|
3918
|
+
|
|
3919
|
+
export type UpdateGmbLocationResponse = ({
|
|
3920
|
+
message?: string;
|
|
3921
|
+
selectedLocation?: {
|
|
3922
|
+
id?: string;
|
|
3923
|
+
name?: string;
|
|
3924
|
+
};
|
|
3925
|
+
});
|
|
3926
|
+
|
|
3927
|
+
export type UpdateGmbLocationError = (unknown | {
|
|
3928
|
+
error?: string;
|
|
3929
|
+
});
|
|
3930
|
+
|
|
3708
3931
|
export type GetRedditSubredditsData = {
|
|
3709
3932
|
path: {
|
|
3710
3933
|
accountId: string;
|
|
@@ -3713,11 +3936,31 @@ export type GetRedditSubredditsData = {
|
|
|
3713
3936
|
|
|
3714
3937
|
export type GetRedditSubredditsResponse = ({
|
|
3715
3938
|
subreddits?: Array<{
|
|
3939
|
+
/**
|
|
3940
|
+
* Reddit subreddit ID
|
|
3941
|
+
*/
|
|
3942
|
+
id?: string;
|
|
3943
|
+
/**
|
|
3944
|
+
* Subreddit name without r/ prefix
|
|
3945
|
+
*/
|
|
3716
3946
|
name?: string;
|
|
3717
|
-
|
|
3718
|
-
|
|
3719
|
-
|
|
3947
|
+
/**
|
|
3948
|
+
* Subreddit title
|
|
3949
|
+
*/
|
|
3950
|
+
title?: string;
|
|
3951
|
+
/**
|
|
3952
|
+
* Subreddit URL path
|
|
3953
|
+
*/
|
|
3954
|
+
url?: string;
|
|
3955
|
+
/**
|
|
3956
|
+
* Whether the subreddit is NSFW
|
|
3957
|
+
*/
|
|
3958
|
+
over18?: boolean;
|
|
3720
3959
|
}>;
|
|
3960
|
+
/**
|
|
3961
|
+
* Currently set default subreddit for posting
|
|
3962
|
+
*/
|
|
3963
|
+
defaultSubreddit?: string;
|
|
3721
3964
|
});
|
|
3722
3965
|
|
|
3723
3966
|
export type GetRedditSubredditsError = (unknown | {
|
|
@@ -3734,8 +3977,7 @@ export type UpdateRedditSubredditsData = {
|
|
|
3734
3977
|
};
|
|
3735
3978
|
|
|
3736
3979
|
export type UpdateRedditSubredditsResponse = ({
|
|
3737
|
-
|
|
3738
|
-
account?: SocialAccount;
|
|
3980
|
+
success?: boolean;
|
|
3739
3981
|
});
|
|
3740
3982
|
|
|
3741
3983
|
export type UpdateRedditSubredditsError = (unknown | {
|
|
@@ -3926,7 +4168,7 @@ export type CreateWebhookSettingsData = {
|
|
|
3926
4168
|
/**
|
|
3927
4169
|
* Events to subscribe to
|
|
3928
4170
|
*/
|
|
3929
|
-
events?: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'account.connected' | 'account.disconnected')>;
|
|
4171
|
+
events?: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'account.connected' | 'account.disconnected' | 'message.received')>;
|
|
3930
4172
|
/**
|
|
3931
4173
|
* Enable or disable webhook delivery
|
|
3932
4174
|
*/
|
|
@@ -3970,7 +4212,7 @@ export type UpdateWebhookSettingsData = {
|
|
|
3970
4212
|
/**
|
|
3971
4213
|
* Events to subscribe to
|
|
3972
4214
|
*/
|
|
3973
|
-
events?: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'account.connected' | 'account.disconnected')>;
|
|
4215
|
+
events?: Array<('post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'account.connected' | 'account.disconnected' | 'message.received')>;
|
|
3974
4216
|
/**
|
|
3975
4217
|
* Enable or disable webhook delivery
|
|
3976
4218
|
*/
|
|
@@ -4036,7 +4278,7 @@ export type GetWebhookLogsData = {
|
|
|
4036
4278
|
/**
|
|
4037
4279
|
* Filter by event type
|
|
4038
4280
|
*/
|
|
4039
|
-
event?: 'post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'account.connected' | 'account.disconnected' | 'webhook.test';
|
|
4281
|
+
event?: 'post.scheduled' | 'post.published' | 'post.failed' | 'post.partial' | 'account.connected' | 'account.disconnected' | 'message.received' | 'webhook.test';
|
|
4040
4282
|
/**
|
|
4041
4283
|
* Maximum number of logs to return (max 100)
|
|
4042
4284
|
*/
|
|
@@ -4153,4 +4395,733 @@ export type GetPostLogsResponse = ({
|
|
|
4153
4395
|
|
|
4154
4396
|
export type GetPostLogsError = ({
|
|
4155
4397
|
error?: string;
|
|
4398
|
+
} | unknown);
|
|
4399
|
+
|
|
4400
|
+
export type ListInboxConversationsData = {
|
|
4401
|
+
query?: {
|
|
4402
|
+
/**
|
|
4403
|
+
* Filter by specific social account ID
|
|
4404
|
+
*/
|
|
4405
|
+
accountId?: string;
|
|
4406
|
+
/**
|
|
4407
|
+
* Pagination cursor for next page
|
|
4408
|
+
*/
|
|
4409
|
+
cursor?: string;
|
|
4410
|
+
/**
|
|
4411
|
+
* Maximum number of conversations to return
|
|
4412
|
+
*/
|
|
4413
|
+
limit?: number;
|
|
4414
|
+
/**
|
|
4415
|
+
* Filter by platform
|
|
4416
|
+
*/
|
|
4417
|
+
platform?: 'facebook' | 'instagram' | 'bluesky' | 'reddit' | 'telegram';
|
|
4418
|
+
/**
|
|
4419
|
+
* Filter by profile ID
|
|
4420
|
+
*/
|
|
4421
|
+
profileId?: string;
|
|
4422
|
+
/**
|
|
4423
|
+
* Sort order by updated time
|
|
4424
|
+
*/
|
|
4425
|
+
sortOrder?: 'asc' | 'desc';
|
|
4426
|
+
/**
|
|
4427
|
+
* Filter by conversation status
|
|
4428
|
+
*/
|
|
4429
|
+
status?: 'active' | 'archived';
|
|
4430
|
+
};
|
|
4431
|
+
};
|
|
4432
|
+
|
|
4433
|
+
export type ListInboxConversationsResponse = ({
|
|
4434
|
+
data?: Array<{
|
|
4435
|
+
id?: string;
|
|
4436
|
+
platform?: string;
|
|
4437
|
+
accountId?: string;
|
|
4438
|
+
accountUsername?: string;
|
|
4439
|
+
participantId?: string;
|
|
4440
|
+
participantName?: string;
|
|
4441
|
+
participantPicture?: (string) | null;
|
|
4442
|
+
lastMessage?: string;
|
|
4443
|
+
updatedTime?: string;
|
|
4444
|
+
status?: 'active' | 'archived';
|
|
4445
|
+
/**
|
|
4446
|
+
* Number of unread messages
|
|
4447
|
+
*/
|
|
4448
|
+
unreadCount?: (number) | null;
|
|
4449
|
+
/**
|
|
4450
|
+
* Direct link to open the conversation on the platform (if available)
|
|
4451
|
+
*/
|
|
4452
|
+
url?: (string) | null;
|
|
4453
|
+
}>;
|
|
4454
|
+
pagination?: {
|
|
4455
|
+
hasMore?: boolean;
|
|
4456
|
+
nextCursor?: (string) | null;
|
|
4457
|
+
};
|
|
4458
|
+
meta?: {
|
|
4459
|
+
accountsQueried?: number;
|
|
4460
|
+
accountsFailed?: number;
|
|
4461
|
+
failedAccounts?: Array<{
|
|
4462
|
+
accountId?: string;
|
|
4463
|
+
accountUsername?: (string) | null;
|
|
4464
|
+
platform?: string;
|
|
4465
|
+
error?: string;
|
|
4466
|
+
/**
|
|
4467
|
+
* Error code if available
|
|
4468
|
+
*/
|
|
4469
|
+
code?: (string) | null;
|
|
4470
|
+
/**
|
|
4471
|
+
* Seconds to wait before retry (rate limits)
|
|
4472
|
+
*/
|
|
4473
|
+
retryAfter?: (number) | null;
|
|
4474
|
+
}>;
|
|
4475
|
+
lastUpdated?: string;
|
|
4476
|
+
};
|
|
4477
|
+
});
|
|
4478
|
+
|
|
4479
|
+
export type ListInboxConversationsError = ({
|
|
4480
|
+
error?: string;
|
|
4481
|
+
} | unknown);
|
|
4482
|
+
|
|
4483
|
+
export type GetInboxConversationData = {
|
|
4484
|
+
path: {
|
|
4485
|
+
conversationId: string;
|
|
4486
|
+
};
|
|
4487
|
+
query: {
|
|
4488
|
+
/**
|
|
4489
|
+
* The social account ID
|
|
4490
|
+
*/
|
|
4491
|
+
accountId: string;
|
|
4492
|
+
};
|
|
4493
|
+
};
|
|
4494
|
+
|
|
4495
|
+
export type GetInboxConversationResponse = ({
|
|
4496
|
+
data?: {
|
|
4497
|
+
id?: string;
|
|
4498
|
+
accountId?: string;
|
|
4499
|
+
accountUsername?: string;
|
|
4500
|
+
platform?: string;
|
|
4501
|
+
status?: 'active' | 'archived';
|
|
4502
|
+
participantName?: string;
|
|
4503
|
+
participantId?: string;
|
|
4504
|
+
lastMessage?: string;
|
|
4505
|
+
lastMessageAt?: string;
|
|
4506
|
+
updatedTime?: string;
|
|
4507
|
+
participants?: Array<{
|
|
4508
|
+
id?: string;
|
|
4509
|
+
name?: string;
|
|
4510
|
+
}>;
|
|
4511
|
+
};
|
|
4512
|
+
});
|
|
4513
|
+
|
|
4514
|
+
export type GetInboxConversationError = ({
|
|
4515
|
+
error?: string;
|
|
4516
|
+
} | unknown);
|
|
4517
|
+
|
|
4518
|
+
export type UpdateInboxConversationData = {
|
|
4519
|
+
body: {
|
|
4520
|
+
/**
|
|
4521
|
+
* Social account ID
|
|
4522
|
+
*/
|
|
4523
|
+
accountId: string;
|
|
4524
|
+
status: 'active' | 'archived';
|
|
4525
|
+
};
|
|
4526
|
+
path: {
|
|
4527
|
+
conversationId: string;
|
|
4528
|
+
};
|
|
4529
|
+
};
|
|
4530
|
+
|
|
4531
|
+
export type UpdateInboxConversationResponse = ({
|
|
4532
|
+
success?: boolean;
|
|
4533
|
+
data?: {
|
|
4534
|
+
id?: string;
|
|
4535
|
+
accountId?: string;
|
|
4536
|
+
status?: 'active' | 'archived';
|
|
4537
|
+
platform?: string;
|
|
4538
|
+
updatedAt?: string;
|
|
4539
|
+
};
|
|
4540
|
+
});
|
|
4541
|
+
|
|
4542
|
+
export type UpdateInboxConversationError = ({
|
|
4543
|
+
error?: string;
|
|
4544
|
+
} | unknown);
|
|
4545
|
+
|
|
4546
|
+
export type GetInboxConversationMessagesData = {
|
|
4547
|
+
path: {
|
|
4548
|
+
conversationId: string;
|
|
4549
|
+
};
|
|
4550
|
+
query: {
|
|
4551
|
+
/**
|
|
4552
|
+
* Social account ID
|
|
4553
|
+
*/
|
|
4554
|
+
accountId: string;
|
|
4555
|
+
};
|
|
4556
|
+
};
|
|
4557
|
+
|
|
4558
|
+
export type GetInboxConversationMessagesResponse = ({
|
|
4559
|
+
status?: string;
|
|
4560
|
+
messages?: Array<{
|
|
4561
|
+
id?: string;
|
|
4562
|
+
conversationId?: string;
|
|
4563
|
+
accountId?: string;
|
|
4564
|
+
platform?: string;
|
|
4565
|
+
message?: string;
|
|
4566
|
+
senderId?: string;
|
|
4567
|
+
senderName?: (string) | null;
|
|
4568
|
+
direction?: 'incoming' | 'outgoing';
|
|
4569
|
+
createdAt?: string;
|
|
4570
|
+
attachments?: Array<{
|
|
4571
|
+
id?: string;
|
|
4572
|
+
type?: 'image' | 'video' | 'audio' | 'file' | 'sticker' | 'share';
|
|
4573
|
+
url?: string;
|
|
4574
|
+
filename?: (string) | null;
|
|
4575
|
+
previewUrl?: (string) | null;
|
|
4576
|
+
}>;
|
|
4577
|
+
/**
|
|
4578
|
+
* Reddit message subject
|
|
4579
|
+
*/
|
|
4580
|
+
subject?: (string) | null;
|
|
4581
|
+
/**
|
|
4582
|
+
* Instagram story reply
|
|
4583
|
+
*/
|
|
4584
|
+
storyReply?: (boolean) | null;
|
|
4585
|
+
/**
|
|
4586
|
+
* Instagram story mention
|
|
4587
|
+
*/
|
|
4588
|
+
isStoryMention?: (boolean) | null;
|
|
4589
|
+
}>;
|
|
4590
|
+
lastUpdated?: string;
|
|
4591
|
+
});
|
|
4592
|
+
|
|
4593
|
+
export type GetInboxConversationMessagesError = ({
|
|
4594
|
+
error?: string;
|
|
4595
|
+
} | unknown);
|
|
4596
|
+
|
|
4597
|
+
export type SendInboxMessageData = {
|
|
4598
|
+
body: {
|
|
4599
|
+
/**
|
|
4600
|
+
* Social account ID
|
|
4601
|
+
*/
|
|
4602
|
+
accountId: string;
|
|
4603
|
+
/**
|
|
4604
|
+
* Message text
|
|
4605
|
+
*/
|
|
4606
|
+
message: string;
|
|
4607
|
+
};
|
|
4608
|
+
path: {
|
|
4609
|
+
conversationId: string;
|
|
4610
|
+
};
|
|
4611
|
+
};
|
|
4612
|
+
|
|
4613
|
+
export type SendInboxMessageResponse = ({
|
|
4614
|
+
success?: boolean;
|
|
4615
|
+
data?: {
|
|
4616
|
+
/**
|
|
4617
|
+
* ID of the sent message (not returned for Reddit)
|
|
4618
|
+
*/
|
|
4619
|
+
messageId?: string;
|
|
4620
|
+
/**
|
|
4621
|
+
* Twitter conversation ID
|
|
4622
|
+
*/
|
|
4623
|
+
conversationId?: (string) | null;
|
|
4624
|
+
/**
|
|
4625
|
+
* Bluesky sent timestamp
|
|
4626
|
+
*/
|
|
4627
|
+
sentAt?: (string) | null;
|
|
4628
|
+
/**
|
|
4629
|
+
* Success message (Reddit only)
|
|
4630
|
+
*/
|
|
4631
|
+
message?: (string) | null;
|
|
4632
|
+
};
|
|
4633
|
+
});
|
|
4634
|
+
|
|
4635
|
+
export type SendInboxMessageError = ({
|
|
4636
|
+
error?: string;
|
|
4637
|
+
code?: 'PLATFORM_LIMITATION';
|
|
4638
|
+
} | {
|
|
4639
|
+
error?: string;
|
|
4640
|
+
} | unknown);
|
|
4641
|
+
|
|
4642
|
+
export type ListInboxCommentsData = {
|
|
4643
|
+
query?: {
|
|
4644
|
+
/**
|
|
4645
|
+
* Filter by specific social account ID
|
|
4646
|
+
*/
|
|
4647
|
+
accountId?: string;
|
|
4648
|
+
cursor?: string;
|
|
4649
|
+
limit?: number;
|
|
4650
|
+
/**
|
|
4651
|
+
* Minimum comment count
|
|
4652
|
+
*/
|
|
4653
|
+
minComments?: number;
|
|
4654
|
+
/**
|
|
4655
|
+
* Filter by platform
|
|
4656
|
+
*/
|
|
4657
|
+
platform?: 'facebook' | 'instagram' | 'youtube' | 'linkedin' | 'reddit' | 'bluesky' | 'tiktok';
|
|
4658
|
+
/**
|
|
4659
|
+
* Filter by profile ID
|
|
4660
|
+
*/
|
|
4661
|
+
profileId?: string;
|
|
4662
|
+
/**
|
|
4663
|
+
* Posts created after this date
|
|
4664
|
+
*/
|
|
4665
|
+
since?: string;
|
|
4666
|
+
/**
|
|
4667
|
+
* Sort field
|
|
4668
|
+
*/
|
|
4669
|
+
sortBy?: 'date' | 'comments';
|
|
4670
|
+
/**
|
|
4671
|
+
* Sort order
|
|
4672
|
+
*/
|
|
4673
|
+
sortOrder?: 'asc' | 'desc';
|
|
4674
|
+
};
|
|
4675
|
+
};
|
|
4676
|
+
|
|
4677
|
+
export type ListInboxCommentsResponse = ({
|
|
4678
|
+
data?: Array<{
|
|
4679
|
+
id?: string;
|
|
4680
|
+
platform?: string;
|
|
4681
|
+
accountId?: string;
|
|
4682
|
+
accountUsername?: string;
|
|
4683
|
+
content?: string;
|
|
4684
|
+
picture?: (string) | null;
|
|
4685
|
+
permalink?: (string) | null;
|
|
4686
|
+
createdTime?: string;
|
|
4687
|
+
commentCount?: number;
|
|
4688
|
+
likeCount?: number;
|
|
4689
|
+
/**
|
|
4690
|
+
* Bluesky content identifier
|
|
4691
|
+
*/
|
|
4692
|
+
cid?: (string) | null;
|
|
4693
|
+
/**
|
|
4694
|
+
* Reddit subreddit name
|
|
4695
|
+
*/
|
|
4696
|
+
subreddit?: (string) | null;
|
|
4697
|
+
}>;
|
|
4698
|
+
pagination?: {
|
|
4699
|
+
hasMore?: boolean;
|
|
4700
|
+
nextCursor?: (string) | null;
|
|
4701
|
+
};
|
|
4702
|
+
meta?: {
|
|
4703
|
+
accountsQueried?: number;
|
|
4704
|
+
accountsFailed?: number;
|
|
4705
|
+
failedAccounts?: Array<{
|
|
4706
|
+
accountId?: string;
|
|
4707
|
+
accountUsername?: (string) | null;
|
|
4708
|
+
platform?: string;
|
|
4709
|
+
error?: string;
|
|
4710
|
+
/**
|
|
4711
|
+
* Error code if available
|
|
4712
|
+
*/
|
|
4713
|
+
code?: (string) | null;
|
|
4714
|
+
/**
|
|
4715
|
+
* Seconds to wait before retry (rate limits)
|
|
4716
|
+
*/
|
|
4717
|
+
retryAfter?: (number) | null;
|
|
4718
|
+
}>;
|
|
4719
|
+
lastUpdated?: string;
|
|
4720
|
+
};
|
|
4721
|
+
});
|
|
4722
|
+
|
|
4723
|
+
export type ListInboxCommentsError = ({
|
|
4724
|
+
error?: string;
|
|
4725
|
+
} | unknown);
|
|
4726
|
+
|
|
4727
|
+
export type GetInboxPostCommentsData = {
|
|
4728
|
+
path: {
|
|
4729
|
+
postId: string;
|
|
4730
|
+
};
|
|
4731
|
+
query: {
|
|
4732
|
+
accountId: string;
|
|
4733
|
+
/**
|
|
4734
|
+
* (Reddit only) Get replies to a specific comment
|
|
4735
|
+
*/
|
|
4736
|
+
commentId?: string;
|
|
4737
|
+
/**
|
|
4738
|
+
* Pagination cursor
|
|
4739
|
+
*/
|
|
4740
|
+
cursor?: string;
|
|
4741
|
+
/**
|
|
4742
|
+
* Maximum number of comments to return
|
|
4743
|
+
*/
|
|
4744
|
+
limit?: number;
|
|
4745
|
+
/**
|
|
4746
|
+
* (Reddit only) Subreddit name
|
|
4747
|
+
*/
|
|
4748
|
+
subreddit?: string;
|
|
4749
|
+
};
|
|
4750
|
+
};
|
|
4751
|
+
|
|
4752
|
+
export type GetInboxPostCommentsResponse = ({
|
|
4753
|
+
status?: string;
|
|
4754
|
+
comments?: Array<{
|
|
4755
|
+
id?: string;
|
|
4756
|
+
message?: string;
|
|
4757
|
+
createdTime?: string;
|
|
4758
|
+
from?: {
|
|
4759
|
+
id?: string;
|
|
4760
|
+
name?: string;
|
|
4761
|
+
username?: string;
|
|
4762
|
+
picture?: (string) | null;
|
|
4763
|
+
isOwner?: boolean;
|
|
4764
|
+
};
|
|
4765
|
+
likeCount?: number;
|
|
4766
|
+
replyCount?: number;
|
|
4767
|
+
/**
|
|
4768
|
+
* The platform this comment is from
|
|
4769
|
+
*/
|
|
4770
|
+
platform?: string;
|
|
4771
|
+
/**
|
|
4772
|
+
* Direct link to the comment on the platform (if available)
|
|
4773
|
+
*/
|
|
4774
|
+
url?: (string) | null;
|
|
4775
|
+
replies?: Array<{
|
|
4776
|
+
[key: string]: unknown;
|
|
4777
|
+
}>;
|
|
4778
|
+
canReply?: boolean;
|
|
4779
|
+
canDelete?: boolean;
|
|
4780
|
+
/**
|
|
4781
|
+
* Whether this comment can be hidden (Facebook
|
|
4782
|
+
*/
|
|
4783
|
+
canHide?: boolean;
|
|
4784
|
+
/**
|
|
4785
|
+
* Whether this comment can be liked (Facebook
|
|
4786
|
+
*/
|
|
4787
|
+
canLike?: boolean;
|
|
4788
|
+
/**
|
|
4789
|
+
* Whether the comment is currently hidden
|
|
4790
|
+
*/
|
|
4791
|
+
isHidden?: boolean;
|
|
4792
|
+
/**
|
|
4793
|
+
* Whether the current user has liked this comment
|
|
4794
|
+
*/
|
|
4795
|
+
isLiked?: boolean;
|
|
4796
|
+
/**
|
|
4797
|
+
* Bluesky like URI for unliking
|
|
4798
|
+
*/
|
|
4799
|
+
likeUri?: (string) | null;
|
|
4800
|
+
/**
|
|
4801
|
+
* Bluesky content identifier
|
|
4802
|
+
*/
|
|
4803
|
+
cid?: (string) | null;
|
|
4804
|
+
/**
|
|
4805
|
+
* Parent comment ID for nested replies
|
|
4806
|
+
*/
|
|
4807
|
+
parentId?: (string) | null;
|
|
4808
|
+
/**
|
|
4809
|
+
* Bluesky root post URI
|
|
4810
|
+
*/
|
|
4811
|
+
rootUri?: (string) | null;
|
|
4812
|
+
/**
|
|
4813
|
+
* Bluesky root post CID
|
|
4814
|
+
*/
|
|
4815
|
+
rootCid?: (string) | null;
|
|
4816
|
+
}>;
|
|
4817
|
+
pagination?: {
|
|
4818
|
+
hasMore?: boolean;
|
|
4819
|
+
cursor?: (string) | null;
|
|
4820
|
+
};
|
|
4821
|
+
meta?: {
|
|
4822
|
+
platform?: string;
|
|
4823
|
+
postId?: string;
|
|
4824
|
+
accountId?: string;
|
|
4825
|
+
/**
|
|
4826
|
+
* (Reddit only) Subreddit name
|
|
4827
|
+
*/
|
|
4828
|
+
subreddit?: (string) | null;
|
|
4829
|
+
lastUpdated?: string;
|
|
4830
|
+
};
|
|
4831
|
+
});
|
|
4832
|
+
|
|
4833
|
+
export type GetInboxPostCommentsError = ({
|
|
4834
|
+
error?: string;
|
|
4835
|
+
} | unknown);
|
|
4836
|
+
|
|
4837
|
+
export type ReplyToInboxPostData = {
|
|
4838
|
+
body: {
|
|
4839
|
+
accountId: string;
|
|
4840
|
+
message: string;
|
|
4841
|
+
/**
|
|
4842
|
+
* Reply to specific comment (optional)
|
|
4843
|
+
*/
|
|
4844
|
+
commentId?: string;
|
|
4845
|
+
/**
|
|
4846
|
+
* (Reddit only) Subreddit name for replies
|
|
4847
|
+
*/
|
|
4848
|
+
subreddit?: string;
|
|
4849
|
+
/**
|
|
4850
|
+
* (Bluesky only) Parent content identifier
|
|
4851
|
+
*/
|
|
4852
|
+
parentCid?: string;
|
|
4853
|
+
/**
|
|
4854
|
+
* (Bluesky only) Root post URI
|
|
4855
|
+
*/
|
|
4856
|
+
rootUri?: string;
|
|
4857
|
+
/**
|
|
4858
|
+
* (Bluesky only) Root post CID
|
|
4859
|
+
*/
|
|
4860
|
+
rootCid?: string;
|
|
4861
|
+
};
|
|
4862
|
+
path: {
|
|
4863
|
+
postId: string;
|
|
4864
|
+
};
|
|
4865
|
+
};
|
|
4866
|
+
|
|
4867
|
+
export type ReplyToInboxPostResponse = ({
|
|
4868
|
+
success?: boolean;
|
|
4869
|
+
data?: {
|
|
4870
|
+
commentId?: string;
|
|
4871
|
+
isReply?: boolean;
|
|
4872
|
+
/**
|
|
4873
|
+
* Bluesky CID
|
|
4874
|
+
*/
|
|
4875
|
+
cid?: (string) | null;
|
|
4876
|
+
};
|
|
4877
|
+
});
|
|
4878
|
+
|
|
4879
|
+
export type ReplyToInboxPostError = ({
|
|
4880
|
+
error?: string;
|
|
4881
|
+
} | unknown);
|
|
4882
|
+
|
|
4883
|
+
export type DeleteInboxCommentData = {
|
|
4884
|
+
path: {
|
|
4885
|
+
postId: string;
|
|
4886
|
+
};
|
|
4887
|
+
query: {
|
|
4888
|
+
accountId: string;
|
|
4889
|
+
commentId: string;
|
|
4890
|
+
};
|
|
4891
|
+
};
|
|
4892
|
+
|
|
4893
|
+
export type DeleteInboxCommentResponse = ({
|
|
4894
|
+
success?: boolean;
|
|
4895
|
+
data?: {
|
|
4896
|
+
message?: string;
|
|
4897
|
+
};
|
|
4898
|
+
});
|
|
4899
|
+
|
|
4900
|
+
export type DeleteInboxCommentError = ({
|
|
4901
|
+
error?: string;
|
|
4902
|
+
} | unknown);
|
|
4903
|
+
|
|
4904
|
+
export type HideInboxCommentData = {
|
|
4905
|
+
body: {
|
|
4906
|
+
/**
|
|
4907
|
+
* The social account ID
|
|
4908
|
+
*/
|
|
4909
|
+
accountId: string;
|
|
4910
|
+
};
|
|
4911
|
+
path: {
|
|
4912
|
+
commentId: string;
|
|
4913
|
+
postId: string;
|
|
4914
|
+
};
|
|
4915
|
+
};
|
|
4916
|
+
|
|
4917
|
+
export type HideInboxCommentResponse = ({
|
|
4918
|
+
status?: string;
|
|
4919
|
+
commentId?: string;
|
|
4920
|
+
hidden?: boolean;
|
|
4921
|
+
platform?: string;
|
|
4922
|
+
});
|
|
4923
|
+
|
|
4924
|
+
export type HideInboxCommentError = (unknown | {
|
|
4925
|
+
error?: string;
|
|
4926
|
+
});
|
|
4927
|
+
|
|
4928
|
+
export type UnhideInboxCommentData = {
|
|
4929
|
+
path: {
|
|
4930
|
+
commentId: string;
|
|
4931
|
+
postId: string;
|
|
4932
|
+
};
|
|
4933
|
+
query: {
|
|
4934
|
+
accountId: string;
|
|
4935
|
+
};
|
|
4936
|
+
};
|
|
4937
|
+
|
|
4938
|
+
export type UnhideInboxCommentResponse = ({
|
|
4939
|
+
status?: string;
|
|
4940
|
+
commentId?: string;
|
|
4941
|
+
hidden?: boolean;
|
|
4942
|
+
platform?: string;
|
|
4943
|
+
});
|
|
4944
|
+
|
|
4945
|
+
export type UnhideInboxCommentError = (unknown | {
|
|
4946
|
+
error?: string;
|
|
4947
|
+
});
|
|
4948
|
+
|
|
4949
|
+
export type LikeInboxCommentData = {
|
|
4950
|
+
body: {
|
|
4951
|
+
/**
|
|
4952
|
+
* The social account ID
|
|
4953
|
+
*/
|
|
4954
|
+
accountId: string;
|
|
4955
|
+
/**
|
|
4956
|
+
* (Bluesky only) Content identifier for the comment
|
|
4957
|
+
*/
|
|
4958
|
+
cid?: string;
|
|
4959
|
+
};
|
|
4960
|
+
path: {
|
|
4961
|
+
commentId: string;
|
|
4962
|
+
postId: string;
|
|
4963
|
+
};
|
|
4964
|
+
};
|
|
4965
|
+
|
|
4966
|
+
export type LikeInboxCommentResponse = ({
|
|
4967
|
+
status?: string;
|
|
4968
|
+
commentId?: string;
|
|
4969
|
+
liked?: boolean;
|
|
4970
|
+
/**
|
|
4971
|
+
* (Bluesky only) URI to use for unliking
|
|
4972
|
+
*/
|
|
4973
|
+
likeUri?: string;
|
|
4974
|
+
platform?: string;
|
|
4975
|
+
});
|
|
4976
|
+
|
|
4977
|
+
export type LikeInboxCommentError = (unknown | {
|
|
4978
|
+
error?: string;
|
|
4979
|
+
});
|
|
4980
|
+
|
|
4981
|
+
export type UnlikeInboxCommentData = {
|
|
4982
|
+
path: {
|
|
4983
|
+
commentId: string;
|
|
4984
|
+
postId: string;
|
|
4985
|
+
};
|
|
4986
|
+
query: {
|
|
4987
|
+
accountId: string;
|
|
4988
|
+
/**
|
|
4989
|
+
* (Bluesky only) The like URI returned when liking
|
|
4990
|
+
*/
|
|
4991
|
+
likeUri?: string;
|
|
4992
|
+
};
|
|
4993
|
+
};
|
|
4994
|
+
|
|
4995
|
+
export type UnlikeInboxCommentResponse = ({
|
|
4996
|
+
status?: string;
|
|
4997
|
+
commentId?: string;
|
|
4998
|
+
liked?: boolean;
|
|
4999
|
+
platform?: string;
|
|
5000
|
+
});
|
|
5001
|
+
|
|
5002
|
+
export type UnlikeInboxCommentError = (unknown | {
|
|
5003
|
+
error?: string;
|
|
5004
|
+
});
|
|
5005
|
+
|
|
5006
|
+
export type ListInboxReviewsData = {
|
|
5007
|
+
query?: {
|
|
5008
|
+
/**
|
|
5009
|
+
* Filter by specific social account ID
|
|
5010
|
+
*/
|
|
5011
|
+
accountId?: string;
|
|
5012
|
+
cursor?: string;
|
|
5013
|
+
/**
|
|
5014
|
+
* Filter by reply status
|
|
5015
|
+
*/
|
|
5016
|
+
hasReply?: boolean;
|
|
5017
|
+
limit?: number;
|
|
5018
|
+
maxRating?: number;
|
|
5019
|
+
minRating?: number;
|
|
5020
|
+
platform?: 'facebook' | 'googlebusiness';
|
|
5021
|
+
profileId?: string;
|
|
5022
|
+
sortBy?: 'date' | 'rating';
|
|
5023
|
+
sortOrder?: 'asc' | 'desc';
|
|
5024
|
+
};
|
|
5025
|
+
};
|
|
5026
|
+
|
|
5027
|
+
export type ListInboxReviewsResponse = ({
|
|
5028
|
+
status?: string;
|
|
5029
|
+
data?: Array<{
|
|
5030
|
+
id?: string;
|
|
5031
|
+
platform?: string;
|
|
5032
|
+
accountId?: string;
|
|
5033
|
+
accountUsername?: string;
|
|
5034
|
+
reviewer?: {
|
|
5035
|
+
id?: (string) | null;
|
|
5036
|
+
name?: string;
|
|
5037
|
+
profileImage?: (string) | null;
|
|
5038
|
+
};
|
|
5039
|
+
rating?: number;
|
|
5040
|
+
text?: string;
|
|
5041
|
+
created?: string;
|
|
5042
|
+
hasReply?: boolean;
|
|
5043
|
+
reply?: {
|
|
5044
|
+
id?: string;
|
|
5045
|
+
text?: string;
|
|
5046
|
+
created?: string;
|
|
5047
|
+
} | null;
|
|
5048
|
+
reviewUrl?: (string) | null;
|
|
5049
|
+
}>;
|
|
5050
|
+
pagination?: {
|
|
5051
|
+
hasMore?: boolean;
|
|
5052
|
+
nextCursor?: (string) | null;
|
|
5053
|
+
};
|
|
5054
|
+
meta?: {
|
|
5055
|
+
accountsQueried?: number;
|
|
5056
|
+
accountsFailed?: number;
|
|
5057
|
+
failedAccounts?: Array<{
|
|
5058
|
+
accountId?: string;
|
|
5059
|
+
accountUsername?: (string) | null;
|
|
5060
|
+
platform?: string;
|
|
5061
|
+
error?: string;
|
|
5062
|
+
/**
|
|
5063
|
+
* Error code if available
|
|
5064
|
+
*/
|
|
5065
|
+
code?: (string) | null;
|
|
5066
|
+
/**
|
|
5067
|
+
* Seconds to wait before retry (rate limits)
|
|
5068
|
+
*/
|
|
5069
|
+
retryAfter?: (number) | null;
|
|
5070
|
+
}>;
|
|
5071
|
+
lastUpdated?: string;
|
|
5072
|
+
};
|
|
5073
|
+
summary?: {
|
|
5074
|
+
totalReviews?: number;
|
|
5075
|
+
averageRating?: (number) | null;
|
|
5076
|
+
};
|
|
5077
|
+
});
|
|
5078
|
+
|
|
5079
|
+
export type ListInboxReviewsError = ({
|
|
5080
|
+
error?: string;
|
|
5081
|
+
} | unknown);
|
|
5082
|
+
|
|
5083
|
+
export type ReplyToInboxReviewData = {
|
|
5084
|
+
body: {
|
|
5085
|
+
accountId: string;
|
|
5086
|
+
message: string;
|
|
5087
|
+
};
|
|
5088
|
+
path: {
|
|
5089
|
+
/**
|
|
5090
|
+
* Review ID (URL-encoded for Google Business)
|
|
5091
|
+
*/
|
|
5092
|
+
reviewId: string;
|
|
5093
|
+
};
|
|
5094
|
+
};
|
|
5095
|
+
|
|
5096
|
+
export type ReplyToInboxReviewResponse = ({
|
|
5097
|
+
status?: string;
|
|
5098
|
+
reply?: {
|
|
5099
|
+
id?: string;
|
|
5100
|
+
text?: string;
|
|
5101
|
+
created?: string;
|
|
5102
|
+
};
|
|
5103
|
+
platform?: string;
|
|
5104
|
+
});
|
|
5105
|
+
|
|
5106
|
+
export type ReplyToInboxReviewError = ({
|
|
5107
|
+
error?: string;
|
|
5108
|
+
} | unknown);
|
|
5109
|
+
|
|
5110
|
+
export type DeleteInboxReviewReplyData = {
|
|
5111
|
+
body: {
|
|
5112
|
+
accountId: string;
|
|
5113
|
+
};
|
|
5114
|
+
path: {
|
|
5115
|
+
reviewId: string;
|
|
5116
|
+
};
|
|
5117
|
+
};
|
|
5118
|
+
|
|
5119
|
+
export type DeleteInboxReviewReplyResponse = ({
|
|
5120
|
+
status?: string;
|
|
5121
|
+
message?: string;
|
|
5122
|
+
platform?: string;
|
|
5123
|
+
});
|
|
5124
|
+
|
|
5125
|
+
export type DeleteInboxReviewReplyError = ({
|
|
5126
|
+
error?: string;
|
|
4156
5127
|
} | unknown);
|