zernio-sdk 0.0.784 → 0.0.786
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/docs/CommentsApi.md +9 -5
- data/docs/ReviewsApi.md +9 -5
- data/lib/zernio-sdk/api/comments_api.rb +9 -2
- data/lib/zernio-sdk/api/reviews_api.rb +9 -2
- data/lib/zernio-sdk/version.rb +1 -1
- data/openapi.yaml +43 -3
- data/spec/api/comments_api_spec.rb +2 -1
- data/spec/api/reviews_api_spec.rb +2 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: e70db227d77b0022f2479e97c89b45ae0fafd9de3a671089251aa2aea36db7db
|
|
4
|
+
data.tar.gz: c07a16a15d790252b2cffdffcc4e97ff13ad5ee2753cbb72d6323fbb46b498ca
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 8d341798bd632d644c9dcd9ddb3b990af1c26ac3025ed16a8727e0a1e9d03e8d31dd39eaad6ae0ad8beafdd10cc07873d3f3dc9634a27fb27cf8369d98c6ba36
|
|
7
|
+
data.tar.gz: 1d5dd020710394301785a45933b011304dd615e43cb736404e2f071f491e046c994330fa9161bc96ff8399c53df16ee8c1e4e64b0fbfafaacc34395e929ca2c2
|
data/docs/CommentsApi.md
CHANGED
|
@@ -552,11 +552,11 @@ end
|
|
|
552
552
|
|
|
553
553
|
## reply_to_inbox_post
|
|
554
554
|
|
|
555
|
-
> <ReplyToInboxPost200Response> reply_to_inbox_post(post_id, reply_to_inbox_post_request)
|
|
555
|
+
> <ReplyToInboxPost200Response> reply_to_inbox_post(post_id, reply_to_inbox_post_request, opts)
|
|
556
556
|
|
|
557
557
|
Reply to comment
|
|
558
558
|
|
|
559
|
-
Post a reply to a post or specific comment. Requires accountId in request body.
|
|
559
|
+
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.
|
|
560
560
|
|
|
561
561
|
### Examples
|
|
562
562
|
|
|
@@ -572,10 +572,13 @@ end
|
|
|
572
572
|
api_instance = Zernio::CommentsApi.new
|
|
573
573
|
post_id = 'post_id_example' # String | Zernio post ID or platform-specific post ID. LinkedIn third-party posts accept full activity URN or numeric ID.
|
|
574
574
|
reply_to_inbox_post_request = Zernio::ReplyToInboxPostRequest.new({account_id: 'account_id_example', message: 'message_example'}) # ReplyToInboxPostRequest |
|
|
575
|
+
opts = {
|
|
576
|
+
idempotency_key: 'idempotency_key_example' # String | Optional client-generated unique key (e.g. a UUID) that makes retries safe. Same key + same body replays the original response; same key + different body → 422; key still processing → 409.
|
|
577
|
+
}
|
|
575
578
|
|
|
576
579
|
begin
|
|
577
580
|
# Reply to comment
|
|
578
|
-
result = api_instance.reply_to_inbox_post(post_id, reply_to_inbox_post_request)
|
|
581
|
+
result = api_instance.reply_to_inbox_post(post_id, reply_to_inbox_post_request, opts)
|
|
579
582
|
p result
|
|
580
583
|
rescue Zernio::ApiError => e
|
|
581
584
|
puts "Error when calling CommentsApi->reply_to_inbox_post: #{e}"
|
|
@@ -586,12 +589,12 @@ end
|
|
|
586
589
|
|
|
587
590
|
This returns an Array which contains the response data, status code and headers.
|
|
588
591
|
|
|
589
|
-
> <Array(<ReplyToInboxPost200Response>, Integer, Hash)> reply_to_inbox_post_with_http_info(post_id, reply_to_inbox_post_request)
|
|
592
|
+
> <Array(<ReplyToInboxPost200Response>, Integer, Hash)> reply_to_inbox_post_with_http_info(post_id, reply_to_inbox_post_request, opts)
|
|
590
593
|
|
|
591
594
|
```ruby
|
|
592
595
|
begin
|
|
593
596
|
# Reply to comment
|
|
594
|
-
data, status_code, headers = api_instance.reply_to_inbox_post_with_http_info(post_id, reply_to_inbox_post_request)
|
|
597
|
+
data, status_code, headers = api_instance.reply_to_inbox_post_with_http_info(post_id, reply_to_inbox_post_request, opts)
|
|
595
598
|
p status_code # => 2xx
|
|
596
599
|
p headers # => { ... }
|
|
597
600
|
p data # => <ReplyToInboxPost200Response>
|
|
@@ -606,6 +609,7 @@ end
|
|
|
606
609
|
| ---- | ---- | ----------- | ----- |
|
|
607
610
|
| **post_id** | **String** | Zernio post ID or platform-specific post ID. LinkedIn third-party posts accept full activity URN or numeric ID. | |
|
|
608
611
|
| **reply_to_inbox_post_request** | [**ReplyToInboxPostRequest**](ReplyToInboxPostRequest.md) | | |
|
|
612
|
+
| **idempotency_key** | **String** | Optional client-generated unique key (e.g. a UUID) that makes retries safe. Same key + same body replays the original response; same key + different body → 422; key still processing → 409. | [optional] |
|
|
609
613
|
|
|
610
614
|
### Return type
|
|
611
615
|
|
data/docs/ReviewsApi.md
CHANGED
|
@@ -171,11 +171,11 @@ end
|
|
|
171
171
|
|
|
172
172
|
## reply_to_inbox_review
|
|
173
173
|
|
|
174
|
-
> <ReplyToInboxReview200Response> reply_to_inbox_review(review_id, reply_to_inbox_review_request)
|
|
174
|
+
> <ReplyToInboxReview200Response> reply_to_inbox_review(review_id, reply_to_inbox_review_request, opts)
|
|
175
175
|
|
|
176
176
|
Reply to review
|
|
177
177
|
|
|
178
|
-
Post a reply to a review. Requires accountId in request body.
|
|
178
|
+
Post a reply to a review. 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 sending the reply to the platform again; 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 reviewId returns 422 rather than replaying the other review'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) fetch the review before retrying with the same key, and treat a missing reply as inconclusive rather than as proof nothing was sent.
|
|
179
179
|
|
|
180
180
|
### Examples
|
|
181
181
|
|
|
@@ -191,10 +191,13 @@ end
|
|
|
191
191
|
api_instance = Zernio::ReviewsApi.new
|
|
192
192
|
review_id = 'review_id_example' # String | Review ID (URL-encoded for Google Business)
|
|
193
193
|
reply_to_inbox_review_request = Zernio::ReplyToInboxReviewRequest.new({account_id: 'account_id_example', message: 'message_example'}) # ReplyToInboxReviewRequest |
|
|
194
|
+
opts = {
|
|
195
|
+
idempotency_key: 'idempotency_key_example' # String | Optional client-generated unique key (e.g. a UUID) that makes retries safe. Same key + same body replays the original response; same key + different body → 422; key still processing → 409.
|
|
196
|
+
}
|
|
194
197
|
|
|
195
198
|
begin
|
|
196
199
|
# Reply to review
|
|
197
|
-
result = api_instance.reply_to_inbox_review(review_id, reply_to_inbox_review_request)
|
|
200
|
+
result = api_instance.reply_to_inbox_review(review_id, reply_to_inbox_review_request, opts)
|
|
198
201
|
p result
|
|
199
202
|
rescue Zernio::ApiError => e
|
|
200
203
|
puts "Error when calling ReviewsApi->reply_to_inbox_review: #{e}"
|
|
@@ -205,12 +208,12 @@ end
|
|
|
205
208
|
|
|
206
209
|
This returns an Array which contains the response data, status code and headers.
|
|
207
210
|
|
|
208
|
-
> <Array(<ReplyToInboxReview200Response>, Integer, Hash)> reply_to_inbox_review_with_http_info(review_id, reply_to_inbox_review_request)
|
|
211
|
+
> <Array(<ReplyToInboxReview200Response>, Integer, Hash)> reply_to_inbox_review_with_http_info(review_id, reply_to_inbox_review_request, opts)
|
|
209
212
|
|
|
210
213
|
```ruby
|
|
211
214
|
begin
|
|
212
215
|
# Reply to review
|
|
213
|
-
data, status_code, headers = api_instance.reply_to_inbox_review_with_http_info(review_id, reply_to_inbox_review_request)
|
|
216
|
+
data, status_code, headers = api_instance.reply_to_inbox_review_with_http_info(review_id, reply_to_inbox_review_request, opts)
|
|
214
217
|
p status_code # => 2xx
|
|
215
218
|
p headers # => { ... }
|
|
216
219
|
p data # => <ReplyToInboxReview200Response>
|
|
@@ -225,6 +228,7 @@ end
|
|
|
225
228
|
| ---- | ---- | ----------- | ----- |
|
|
226
229
|
| **review_id** | **String** | Review ID (URL-encoded for Google Business) | |
|
|
227
230
|
| **reply_to_inbox_review_request** | [**ReplyToInboxReviewRequest**](ReplyToInboxReviewRequest.md) | | |
|
|
231
|
+
| **idempotency_key** | **String** | Optional client-generated unique key (e.g. a UUID) that makes retries safe. Same key + same body replays the original response; same key + different body → 422; key still processing → 409. | [optional] |
|
|
228
232
|
|
|
229
233
|
### Return type
|
|
230
234
|
|
|
@@ -609,10 +609,11 @@ module Zernio
|
|
|
609
609
|
end
|
|
610
610
|
|
|
611
611
|
# Reply to comment
|
|
612
|
-
# Post a reply to a post or specific comment. Requires accountId in request body.
|
|
612
|
+
# 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
613
|
# @param post_id [String] Zernio post ID or platform-specific post ID. LinkedIn third-party posts accept full activity URN or numeric ID.
|
|
614
614
|
# @param reply_to_inbox_post_request [ReplyToInboxPostRequest]
|
|
615
615
|
# @param [Hash] opts the optional parameters
|
|
616
|
+
# @option opts [String] :idempotency_key Optional client-generated unique key (e.g. a UUID) that makes retries safe. Same key + same body replays the original response; same key + different body → 422; key still processing → 409.
|
|
616
617
|
# @return [ReplyToInboxPost200Response]
|
|
617
618
|
def reply_to_inbox_post(post_id, reply_to_inbox_post_request, opts = {})
|
|
618
619
|
data, _status_code, _headers = reply_to_inbox_post_with_http_info(post_id, reply_to_inbox_post_request, opts)
|
|
@@ -620,10 +621,11 @@ module Zernio
|
|
|
620
621
|
end
|
|
621
622
|
|
|
622
623
|
# Reply to comment
|
|
623
|
-
# Post a reply to a post or specific comment. Requires accountId in request body.
|
|
624
|
+
# 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.
|
|
624
625
|
# @param post_id [String] Zernio post ID or platform-specific post ID. LinkedIn third-party posts accept full activity URN or numeric ID.
|
|
625
626
|
# @param reply_to_inbox_post_request [ReplyToInboxPostRequest]
|
|
626
627
|
# @param [Hash] opts the optional parameters
|
|
628
|
+
# @option opts [String] :idempotency_key Optional client-generated unique key (e.g. a UUID) that makes retries safe. Same key + same body replays the original response; same key + different body → 422; key still processing → 409.
|
|
627
629
|
# @return [Array<(ReplyToInboxPost200Response, Integer, Hash)>] ReplyToInboxPost200Response data, response status code and response headers
|
|
628
630
|
def reply_to_inbox_post_with_http_info(post_id, reply_to_inbox_post_request, opts = {})
|
|
629
631
|
if @api_client.config.debugging
|
|
@@ -637,6 +639,10 @@ module Zernio
|
|
|
637
639
|
if @api_client.config.client_side_validation && reply_to_inbox_post_request.nil?
|
|
638
640
|
fail ArgumentError, "Missing the required parameter 'reply_to_inbox_post_request' when calling CommentsApi.reply_to_inbox_post"
|
|
639
641
|
end
|
|
642
|
+
if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length > 255
|
|
643
|
+
fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling CommentsApi.reply_to_inbox_post, the character length must be smaller than or equal to 255.'
|
|
644
|
+
end
|
|
645
|
+
|
|
640
646
|
# resource path
|
|
641
647
|
local_var_path = '/v1/inbox/comments/{postId}'.sub('{' + 'postId' + '}', CGI.escape(post_id.to_s))
|
|
642
648
|
|
|
@@ -652,6 +658,7 @@ module Zernio
|
|
|
652
658
|
if !content_type.nil?
|
|
653
659
|
header_params['Content-Type'] = content_type
|
|
654
660
|
end
|
|
661
|
+
header_params[:'Idempotency-Key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
|
|
655
662
|
|
|
656
663
|
# form parameters
|
|
657
664
|
form_params = opts[:form_params] || {}
|
|
@@ -217,10 +217,11 @@ module Zernio
|
|
|
217
217
|
end
|
|
218
218
|
|
|
219
219
|
# Reply to review
|
|
220
|
-
# Post a reply to a review. Requires accountId in request body.
|
|
220
|
+
# Post a reply to a review. 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 sending the reply to the platform again; 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 reviewId returns 422 rather than replaying the other review'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) fetch the review before retrying with the same key, and treat a missing reply as inconclusive rather than as proof nothing was sent.
|
|
221
221
|
# @param review_id [String] Review ID (URL-encoded for Google Business)
|
|
222
222
|
# @param reply_to_inbox_review_request [ReplyToInboxReviewRequest]
|
|
223
223
|
# @param [Hash] opts the optional parameters
|
|
224
|
+
# @option opts [String] :idempotency_key Optional client-generated unique key (e.g. a UUID) that makes retries safe. Same key + same body replays the original response; same key + different body → 422; key still processing → 409.
|
|
224
225
|
# @return [ReplyToInboxReview200Response]
|
|
225
226
|
def reply_to_inbox_review(review_id, reply_to_inbox_review_request, opts = {})
|
|
226
227
|
data, _status_code, _headers = reply_to_inbox_review_with_http_info(review_id, reply_to_inbox_review_request, opts)
|
|
@@ -228,10 +229,11 @@ module Zernio
|
|
|
228
229
|
end
|
|
229
230
|
|
|
230
231
|
# Reply to review
|
|
231
|
-
# Post a reply to a review. Requires accountId in request body.
|
|
232
|
+
# Post a reply to a review. 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 sending the reply to the platform again; 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 reviewId returns 422 rather than replaying the other review'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) fetch the review before retrying with the same key, and treat a missing reply as inconclusive rather than as proof nothing was sent.
|
|
232
233
|
# @param review_id [String] Review ID (URL-encoded for Google Business)
|
|
233
234
|
# @param reply_to_inbox_review_request [ReplyToInboxReviewRequest]
|
|
234
235
|
# @param [Hash] opts the optional parameters
|
|
236
|
+
# @option opts [String] :idempotency_key Optional client-generated unique key (e.g. a UUID) that makes retries safe. Same key + same body replays the original response; same key + different body → 422; key still processing → 409.
|
|
235
237
|
# @return [Array<(ReplyToInboxReview200Response, Integer, Hash)>] ReplyToInboxReview200Response data, response status code and response headers
|
|
236
238
|
def reply_to_inbox_review_with_http_info(review_id, reply_to_inbox_review_request, opts = {})
|
|
237
239
|
if @api_client.config.debugging
|
|
@@ -245,6 +247,10 @@ module Zernio
|
|
|
245
247
|
if @api_client.config.client_side_validation && reply_to_inbox_review_request.nil?
|
|
246
248
|
fail ArgumentError, "Missing the required parameter 'reply_to_inbox_review_request' when calling ReviewsApi.reply_to_inbox_review"
|
|
247
249
|
end
|
|
250
|
+
if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length > 255
|
|
251
|
+
fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling ReviewsApi.reply_to_inbox_review, the character length must be smaller than or equal to 255.'
|
|
252
|
+
end
|
|
253
|
+
|
|
248
254
|
# resource path
|
|
249
255
|
local_var_path = '/v1/inbox/reviews/{reviewId}/reply'.sub('{' + 'reviewId' + '}', CGI.escape(review_id.to_s))
|
|
250
256
|
|
|
@@ -260,6 +266,7 @@ module Zernio
|
|
|
260
266
|
if !content_type.nil?
|
|
261
267
|
header_params['Content-Type'] = content_type
|
|
262
268
|
end
|
|
269
|
+
header_params[:'Idempotency-Key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
|
|
263
270
|
|
|
264
271
|
# form parameters
|
|
265
272
|
form_params = opts[:form_params] || {}
|
data/lib/zernio-sdk/version.rb
CHANGED
data/openapi.yaml
CHANGED
|
@@ -546,7 +546,7 @@ components:
|
|
|
546
546
|
IdempotencyKeyInFlight:
|
|
547
547
|
description: Same Idempotency-Key still processing; retry after a short backoff
|
|
548
548
|
IdempotencyKeyReused:
|
|
549
|
-
description: Idempotency-Key reused with a different
|
|
549
|
+
description: Idempotency-Key reused with a different request
|
|
550
550
|
BadRequest:
|
|
551
551
|
description: Invalid request
|
|
552
552
|
content:
|
|
@@ -28262,7 +28262,24 @@ paths:
|
|
|
28262
28262
|
x-resource-group: "engagement"
|
|
28263
28263
|
operationId: replyToInboxPost
|
|
28264
28264
|
summary: Reply to comment
|
|
28265
|
-
description:
|
|
28265
|
+
description: |
|
|
28266
|
+
Post a reply to a post or specific comment. Requires accountId in request body.
|
|
28267
|
+
|
|
28268
|
+
**Idempotency:** send an `Idempotency-Key` header to make retries safe
|
|
28269
|
+
(e.g. after a client-side timeout where delivery is unknown): same key +
|
|
28270
|
+
same body replays the original response (with `Idempotent-Replayed: true`)
|
|
28271
|
+
instead of posting the comment a second time; same key + different body
|
|
28272
|
+
returns 422; a key still in flight returns 409. Keys are retained for 24
|
|
28273
|
+
hours and are scoped to the credential and to this exact path, so reusing
|
|
28274
|
+
a key against a different postId returns 422 rather than replaying the
|
|
28275
|
+
other post's response.
|
|
28276
|
+
|
|
28277
|
+
Only successful (2xx) responses are stored for replay. If the request
|
|
28278
|
+
throws or returns a non-2xx status the key is released, so the header
|
|
28279
|
+
protects the "request succeeded but the response was lost" case. After an
|
|
28280
|
+
ambiguous failure (a 5xx or a network timeout) list the post's comments
|
|
28281
|
+
before retrying with the same key, and treat an empty result as
|
|
28282
|
+
inconclusive rather than as proof nothing was posted.
|
|
28266
28283
|
tags: [Comments]
|
|
28267
28284
|
security: [{ bearerAuth: [] }]
|
|
28268
28285
|
parameters:
|
|
@@ -28271,6 +28288,7 @@ paths:
|
|
|
28271
28288
|
required: true
|
|
28272
28289
|
description: Zernio post ID or platform-specific post ID. LinkedIn third-party posts accept full activity URN or numeric ID.
|
|
28273
28290
|
schema: { type: string }
|
|
28291
|
+
- $ref: '#/components/parameters/IdempotencyKeyHeader'
|
|
28274
28292
|
requestBody:
|
|
28275
28293
|
required: true
|
|
28276
28294
|
content:
|
|
@@ -28309,6 +28327,8 @@ paths:
|
|
|
28309
28327
|
'401': { $ref: '#/components/responses/Unauthorized' }
|
|
28310
28328
|
'403':
|
|
28311
28329
|
description: 'Inbox addon required, or the connected account is not permitted to comment on this post on the platform (code platform_api_error, type platform_error)'
|
|
28330
|
+
'409': { $ref: '#/components/responses/IdempotencyKeyInFlight' }
|
|
28331
|
+
'422': { $ref: '#/components/responses/IdempotencyKeyReused' }
|
|
28312
28332
|
'429': { $ref: '#/components/responses/RateLimited' }
|
|
28313
28333
|
'502':
|
|
28314
28334
|
description: 'Upstream platform error (code platform_api_error, type platform_error)'
|
|
@@ -29684,7 +29704,24 @@ paths:
|
|
|
29684
29704
|
x-resource-group: "engagement"
|
|
29685
29705
|
operationId: replyToInboxReview
|
|
29686
29706
|
summary: Reply to review
|
|
29687
|
-
description:
|
|
29707
|
+
description: |
|
|
29708
|
+
Post a reply to a review. Requires accountId in request body.
|
|
29709
|
+
|
|
29710
|
+
**Idempotency:** send an `Idempotency-Key` header to make retries safe
|
|
29711
|
+
(e.g. after a client-side timeout where delivery is unknown): same key +
|
|
29712
|
+
same body replays the original response (with `Idempotent-Replayed: true`)
|
|
29713
|
+
instead of sending the reply to the platform again; same key + different
|
|
29714
|
+
body returns 422; a key still in flight returns 409. Keys are retained for
|
|
29715
|
+
24 hours and are scoped to the credential and to this exact path, so
|
|
29716
|
+
reusing a key against a different reviewId returns 422 rather than
|
|
29717
|
+
replaying the other review's response.
|
|
29718
|
+
|
|
29719
|
+
Only successful (2xx) responses are stored for replay. If the request
|
|
29720
|
+
throws or returns a non-2xx status the key is released, so the header
|
|
29721
|
+
protects the "request succeeded but the response was lost" case. After an
|
|
29722
|
+
ambiguous failure (a 5xx or a network timeout) fetch the review before
|
|
29723
|
+
retrying with the same key, and treat a missing reply as inconclusive
|
|
29724
|
+
rather than as proof nothing was sent.
|
|
29688
29725
|
tags: [Reviews]
|
|
29689
29726
|
security: [{ bearerAuth: [] }]
|
|
29690
29727
|
parameters:
|
|
@@ -29693,6 +29730,7 @@ paths:
|
|
|
29693
29730
|
required: true
|
|
29694
29731
|
schema: { type: string }
|
|
29695
29732
|
description: Review ID (URL-encoded for Google Business)
|
|
29733
|
+
- $ref: '#/components/parameters/IdempotencyKeyHeader'
|
|
29696
29734
|
requestBody:
|
|
29697
29735
|
required: true
|
|
29698
29736
|
content:
|
|
@@ -29722,6 +29760,8 @@ paths:
|
|
|
29722
29760
|
'401': { $ref: '#/components/responses/Unauthorized' }
|
|
29723
29761
|
'403':
|
|
29724
29762
|
description: Inbox addon required
|
|
29763
|
+
'409': { $ref: '#/components/responses/IdempotencyKeyInFlight' }
|
|
29764
|
+
'422': { $ref: '#/components/responses/IdempotencyKeyReused' }
|
|
29725
29765
|
delete:
|
|
29726
29766
|
x-resource-group: "engagement"
|
|
29727
29767
|
operationId: deleteInboxReviewReply
|
|
@@ -140,10 +140,11 @@ describe 'CommentsApi' do
|
|
|
140
140
|
|
|
141
141
|
# unit tests for reply_to_inbox_post
|
|
142
142
|
# Reply to comment
|
|
143
|
-
# Post a reply to a post or specific comment. Requires accountId in request body.
|
|
143
|
+
# 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.
|
|
144
144
|
# @param post_id Zernio post ID or platform-specific post ID. LinkedIn third-party posts accept full activity URN or numeric ID.
|
|
145
145
|
# @param reply_to_inbox_post_request
|
|
146
146
|
# @param [Hash] opts the optional parameters
|
|
147
|
+
# @option opts [String] :idempotency_key Optional client-generated unique key (e.g. a UUID) that makes retries safe. Same key + same body replays the original response; same key + different body → 422; key still processing → 409.
|
|
147
148
|
# @return [ReplyToInboxPost200Response]
|
|
148
149
|
describe 'reply_to_inbox_post test' do
|
|
149
150
|
it 'should work' do
|
|
@@ -68,10 +68,11 @@ describe 'ReviewsApi' do
|
|
|
68
68
|
|
|
69
69
|
# unit tests for reply_to_inbox_review
|
|
70
70
|
# Reply to review
|
|
71
|
-
# Post a reply to a review. Requires accountId in request body.
|
|
71
|
+
# Post a reply to a review. 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 sending the reply to the platform again; 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 reviewId returns 422 rather than replaying the other review'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) fetch the review before retrying with the same key, and treat a missing reply as inconclusive rather than as proof nothing was sent.
|
|
72
72
|
# @param review_id Review ID (URL-encoded for Google Business)
|
|
73
73
|
# @param reply_to_inbox_review_request
|
|
74
74
|
# @param [Hash] opts the optional parameters
|
|
75
|
+
# @option opts [String] :idempotency_key Optional client-generated unique key (e.g. a UUID) that makes retries safe. Same key + same body replays the original response; same key + different body → 422; key still processing → 409.
|
|
75
76
|
# @return [ReplyToInboxReview200Response]
|
|
76
77
|
describe 'reply_to_inbox_review test' do
|
|
77
78
|
it 'should work' do
|