late-sdk 0.0.912 → 0.0.914
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.
- checksums.yaml +4 -4
- data/README.md +4 -0
- data/docs/AnalyticsApi.md +1 -1
- data/docs/CommentsApi.md +153 -5
- data/docs/PinInboxComment200Response.md +24 -0
- data/docs/PinInboxCommentRequest.md +18 -0
- data/docs/SyncExternalPosts200ResponseSynced.md +1 -1
- data/docs/TikTokPlatformData.md +1 -1
- data/lib/zernio-sdk/api/analytics_api.rb +2 -2
- data/lib/zernio-sdk/api/comments_api.rb +164 -8
- data/lib/zernio-sdk/models/pin_inbox_comment200_response.rb +174 -0
- data/lib/zernio-sdk/models/pin_inbox_comment_request.rb +165 -0
- data/lib/zernio-sdk/models/sync_external_posts200_response_synced.rb +1 -1
- data/lib/zernio-sdk/models/tik_tok_platform_data.rb +1 -1
- data/lib/zernio-sdk/models/webhook_payload_comment.rb +1 -1
- data/lib/zernio-sdk/models/webhook_payload_comment_comment.rb +2 -2
- data/lib/zernio-sdk/version.rb +1 -1
- data/lib/zernio-sdk.rb +2 -0
- data/openapi.yaml +113 -10
- data/spec/api/analytics_api_spec.rb +1 -1
- data/spec/api/comments_api_spec.rb +32 -4
- data/spec/models/pin_inbox_comment200_response_spec.rb +54 -0
- data/spec/models/pin_inbox_comment_request_spec.rb +36 -0
- data/spec/models/webhook_payload_comment_comment_spec.rb +1 -1
- data/zernio-sdk-0.0.914.gem +0 -0
- metadata +10 -2
- data/zernio-sdk-0.0.912.gem +0 -0
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 873a429acb1e9d45fb4b1f0fcd4c2b88d8e6d2bfceb1361a27f70393b78efaa7
|
|
4
|
+
data.tar.gz: d9f14f5952f620e91851f19cc73e4c3dbe5c18165053c0216e0fa00e0d022a53
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 2a438c07f5ea5258569154fe820d9a50b94e1320d0938e4b965e04b9deff15d3240431f60724ebc8667958ab133d66b9afe069aa6ac91f1209be62872b324a86
|
|
7
|
+
data.tar.gz: b80e63a0374f26aa56ed308a019cdf232beee83bba1a90fd832920caf597d38b9da69f8dd6c8e13bed3a4f070175eb596e6bf835a4fe1db0c60a0064768b3a2e
|
data/README.md
CHANGED
|
@@ -357,12 +357,14 @@ Class | Method | HTTP request | Description
|
|
|
357
357
|
*Zernio::CommentsApi* | [**like_inbox_comment**](docs/CommentsApi.md#like_inbox_comment) | **POST** /v1/inbox/comments/{postId}/{commentId}/like | Like comment
|
|
358
358
|
*Zernio::CommentsApi* | [**like_post**](docs/CommentsApi.md#like_post) | **POST** /v1/inbox/posts/{postId}/like | Like post
|
|
359
359
|
*Zernio::CommentsApi* | [**list_inbox_comments**](docs/CommentsApi.md#list_inbox_comments) | **GET** /v1/inbox/comments | List commented posts
|
|
360
|
+
*Zernio::CommentsApi* | [**pin_inbox_comment**](docs/CommentsApi.md#pin_inbox_comment) | **POST** /v1/inbox/comments/{postId}/{commentId}/pin | Pin comment
|
|
360
361
|
*Zernio::CommentsApi* | [**reply_to_inbox_post**](docs/CommentsApi.md#reply_to_inbox_post) | **POST** /v1/inbox/comments/{postId} | Reply to comment
|
|
361
362
|
*Zernio::CommentsApi* | [**send_private_reply_to_comment**](docs/CommentsApi.md#send_private_reply_to_comment) | **POST** /v1/inbox/comments/{postId}/{commentId}/private-reply | Send private reply
|
|
362
363
|
*Zernio::CommentsApi* | [**set_comment_moderation**](docs/CommentsApi.md#set_comment_moderation) | **POST** /v1/inbox/comments/{postId}/{commentId}/moderation | Set comment moderation status
|
|
363
364
|
*Zernio::CommentsApi* | [**unhide_inbox_comment**](docs/CommentsApi.md#unhide_inbox_comment) | **DELETE** /v1/inbox/comments/{postId}/{commentId}/hide | Unhide comment
|
|
364
365
|
*Zernio::CommentsApi* | [**unlike_inbox_comment**](docs/CommentsApi.md#unlike_inbox_comment) | **DELETE** /v1/inbox/comments/{postId}/{commentId}/like | Unlike comment
|
|
365
366
|
*Zernio::CommentsApi* | [**unlike_post**](docs/CommentsApi.md#unlike_post) | **DELETE** /v1/inbox/posts/{postId}/like | Unlike post
|
|
367
|
+
*Zernio::CommentsApi* | [**unpin_inbox_comment**](docs/CommentsApi.md#unpin_inbox_comment) | **DELETE** /v1/inbox/comments/{postId}/{commentId}/pin | Unpin comment
|
|
366
368
|
*Zernio::ConnectApi* | [**assign_google_business_location**](docs/ConnectApi.md#assign_google_business_location) | **POST** /v1/accounts/{accountId}/gmb-locations/assign | Assign Google Business Profile location to another profile
|
|
367
369
|
*Zernio::ConnectApi* | [**complete_meta_ads_business_login**](docs/ConnectApi.md#complete_meta_ads_business_login) | **GET** /v1/connect/meta-ads/callback | Complete Meta business login
|
|
368
370
|
*Zernio::ConnectApi* | [**complete_telegram_connect**](docs/ConnectApi.md#complete_telegram_connect) | **PATCH** /v1/connect/telegram | Check Telegram status
|
|
@@ -2060,6 +2062,8 @@ Class | Method | HTTP request | Description
|
|
|
2060
2062
|
- [Zernio::Pending](docs/Pending.md)
|
|
2061
2063
|
- [Zernio::PhoneNumberStockWatch](docs/PhoneNumberStockWatch.md)
|
|
2062
2064
|
- [Zernio::PinDiscordMessage200Response](docs/PinDiscordMessage200Response.md)
|
|
2065
|
+
- [Zernio::PinInboxComment200Response](docs/PinInboxComment200Response.md)
|
|
2066
|
+
- [Zernio::PinInboxCommentRequest](docs/PinInboxCommentRequest.md)
|
|
2063
2067
|
- [Zernio::PinterestPlatformData](docs/PinterestPlatformData.md)
|
|
2064
2068
|
- [Zernio::PlatformAnalytics](docs/PlatformAnalytics.md)
|
|
2065
2069
|
- [Zernio::PlatformTarget](docs/PlatformTarget.md)
|
data/docs/AnalyticsApi.md
CHANGED
|
@@ -1985,7 +1985,7 @@ end
|
|
|
1985
1985
|
|
|
1986
1986
|
Sync an external post
|
|
1987
1987
|
|
|
1988
|
-
Fetch an account's latest external posts (published directly on the platform, not through Zernio) on demand, so a newly published post is retrievable within seconds instead of waiting for the background sync (which refreshes each account at most every ~90 minutes). Primary use case: verifying a submitted post. When a user publishes on the platform and immediately pastes the post URL into your app, call this with `accountId` plus `url` (or `postId`) to confirm the post exists and return its metadata. Behavior: -
|
|
1988
|
+
Fetch an account's latest external posts (published directly on the platform, not through Zernio) on demand, so a newly published post is retrievable within seconds instead of waiting for the background sync (which refreshes each account at most every ~90 minutes). Primary use case: verifying a submitted post. When a user publishes on the platform and immediately pastes the post URL into your app, call this with `accountId` plus `url` (or `postId`) to confirm the post exists and return its metadata. Behavior: - Account access and connection state are checked before any platform call, including requests inside the debounce window. - Inactive accounts or accounts marked `needsReconnection` return `409` with code `ads_connection_required`. Stop scheduled retries for that account until it is reconnected, then read `GET /v1/accounts` for its current account ID. - For connected accounts, we fetch the latest posts live from the platform, then match and return the submitted post. - Requests are debounced per account (~15s): if the account was synced inside that window, the live fetch is skipped. `accountId` is required, because a post URL or id alone cannot be resolved to an account, and the account must be connected to Zernio (we use its token to read the platform). Supported for every platform with a listing API (Instagram, Facebook, TikTok, YouTube, X, Threads, Pinterest, Reddit, Bluesky, Google Business Profile, and LinkedIn organization accounts). LinkedIn personal profiles: LinkedIn has no listing API for personal profiles, so a `url` is REQUIRED and imports that single post. Pass any LinkedIn post URL (`linkedin.com/posts/…`, `linkedin.com/feed/update/urn:li:activity:…`) or a `urn:li:share:…` / `urn:li:ugcPost:…` URN. Works for posts published outside Zernio and before the account was connected, any age; the post must be authored by the connected member. Imported posts return full analytics (impressions, reach, reactions, comments, reshares, saves) and keep refreshing on the background analytics cycle, but carry no content/media (LinkedIn does not expose them for personal profiles). `url` accepts any format the platform uses (e.g. `instagram.com/p/…`, `instagram.com/reel/…`, `youtu.be/…`, `youtube.com/shorts/…`, `tiktok.com/@user/video/…`, `vm.tiktok.com` short links, `pinterest.com/pin/…` on any regional domain, and `pin.it` short links). Pass `postId` (the platform media/video/pin id) as an alternative locator. Note: post-level analytics (reach, impressions) still carry the platform's own delay (e.g. ~24h on Instagram). This endpoint confirms the post exists and returns its metadata plus basic engagement (likes, comments), not delayed insights.
|
|
1989
1989
|
|
|
1990
1990
|
### Examples
|
|
1991
1991
|
|
data/docs/CommentsApi.md
CHANGED
|
@@ -11,12 +11,14 @@ All URIs are relative to *https://zernio.com/api*
|
|
|
11
11
|
| [**like_inbox_comment**](CommentsApi.md#like_inbox_comment) | **POST** /v1/inbox/comments/{postId}/{commentId}/like | Like comment |
|
|
12
12
|
| [**like_post**](CommentsApi.md#like_post) | **POST** /v1/inbox/posts/{postId}/like | Like post |
|
|
13
13
|
| [**list_inbox_comments**](CommentsApi.md#list_inbox_comments) | **GET** /v1/inbox/comments | List commented posts |
|
|
14
|
+
| [**pin_inbox_comment**](CommentsApi.md#pin_inbox_comment) | **POST** /v1/inbox/comments/{postId}/{commentId}/pin | Pin comment |
|
|
14
15
|
| [**reply_to_inbox_post**](CommentsApi.md#reply_to_inbox_post) | **POST** /v1/inbox/comments/{postId} | Reply to comment |
|
|
15
16
|
| [**send_private_reply_to_comment**](CommentsApi.md#send_private_reply_to_comment) | **POST** /v1/inbox/comments/{postId}/{commentId}/private-reply | Send private reply |
|
|
16
17
|
| [**set_comment_moderation**](CommentsApi.md#set_comment_moderation) | **POST** /v1/inbox/comments/{postId}/{commentId}/moderation | Set comment moderation status |
|
|
17
18
|
| [**unhide_inbox_comment**](CommentsApi.md#unhide_inbox_comment) | **DELETE** /v1/inbox/comments/{postId}/{commentId}/hide | Unhide comment |
|
|
18
19
|
| [**unlike_inbox_comment**](CommentsApi.md#unlike_inbox_comment) | **DELETE** /v1/inbox/comments/{postId}/{commentId}/like | Unlike comment |
|
|
19
20
|
| [**unlike_post**](CommentsApi.md#unlike_post) | **DELETE** /v1/inbox/posts/{postId}/like | Unlike post |
|
|
21
|
+
| [**unpin_inbox_comment**](CommentsApi.md#unpin_inbox_comment) | **DELETE** /v1/inbox/comments/{postId}/{commentId}/pin | Unpin comment |
|
|
20
22
|
|
|
21
23
|
|
|
22
24
|
## delete_inbox_comment
|
|
@@ -171,7 +173,7 @@ end
|
|
|
171
173
|
|
|
172
174
|
Get post comments
|
|
173
175
|
|
|
174
|
-
Fetch comments for a specific post. Requires accountId query parameter. On Facebook and Instagram, passing a COMMENT id as `postId` is also supported and returns that comment's replies instead of the post's top-level comments. This is not available on YouTube, where `postId` must be a video id. Responses are cached for up to 10 minutes, so a page may lag new comments by that window. Do not poll this endpoint for real-time updates: subscribe to the `comment.received` webhook, which delivers new comments as they arrive. Your own writes (creating, replying to, or deleting a comment) refresh the cache immediately.
|
|
176
|
+
Fetch comments for a specific post. Requires accountId query parameter. On Facebook and Instagram, passing a COMMENT id as `postId` is also supported and returns that comment's replies instead of the post's top-level comments. This is not available on YouTube, where `postId` must be a video id. Responses are cached for up to 10 minutes, so a page may lag new comments by that window. Do not poll this endpoint for real-time updates: subscribe to the `comment.received` webhook, which delivers new comments as they arrive. Your own writes (creating, replying to, or deleting a comment) refresh the cache immediately. TikTok is served for accounts connected through the TikTok for Business app: `postId` is the TikTok video id, each top-level comment carries up to three inline replies, and `commentId` pages the full reply list of one comment. Developer-app TikTok accounts return 400 with code `PLATFORM_LIMITATION`.
|
|
175
177
|
|
|
176
178
|
### Examples
|
|
177
179
|
|
|
@@ -191,7 +193,7 @@ opts = {
|
|
|
191
193
|
subreddit: 'subreddit_example', # String | (Reddit only) Subreddit name
|
|
192
194
|
limit: 56, # Integer | Maximum number of comments to return
|
|
193
195
|
cursor: 'cursor_example', # String | Pagination cursor, returned by a previous call as `pagination.cursor`. This is the platform's own opaque paging value passed through verbatim: never construct, decode or validate it client-side.
|
|
194
|
-
comment_id: 'comment_id_example' # String | (Reddit only) Get replies to a specific comment
|
|
196
|
+
comment_id: 'comment_id_example' # String | (Reddit and TikTok only) Get replies to a specific comment
|
|
195
197
|
}
|
|
196
198
|
|
|
197
199
|
begin
|
|
@@ -230,7 +232,7 @@ end
|
|
|
230
232
|
| **subreddit** | **String** | (Reddit only) Subreddit name | [optional] |
|
|
231
233
|
| **limit** | **Integer** | Maximum number of comments to return | [optional][default to 25] |
|
|
232
234
|
| **cursor** | **String** | Pagination cursor, returned by a previous call as `pagination.cursor`. This is the platform's own opaque paging value passed through verbatim: never construct, decode or validate it client-side. | [optional] |
|
|
233
|
-
| **comment_id** | **String** | (Reddit only) Get replies to a specific comment | [optional] |
|
|
235
|
+
| **comment_id** | **String** | (Reddit and TikTok only) Get replies to a specific comment | [optional] |
|
|
234
236
|
|
|
235
237
|
### Return type
|
|
236
238
|
|
|
@@ -252,7 +254,7 @@ end
|
|
|
252
254
|
|
|
253
255
|
Hide comment
|
|
254
256
|
|
|
255
|
-
Hide a comment on a post. Supported by Facebook, Instagram, Threads, and
|
|
257
|
+
Hide a comment on a post. Supported by Facebook, Instagram, Threads, X, and TikTok (accounts connected through the TikTok for Business app). Hidden comments are only visible to the commenter and page admin. For X, the reply must belong to a conversation started by the authenticated user.
|
|
256
258
|
|
|
257
259
|
### Examples
|
|
258
260
|
|
|
@@ -550,6 +552,79 @@ end
|
|
|
550
552
|
- **Accept**: application/json
|
|
551
553
|
|
|
552
554
|
|
|
555
|
+
## pin_inbox_comment
|
|
556
|
+
|
|
557
|
+
> <PinInboxComment200Response> pin_inbox_comment(post_id, comment_id, pin_inbox_comment_request)
|
|
558
|
+
|
|
559
|
+
Pin comment
|
|
560
|
+
|
|
561
|
+
Pin a top-level comment to the top of a post's comment section. TikTok accounts connected through the TikTok for Business app only; every other platform returns 400.
|
|
562
|
+
|
|
563
|
+
### Examples
|
|
564
|
+
|
|
565
|
+
```ruby
|
|
566
|
+
require 'time'
|
|
567
|
+
require 'zernio-sdk'
|
|
568
|
+
# setup authorization
|
|
569
|
+
Zernio.configure do |config|
|
|
570
|
+
# Configure Bearer authorization (JWT): bearerAuth
|
|
571
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
|
572
|
+
end
|
|
573
|
+
|
|
574
|
+
api_instance = Zernio::CommentsApi.new
|
|
575
|
+
post_id = 'post_id_example' # String |
|
|
576
|
+
comment_id = 'comment_id_example' # String |
|
|
577
|
+
pin_inbox_comment_request = Zernio::PinInboxCommentRequest.new({account_id: 'account_id_example'}) # PinInboxCommentRequest |
|
|
578
|
+
|
|
579
|
+
begin
|
|
580
|
+
# Pin comment
|
|
581
|
+
result = api_instance.pin_inbox_comment(post_id, comment_id, pin_inbox_comment_request)
|
|
582
|
+
p result
|
|
583
|
+
rescue Zernio::ApiError => e
|
|
584
|
+
puts "Error when calling CommentsApi->pin_inbox_comment: #{e}"
|
|
585
|
+
end
|
|
586
|
+
```
|
|
587
|
+
|
|
588
|
+
#### Using the pin_inbox_comment_with_http_info variant
|
|
589
|
+
|
|
590
|
+
This returns an Array which contains the response data, status code and headers.
|
|
591
|
+
|
|
592
|
+
> <Array(<PinInboxComment200Response>, Integer, Hash)> pin_inbox_comment_with_http_info(post_id, comment_id, pin_inbox_comment_request)
|
|
593
|
+
|
|
594
|
+
```ruby
|
|
595
|
+
begin
|
|
596
|
+
# Pin comment
|
|
597
|
+
data, status_code, headers = api_instance.pin_inbox_comment_with_http_info(post_id, comment_id, pin_inbox_comment_request)
|
|
598
|
+
p status_code # => 2xx
|
|
599
|
+
p headers # => { ... }
|
|
600
|
+
p data # => <PinInboxComment200Response>
|
|
601
|
+
rescue Zernio::ApiError => e
|
|
602
|
+
puts "Error when calling CommentsApi->pin_inbox_comment_with_http_info: #{e}"
|
|
603
|
+
end
|
|
604
|
+
```
|
|
605
|
+
|
|
606
|
+
### Parameters
|
|
607
|
+
|
|
608
|
+
| Name | Type | Description | Notes |
|
|
609
|
+
| ---- | ---- | ----------- | ----- |
|
|
610
|
+
| **post_id** | **String** | | |
|
|
611
|
+
| **comment_id** | **String** | | |
|
|
612
|
+
| **pin_inbox_comment_request** | [**PinInboxCommentRequest**](PinInboxCommentRequest.md) | | |
|
|
613
|
+
|
|
614
|
+
### Return type
|
|
615
|
+
|
|
616
|
+
[**PinInboxComment200Response**](PinInboxComment200Response.md)
|
|
617
|
+
|
|
618
|
+
### Authorization
|
|
619
|
+
|
|
620
|
+
[bearerAuth](../README.md#bearerAuth)
|
|
621
|
+
|
|
622
|
+
### HTTP request headers
|
|
623
|
+
|
|
624
|
+
- **Content-Type**: application/json
|
|
625
|
+
- **Accept**: application/json
|
|
626
|
+
|
|
627
|
+
|
|
553
628
|
## reply_to_inbox_post
|
|
554
629
|
|
|
555
630
|
> <ReplyToInboxPost200Response> reply_to_inbox_post(post_id, reply_to_inbox_post_request, opts)
|
|
@@ -777,7 +852,7 @@ end
|
|
|
777
852
|
|
|
778
853
|
Unhide comment
|
|
779
854
|
|
|
780
|
-
Unhide a previously hidden comment. Supported by Facebook, Instagram, Threads, and
|
|
855
|
+
Unhide a previously hidden comment. Supported by Facebook, Instagram, Threads, X, and TikTok (accounts connected through the TikTok for Business app).
|
|
781
856
|
|
|
782
857
|
### Examples
|
|
783
858
|
|
|
@@ -995,3 +1070,76 @@ end
|
|
|
995
1070
|
- **Content-Type**: Not defined
|
|
996
1071
|
- **Accept**: application/json
|
|
997
1072
|
|
|
1073
|
+
|
|
1074
|
+
## unpin_inbox_comment
|
|
1075
|
+
|
|
1076
|
+
> <PinInboxComment200Response> unpin_inbox_comment(post_id, comment_id, account_id)
|
|
1077
|
+
|
|
1078
|
+
Unpin comment
|
|
1079
|
+
|
|
1080
|
+
Unpin a previously pinned comment. TikTok accounts connected through the TikTok for Business app only.
|
|
1081
|
+
|
|
1082
|
+
### Examples
|
|
1083
|
+
|
|
1084
|
+
```ruby
|
|
1085
|
+
require 'time'
|
|
1086
|
+
require 'zernio-sdk'
|
|
1087
|
+
# setup authorization
|
|
1088
|
+
Zernio.configure do |config|
|
|
1089
|
+
# Configure Bearer authorization (JWT): bearerAuth
|
|
1090
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
|
1091
|
+
end
|
|
1092
|
+
|
|
1093
|
+
api_instance = Zernio::CommentsApi.new
|
|
1094
|
+
post_id = 'post_id_example' # String |
|
|
1095
|
+
comment_id = 'comment_id_example' # String |
|
|
1096
|
+
account_id = 'account_id_example' # String |
|
|
1097
|
+
|
|
1098
|
+
begin
|
|
1099
|
+
# Unpin comment
|
|
1100
|
+
result = api_instance.unpin_inbox_comment(post_id, comment_id, account_id)
|
|
1101
|
+
p result
|
|
1102
|
+
rescue Zernio::ApiError => e
|
|
1103
|
+
puts "Error when calling CommentsApi->unpin_inbox_comment: #{e}"
|
|
1104
|
+
end
|
|
1105
|
+
```
|
|
1106
|
+
|
|
1107
|
+
#### Using the unpin_inbox_comment_with_http_info variant
|
|
1108
|
+
|
|
1109
|
+
This returns an Array which contains the response data, status code and headers.
|
|
1110
|
+
|
|
1111
|
+
> <Array(<PinInboxComment200Response>, Integer, Hash)> unpin_inbox_comment_with_http_info(post_id, comment_id, account_id)
|
|
1112
|
+
|
|
1113
|
+
```ruby
|
|
1114
|
+
begin
|
|
1115
|
+
# Unpin comment
|
|
1116
|
+
data, status_code, headers = api_instance.unpin_inbox_comment_with_http_info(post_id, comment_id, account_id)
|
|
1117
|
+
p status_code # => 2xx
|
|
1118
|
+
p headers # => { ... }
|
|
1119
|
+
p data # => <PinInboxComment200Response>
|
|
1120
|
+
rescue Zernio::ApiError => e
|
|
1121
|
+
puts "Error when calling CommentsApi->unpin_inbox_comment_with_http_info: #{e}"
|
|
1122
|
+
end
|
|
1123
|
+
```
|
|
1124
|
+
|
|
1125
|
+
### Parameters
|
|
1126
|
+
|
|
1127
|
+
| Name | Type | Description | Notes |
|
|
1128
|
+
| ---- | ---- | ----------- | ----- |
|
|
1129
|
+
| **post_id** | **String** | | |
|
|
1130
|
+
| **comment_id** | **String** | | |
|
|
1131
|
+
| **account_id** | **String** | | |
|
|
1132
|
+
|
|
1133
|
+
### Return type
|
|
1134
|
+
|
|
1135
|
+
[**PinInboxComment200Response**](PinInboxComment200Response.md)
|
|
1136
|
+
|
|
1137
|
+
### Authorization
|
|
1138
|
+
|
|
1139
|
+
[bearerAuth](../README.md#bearerAuth)
|
|
1140
|
+
|
|
1141
|
+
### HTTP request headers
|
|
1142
|
+
|
|
1143
|
+
- **Content-Type**: Not defined
|
|
1144
|
+
- **Accept**: application/json
|
|
1145
|
+
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
# Zernio::PinInboxComment200Response
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **status** | **String** | | [optional] |
|
|
8
|
+
| **comment_id** | **String** | | [optional] |
|
|
9
|
+
| **pinned** | **Boolean** | | [optional] |
|
|
10
|
+
| **platform** | **String** | | [optional] |
|
|
11
|
+
|
|
12
|
+
## Example
|
|
13
|
+
|
|
14
|
+
```ruby
|
|
15
|
+
require 'zernio-sdk'
|
|
16
|
+
|
|
17
|
+
instance = Zernio::PinInboxComment200Response.new(
|
|
18
|
+
status: null,
|
|
19
|
+
comment_id: null,
|
|
20
|
+
pinned: null,
|
|
21
|
+
platform: null
|
|
22
|
+
)
|
|
23
|
+
```
|
|
24
|
+
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# Zernio::PinInboxCommentRequest
|
|
2
|
+
|
|
3
|
+
## Properties
|
|
4
|
+
|
|
5
|
+
| Name | Type | Description | Notes |
|
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
|
7
|
+
| **account_id** | **String** | The social account ID | |
|
|
8
|
+
|
|
9
|
+
## Example
|
|
10
|
+
|
|
11
|
+
```ruby
|
|
12
|
+
require 'zernio-sdk'
|
|
13
|
+
|
|
14
|
+
instance = Zernio::PinInboxCommentRequest.new(
|
|
15
|
+
account_id: null
|
|
16
|
+
)
|
|
17
|
+
```
|
|
18
|
+
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
|
7
7
|
| **posts_found** | **Integer** | Posts returned by the platform listing during the on-demand sync | [optional] |
|
|
8
8
|
| **posts_synced** | **Integer** | Posts inserted or updated in Zernio | [optional] |
|
|
9
|
-
| **skipped** | **Boolean** | True when
|
|
9
|
+
| **skipped** | **Boolean** | True when the account was synced within the debounce window and no live fetch ran. | [optional] |
|
|
10
10
|
|
|
11
11
|
## Example
|
|
12
12
|
|
data/docs/TikTokPlatformData.md
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
| Name | Type | Description | Notes |
|
|
6
6
|
| ---- | ---- | ----------- | ----- |
|
|
7
7
|
| **draft** | **Boolean** | When true, sends the post to the TikTok Creator Inbox as a draft instead of publishing immediately. The creator receives an inbox notification to complete posting via TikTok's editing flow. Maps to TikTok API post_mode: \"MEDIA_UPLOAD\" (photos) or the dedicated inbox endpoint (videos). When false or omitted, publishes directly via post_mode: \"DIRECT_POST\". Note: publish_type is not a supported field. Use this field instead. | [optional] |
|
|
8
|
-
| **privacy_level** | **String** | One of the values returned by the TikTok creator info API for the account | [optional] |
|
|
8
|
+
| **privacy_level** | **String** | One of the values returned by the TikTok creator info API for the account. Accounts connected through the TikTok for Business app publish videos as public only: a non-public value on a video post is rejected at creation unless draft is true (photo posts keep every level). | [optional] |
|
|
9
9
|
| **allow_comment** | **Boolean** | Allow comments on the post | [optional] |
|
|
10
10
|
| **allow_duet** | **Boolean** | Allow duets (required for video posts) | [optional] |
|
|
11
11
|
| **allow_stitch** | **Boolean** | Allow stitches (required for video posts) | [optional] |
|
|
@@ -1995,7 +1995,7 @@ module Zernio
|
|
|
1995
1995
|
end
|
|
1996
1996
|
|
|
1997
1997
|
# Sync an external post
|
|
1998
|
-
# Fetch an account's latest external posts (published directly on the platform, not through Zernio) on demand, so a newly published post is retrievable within seconds instead of waiting for the background sync (which refreshes each account at most every ~90 minutes). Primary use case: verifying a submitted post. When a user publishes on the platform and immediately pastes the post URL into your app, call this with `accountId` plus `url` (or `postId`) to confirm the post exists and return its metadata. Behavior: -
|
|
1998
|
+
# Fetch an account's latest external posts (published directly on the platform, not through Zernio) on demand, so a newly published post is retrievable within seconds instead of waiting for the background sync (which refreshes each account at most every ~90 minutes). Primary use case: verifying a submitted post. When a user publishes on the platform and immediately pastes the post URL into your app, call this with `accountId` plus `url` (or `postId`) to confirm the post exists and return its metadata. Behavior: - Account access and connection state are checked before any platform call, including requests inside the debounce window. - Inactive accounts or accounts marked `needsReconnection` return `409` with code `ads_connection_required`. Stop scheduled retries for that account until it is reconnected, then read `GET /v1/accounts` for its current account ID. - For connected accounts, we fetch the latest posts live from the platform, then match and return the submitted post. - Requests are debounced per account (~15s): if the account was synced inside that window, the live fetch is skipped. `accountId` is required, because a post URL or id alone cannot be resolved to an account, and the account must be connected to Zernio (we use its token to read the platform). Supported for every platform with a listing API (Instagram, Facebook, TikTok, YouTube, X, Threads, Pinterest, Reddit, Bluesky, Google Business Profile, and LinkedIn organization accounts). LinkedIn personal profiles: LinkedIn has no listing API for personal profiles, so a `url` is REQUIRED and imports that single post. Pass any LinkedIn post URL (`linkedin.com/posts/…`, `linkedin.com/feed/update/urn:li:activity:…`) or a `urn:li:share:…` / `urn:li:ugcPost:…` URN. Works for posts published outside Zernio and before the account was connected, any age; the post must be authored by the connected member. Imported posts return full analytics (impressions, reach, reactions, comments, reshares, saves) and keep refreshing on the background analytics cycle, but carry no content/media (LinkedIn does not expose them for personal profiles). `url` accepts any format the platform uses (e.g. `instagram.com/p/…`, `instagram.com/reel/…`, `youtu.be/…`, `youtube.com/shorts/…`, `tiktok.com/@user/video/…`, `vm.tiktok.com` short links, `pinterest.com/pin/…` on any regional domain, and `pin.it` short links). Pass `postId` (the platform media/video/pin id) as an alternative locator. Note: post-level analytics (reach, impressions) still carry the platform's own delay (e.g. ~24h on Instagram). This endpoint confirms the post exists and returns its metadata plus basic engagement (likes, comments), not delayed insights.
|
|
1999
1999
|
# @param sync_external_posts_request [SyncExternalPostsRequest]
|
|
2000
2000
|
# @param [Hash] opts the optional parameters
|
|
2001
2001
|
# @return [SyncExternalPosts200Response]
|
|
@@ -2005,7 +2005,7 @@ module Zernio
|
|
|
2005
2005
|
end
|
|
2006
2006
|
|
|
2007
2007
|
# Sync an external post
|
|
2008
|
-
# Fetch an account's latest external posts (published directly on the platform, not through Zernio) on demand, so a newly published post is retrievable within seconds instead of waiting for the background sync (which refreshes each account at most every ~90 minutes). Primary use case: verifying a submitted post. When a user publishes on the platform and immediately pastes the post URL into your app, call this with `accountId` plus `url` (or `postId`) to confirm the post exists and return its metadata. Behavior: -
|
|
2008
|
+
# Fetch an account's latest external posts (published directly on the platform, not through Zernio) on demand, so a newly published post is retrievable within seconds instead of waiting for the background sync (which refreshes each account at most every ~90 minutes). Primary use case: verifying a submitted post. When a user publishes on the platform and immediately pastes the post URL into your app, call this with `accountId` plus `url` (or `postId`) to confirm the post exists and return its metadata. Behavior: - Account access and connection state are checked before any platform call, including requests inside the debounce window. - Inactive accounts or accounts marked `needsReconnection` return `409` with code `ads_connection_required`. Stop scheduled retries for that account until it is reconnected, then read `GET /v1/accounts` for its current account ID. - For connected accounts, we fetch the latest posts live from the platform, then match and return the submitted post. - Requests are debounced per account (~15s): if the account was synced inside that window, the live fetch is skipped. `accountId` is required, because a post URL or id alone cannot be resolved to an account, and the account must be connected to Zernio (we use its token to read the platform). Supported for every platform with a listing API (Instagram, Facebook, TikTok, YouTube, X, Threads, Pinterest, Reddit, Bluesky, Google Business Profile, and LinkedIn organization accounts). LinkedIn personal profiles: LinkedIn has no listing API for personal profiles, so a `url` is REQUIRED and imports that single post. Pass any LinkedIn post URL (`linkedin.com/posts/…`, `linkedin.com/feed/update/urn:li:activity:…`) or a `urn:li:share:…` / `urn:li:ugcPost:…` URN. Works for posts published outside Zernio and before the account was connected, any age; the post must be authored by the connected member. Imported posts return full analytics (impressions, reach, reactions, comments, reshares, saves) and keep refreshing on the background analytics cycle, but carry no content/media (LinkedIn does not expose them for personal profiles). `url` accepts any format the platform uses (e.g. `instagram.com/p/…`, `instagram.com/reel/…`, `youtu.be/…`, `youtube.com/shorts/…`, `tiktok.com/@user/video/…`, `vm.tiktok.com` short links, `pinterest.com/pin/…` on any regional domain, and `pin.it` short links). Pass `postId` (the platform media/video/pin id) as an alternative locator. Note: post-level analytics (reach, impressions) still carry the platform's own delay (e.g. ~24h on Instagram). This endpoint confirms the post exists and returns its metadata plus basic engagement (likes, comments), not delayed insights.
|
|
2009
2009
|
# @param sync_external_posts_request [SyncExternalPostsRequest]
|
|
2010
2010
|
# @param [Hash] opts the optional parameters
|
|
2011
2011
|
# @return [Array<(SyncExternalPosts200Response, Integer, Hash)>] SyncExternalPosts200Response data, response status code and response headers
|
|
@@ -177,14 +177,14 @@ module Zernio
|
|
|
177
177
|
end
|
|
178
178
|
|
|
179
179
|
# Get post comments
|
|
180
|
-
# Fetch comments for a specific post. Requires accountId query parameter. On Facebook and Instagram, passing a COMMENT id as `postId` is also supported and returns that comment's replies instead of the post's top-level comments. This is not available on YouTube, where `postId` must be a video id. Responses are cached for up to 10 minutes, so a page may lag new comments by that window. Do not poll this endpoint for real-time updates: subscribe to the `comment.received` webhook, which delivers new comments as they arrive. Your own writes (creating, replying to, or deleting a comment) refresh the cache immediately.
|
|
180
|
+
# Fetch comments for a specific post. Requires accountId query parameter. On Facebook and Instagram, passing a COMMENT id as `postId` is also supported and returns that comment's replies instead of the post's top-level comments. This is not available on YouTube, where `postId` must be a video id. Responses are cached for up to 10 minutes, so a page may lag new comments by that window. Do not poll this endpoint for real-time updates: subscribe to the `comment.received` webhook, which delivers new comments as they arrive. Your own writes (creating, replying to, or deleting a comment) refresh the cache immediately. TikTok is served for accounts connected through the TikTok for Business app: `postId` is the TikTok video id, each top-level comment carries up to three inline replies, and `commentId` pages the full reply list of one comment. Developer-app TikTok accounts return 400 with code `PLATFORM_LIMITATION`.
|
|
181
181
|
# @param post_id [String] Zernio post ID or platform-specific post ID. Zernio IDs are auto-resolved. LinkedIn third-party posts accept full activity URN or numeric ID. On Facebook and Instagram, a comment ID is also accepted here and returns that comment's replies.
|
|
182
182
|
# @param account_id [String]
|
|
183
183
|
# @param [Hash] opts the optional parameters
|
|
184
184
|
# @option opts [String] :subreddit (Reddit only) Subreddit name
|
|
185
185
|
# @option opts [Integer] :limit Maximum number of comments to return (default to 25)
|
|
186
186
|
# @option opts [String] :cursor Pagination cursor, returned by a previous call as `pagination.cursor`. This is the platform's own opaque paging value passed through verbatim: never construct, decode or validate it client-side.
|
|
187
|
-
# @option opts [String] :comment_id (Reddit only) Get replies to a specific comment
|
|
187
|
+
# @option opts [String] :comment_id (Reddit and TikTok only) Get replies to a specific comment
|
|
188
188
|
# @return [GetInboxPostComments200Response]
|
|
189
189
|
def get_inbox_post_comments(post_id, account_id, opts = {})
|
|
190
190
|
data, _status_code, _headers = get_inbox_post_comments_with_http_info(post_id, account_id, opts)
|
|
@@ -192,14 +192,14 @@ module Zernio
|
|
|
192
192
|
end
|
|
193
193
|
|
|
194
194
|
# Get post comments
|
|
195
|
-
# Fetch comments for a specific post. Requires accountId query parameter. On Facebook and Instagram, passing a COMMENT id as `postId` is also supported and returns that comment's replies instead of the post's top-level comments. This is not available on YouTube, where `postId` must be a video id. Responses are cached for up to 10 minutes, so a page may lag new comments by that window. Do not poll this endpoint for real-time updates: subscribe to the `comment.received` webhook, which delivers new comments as they arrive. Your own writes (creating, replying to, or deleting a comment) refresh the cache immediately.
|
|
195
|
+
# Fetch comments for a specific post. Requires accountId query parameter. On Facebook and Instagram, passing a COMMENT id as `postId` is also supported and returns that comment's replies instead of the post's top-level comments. This is not available on YouTube, where `postId` must be a video id. Responses are cached for up to 10 minutes, so a page may lag new comments by that window. Do not poll this endpoint for real-time updates: subscribe to the `comment.received` webhook, which delivers new comments as they arrive. Your own writes (creating, replying to, or deleting a comment) refresh the cache immediately. TikTok is served for accounts connected through the TikTok for Business app: `postId` is the TikTok video id, each top-level comment carries up to three inline replies, and `commentId` pages the full reply list of one comment. Developer-app TikTok accounts return 400 with code `PLATFORM_LIMITATION`.
|
|
196
196
|
# @param post_id [String] Zernio post ID or platform-specific post ID. Zernio IDs are auto-resolved. LinkedIn third-party posts accept full activity URN or numeric ID. On Facebook and Instagram, a comment ID is also accepted here and returns that comment's replies.
|
|
197
197
|
# @param account_id [String]
|
|
198
198
|
# @param [Hash] opts the optional parameters
|
|
199
199
|
# @option opts [String] :subreddit (Reddit only) Subreddit name
|
|
200
200
|
# @option opts [Integer] :limit Maximum number of comments to return (default to 25)
|
|
201
201
|
# @option opts [String] :cursor Pagination cursor, returned by a previous call as `pagination.cursor`. This is the platform's own opaque paging value passed through verbatim: never construct, decode or validate it client-side.
|
|
202
|
-
# @option opts [String] :comment_id (Reddit only) Get replies to a specific comment
|
|
202
|
+
# @option opts [String] :comment_id (Reddit and TikTok only) Get replies to a specific comment
|
|
203
203
|
# @return [Array<(GetInboxPostComments200Response, Integer, Hash)>] GetInboxPostComments200Response data, response status code and response headers
|
|
204
204
|
def get_inbox_post_comments_with_http_info(post_id, account_id, opts = {})
|
|
205
205
|
if @api_client.config.debugging
|
|
@@ -267,7 +267,7 @@ module Zernio
|
|
|
267
267
|
end
|
|
268
268
|
|
|
269
269
|
# Hide comment
|
|
270
|
-
# Hide a comment on a post. Supported by Facebook, Instagram, Threads, and
|
|
270
|
+
# Hide a comment on a post. Supported by Facebook, Instagram, Threads, X, and TikTok (accounts connected through the TikTok for Business app). Hidden comments are only visible to the commenter and page admin. For X, the reply must belong to a conversation started by the authenticated user.
|
|
271
271
|
# @param post_id [String]
|
|
272
272
|
# @param comment_id [String]
|
|
273
273
|
# @param hide_inbox_comment_request [HideInboxCommentRequest]
|
|
@@ -279,7 +279,7 @@ module Zernio
|
|
|
279
279
|
end
|
|
280
280
|
|
|
281
281
|
# Hide comment
|
|
282
|
-
# Hide a comment on a post. Supported by Facebook, Instagram, Threads, and
|
|
282
|
+
# Hide a comment on a post. Supported by Facebook, Instagram, Threads, X, and TikTok (accounts connected through the TikTok for Business app). Hidden comments are only visible to the commenter and page admin. For X, the reply must belong to a conversation started by the authenticated user.
|
|
283
283
|
# @param post_id [String]
|
|
284
284
|
# @param comment_id [String]
|
|
285
285
|
# @param hide_inbox_comment_request [HideInboxCommentRequest]
|
|
@@ -608,6 +608,86 @@ module Zernio
|
|
|
608
608
|
return data, status_code, headers
|
|
609
609
|
end
|
|
610
610
|
|
|
611
|
+
# Pin comment
|
|
612
|
+
# Pin a top-level comment to the top of a post's comment section. TikTok accounts connected through the TikTok for Business app only; every other platform returns 400.
|
|
613
|
+
# @param post_id [String]
|
|
614
|
+
# @param comment_id [String]
|
|
615
|
+
# @param pin_inbox_comment_request [PinInboxCommentRequest]
|
|
616
|
+
# @param [Hash] opts the optional parameters
|
|
617
|
+
# @return [PinInboxComment200Response]
|
|
618
|
+
def pin_inbox_comment(post_id, comment_id, pin_inbox_comment_request, opts = {})
|
|
619
|
+
data, _status_code, _headers = pin_inbox_comment_with_http_info(post_id, comment_id, pin_inbox_comment_request, opts)
|
|
620
|
+
data
|
|
621
|
+
end
|
|
622
|
+
|
|
623
|
+
# Pin comment
|
|
624
|
+
# Pin a top-level comment to the top of a post's comment section. TikTok accounts connected through the TikTok for Business app only; every other platform returns 400.
|
|
625
|
+
# @param post_id [String]
|
|
626
|
+
# @param comment_id [String]
|
|
627
|
+
# @param pin_inbox_comment_request [PinInboxCommentRequest]
|
|
628
|
+
# @param [Hash] opts the optional parameters
|
|
629
|
+
# @return [Array<(PinInboxComment200Response, Integer, Hash)>] PinInboxComment200Response data, response status code and response headers
|
|
630
|
+
def pin_inbox_comment_with_http_info(post_id, comment_id, pin_inbox_comment_request, opts = {})
|
|
631
|
+
if @api_client.config.debugging
|
|
632
|
+
@api_client.config.logger.debug 'Calling API: CommentsApi.pin_inbox_comment ...'
|
|
633
|
+
end
|
|
634
|
+
# verify the required parameter 'post_id' is set
|
|
635
|
+
if @api_client.config.client_side_validation && post_id.nil?
|
|
636
|
+
fail ArgumentError, "Missing the required parameter 'post_id' when calling CommentsApi.pin_inbox_comment"
|
|
637
|
+
end
|
|
638
|
+
# verify the required parameter 'comment_id' is set
|
|
639
|
+
if @api_client.config.client_side_validation && comment_id.nil?
|
|
640
|
+
fail ArgumentError, "Missing the required parameter 'comment_id' when calling CommentsApi.pin_inbox_comment"
|
|
641
|
+
end
|
|
642
|
+
# verify the required parameter 'pin_inbox_comment_request' is set
|
|
643
|
+
if @api_client.config.client_side_validation && pin_inbox_comment_request.nil?
|
|
644
|
+
fail ArgumentError, "Missing the required parameter 'pin_inbox_comment_request' when calling CommentsApi.pin_inbox_comment"
|
|
645
|
+
end
|
|
646
|
+
# resource path
|
|
647
|
+
local_var_path = '/v1/inbox/comments/{postId}/{commentId}/pin'.sub('{' + 'postId' + '}', CGI.escape(post_id.to_s)).sub('{' + 'commentId' + '}', CGI.escape(comment_id.to_s))
|
|
648
|
+
|
|
649
|
+
# query parameters
|
|
650
|
+
query_params = opts[:query_params] || {}
|
|
651
|
+
|
|
652
|
+
# header parameters
|
|
653
|
+
header_params = opts[:header_params] || {}
|
|
654
|
+
# HTTP header 'Accept' (if needed)
|
|
655
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
656
|
+
# HTTP header 'Content-Type'
|
|
657
|
+
content_type = @api_client.select_header_content_type(['application/json'])
|
|
658
|
+
if !content_type.nil?
|
|
659
|
+
header_params['Content-Type'] = content_type
|
|
660
|
+
end
|
|
661
|
+
|
|
662
|
+
# form parameters
|
|
663
|
+
form_params = opts[:form_params] || {}
|
|
664
|
+
|
|
665
|
+
# http body (model)
|
|
666
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(pin_inbox_comment_request)
|
|
667
|
+
|
|
668
|
+
# return_type
|
|
669
|
+
return_type = opts[:debug_return_type] || 'PinInboxComment200Response'
|
|
670
|
+
|
|
671
|
+
# auth_names
|
|
672
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
|
673
|
+
|
|
674
|
+
new_options = opts.merge(
|
|
675
|
+
:operation => :"CommentsApi.pin_inbox_comment",
|
|
676
|
+
:header_params => header_params,
|
|
677
|
+
:query_params => query_params,
|
|
678
|
+
:form_params => form_params,
|
|
679
|
+
:body => post_body,
|
|
680
|
+
:auth_names => auth_names,
|
|
681
|
+
:return_type => return_type
|
|
682
|
+
)
|
|
683
|
+
|
|
684
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
|
685
|
+
if @api_client.config.debugging
|
|
686
|
+
@api_client.config.logger.debug "API called: CommentsApi#pin_inbox_comment\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
687
|
+
end
|
|
688
|
+
return data, status_code, headers
|
|
689
|
+
end
|
|
690
|
+
|
|
611
691
|
# Reply to comment
|
|
612
692
|
# Post a reply to a post or specific comment. Requires accountId in request body. **Idempotency:** send an `Idempotency-Key` header to make retries safe (e.g. after a client-side timeout where delivery is unknown): same key + same body replays the original response (with `Idempotent-Replayed: true`) instead of posting the comment a second time; same key + different body returns 422; a key still in flight returns 409. Keys are retained for 24 hours and are scoped to the credential and to this exact path, so reusing a key against a different postId returns 422 rather than replaying the other post's response. Only successful (2xx) responses are stored for replay. If the request throws or returns a non-2xx status the key is released, so the header protects the \"request succeeded but the response was lost\" case. After an ambiguous failure (a 5xx or a network timeout) list the post's comments before retrying with the same key, and treat an empty result as inconclusive rather than as proof nothing was posted.
|
|
613
693
|
# @param post_id [String] Zernio post ID or platform-specific post ID. LinkedIn third-party posts accept full activity URN or numeric ID.
|
|
@@ -850,7 +930,7 @@ module Zernio
|
|
|
850
930
|
end
|
|
851
931
|
|
|
852
932
|
# Unhide comment
|
|
853
|
-
# Unhide a previously hidden comment. Supported by Facebook, Instagram, Threads, and
|
|
933
|
+
# Unhide a previously hidden comment. Supported by Facebook, Instagram, Threads, X, and TikTok (accounts connected through the TikTok for Business app).
|
|
854
934
|
# @param post_id [String]
|
|
855
935
|
# @param comment_id [String]
|
|
856
936
|
# @param account_id [String]
|
|
@@ -862,7 +942,7 @@ module Zernio
|
|
|
862
942
|
end
|
|
863
943
|
|
|
864
944
|
# Unhide comment
|
|
865
|
-
# Unhide a previously hidden comment. Supported by Facebook, Instagram, Threads, and
|
|
945
|
+
# Unhide a previously hidden comment. Supported by Facebook, Instagram, Threads, X, and TikTok (accounts connected through the TikTok for Business app).
|
|
866
946
|
# @param post_id [String]
|
|
867
947
|
# @param comment_id [String]
|
|
868
948
|
# @param account_id [String]
|
|
@@ -1076,5 +1156,81 @@ module Zernio
|
|
|
1076
1156
|
end
|
|
1077
1157
|
return data, status_code, headers
|
|
1078
1158
|
end
|
|
1159
|
+
|
|
1160
|
+
# Unpin comment
|
|
1161
|
+
# Unpin a previously pinned comment. TikTok accounts connected through the TikTok for Business app only.
|
|
1162
|
+
# @param post_id [String]
|
|
1163
|
+
# @param comment_id [String]
|
|
1164
|
+
# @param account_id [String]
|
|
1165
|
+
# @param [Hash] opts the optional parameters
|
|
1166
|
+
# @return [PinInboxComment200Response]
|
|
1167
|
+
def unpin_inbox_comment(post_id, comment_id, account_id, opts = {})
|
|
1168
|
+
data, _status_code, _headers = unpin_inbox_comment_with_http_info(post_id, comment_id, account_id, opts)
|
|
1169
|
+
data
|
|
1170
|
+
end
|
|
1171
|
+
|
|
1172
|
+
# Unpin comment
|
|
1173
|
+
# Unpin a previously pinned comment. TikTok accounts connected through the TikTok for Business app only.
|
|
1174
|
+
# @param post_id [String]
|
|
1175
|
+
# @param comment_id [String]
|
|
1176
|
+
# @param account_id [String]
|
|
1177
|
+
# @param [Hash] opts the optional parameters
|
|
1178
|
+
# @return [Array<(PinInboxComment200Response, Integer, Hash)>] PinInboxComment200Response data, response status code and response headers
|
|
1179
|
+
def unpin_inbox_comment_with_http_info(post_id, comment_id, account_id, opts = {})
|
|
1180
|
+
if @api_client.config.debugging
|
|
1181
|
+
@api_client.config.logger.debug 'Calling API: CommentsApi.unpin_inbox_comment ...'
|
|
1182
|
+
end
|
|
1183
|
+
# verify the required parameter 'post_id' is set
|
|
1184
|
+
if @api_client.config.client_side_validation && post_id.nil?
|
|
1185
|
+
fail ArgumentError, "Missing the required parameter 'post_id' when calling CommentsApi.unpin_inbox_comment"
|
|
1186
|
+
end
|
|
1187
|
+
# verify the required parameter 'comment_id' is set
|
|
1188
|
+
if @api_client.config.client_side_validation && comment_id.nil?
|
|
1189
|
+
fail ArgumentError, "Missing the required parameter 'comment_id' when calling CommentsApi.unpin_inbox_comment"
|
|
1190
|
+
end
|
|
1191
|
+
# verify the required parameter 'account_id' is set
|
|
1192
|
+
if @api_client.config.client_side_validation && account_id.nil?
|
|
1193
|
+
fail ArgumentError, "Missing the required parameter 'account_id' when calling CommentsApi.unpin_inbox_comment"
|
|
1194
|
+
end
|
|
1195
|
+
# resource path
|
|
1196
|
+
local_var_path = '/v1/inbox/comments/{postId}/{commentId}/pin'.sub('{' + 'postId' + '}', CGI.escape(post_id.to_s)).sub('{' + 'commentId' + '}', CGI.escape(comment_id.to_s))
|
|
1197
|
+
|
|
1198
|
+
# query parameters
|
|
1199
|
+
query_params = opts[:query_params] || {}
|
|
1200
|
+
query_params[:'accountId'] = account_id
|
|
1201
|
+
|
|
1202
|
+
# header parameters
|
|
1203
|
+
header_params = opts[:header_params] || {}
|
|
1204
|
+
# HTTP header 'Accept' (if needed)
|
|
1205
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json']) unless header_params['Accept']
|
|
1206
|
+
|
|
1207
|
+
# form parameters
|
|
1208
|
+
form_params = opts[:form_params] || {}
|
|
1209
|
+
|
|
1210
|
+
# http body (model)
|
|
1211
|
+
post_body = opts[:debug_body]
|
|
1212
|
+
|
|
1213
|
+
# return_type
|
|
1214
|
+
return_type = opts[:debug_return_type] || 'PinInboxComment200Response'
|
|
1215
|
+
|
|
1216
|
+
# auth_names
|
|
1217
|
+
auth_names = opts[:debug_auth_names] || ['bearerAuth']
|
|
1218
|
+
|
|
1219
|
+
new_options = opts.merge(
|
|
1220
|
+
:operation => :"CommentsApi.unpin_inbox_comment",
|
|
1221
|
+
:header_params => header_params,
|
|
1222
|
+
:query_params => query_params,
|
|
1223
|
+
:form_params => form_params,
|
|
1224
|
+
:body => post_body,
|
|
1225
|
+
:auth_names => auth_names,
|
|
1226
|
+
:return_type => return_type
|
|
1227
|
+
)
|
|
1228
|
+
|
|
1229
|
+
data, status_code, headers = @api_client.call_api(:DELETE, local_var_path, new_options)
|
|
1230
|
+
if @api_client.config.debugging
|
|
1231
|
+
@api_client.config.logger.debug "API called: CommentsApi#unpin_inbox_comment\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
1232
|
+
end
|
|
1233
|
+
return data, status_code, headers
|
|
1234
|
+
end
|
|
1079
1235
|
end
|
|
1080
1236
|
end
|