@getlatedev/node 0.2.1296 → 0.2.1298

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,5 +1,13 @@
1
1
  // This file is auto-generated by @hey-api/openapi-ts
2
2
 
3
+ export type AccountCursorPagination = {
4
+ limit: number;
5
+ /**
6
+ * Opaque cursor for the next page; pass it back as `cursor`. Null on the last page.
7
+ */
8
+ nextCursor: (string) | null;
9
+ };
10
+
3
11
  export type AccountsListResponse = {
4
12
  accounts: Array<SocialAccount>;
5
13
  /**
@@ -7,9 +15,9 @@ export type AccountsListResponse = {
7
15
  */
8
16
  hasAnalyticsAccess: boolean;
9
17
  /**
10
- * Only present when page/limit params are provided
18
+ * Present on a paginated request: `{ page, limit, total, pages }` with page and limit, `{ limit, nextCursor }` with cursor paging (limit alone or cursor).
11
19
  */
12
- pagination?: Pagination;
20
+ pagination?: (Pagination | AccountCursorPagination);
13
21
  /**
14
22
  * Only with profileIds and perProfile. Accounts matching the filters per profile ID; a profile with none is absent.
15
23
  */
@@ -6763,6 +6771,10 @@ export type FollowerStatsResponse = {
6763
6771
  to?: string;
6764
6772
  };
6765
6773
  granularity?: string;
6774
+ /**
6775
+ * Only present when limit or cursor is sent.
6776
+ */
6777
+ pagination?: AccountCursorPagination;
6766
6778
  };
6767
6779
 
6768
6780
  export type FoodMenu = {
@@ -21290,6 +21302,10 @@ export type ListAccountsData = {
21290
21302
  * Only accounts of this kind. ads = ad accounts (Meta, Google, LinkedIn, Pinterest, TikTok, X, OpenAI, Reddit), communication = WhatsApp, Telegram, Discord, Slack and iMessage, blogs = Shopify and WordPress, crm = HubSpot, social = every other platform.
21291
21303
  */
21292
21304
  category?: 'social' | 'ads' | 'communication' | 'blogs' | 'crm';
21305
+ /**
21306
+ * Opaque cursor from a previous response's `pagination.nextCursor`; returns the next page of `limit` accounts (500 when limit is omitted). A cursor we cannot parse returns 400. Cannot be combined with page.
21307
+ */
21308
+ cursor?: string;
21293
21309
  /**
21294
21310
  * When true, leaves out accounts the dashboard does not show as connections: posting
21295
21311
  * accounts with `enabled: false` (ads accounts are always kept, whatever their `enabled`
@@ -21307,7 +21323,7 @@ export type ListAccountsData = {
21307
21323
  /**
21308
21324
  * When true, appends the shared WhatsApp sandbox account and the iMessage sandbox account
21309
21325
  * to the list when they are active, honouring `platform` but no other filter. Ignored on
21310
- * a paginated request (page/limit) and together with `perProfile`. Accepts `true` or
21326
+ * a paginated request (page, limit or cursor) and together with `perProfile`. Accepts `true` or
21311
21327
  * `false` in any letter case; any other value returns 400.
21312
21328
  *
21313
21329
  */
@@ -21320,7 +21336,7 @@ export type ListAccountsData = {
21320
21336
  */
21321
21337
  includeStatusCounts?: boolean;
21322
21338
  /**
21323
- * Page size. Must be provided together with page; sending only one of the two returns 400.
21339
+ * Page size. With page, an offset page; alone or with cursor, a cursor page.
21324
21340
  *
21325
21341
  */
21326
21342
  limit?: number;
@@ -21329,12 +21345,12 @@ export type ListAccountsData = {
21329
21345
  */
21330
21346
  order?: 'asc' | 'desc';
21331
21347
  /**
21332
- * Page number (1-based). Must be provided together with limit to enable server-side pagination; sending only one of the two returns 400. Omit both for all accounts.
21348
+ * Page number (1-based) for offset paging. Requires limit; omit page, limit and cursor for all accounts.
21333
21349
  *
21334
21350
  */
21335
21351
  page?: number;
21336
21352
  /**
21337
- * Return a preview of each profile in profileIds: the newest account of every platform it has, topped up to at least N. Requires profileIds; cannot be combined with page and limit.
21353
+ * Return a preview of each profile in profileIds: the newest account of every platform it has, topped up to at least N. Requires profileIds; cannot be combined with page, limit or cursor.
21338
21354
  */
21339
21355
  perProfile?: number;
21340
21356
  /**
@@ -21354,7 +21370,7 @@ export type ListAccountsData = {
21354
21370
  */
21355
21371
  search?: string;
21356
21372
  /**
21357
- * Sort a paginated listing (page/limit) by account name, platform, profile name, status (accounts needing a reconnect first when ascending) or connection date. Ties keep the default order: platform, then newest first.
21373
+ * Sort an offset-paginated listing (page and limit) by account name, platform, profile name, status (accounts needing a reconnect first when ascending) or connection date. Ties keep the default order: platform, then newest first.
21358
21374
  */
21359
21375
  sort?: 'account' | 'platform' | 'profile' | 'status' | 'connected';
21360
21376
  /**
@@ -21375,6 +21391,10 @@ export type GetFollowerStatsData = {
21375
21391
  * Comma-separated list of account IDs (optional, defaults to all user's accounts)
21376
21392
  */
21377
21393
  accountIds?: string;
21394
+ /**
21395
+ * Opaque cursor from a previous response's `pagination.nextCursor`; returns the next page of `limit` accounts (25 when limit is omitted). A cursor we cannot parse returns 400.
21396
+ */
21397
+ cursor?: string;
21378
21398
  /**
21379
21399
  * Start date in YYYY-MM-DD format (defaults to 30 days ago)
21380
21400
  */
@@ -21383,6 +21403,10 @@ export type GetFollowerStatsData = {
21383
21403
  * Data aggregation level
21384
21404
  */
21385
21405
  granularity?: 'daily' | 'weekly' | 'monthly';
21406
+ /**
21407
+ * Accounts per page, ordered by account id. Send it to page through accounts; the response then carries `pagination.nextCursor`. Without limit or cursor every matching account is returned.
21408
+ */
21409
+ limit?: number;
21386
21410
  /**
21387
21411
  * Filter by profile ID
21388
21412
  */
@@ -53884,6 +53908,9 @@ export type AddUsersToAdAudienceData = {
53884
53908
  export type AddUsersToAdAudienceResponse = ({
53885
53909
  message?: string;
53886
53910
  numReceived?: number;
53911
+ /**
53912
+ * Rows the platform could not read. Returned on Meta only.
53913
+ */
53887
53914
  numInvalid?: number;
53888
53915
  });
53889
53916
 
@@ -53891,6 +53918,43 @@ export type AddUsersToAdAudienceError = (unknown | ErrorResponse | {
53891
53918
  error?: string;
53892
53919
  });
53893
53920
 
53921
+ export type RemoveUsersFromAdAudienceData = {
53922
+ body: {
53923
+ users: Array<{
53924
+ email?: string;
53925
+ phone?: string;
53926
+ }>;
53927
+ };
53928
+ path: {
53929
+ /**
53930
+ * The Zernio audience id (the id field of GET /v1/ads/audiences), not the platform segment id.
53931
+ */
53932
+ audienceId: string;
53933
+ };
53934
+ };
53935
+
53936
+ export type RemoveUsersFromAdAudienceResponse = ({
53937
+ message?: string;
53938
+ /**
53939
+ * Rows Meta received.
53940
+ */
53941
+ numReceived?: number;
53942
+ /**
53943
+ * Rows Meta could not read.
53944
+ */
53945
+ numInvalid?: number;
53946
+ /**
53947
+ * A sample of the rows Meta could not read, passed through as Meta returns it. Empty when every row was valid.
53948
+ */
53949
+ invalidEntrySamples?: {
53950
+ [key: string]: (string);
53951
+ };
53952
+ });
53953
+
53954
+ export type RemoveUsersFromAdAudienceError = (ErrorResponse | unknown | {
53955
+ error?: string;
53956
+ });
53957
+
53894
53958
  export type ReplaceAdAudienceCompaniesData = {
53895
53959
  body: {
53896
53960
  /**