seatschart 0.1.0

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.
Files changed (168) hide show
  1. checksums.yaml +7 -0
  2. data/LICENSE +21 -0
  3. data/README.md +552 -0
  4. data/lib/seatschart/api/api_keys_api.rb +364 -0
  5. data/lib/seatschart/api/assets_api.rb +95 -0
  6. data/lib/seatschart/api/audit_api.rb +88 -0
  7. data/lib/seatschart/api/auth_api.rb +1187 -0
  8. data/lib/seatschart/api/billing_api.rb +355 -0
  9. data/lib/seatschart/api/charts_api.rb +4195 -0
  10. data/lib/seatschart/api/default_api.rb +763 -0
  11. data/lib/seatschart/api/embed_api.rb +407 -0
  12. data/lib/seatschart/api/embed_origins_api.rb +281 -0
  13. data/lib/seatschart/api/event_log_api.rb +148 -0
  14. data/lib/seatschart/api/events_api.rb +6608 -0
  15. data/lib/seatschart/api/health_api.rb +77 -0
  16. data/lib/seatschart/api/map_designer_api.rb +135 -0
  17. data/lib/seatschart/api/object_status_api.rb +805 -0
  18. data/lib/seatschart/api/orders_api.rb +166 -0
  19. data/lib/seatschart/api/public_api.rb +455 -0
  20. data/lib/seatschart/api/quotes_api.rb +103 -0
  21. data/lib/seatschart/api/seasons_api.rb +5543 -0
  22. data/lib/seatschart/api/seats_api.rb +1103 -0
  23. data/lib/seatschart/api/sse_api.rb +83 -0
  24. data/lib/seatschart/api/team_api.rb +428 -0
  25. data/lib/seatschart/api/usage_api.rb +540 -0
  26. data/lib/seatschart/api/webhooks_api.rb +771 -0
  27. data/lib/seatschart/api/workspace_api.rb +1244 -0
  28. data/lib/seatschart/api_client.rb +394 -0
  29. data/lib/seatschart/api_error.rb +58 -0
  30. data/lib/seatschart/configuration.rb +316 -0
  31. data/lib/seatschart/models/delete_api_workspaces_by_workspace_id200_response.rb +283 -0
  32. data/lib/seatschart/models/get_api_charts_by_chart_id_versions200_response.rb +247 -0
  33. data/lib/seatschart/models/get_api_charts_by_chart_id_versions200_response_items_inner.rb +473 -0
  34. data/lib/seatschart/models/get_api_charts_by_chart_id_versions200_response_items_inner_published_by.rb +280 -0
  35. data/lib/seatschart/models/get_api_events_by_event_id_map_versions200_response.rb +247 -0
  36. data/lib/seatschart/models/get_api_events_by_event_id_map_versions200_response_items_inner.rb +444 -0
  37. data/lib/seatschart/models/get_api_events_by_event_id_seat_views200_response.rb +267 -0
  38. data/lib/seatschart/models/get_api_events_by_event_id_seat_views200_response_views_value.rb +273 -0
  39. data/lib/seatschart/models/get_api_events_by_event_id_seat_views404_response.rb +237 -0
  40. data/lib/seatschart/models/get_api_monitoring_requests200_response.rb +388 -0
  41. data/lib/seatschart/models/get_api_monitoring_requests200_response_lanes.rb +237 -0
  42. data/lib/seatschart/models/get_api_monitoring_requests200_response_lanes_sales.rb +256 -0
  43. data/lib/seatschart/models/get_api_monitoring_requests200_response_points_inner.rb +286 -0
  44. data/lib/seatschart/models/get_api_workspace_integration200_response.rb +287 -0
  45. data/lib/seatschart/models/get_api_workspace_settings200_response.rb +329 -0
  46. data/lib/seatschart/models/get_api_workspace_settings200_response_bounds.rb +237 -0
  47. data/lib/seatschart/models/get_api_workspace_settings200_response_bounds_hold_period_minutes.rb +237 -0
  48. data/lib/seatschart/models/get_api_workspace_settings200_response_effective.rb +269 -0
  49. data/lib/seatschart/models/get_api_workspace_settings200_response_overrides.rb +241 -0
  50. data/lib/seatschart/models/get_api_workspace_settings200_response_sources.rb +339 -0
  51. data/lib/seatschart/models/get_api_workspaces200_response.rb +223 -0
  52. data/lib/seatschart/models/get_api_workspaces200_response_items_inner.rb +423 -0
  53. data/lib/seatschart/models/patch_api_charts_by_chart_id_categories_by_category_id_request.rb +304 -0
  54. data/lib/seatschart/models/patch_api_charts_by_chart_id_request.rb +288 -0
  55. data/lib/seatschart/models/patch_api_events_by_event_id_inventory_channels_by_channel_key_id_request.rb +272 -0
  56. data/lib/seatschart/models/patch_api_events_by_event_id_request.rb +448 -0
  57. data/lib/seatschart/models/patch_api_events_by_event_id_request_categories_inner.rb +343 -0
  58. data/lib/seatschart/models/patch_api_events_by_event_id_request_table_booking_config.rb +266 -0
  59. data/lib/seatschart/models/patch_api_keys_by_id_request.rb +292 -0
  60. data/lib/seatschart/models/patch_api_seasons_by_season_id_events_by_event_id_request.rb +221 -0
  61. data/lib/seatschart/models/patch_api_seasons_by_season_id_request.rb +276 -0
  62. data/lib/seatschart/models/patch_api_team_members_by_user_id_request.rb +255 -0
  63. data/lib/seatschart/models/patch_api_webhooks_by_id_request.rb +291 -0
  64. data/lib/seatschart/models/patch_api_workspace_chart_validation_request.rb +224 -0
  65. data/lib/seatschart/models/patch_api_workspace_chart_validation_request_severities.rb +543 -0
  66. data/lib/seatschart/models/patch_api_workspace_integration_request.rb +257 -0
  67. data/lib/seatschart/models/patch_api_workspace_request.rb +249 -0
  68. data/lib/seatschart/models/patch_api_workspace_settings_request.rb +307 -0
  69. data/lib/seatschart/models/post_api_auth2fa_disable_request.rb +281 -0
  70. data/lib/seatschart/models/post_api_auth2fa_enable_request.rb +250 -0
  71. data/lib/seatschart/models/post_api_auth2fa_enroll_confirm_request.rb +295 -0
  72. data/lib/seatschart/models/post_api_auth2fa_enroll_start_request.rb +250 -0
  73. data/lib/seatschart/models/post_api_auth2fa_verify_request.rb +326 -0
  74. data/lib/seatschart/models/post_api_auth_accept_invite_request.rb +293 -0
  75. data/lib/seatschart/models/post_api_auth_login_request.rb +293 -0
  76. data/lib/seatschart/models/post_api_auth_logout_request.rb +242 -0
  77. data/lib/seatschart/models/post_api_auth_refresh_request.rb +292 -0
  78. data/lib/seatschart/models/post_api_auth_signup_request.rb +321 -0
  79. data/lib/seatschart/models/post_api_auth_switch_workspace_request.rb +249 -0
  80. data/lib/seatschart/models/post_api_billing_checkout_session_request.rb +249 -0
  81. data/lib/seatschart/models/post_api_billing_confirm_checkout_request.rb +249 -0
  82. data/lib/seatschart/models/post_api_charts_by_chart_id_actions_archive200_response.rb +221 -0
  83. data/lib/seatschart/models/post_api_charts_by_chart_id_actions_archive200_response_chart.rb +249 -0
  84. data/lib/seatschart/models/post_api_charts_by_chart_id_actions_copy_to_workspace_request.rb +287 -0
  85. data/lib/seatschart/models/post_api_charts_by_chart_id_actions_validate_request.rb +348 -0
  86. data/lib/seatschart/models/post_api_charts_by_chart_id_actions_validate_request_seats_inner.rb +555 -0
  87. data/lib/seatschart/models/post_api_charts_by_chart_id_actions_validate_request_seats_inner_accessibility.rb +356 -0
  88. data/lib/seatschart/models/post_api_charts_by_chart_id_categories_request.rb +361 -0
  89. data/lib/seatschart/models/post_api_charts_by_chart_id_categories_request_ticket_types_inner.rb +448 -0
  90. data/lib/seatschart/models/post_api_charts_by_chart_id_duplicate_request.rb +233 -0
  91. data/lib/seatschart/models/post_api_charts_by_chart_id_map_publish422_response.rb +289 -0
  92. data/lib/seatschart/models/post_api_charts_by_chart_id_map_publish422_response_issues_inner.rb +402 -0
  93. data/lib/seatschart/models/post_api_charts_by_chart_id_map_publish_request.rb +244 -0
  94. data/lib/seatschart/models/post_api_charts_by_chart_id_preview_link_request.rb +243 -0
  95. data/lib/seatschart/models/post_api_charts_by_chart_id_versions_by_version_actions_copy_request.rb +242 -0
  96. data/lib/seatschart/models/post_api_charts_request.rb +372 -0
  97. data/lib/seatschart/models/post_api_charts_request_categories_inner.rb +346 -0
  98. data/lib/seatschart/models/post_api_embed_origins_request.rb +249 -0
  99. data/lib/seatschart/models/post_api_embed_tokens_request.rb +394 -0
  100. data/lib/seatschart/models/post_api_events_actions_change_object_status_request.rb +251 -0
  101. data/lib/seatschart/models/post_api_events_actions_change_object_status_request_status_changes_inner.rb +737 -0
  102. data/lib/seatschart/models/post_api_events_actions_change_object_status_request_status_changes_inner_objects_inner.rb +104 -0
  103. data/lib/seatschart/models/post_api_events_actions_change_object_status_request_status_changes_inner_objects_inner_any_of.rb +335 -0
  104. data/lib/seatschart/models/post_api_events_bulk_request.rb +332 -0
  105. data/lib/seatschart/models/post_api_events_bulk_request_events_inner.rb +398 -0
  106. data/lib/seatschart/models/post_api_events_by_event_id_actions_change_object_status_request.rb +824 -0
  107. data/lib/seatschart/models/post_api_events_by_event_id_actions_override_season_status_request.rb +272 -0
  108. data/lib/seatschart/models/post_api_events_by_event_id_actions_update_extra_data_request.rb +260 -0
  109. data/lib/seatschart/models/post_api_events_by_event_id_actions_update_extra_data_request_objects_inner.rb +263 -0
  110. data/lib/seatschart/models/post_api_events_by_event_id_actions_use_season_status_request.rb +252 -0
  111. data/lib/seatschart/models/post_api_events_by_event_id_duplicate_request.rb +261 -0
  112. data/lib/seatschart/models/post_api_events_by_event_id_inventory_channels_assign_request.rb +321 -0
  113. data/lib/seatschart/models/post_api_events_by_event_id_inventory_channels_request.rb +323 -0
  114. data/lib/seatschart/models/post_api_events_by_event_id_inventory_for_sale_apply_request.rb +333 -0
  115. data/lib/seatschart/models/post_api_events_by_event_id_objects_actions_retrieve_request.rb +252 -0
  116. data/lib/seatschart/models/post_api_events_request.rb +502 -0
  117. data/lib/seatschart/models/post_api_events_request_category_overrides_value.rb +276 -0
  118. data/lib/seatschart/models/post_api_events_request_channels_inner.rb +360 -0
  119. data/lib/seatschart/models/post_api_events_request_for_sale_config.rb +295 -0
  120. data/lib/seatschart/models/post_api_events_request_table_booking_config.rb +267 -0
  121. data/lib/seatschart/models/post_api_extract_seats_request.rb +279 -0
  122. data/lib/seatschart/models/post_api_ga_confirm409_response.rb +271 -0
  123. data/lib/seatschart/models/post_api_ga_confirm_request.rb +687 -0
  124. data/lib/seatschart/models/post_api_ga_release_request.rb +385 -0
  125. data/lib/seatschart/models/post_api_ga_reserve_request.rb +527 -0
  126. data/lib/seatschart/models/post_api_hold_tokens_by_token_request.rb +249 -0
  127. data/lib/seatschart/models/post_api_hold_tokens_request.rb +391 -0
  128. data/lib/seatschart/models/post_api_keys_request.rb +299 -0
  129. data/lib/seatschart/models/post_api_orders_by_order_id_cancel_request.rb +249 -0
  130. data/lib/seatschart/models/post_api_quotes_request.rb +351 -0
  131. data/lib/seatschart/models/post_api_seasons_by_season_id_actions_add_events_request.rb +261 -0
  132. data/lib/seatschart/models/post_api_seasons_by_season_id_actions_create_events_request.rb +322 -0
  133. data/lib/seatschart/models/post_api_seasons_by_season_id_actions_create_events_request_events_inner.rb +289 -0
  134. data/lib/seatschart/models/post_api_seasons_by_season_id_actions_remove_events_request.rb +251 -0
  135. data/lib/seatschart/models/post_api_seasons_by_season_id_events_request.rb +267 -0
  136. data/lib/seatschart/models/post_api_seasons_by_season_id_inventory_sync_request.rb +235 -0
  137. data/lib/seatschart/models/post_api_seasons_by_season_id_partial_seasons_request.rb +279 -0
  138. data/lib/seatschart/models/post_api_seasons_request.rb +395 -0
  139. data/lib/seatschart/models/post_api_seats_best_available_request.rb +809 -0
  140. data/lib/seatschart/models/post_api_seats_confirm409_response.rb +271 -0
  141. data/lib/seatschart/models/post_api_seats_confirm_request.rb +711 -0
  142. data/lib/seatschart/models/post_api_seats_holds_renew_request.rb +249 -0
  143. data/lib/seatschart/models/post_api_seats_release_request.rb +387 -0
  144. data/lib/seatschart/models/post_api_seats_reserve_request.rb +561 -0
  145. data/lib/seatschart/models/post_api_team_invitations_request.rb +299 -0
  146. data/lib/seatschart/models/post_api_ticket_buyers_request.rb +252 -0
  147. data/lib/seatschart/models/post_api_viewer_tokens_request.rb +292 -0
  148. data/lib/seatschart/models/post_api_webhooks_request.rb +298 -0
  149. data/lib/seatschart/models/post_api_workspaces_request.rb +269 -0
  150. data/lib/seatschart/models/put_api_charts_by_chart_id_tags_request.rb +243 -0
  151. data/lib/seatschart/models/put_api_charts_by_chart_id_versions_by_version_thumbnail_request.rb +261 -0
  152. data/lib/seatschart/models/put_api_events_by_event_id_inventory_channels_definitions_request.rb +242 -0
  153. data/lib/seatschart/models/put_api_events_by_event_id_inventory_channels_definitions_request_channels_inner.rb +405 -0
  154. data/lib/seatschart/models/put_api_events_by_event_id_inventory_channels_request.rb +242 -0
  155. data/lib/seatschart/models/put_api_events_by_event_id_inventory_channels_request_assignments_inner.rb +320 -0
  156. data/lib/seatschart/models/put_api_events_by_event_id_inventory_for_sale_request.rb +333 -0
  157. data/lib/seatschart/models/put_api_events_by_event_id_pricing_request.rb +297 -0
  158. data/lib/seatschart/models/put_api_events_by_event_id_pricing_request_categories_inner.rb +295 -0
  159. data/lib/seatschart/models/put_api_events_by_event_id_pricing_request_categories_inner_ticket_types_inner.rb +425 -0
  160. data/lib/seatschart/models/put_api_events_by_event_id_sales_rules_request.rb +320 -0
  161. data/lib/seatschart/models/put_api_events_by_event_id_sales_rules_request_buyer_limit.rb +259 -0
  162. data/lib/seatschart/models/put_api_events_by_event_id_sales_rules_request_lot_plans_inner.rb +374 -0
  163. data/lib/seatschart/models/put_api_events_by_event_id_sales_rules_request_lot_plans_inner_lots_inner.rb +364 -0
  164. data/lib/seatschart/models/put_api_events_by_event_id_sales_rules_request_quotas_inner.rb +418 -0
  165. data/lib/seatschart/retry.rb +118 -0
  166. data/lib/seatschart/version.rb +15 -0
  167. data/lib/seatschart.rb +198 -0
  168. metadata +254 -0
@@ -0,0 +1,805 @@
1
+ =begin
2
+ #SeatsChart API
3
+
4
+ #Seat inventory and locking API for B2B2C integrations. Authenticate using `x-api-key` (partners) or `Authorization: Bearer` with an HS256 JWT.
5
+
6
+ The version of the OpenAPI document: 1.0.0
7
+
8
+ Generated by: https://openapi-generator.tech
9
+ Generator version: 7.11.0
10
+
11
+ =end
12
+
13
+ require 'cgi'
14
+
15
+ module SeatsChart
16
+ class ObjectStatusApi
17
+ attr_accessor :api_client
18
+
19
+ def initialize(api_client = ApiClient.default)
20
+ @api_client = api_client
21
+ end
22
+ # List object status overlays for an event
23
+ # Ops overlay (custom / resale / extraData). Distinct from Redis holds. See docs/SEATSIO_PARITY.md.
24
+ # @param event_id [String]
25
+ # @param [Hash] opts the optional parameters
26
+ # @return [nil]
27
+ def get_api_events_by_event_id_object_statuses(event_id, opts = {})
28
+ get_api_events_by_event_id_object_statuses_with_http_info(event_id, opts)
29
+ nil
30
+ end
31
+
32
+ # List object status overlays for an event
33
+ # Ops overlay (custom / resale / extraData). Distinct from Redis holds. See docs/SEATSIO_PARITY.md.
34
+ # @param event_id [String]
35
+ # @param [Hash] opts the optional parameters
36
+ # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
37
+ def get_api_events_by_event_id_object_statuses_with_http_info(event_id, opts = {})
38
+ if @api_client.config.debugging
39
+ @api_client.config.logger.debug 'Calling API: ObjectStatusApi.get_api_events_by_event_id_object_statuses ...'
40
+ end
41
+ # verify the required parameter 'event_id' is set
42
+ if @api_client.config.client_side_validation && event_id.nil?
43
+ fail ArgumentError, "Missing the required parameter 'event_id' when calling ObjectStatusApi.get_api_events_by_event_id_object_statuses"
44
+ end
45
+ if @api_client.config.client_side_validation && event_id.to_s.length > 36
46
+ fail ArgumentError, 'invalid value for "event_id" when calling ObjectStatusApi.get_api_events_by_event_id_object_statuses, the character length must be smaller than or equal to 36.'
47
+ end
48
+
49
+ if @api_client.config.client_side_validation && event_id.to_s.length < 36
50
+ fail ArgumentError, 'invalid value for "event_id" when calling ObjectStatusApi.get_api_events_by_event_id_object_statuses, the character length must be great than or equal to 36.'
51
+ end
52
+
53
+ # resource path
54
+ local_var_path = '/api/events/{eventId}/object-statuses'.sub('{' + 'eventId' + '}', CGI.escape(event_id.to_s))
55
+
56
+ # query parameters
57
+ query_params = opts[:query_params] || {}
58
+
59
+ # header parameters
60
+ header_params = opts[:header_params] || {}
61
+
62
+ # form parameters
63
+ form_params = opts[:form_params] || {}
64
+
65
+ # http body (model)
66
+ post_body = opts[:debug_body]
67
+
68
+ # return_type
69
+ return_type = opts[:debug_return_type]
70
+
71
+ # auth_names
72
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth', 'BearerAuth']
73
+
74
+ new_options = opts.merge(
75
+ :operation => :"ObjectStatusApi.get_api_events_by_event_id_object_statuses",
76
+ :header_params => header_params,
77
+ :query_params => query_params,
78
+ :form_params => form_params,
79
+ :body => post_body,
80
+ :auth_names => auth_names,
81
+ :return_type => return_type
82
+ )
83
+
84
+ data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
85
+ if @api_client.config.debugging
86
+ @api_client.config.logger.debug "API called: ObjectStatusApi#get_api_events_by_event_id_object_statuses\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
87
+ end
88
+ return data, status_code, headers
89
+ end
90
+
91
+ # Atomically change object statuses across events (all-or-nothing batch)
92
+ # Applies several status changes — different events, statuses, hold tokens and orders — **all-or-nothing in one SQL transaction**. Either every change is applied or none is; there is never a partial result to reconcile. **Body**: `statusChanges[]` (1–100; at most 512 objects overall), each with exactly one of `eventId` / `eventKey`, `objects` (seat UUID or label; GA area id or name with `quantity`; optional per-object `ticketType` for bookings), `status` (or `type: RELEASE`) and the same optional fields as POST /events/{eventId}/actions/change-object-status: `orderId`, `holdToken` (book seats held by a buyer hold token), `keepExtraData`, `resalePriceCents`, `resaleListingId`, `allowedPreviousStatuses` / `rejectedPreviousStatuses`, `channelKeys` / `ignoreChannels`, `ticketBuyerId`. One **Idempotency-Key** covers the whole batch: a replay returns the stored response, a retry after a crash reuses the same booking orders. **Consistency**: row locks are taken in a deterministic order — booking orders by id, then every seat of every change by (eventId, seatId), then GA areas by (eventId, areaId) — so concurrent batches on overlapping seats serialize instead of deadlocking (a database-detected deadlock is retried transparently). Buyer holds are honoured exactly as for a single-event change: a seat held by a buyer (Redis hold lock, read under the seat row lock) is never booked unless its `holdToken` is supplied, hold sessions are frozen before the transaction, and GA places are first reserved in the same structure buyers hold from, so capacity can never be exceeded. **Not atomic, refused with 400 `not_atomic`**: administrative GA holds (`reservedByToken`) and GA releases by hold token (they live in Redis only). An object or hold token may appear in only one change (400 `duplicate_object` / `duplicate_hold_token`). **Responses**: 200 `{ results: [{ index, eventId, outcome: \"applied\", objects, gaAreas }] }` in request order. On any failure nothing is written and the status is that of the first failing change (400, 404, 409), with `{ error, message, failed, results: [{ index, eventId, outcome: \"failed\" | \"rolled_back\", status?, error?, message?, objects?, labels? }] }` — every invalid change is reported at once when the request itself is invalid; a conflict found under the row locks reports the change that hit it.
93
+ # @param post_api_events_actions_change_object_status_request [PostApiEventsActionsChangeObjectStatusRequest]
94
+ # @param [Hash] opts the optional parameters
95
+ # @option opts [String] :idempotency_key Required on transactional routes. Reuse the same key for every retry of one logical operation; the API replays the stored outcome.
96
+ # @return [nil]
97
+ def post_api_events_actions_change_object_status(post_api_events_actions_change_object_status_request, opts = {})
98
+ post_api_events_actions_change_object_status_with_http_info(post_api_events_actions_change_object_status_request, opts)
99
+ nil
100
+ end
101
+
102
+ # Atomically change object statuses across events (all-or-nothing batch)
103
+ # Applies several status changes — different events, statuses, hold tokens and orders — **all-or-nothing in one SQL transaction**. Either every change is applied or none is; there is never a partial result to reconcile. **Body**: &#x60;statusChanges[]&#x60; (1–100; at most 512 objects overall), each with exactly one of &#x60;eventId&#x60; / &#x60;eventKey&#x60;, &#x60;objects&#x60; (seat UUID or label; GA area id or name with &#x60;quantity&#x60;; optional per-object &#x60;ticketType&#x60; for bookings), &#x60;status&#x60; (or &#x60;type: RELEASE&#x60;) and the same optional fields as POST /events/{eventId}/actions/change-object-status: &#x60;orderId&#x60;, &#x60;holdToken&#x60; (book seats held by a buyer hold token), &#x60;keepExtraData&#x60;, &#x60;resalePriceCents&#x60;, &#x60;resaleListingId&#x60;, &#x60;allowedPreviousStatuses&#x60; / &#x60;rejectedPreviousStatuses&#x60;, &#x60;channelKeys&#x60; / &#x60;ignoreChannels&#x60;, &#x60;ticketBuyerId&#x60;. One **Idempotency-Key** covers the whole batch: a replay returns the stored response, a retry after a crash reuses the same booking orders. **Consistency**: row locks are taken in a deterministic order — booking orders by id, then every seat of every change by (eventId, seatId), then GA areas by (eventId, areaId) — so concurrent batches on overlapping seats serialize instead of deadlocking (a database-detected deadlock is retried transparently). Buyer holds are honoured exactly as for a single-event change: a seat held by a buyer (Redis hold lock, read under the seat row lock) is never booked unless its &#x60;holdToken&#x60; is supplied, hold sessions are frozen before the transaction, and GA places are first reserved in the same structure buyers hold from, so capacity can never be exceeded. **Not atomic, refused with 400 &#x60;not_atomic&#x60;**: administrative GA holds (&#x60;reservedByToken&#x60;) and GA releases by hold token (they live in Redis only). An object or hold token may appear in only one change (400 &#x60;duplicate_object&#x60; / &#x60;duplicate_hold_token&#x60;). **Responses**: 200 &#x60;{ results: [{ index, eventId, outcome: \&quot;applied\&quot;, objects, gaAreas }] }&#x60; in request order. On any failure nothing is written and the status is that of the first failing change (400, 404, 409), with &#x60;{ error, message, failed, results: [{ index, eventId, outcome: \&quot;failed\&quot; | \&quot;rolled_back\&quot;, status?, error?, message?, objects?, labels? }] }&#x60; — every invalid change is reported at once when the request itself is invalid; a conflict found under the row locks reports the change that hit it.
104
+ # @param post_api_events_actions_change_object_status_request [PostApiEventsActionsChangeObjectStatusRequest]
105
+ # @param [Hash] opts the optional parameters
106
+ # @option opts [String] :idempotency_key Required on transactional routes. Reuse the same key for every retry of one logical operation; the API replays the stored outcome.
107
+ # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
108
+ def post_api_events_actions_change_object_status_with_http_info(post_api_events_actions_change_object_status_request, opts = {})
109
+ if @api_client.config.debugging
110
+ @api_client.config.logger.debug 'Calling API: ObjectStatusApi.post_api_events_actions_change_object_status ...'
111
+ end
112
+ # verify the required parameter 'post_api_events_actions_change_object_status_request' is set
113
+ if @api_client.config.client_side_validation && post_api_events_actions_change_object_status_request.nil?
114
+ fail ArgumentError, "Missing the required parameter 'post_api_events_actions_change_object_status_request' when calling ObjectStatusApi.post_api_events_actions_change_object_status"
115
+ end
116
+ if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length > 255
117
+ fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling ObjectStatusApi.post_api_events_actions_change_object_status, the character length must be smaller than or equal to 255.'
118
+ end
119
+
120
+ if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length < 1
121
+ fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling ObjectStatusApi.post_api_events_actions_change_object_status, the character length must be great than or equal to 1.'
122
+ end
123
+
124
+ # resource path
125
+ local_var_path = '/api/events/actions/change-object-status'
126
+
127
+ # query parameters
128
+ query_params = opts[:query_params] || {}
129
+
130
+ # header parameters
131
+ header_params = opts[:header_params] || {}
132
+ # HTTP header 'Content-Type'
133
+ content_type = @api_client.select_header_content_type(['application/json', 'multipart/form-data', 'text/plain'])
134
+ if !content_type.nil?
135
+ header_params['Content-Type'] = content_type
136
+ end
137
+ header_params[:'Idempotency-Key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
138
+
139
+ # form parameters
140
+ form_params = opts[:form_params] || {}
141
+
142
+ # http body (model)
143
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(post_api_events_actions_change_object_status_request)
144
+
145
+ # return_type
146
+ return_type = opts[:debug_return_type]
147
+
148
+ # auth_names
149
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth', 'BearerAuth']
150
+
151
+ new_options = opts.merge(
152
+ :operation => :"ObjectStatusApi.post_api_events_actions_change_object_status",
153
+ :header_params => header_params,
154
+ :query_params => query_params,
155
+ :form_params => form_params,
156
+ :body => post_body,
157
+ :auth_names => auth_names,
158
+ :return_type => return_type
159
+ )
160
+
161
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
162
+ if @api_client.config.debugging
163
+ @api_client.config.logger.debug "API called: ObjectStatusApi#post_api_events_actions_change_object_status\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
164
+ end
165
+ return data, status_code, headers
166
+ end
167
+
168
+ # Create a durable administrative booking on unheld inventory (or on a hold token)
169
+ # Administrative status change on the path event. One SQL transaction per event; seats are locked in id order and every precondition is evaluated under those row locks, so a concurrent hold, purchase or other change cannot slip in between the check and the write. Requires **Idempotency-Key**; a replay returns the stored response and a retry after a crash reuses the same durable booking order. **Objects** (max 64 per call, per event): seat UUID or seat label (labels are resolved per event; a label that matches several seats returns 409 `ambiguous_label`; unknown references return 404 `objects_not_found`). General admission areas are addressed by UUID or name **with `quantity`** (1–10000): - `booked`: the places are first reserved in the same Redis structure buyers hold from (capacity minus not-for-sale places), then `sold_count` is incremented in the transaction with a `sold_count + quantity <= capacity` guard; the durable receipt belongs to the administrative booking order (cancel it with POST /orders/{orderId}/cancel). - `reservedByToken` (or POST …/actions/hold, GA only): holds the places atomically against capacity minus withheld, sold and held places and issues a **GA hold token** (`hold: { holdToken, holdUserId, holdExpiresAt }`), confirmable with POST /ga/confirm (`holdToken`, `userId` = `holdUserId`). Optional `userId` (customer identity of the hold; one hold per user and area, 409 `hold_exists`) and `holdExpiresInMinutes` (1–120). 409 `insufficient_capacity`. - `RELEASE` / `free` without `holdToken`: releases places of **administrative** bookings (newest receipts first, optionally only those of `orderId`), recording a release receipt per consumed booking and decrementing `sold_count` under the GA row lock (409 `insufficient_booked_places` with `available`). Buyer purchases are never released here. - `RELEASE` with `holdToken` (GA hold token): releases that many places held by the token (409 `insufficient_held_places`, `hold_token_conflict`). Every GA operation is idempotent per Idempotency-Key (deterministic receipts/holds/markers), and capacity can never be exceeded nor `sold_count` go below zero. Response `gaAreas: { <areaId>: { areaId, label, quantity, soldCount, status, heldCount?, releasedFrom? } }`. **`allowedPreviousStatuses` / `rejectedPreviousStatuses`**: `free`, `booked`, `resale`, `reservedByToken`, `retired` or a custom status. On violation nothing is written and 409 `illegal_previous_status` lists every offending object with its current status. For GA quantities the previous status follows from the operation: `free` for book/hold, `booked` for a release, `reservedByToken` for a release by `holdToken`. **`holdToken`**: with status `booked`, books seats held by that hold token. The hold session is frozen first, so the buyer cannot confirm the same seats concurrently; seats held by another token or not held by this one return 409 `hold_token_conflict`. Remaining seats of the session stay held. With `RELEASE` it releases GA places (see above). **`ticketType`** (per object, `{ objectId, ticketType }`, status `booked` only): ticket type id recorded on the new booking (order item and reservation, like a confirmed sale) and returned per object; it shows up in reports by ticket type. Other statuses return 400. **`keepExtraData`**: keeps the stored extraData; per-object `extraData` sent with it is merged on top (without it, the object's extraData is replaced by the one sent, or cleared). **`ticketBuyerId`** (opaque, ≤ 256 chars, never an internal user id) is recorded on new bookings, object statuses, status history and GA hold tokens; query it with GET /events/{eventId}/objects?ticketBuyerId=…. **`channelKeys`** (channel secret keys or channel ids) restricts the change to public objects and objects of the named channels (409 `channel_forbidden` otherwise). Without `channelKeys`, or with `ignoreChannels: true`, channel partitions are ignored (backward-compatible default). **`events`** (max 50, must include the path event): applies the same change to each event of the tenant, labels resolved per event. By default each event is atomic on its own (no cross-event atomicity): response 200 when every event succeeded, otherwise 207 with `results[]` (`{ eventId, ok, objects | status, error, message }`), `succeeded` and `failed`. Replaying the same Idempotency-Key returns the stored per-event outcome; retry failed events (listed with their error) with a new key. **`atomic: true`** makes the whole call all-or-nothing in one SQL transaction (same engine as POST /events/actions/change-object-status; at most 512 objects across the events): 200 with `atomic: true` when everything was applied, otherwise the status of the first failing event and `results[]` with `outcome: failed` (with `error`, `message`) or `rolled_back` per event — nothing was written. GA administrative holds cannot be atomic (400 `not_atomic`). **`seasonId`** (season or partial season id; XOR with `events`): fans out by unique label to every live member in one transaction (cap 50 members, 64 seats overall). Preconditions and channelKeys apply to every member seat.
170
+ # @param event_id [String]
171
+ # @param post_api_events_by_event_id_actions_change_object_status_request [PostApiEventsByEventIdActionsChangeObjectStatusRequest]
172
+ # @param [Hash] opts the optional parameters
173
+ # @option opts [String] :idempotency_key Required on transactional routes. Reuse the same key for every retry of one logical operation; the API replays the stored outcome.
174
+ # @return [nil]
175
+ def post_api_events_by_event_id_actions_book(event_id, post_api_events_by_event_id_actions_change_object_status_request, opts = {})
176
+ post_api_events_by_event_id_actions_book_with_http_info(event_id, post_api_events_by_event_id_actions_change_object_status_request, opts)
177
+ nil
178
+ end
179
+
180
+ # Create a durable administrative booking on unheld inventory (or on a hold token)
181
+ # Administrative status change on the path event. One SQL transaction per event; seats are locked in id order and every precondition is evaluated under those row locks, so a concurrent hold, purchase or other change cannot slip in between the check and the write. Requires **Idempotency-Key**; a replay returns the stored response and a retry after a crash reuses the same durable booking order. **Objects** (max 64 per call, per event): seat UUID or seat label (labels are resolved per event; a label that matches several seats returns 409 &#x60;ambiguous_label&#x60;; unknown references return 404 &#x60;objects_not_found&#x60;). General admission areas are addressed by UUID or name **with &#x60;quantity&#x60;** (1–10000): - &#x60;booked&#x60;: the places are first reserved in the same Redis structure buyers hold from (capacity minus not-for-sale places), then &#x60;sold_count&#x60; is incremented in the transaction with a &#x60;sold_count + quantity &lt;&#x3D; capacity&#x60; guard; the durable receipt belongs to the administrative booking order (cancel it with POST /orders/{orderId}/cancel). - &#x60;reservedByToken&#x60; (or POST …/actions/hold, GA only): holds the places atomically against capacity minus withheld, sold and held places and issues a **GA hold token** (&#x60;hold: { holdToken, holdUserId, holdExpiresAt }&#x60;), confirmable with POST /ga/confirm (&#x60;holdToken&#x60;, &#x60;userId&#x60; &#x3D; &#x60;holdUserId&#x60;). Optional &#x60;userId&#x60; (customer identity of the hold; one hold per user and area, 409 &#x60;hold_exists&#x60;) and &#x60;holdExpiresInMinutes&#x60; (1–120). 409 &#x60;insufficient_capacity&#x60;. - &#x60;RELEASE&#x60; / &#x60;free&#x60; without &#x60;holdToken&#x60;: releases places of **administrative** bookings (newest receipts first, optionally only those of &#x60;orderId&#x60;), recording a release receipt per consumed booking and decrementing &#x60;sold_count&#x60; under the GA row lock (409 &#x60;insufficient_booked_places&#x60; with &#x60;available&#x60;). Buyer purchases are never released here. - &#x60;RELEASE&#x60; with &#x60;holdToken&#x60; (GA hold token): releases that many places held by the token (409 &#x60;insufficient_held_places&#x60;, &#x60;hold_token_conflict&#x60;). Every GA operation is idempotent per Idempotency-Key (deterministic receipts/holds/markers), and capacity can never be exceeded nor &#x60;sold_count&#x60; go below zero. Response &#x60;gaAreas: { &lt;areaId&gt;: { areaId, label, quantity, soldCount, status, heldCount?, releasedFrom? } }&#x60;. **&#x60;allowedPreviousStatuses&#x60; / &#x60;rejectedPreviousStatuses&#x60;**: &#x60;free&#x60;, &#x60;booked&#x60;, &#x60;resale&#x60;, &#x60;reservedByToken&#x60;, &#x60;retired&#x60; or a custom status. On violation nothing is written and 409 &#x60;illegal_previous_status&#x60; lists every offending object with its current status. For GA quantities the previous status follows from the operation: &#x60;free&#x60; for book/hold, &#x60;booked&#x60; for a release, &#x60;reservedByToken&#x60; for a release by &#x60;holdToken&#x60;. **&#x60;holdToken&#x60;**: with status &#x60;booked&#x60;, books seats held by that hold token. The hold session is frozen first, so the buyer cannot confirm the same seats concurrently; seats held by another token or not held by this one return 409 &#x60;hold_token_conflict&#x60;. Remaining seats of the session stay held. With &#x60;RELEASE&#x60; it releases GA places (see above). **&#x60;ticketType&#x60;** (per object, &#x60;{ objectId, ticketType }&#x60;, status &#x60;booked&#x60; only): ticket type id recorded on the new booking (order item and reservation, like a confirmed sale) and returned per object; it shows up in reports by ticket type. Other statuses return 400. **&#x60;keepExtraData&#x60;**: keeps the stored extraData; per-object &#x60;extraData&#x60; sent with it is merged on top (without it, the object&#39;s extraData is replaced by the one sent, or cleared). **&#x60;ticketBuyerId&#x60;** (opaque, ≤ 256 chars, never an internal user id) is recorded on new bookings, object statuses, status history and GA hold tokens; query it with GET /events/{eventId}/objects?ticketBuyerId&#x3D;…. **&#x60;channelKeys&#x60;** (channel secret keys or channel ids) restricts the change to public objects and objects of the named channels (409 &#x60;channel_forbidden&#x60; otherwise). Without &#x60;channelKeys&#x60;, or with &#x60;ignoreChannels: true&#x60;, channel partitions are ignored (backward-compatible default). **&#x60;events&#x60;** (max 50, must include the path event): applies the same change to each event of the tenant, labels resolved per event. By default each event is atomic on its own (no cross-event atomicity): response 200 when every event succeeded, otherwise 207 with &#x60;results[]&#x60; (&#x60;{ eventId, ok, objects | status, error, message }&#x60;), &#x60;succeeded&#x60; and &#x60;failed&#x60;. Replaying the same Idempotency-Key returns the stored per-event outcome; retry failed events (listed with their error) with a new key. **&#x60;atomic: true&#x60;** makes the whole call all-or-nothing in one SQL transaction (same engine as POST /events/actions/change-object-status; at most 512 objects across the events): 200 with &#x60;atomic: true&#x60; when everything was applied, otherwise the status of the first failing event and &#x60;results[]&#x60; with &#x60;outcome: failed&#x60; (with &#x60;error&#x60;, &#x60;message&#x60;) or &#x60;rolled_back&#x60; per event — nothing was written. GA administrative holds cannot be atomic (400 &#x60;not_atomic&#x60;). **&#x60;seasonId&#x60;** (season or partial season id; XOR with &#x60;events&#x60;): fans out by unique label to every live member in one transaction (cap 50 members, 64 seats overall). Preconditions and channelKeys apply to every member seat.
182
+ # @param event_id [String]
183
+ # @param post_api_events_by_event_id_actions_change_object_status_request [PostApiEventsByEventIdActionsChangeObjectStatusRequest]
184
+ # @param [Hash] opts the optional parameters
185
+ # @option opts [String] :idempotency_key Required on transactional routes. Reuse the same key for every retry of one logical operation; the API replays the stored outcome.
186
+ # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
187
+ def post_api_events_by_event_id_actions_book_with_http_info(event_id, post_api_events_by_event_id_actions_change_object_status_request, opts = {})
188
+ if @api_client.config.debugging
189
+ @api_client.config.logger.debug 'Calling API: ObjectStatusApi.post_api_events_by_event_id_actions_book ...'
190
+ end
191
+ # verify the required parameter 'event_id' is set
192
+ if @api_client.config.client_side_validation && event_id.nil?
193
+ fail ArgumentError, "Missing the required parameter 'event_id' when calling ObjectStatusApi.post_api_events_by_event_id_actions_book"
194
+ end
195
+ if @api_client.config.client_side_validation && event_id.to_s.length > 36
196
+ fail ArgumentError, 'invalid value for "event_id" when calling ObjectStatusApi.post_api_events_by_event_id_actions_book, the character length must be smaller than or equal to 36.'
197
+ end
198
+
199
+ if @api_client.config.client_side_validation && event_id.to_s.length < 36
200
+ fail ArgumentError, 'invalid value for "event_id" when calling ObjectStatusApi.post_api_events_by_event_id_actions_book, the character length must be great than or equal to 36.'
201
+ end
202
+
203
+ # verify the required parameter 'post_api_events_by_event_id_actions_change_object_status_request' is set
204
+ if @api_client.config.client_side_validation && post_api_events_by_event_id_actions_change_object_status_request.nil?
205
+ fail ArgumentError, "Missing the required parameter 'post_api_events_by_event_id_actions_change_object_status_request' when calling ObjectStatusApi.post_api_events_by_event_id_actions_book"
206
+ end
207
+ if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length > 255
208
+ fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling ObjectStatusApi.post_api_events_by_event_id_actions_book, the character length must be smaller than or equal to 255.'
209
+ end
210
+
211
+ if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length < 1
212
+ fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling ObjectStatusApi.post_api_events_by_event_id_actions_book, the character length must be great than or equal to 1.'
213
+ end
214
+
215
+ # resource path
216
+ local_var_path = '/api/events/{eventId}/actions/book'.sub('{' + 'eventId' + '}', CGI.escape(event_id.to_s))
217
+
218
+ # query parameters
219
+ query_params = opts[:query_params] || {}
220
+
221
+ # header parameters
222
+ header_params = opts[:header_params] || {}
223
+ # HTTP header 'Content-Type'
224
+ content_type = @api_client.select_header_content_type(['application/json', 'multipart/form-data', 'text/plain'])
225
+ if !content_type.nil?
226
+ header_params['Content-Type'] = content_type
227
+ end
228
+ header_params[:'Idempotency-Key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
229
+
230
+ # form parameters
231
+ form_params = opts[:form_params] || {}
232
+
233
+ # http body (model)
234
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(post_api_events_by_event_id_actions_change_object_status_request)
235
+
236
+ # return_type
237
+ return_type = opts[:debug_return_type]
238
+
239
+ # auth_names
240
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth', 'BearerAuth']
241
+
242
+ new_options = opts.merge(
243
+ :operation => :"ObjectStatusApi.post_api_events_by_event_id_actions_book",
244
+ :header_params => header_params,
245
+ :query_params => query_params,
246
+ :form_params => form_params,
247
+ :body => post_body,
248
+ :auth_names => auth_names,
249
+ :return_type => return_type
250
+ )
251
+
252
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
253
+ if @api_client.config.debugging
254
+ @api_client.config.logger.debug "API called: ObjectStatusApi#post_api_events_by_event_id_actions_book\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
255
+ end
256
+ return data, status_code, headers
257
+ end
258
+
259
+ # Change object status (booked / free / resale / retired / custom)
260
+ # `type: RELEASE` frees objects; otherwise `status` is required. Optional `resalePriceCents` is stored on extraData. Administrative status change on the path event. One SQL transaction per event; seats are locked in id order and every precondition is evaluated under those row locks, so a concurrent hold, purchase or other change cannot slip in between the check and the write. Requires **Idempotency-Key**; a replay returns the stored response and a retry after a crash reuses the same durable booking order. **Objects** (max 64 per call, per event): seat UUID or seat label (labels are resolved per event; a label that matches several seats returns 409 `ambiguous_label`; unknown references return 404 `objects_not_found`). General admission areas are addressed by UUID or name **with `quantity`** (1–10000): - `booked`: the places are first reserved in the same Redis structure buyers hold from (capacity minus not-for-sale places), then `sold_count` is incremented in the transaction with a `sold_count + quantity <= capacity` guard; the durable receipt belongs to the administrative booking order (cancel it with POST /orders/{orderId}/cancel). - `reservedByToken` (or POST …/actions/hold, GA only): holds the places atomically against capacity minus withheld, sold and held places and issues a **GA hold token** (`hold: { holdToken, holdUserId, holdExpiresAt }`), confirmable with POST /ga/confirm (`holdToken`, `userId` = `holdUserId`). Optional `userId` (customer identity of the hold; one hold per user and area, 409 `hold_exists`) and `holdExpiresInMinutes` (1–120). 409 `insufficient_capacity`. - `RELEASE` / `free` without `holdToken`: releases places of **administrative** bookings (newest receipts first, optionally only those of `orderId`), recording a release receipt per consumed booking and decrementing `sold_count` under the GA row lock (409 `insufficient_booked_places` with `available`). Buyer purchases are never released here. - `RELEASE` with `holdToken` (GA hold token): releases that many places held by the token (409 `insufficient_held_places`, `hold_token_conflict`). Every GA operation is idempotent per Idempotency-Key (deterministic receipts/holds/markers), and capacity can never be exceeded nor `sold_count` go below zero. Response `gaAreas: { <areaId>: { areaId, label, quantity, soldCount, status, heldCount?, releasedFrom? } }`. **`allowedPreviousStatuses` / `rejectedPreviousStatuses`**: `free`, `booked`, `resale`, `reservedByToken`, `retired` or a custom status. On violation nothing is written and 409 `illegal_previous_status` lists every offending object with its current status. For GA quantities the previous status follows from the operation: `free` for book/hold, `booked` for a release, `reservedByToken` for a release by `holdToken`. **`holdToken`**: with status `booked`, books seats held by that hold token. The hold session is frozen first, so the buyer cannot confirm the same seats concurrently; seats held by another token or not held by this one return 409 `hold_token_conflict`. Remaining seats of the session stay held. With `RELEASE` it releases GA places (see above). **`ticketType`** (per object, `{ objectId, ticketType }`, status `booked` only): ticket type id recorded on the new booking (order item and reservation, like a confirmed sale) and returned per object; it shows up in reports by ticket type. Other statuses return 400. **`keepExtraData`**: keeps the stored extraData; per-object `extraData` sent with it is merged on top (without it, the object's extraData is replaced by the one sent, or cleared). **`ticketBuyerId`** (opaque, ≤ 256 chars, never an internal user id) is recorded on new bookings, object statuses, status history and GA hold tokens; query it with GET /events/{eventId}/objects?ticketBuyerId=…. **`channelKeys`** (channel secret keys or channel ids) restricts the change to public objects and objects of the named channels (409 `channel_forbidden` otherwise). Without `channelKeys`, or with `ignoreChannels: true`, channel partitions are ignored (backward-compatible default). **`events`** (max 50, must include the path event): applies the same change to each event of the tenant, labels resolved per event. By default each event is atomic on its own (no cross-event atomicity): response 200 when every event succeeded, otherwise 207 with `results[]` (`{ eventId, ok, objects | status, error, message }`), `succeeded` and `failed`. Replaying the same Idempotency-Key returns the stored per-event outcome; retry failed events (listed with their error) with a new key. **`atomic: true`** makes the whole call all-or-nothing in one SQL transaction (same engine as POST /events/actions/change-object-status; at most 512 objects across the events): 200 with `atomic: true` when everything was applied, otherwise the status of the first failing event and `results[]` with `outcome: failed` (with `error`, `message`) or `rolled_back` per event — nothing was written. GA administrative holds cannot be atomic (400 `not_atomic`). **`seasonId`** (season or partial season id; XOR with `events`): fans out by unique label to every live member in one transaction (cap 50 members, 64 seats overall). Preconditions and channelKeys apply to every member seat.
261
+ # @param event_id [String]
262
+ # @param post_api_events_by_event_id_actions_change_object_status_request [PostApiEventsByEventIdActionsChangeObjectStatusRequest]
263
+ # @param [Hash] opts the optional parameters
264
+ # @option opts [String] :idempotency_key Required on transactional routes. Reuse the same key for every retry of one logical operation; the API replays the stored outcome.
265
+ # @return [nil]
266
+ def post_api_events_by_event_id_actions_change_object_status(event_id, post_api_events_by_event_id_actions_change_object_status_request, opts = {})
267
+ post_api_events_by_event_id_actions_change_object_status_with_http_info(event_id, post_api_events_by_event_id_actions_change_object_status_request, opts)
268
+ nil
269
+ end
270
+
271
+ # Change object status (booked / free / resale / retired / custom)
272
+ # &#x60;type: RELEASE&#x60; frees objects; otherwise &#x60;status&#x60; is required. Optional &#x60;resalePriceCents&#x60; is stored on extraData. Administrative status change on the path event. One SQL transaction per event; seats are locked in id order and every precondition is evaluated under those row locks, so a concurrent hold, purchase or other change cannot slip in between the check and the write. Requires **Idempotency-Key**; a replay returns the stored response and a retry after a crash reuses the same durable booking order. **Objects** (max 64 per call, per event): seat UUID or seat label (labels are resolved per event; a label that matches several seats returns 409 &#x60;ambiguous_label&#x60;; unknown references return 404 &#x60;objects_not_found&#x60;). General admission areas are addressed by UUID or name **with &#x60;quantity&#x60;** (1–10000): - &#x60;booked&#x60;: the places are first reserved in the same Redis structure buyers hold from (capacity minus not-for-sale places), then &#x60;sold_count&#x60; is incremented in the transaction with a &#x60;sold_count + quantity &lt;&#x3D; capacity&#x60; guard; the durable receipt belongs to the administrative booking order (cancel it with POST /orders/{orderId}/cancel). - &#x60;reservedByToken&#x60; (or POST …/actions/hold, GA only): holds the places atomically against capacity minus withheld, sold and held places and issues a **GA hold token** (&#x60;hold: { holdToken, holdUserId, holdExpiresAt }&#x60;), confirmable with POST /ga/confirm (&#x60;holdToken&#x60;, &#x60;userId&#x60; &#x3D; &#x60;holdUserId&#x60;). Optional &#x60;userId&#x60; (customer identity of the hold; one hold per user and area, 409 &#x60;hold_exists&#x60;) and &#x60;holdExpiresInMinutes&#x60; (1–120). 409 &#x60;insufficient_capacity&#x60;. - &#x60;RELEASE&#x60; / &#x60;free&#x60; without &#x60;holdToken&#x60;: releases places of **administrative** bookings (newest receipts first, optionally only those of &#x60;orderId&#x60;), recording a release receipt per consumed booking and decrementing &#x60;sold_count&#x60; under the GA row lock (409 &#x60;insufficient_booked_places&#x60; with &#x60;available&#x60;). Buyer purchases are never released here. - &#x60;RELEASE&#x60; with &#x60;holdToken&#x60; (GA hold token): releases that many places held by the token (409 &#x60;insufficient_held_places&#x60;, &#x60;hold_token_conflict&#x60;). Every GA operation is idempotent per Idempotency-Key (deterministic receipts/holds/markers), and capacity can never be exceeded nor &#x60;sold_count&#x60; go below zero. Response &#x60;gaAreas: { &lt;areaId&gt;: { areaId, label, quantity, soldCount, status, heldCount?, releasedFrom? } }&#x60;. **&#x60;allowedPreviousStatuses&#x60; / &#x60;rejectedPreviousStatuses&#x60;**: &#x60;free&#x60;, &#x60;booked&#x60;, &#x60;resale&#x60;, &#x60;reservedByToken&#x60;, &#x60;retired&#x60; or a custom status. On violation nothing is written and 409 &#x60;illegal_previous_status&#x60; lists every offending object with its current status. For GA quantities the previous status follows from the operation: &#x60;free&#x60; for book/hold, &#x60;booked&#x60; for a release, &#x60;reservedByToken&#x60; for a release by &#x60;holdToken&#x60;. **&#x60;holdToken&#x60;**: with status &#x60;booked&#x60;, books seats held by that hold token. The hold session is frozen first, so the buyer cannot confirm the same seats concurrently; seats held by another token or not held by this one return 409 &#x60;hold_token_conflict&#x60;. Remaining seats of the session stay held. With &#x60;RELEASE&#x60; it releases GA places (see above). **&#x60;ticketType&#x60;** (per object, &#x60;{ objectId, ticketType }&#x60;, status &#x60;booked&#x60; only): ticket type id recorded on the new booking (order item and reservation, like a confirmed sale) and returned per object; it shows up in reports by ticket type. Other statuses return 400. **&#x60;keepExtraData&#x60;**: keeps the stored extraData; per-object &#x60;extraData&#x60; sent with it is merged on top (without it, the object&#39;s extraData is replaced by the one sent, or cleared). **&#x60;ticketBuyerId&#x60;** (opaque, ≤ 256 chars, never an internal user id) is recorded on new bookings, object statuses, status history and GA hold tokens; query it with GET /events/{eventId}/objects?ticketBuyerId&#x3D;…. **&#x60;channelKeys&#x60;** (channel secret keys or channel ids) restricts the change to public objects and objects of the named channels (409 &#x60;channel_forbidden&#x60; otherwise). Without &#x60;channelKeys&#x60;, or with &#x60;ignoreChannels: true&#x60;, channel partitions are ignored (backward-compatible default). **&#x60;events&#x60;** (max 50, must include the path event): applies the same change to each event of the tenant, labels resolved per event. By default each event is atomic on its own (no cross-event atomicity): response 200 when every event succeeded, otherwise 207 with &#x60;results[]&#x60; (&#x60;{ eventId, ok, objects | status, error, message }&#x60;), &#x60;succeeded&#x60; and &#x60;failed&#x60;. Replaying the same Idempotency-Key returns the stored per-event outcome; retry failed events (listed with their error) with a new key. **&#x60;atomic: true&#x60;** makes the whole call all-or-nothing in one SQL transaction (same engine as POST /events/actions/change-object-status; at most 512 objects across the events): 200 with &#x60;atomic: true&#x60; when everything was applied, otherwise the status of the first failing event and &#x60;results[]&#x60; with &#x60;outcome: failed&#x60; (with &#x60;error&#x60;, &#x60;message&#x60;) or &#x60;rolled_back&#x60; per event — nothing was written. GA administrative holds cannot be atomic (400 &#x60;not_atomic&#x60;). **&#x60;seasonId&#x60;** (season or partial season id; XOR with &#x60;events&#x60;): fans out by unique label to every live member in one transaction (cap 50 members, 64 seats overall). Preconditions and channelKeys apply to every member seat.
273
+ # @param event_id [String]
274
+ # @param post_api_events_by_event_id_actions_change_object_status_request [PostApiEventsByEventIdActionsChangeObjectStatusRequest]
275
+ # @param [Hash] opts the optional parameters
276
+ # @option opts [String] :idempotency_key Required on transactional routes. Reuse the same key for every retry of one logical operation; the API replays the stored outcome.
277
+ # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
278
+ def post_api_events_by_event_id_actions_change_object_status_with_http_info(event_id, post_api_events_by_event_id_actions_change_object_status_request, opts = {})
279
+ if @api_client.config.debugging
280
+ @api_client.config.logger.debug 'Calling API: ObjectStatusApi.post_api_events_by_event_id_actions_change_object_status ...'
281
+ end
282
+ # verify the required parameter 'event_id' is set
283
+ if @api_client.config.client_side_validation && event_id.nil?
284
+ fail ArgumentError, "Missing the required parameter 'event_id' when calling ObjectStatusApi.post_api_events_by_event_id_actions_change_object_status"
285
+ end
286
+ if @api_client.config.client_side_validation && event_id.to_s.length > 36
287
+ fail ArgumentError, 'invalid value for "event_id" when calling ObjectStatusApi.post_api_events_by_event_id_actions_change_object_status, the character length must be smaller than or equal to 36.'
288
+ end
289
+
290
+ if @api_client.config.client_side_validation && event_id.to_s.length < 36
291
+ fail ArgumentError, 'invalid value for "event_id" when calling ObjectStatusApi.post_api_events_by_event_id_actions_change_object_status, the character length must be great than or equal to 36.'
292
+ end
293
+
294
+ # verify the required parameter 'post_api_events_by_event_id_actions_change_object_status_request' is set
295
+ if @api_client.config.client_side_validation && post_api_events_by_event_id_actions_change_object_status_request.nil?
296
+ fail ArgumentError, "Missing the required parameter 'post_api_events_by_event_id_actions_change_object_status_request' when calling ObjectStatusApi.post_api_events_by_event_id_actions_change_object_status"
297
+ end
298
+ if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length > 255
299
+ fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling ObjectStatusApi.post_api_events_by_event_id_actions_change_object_status, the character length must be smaller than or equal to 255.'
300
+ end
301
+
302
+ if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length < 1
303
+ fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling ObjectStatusApi.post_api_events_by_event_id_actions_change_object_status, the character length must be great than or equal to 1.'
304
+ end
305
+
306
+ # resource path
307
+ local_var_path = '/api/events/{eventId}/actions/change-object-status'.sub('{' + 'eventId' + '}', CGI.escape(event_id.to_s))
308
+
309
+ # query parameters
310
+ query_params = opts[:query_params] || {}
311
+
312
+ # header parameters
313
+ header_params = opts[:header_params] || {}
314
+ # HTTP header 'Content-Type'
315
+ content_type = @api_client.select_header_content_type(['application/json', 'multipart/form-data', 'text/plain'])
316
+ if !content_type.nil?
317
+ header_params['Content-Type'] = content_type
318
+ end
319
+ header_params[:'Idempotency-Key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
320
+
321
+ # form parameters
322
+ form_params = opts[:form_params] || {}
323
+
324
+ # http body (model)
325
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(post_api_events_by_event_id_actions_change_object_status_request)
326
+
327
+ # return_type
328
+ return_type = opts[:debug_return_type]
329
+
330
+ # auth_names
331
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth', 'BearerAuth']
332
+
333
+ new_options = opts.merge(
334
+ :operation => :"ObjectStatusApi.post_api_events_by_event_id_actions_change_object_status",
335
+ :header_params => header_params,
336
+ :query_params => query_params,
337
+ :form_params => form_params,
338
+ :body => post_body,
339
+ :auth_names => auth_names,
340
+ :return_type => return_type
341
+ )
342
+
343
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
344
+ if @api_client.config.debugging
345
+ @api_client.config.logger.debug "API called: ObjectStatusApi#post_api_events_by_event_id_actions_change_object_status\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
346
+ end
347
+ return data, status_code, headers
348
+ end
349
+
350
+ # Hold general admission places administratively (issues a GA hold token)
351
+ # Shortcut for `status: \"reservedByToken\"`; only GA quantities are accepted. Administrative status change on the path event. One SQL transaction per event; seats are locked in id order and every precondition is evaluated under those row locks, so a concurrent hold, purchase or other change cannot slip in between the check and the write. Requires **Idempotency-Key**; a replay returns the stored response and a retry after a crash reuses the same durable booking order. **Objects** (max 64 per call, per event): seat UUID or seat label (labels are resolved per event; a label that matches several seats returns 409 `ambiguous_label`; unknown references return 404 `objects_not_found`). General admission areas are addressed by UUID or name **with `quantity`** (1–10000): - `booked`: the places are first reserved in the same Redis structure buyers hold from (capacity minus not-for-sale places), then `sold_count` is incremented in the transaction with a `sold_count + quantity <= capacity` guard; the durable receipt belongs to the administrative booking order (cancel it with POST /orders/{orderId}/cancel). - `reservedByToken` (or POST …/actions/hold, GA only): holds the places atomically against capacity minus withheld, sold and held places and issues a **GA hold token** (`hold: { holdToken, holdUserId, holdExpiresAt }`), confirmable with POST /ga/confirm (`holdToken`, `userId` = `holdUserId`). Optional `userId` (customer identity of the hold; one hold per user and area, 409 `hold_exists`) and `holdExpiresInMinutes` (1–120). 409 `insufficient_capacity`. - `RELEASE` / `free` without `holdToken`: releases places of **administrative** bookings (newest receipts first, optionally only those of `orderId`), recording a release receipt per consumed booking and decrementing `sold_count` under the GA row lock (409 `insufficient_booked_places` with `available`). Buyer purchases are never released here. - `RELEASE` with `holdToken` (GA hold token): releases that many places held by the token (409 `insufficient_held_places`, `hold_token_conflict`). Every GA operation is idempotent per Idempotency-Key (deterministic receipts/holds/markers), and capacity can never be exceeded nor `sold_count` go below zero. Response `gaAreas: { <areaId>: { areaId, label, quantity, soldCount, status, heldCount?, releasedFrom? } }`. **`allowedPreviousStatuses` / `rejectedPreviousStatuses`**: `free`, `booked`, `resale`, `reservedByToken`, `retired` or a custom status. On violation nothing is written and 409 `illegal_previous_status` lists every offending object with its current status. For GA quantities the previous status follows from the operation: `free` for book/hold, `booked` for a release, `reservedByToken` for a release by `holdToken`. **`holdToken`**: with status `booked`, books seats held by that hold token. The hold session is frozen first, so the buyer cannot confirm the same seats concurrently; seats held by another token or not held by this one return 409 `hold_token_conflict`. Remaining seats of the session stay held. With `RELEASE` it releases GA places (see above). **`ticketType`** (per object, `{ objectId, ticketType }`, status `booked` only): ticket type id recorded on the new booking (order item and reservation, like a confirmed sale) and returned per object; it shows up in reports by ticket type. Other statuses return 400. **`keepExtraData`**: keeps the stored extraData; per-object `extraData` sent with it is merged on top (without it, the object's extraData is replaced by the one sent, or cleared). **`ticketBuyerId`** (opaque, ≤ 256 chars, never an internal user id) is recorded on new bookings, object statuses, status history and GA hold tokens; query it with GET /events/{eventId}/objects?ticketBuyerId=…. **`channelKeys`** (channel secret keys or channel ids) restricts the change to public objects and objects of the named channels (409 `channel_forbidden` otherwise). Without `channelKeys`, or with `ignoreChannels: true`, channel partitions are ignored (backward-compatible default). **`events`** (max 50, must include the path event): applies the same change to each event of the tenant, labels resolved per event. By default each event is atomic on its own (no cross-event atomicity): response 200 when every event succeeded, otherwise 207 with `results[]` (`{ eventId, ok, objects | status, error, message }`), `succeeded` and `failed`. Replaying the same Idempotency-Key returns the stored per-event outcome; retry failed events (listed with their error) with a new key. **`atomic: true`** makes the whole call all-or-nothing in one SQL transaction (same engine as POST /events/actions/change-object-status; at most 512 objects across the events): 200 with `atomic: true` when everything was applied, otherwise the status of the first failing event and `results[]` with `outcome: failed` (with `error`, `message`) or `rolled_back` per event — nothing was written. GA administrative holds cannot be atomic (400 `not_atomic`). **`seasonId`** (season or partial season id; XOR with `events`): fans out by unique label to every live member in one transaction (cap 50 members, 64 seats overall). Preconditions and channelKeys apply to every member seat.
352
+ # @param event_id [String]
353
+ # @param post_api_events_by_event_id_actions_change_object_status_request [PostApiEventsByEventIdActionsChangeObjectStatusRequest]
354
+ # @param [Hash] opts the optional parameters
355
+ # @option opts [String] :idempotency_key Required on transactional routes. Reuse the same key for every retry of one logical operation; the API replays the stored outcome.
356
+ # @return [nil]
357
+ def post_api_events_by_event_id_actions_hold(event_id, post_api_events_by_event_id_actions_change_object_status_request, opts = {})
358
+ post_api_events_by_event_id_actions_hold_with_http_info(event_id, post_api_events_by_event_id_actions_change_object_status_request, opts)
359
+ nil
360
+ end
361
+
362
+ # Hold general admission places administratively (issues a GA hold token)
363
+ # Shortcut for &#x60;status: \&quot;reservedByToken\&quot;&#x60;; only GA quantities are accepted. Administrative status change on the path event. One SQL transaction per event; seats are locked in id order and every precondition is evaluated under those row locks, so a concurrent hold, purchase or other change cannot slip in between the check and the write. Requires **Idempotency-Key**; a replay returns the stored response and a retry after a crash reuses the same durable booking order. **Objects** (max 64 per call, per event): seat UUID or seat label (labels are resolved per event; a label that matches several seats returns 409 &#x60;ambiguous_label&#x60;; unknown references return 404 &#x60;objects_not_found&#x60;). General admission areas are addressed by UUID or name **with &#x60;quantity&#x60;** (1–10000): - &#x60;booked&#x60;: the places are first reserved in the same Redis structure buyers hold from (capacity minus not-for-sale places), then &#x60;sold_count&#x60; is incremented in the transaction with a &#x60;sold_count + quantity &lt;&#x3D; capacity&#x60; guard; the durable receipt belongs to the administrative booking order (cancel it with POST /orders/{orderId}/cancel). - &#x60;reservedByToken&#x60; (or POST …/actions/hold, GA only): holds the places atomically against capacity minus withheld, sold and held places and issues a **GA hold token** (&#x60;hold: { holdToken, holdUserId, holdExpiresAt }&#x60;), confirmable with POST /ga/confirm (&#x60;holdToken&#x60;, &#x60;userId&#x60; &#x3D; &#x60;holdUserId&#x60;). Optional &#x60;userId&#x60; (customer identity of the hold; one hold per user and area, 409 &#x60;hold_exists&#x60;) and &#x60;holdExpiresInMinutes&#x60; (1–120). 409 &#x60;insufficient_capacity&#x60;. - &#x60;RELEASE&#x60; / &#x60;free&#x60; without &#x60;holdToken&#x60;: releases places of **administrative** bookings (newest receipts first, optionally only those of &#x60;orderId&#x60;), recording a release receipt per consumed booking and decrementing &#x60;sold_count&#x60; under the GA row lock (409 &#x60;insufficient_booked_places&#x60; with &#x60;available&#x60;). Buyer purchases are never released here. - &#x60;RELEASE&#x60; with &#x60;holdToken&#x60; (GA hold token): releases that many places held by the token (409 &#x60;insufficient_held_places&#x60;, &#x60;hold_token_conflict&#x60;). Every GA operation is idempotent per Idempotency-Key (deterministic receipts/holds/markers), and capacity can never be exceeded nor &#x60;sold_count&#x60; go below zero. Response &#x60;gaAreas: { &lt;areaId&gt;: { areaId, label, quantity, soldCount, status, heldCount?, releasedFrom? } }&#x60;. **&#x60;allowedPreviousStatuses&#x60; / &#x60;rejectedPreviousStatuses&#x60;**: &#x60;free&#x60;, &#x60;booked&#x60;, &#x60;resale&#x60;, &#x60;reservedByToken&#x60;, &#x60;retired&#x60; or a custom status. On violation nothing is written and 409 &#x60;illegal_previous_status&#x60; lists every offending object with its current status. For GA quantities the previous status follows from the operation: &#x60;free&#x60; for book/hold, &#x60;booked&#x60; for a release, &#x60;reservedByToken&#x60; for a release by &#x60;holdToken&#x60;. **&#x60;holdToken&#x60;**: with status &#x60;booked&#x60;, books seats held by that hold token. The hold session is frozen first, so the buyer cannot confirm the same seats concurrently; seats held by another token or not held by this one return 409 &#x60;hold_token_conflict&#x60;. Remaining seats of the session stay held. With &#x60;RELEASE&#x60; it releases GA places (see above). **&#x60;ticketType&#x60;** (per object, &#x60;{ objectId, ticketType }&#x60;, status &#x60;booked&#x60; only): ticket type id recorded on the new booking (order item and reservation, like a confirmed sale) and returned per object; it shows up in reports by ticket type. Other statuses return 400. **&#x60;keepExtraData&#x60;**: keeps the stored extraData; per-object &#x60;extraData&#x60; sent with it is merged on top (without it, the object&#39;s extraData is replaced by the one sent, or cleared). **&#x60;ticketBuyerId&#x60;** (opaque, ≤ 256 chars, never an internal user id) is recorded on new bookings, object statuses, status history and GA hold tokens; query it with GET /events/{eventId}/objects?ticketBuyerId&#x3D;…. **&#x60;channelKeys&#x60;** (channel secret keys or channel ids) restricts the change to public objects and objects of the named channels (409 &#x60;channel_forbidden&#x60; otherwise). Without &#x60;channelKeys&#x60;, or with &#x60;ignoreChannels: true&#x60;, channel partitions are ignored (backward-compatible default). **&#x60;events&#x60;** (max 50, must include the path event): applies the same change to each event of the tenant, labels resolved per event. By default each event is atomic on its own (no cross-event atomicity): response 200 when every event succeeded, otherwise 207 with &#x60;results[]&#x60; (&#x60;{ eventId, ok, objects | status, error, message }&#x60;), &#x60;succeeded&#x60; and &#x60;failed&#x60;. Replaying the same Idempotency-Key returns the stored per-event outcome; retry failed events (listed with their error) with a new key. **&#x60;atomic: true&#x60;** makes the whole call all-or-nothing in one SQL transaction (same engine as POST /events/actions/change-object-status; at most 512 objects across the events): 200 with &#x60;atomic: true&#x60; when everything was applied, otherwise the status of the first failing event and &#x60;results[]&#x60; with &#x60;outcome: failed&#x60; (with &#x60;error&#x60;, &#x60;message&#x60;) or &#x60;rolled_back&#x60; per event — nothing was written. GA administrative holds cannot be atomic (400 &#x60;not_atomic&#x60;). **&#x60;seasonId&#x60;** (season or partial season id; XOR with &#x60;events&#x60;): fans out by unique label to every live member in one transaction (cap 50 members, 64 seats overall). Preconditions and channelKeys apply to every member seat.
364
+ # @param event_id [String]
365
+ # @param post_api_events_by_event_id_actions_change_object_status_request [PostApiEventsByEventIdActionsChangeObjectStatusRequest]
366
+ # @param [Hash] opts the optional parameters
367
+ # @option opts [String] :idempotency_key Required on transactional routes. Reuse the same key for every retry of one logical operation; the API replays the stored outcome.
368
+ # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
369
+ def post_api_events_by_event_id_actions_hold_with_http_info(event_id, post_api_events_by_event_id_actions_change_object_status_request, opts = {})
370
+ if @api_client.config.debugging
371
+ @api_client.config.logger.debug 'Calling API: ObjectStatusApi.post_api_events_by_event_id_actions_hold ...'
372
+ end
373
+ # verify the required parameter 'event_id' is set
374
+ if @api_client.config.client_side_validation && event_id.nil?
375
+ fail ArgumentError, "Missing the required parameter 'event_id' when calling ObjectStatusApi.post_api_events_by_event_id_actions_hold"
376
+ end
377
+ if @api_client.config.client_side_validation && event_id.to_s.length > 36
378
+ fail ArgumentError, 'invalid value for "event_id" when calling ObjectStatusApi.post_api_events_by_event_id_actions_hold, the character length must be smaller than or equal to 36.'
379
+ end
380
+
381
+ if @api_client.config.client_side_validation && event_id.to_s.length < 36
382
+ fail ArgumentError, 'invalid value for "event_id" when calling ObjectStatusApi.post_api_events_by_event_id_actions_hold, the character length must be great than or equal to 36.'
383
+ end
384
+
385
+ # verify the required parameter 'post_api_events_by_event_id_actions_change_object_status_request' is set
386
+ if @api_client.config.client_side_validation && post_api_events_by_event_id_actions_change_object_status_request.nil?
387
+ fail ArgumentError, "Missing the required parameter 'post_api_events_by_event_id_actions_change_object_status_request' when calling ObjectStatusApi.post_api_events_by_event_id_actions_hold"
388
+ end
389
+ if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length > 255
390
+ fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling ObjectStatusApi.post_api_events_by_event_id_actions_hold, the character length must be smaller than or equal to 255.'
391
+ end
392
+
393
+ if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length < 1
394
+ fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling ObjectStatusApi.post_api_events_by_event_id_actions_hold, the character length must be great than or equal to 1.'
395
+ end
396
+
397
+ # resource path
398
+ local_var_path = '/api/events/{eventId}/actions/hold'.sub('{' + 'eventId' + '}', CGI.escape(event_id.to_s))
399
+
400
+ # query parameters
401
+ query_params = opts[:query_params] || {}
402
+
403
+ # header parameters
404
+ header_params = opts[:header_params] || {}
405
+ # HTTP header 'Content-Type'
406
+ content_type = @api_client.select_header_content_type(['application/json', 'multipart/form-data', 'text/plain'])
407
+ if !content_type.nil?
408
+ header_params['Content-Type'] = content_type
409
+ end
410
+ header_params[:'Idempotency-Key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
411
+
412
+ # form parameters
413
+ form_params = opts[:form_params] || {}
414
+
415
+ # http body (model)
416
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(post_api_events_by_event_id_actions_change_object_status_request)
417
+
418
+ # return_type
419
+ return_type = opts[:debug_return_type]
420
+
421
+ # auth_names
422
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth', 'BearerAuth']
423
+
424
+ new_options = opts.merge(
425
+ :operation => :"ObjectStatusApi.post_api_events_by_event_id_actions_hold",
426
+ :header_params => header_params,
427
+ :query_params => query_params,
428
+ :form_params => form_params,
429
+ :body => post_body,
430
+ :auth_names => auth_names,
431
+ :return_type => return_type
432
+ )
433
+
434
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
435
+ if @api_client.config.debugging
436
+ @api_client.config.logger.debug "API called: ObjectStatusApi#post_api_events_by_event_id_actions_hold\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
437
+ end
438
+ return data, status_code, headers
439
+ end
440
+
441
+ # Put booked objects up for resale
442
+ # Resale retains the durable owner and sold status. Optional `resaleListingId` groups the objects into one listing (extraData.resaleListingId). Optional `resalePriceCents` is stored on extraData and merged into GET /seats on the next cache rebuild. Administrative status change on the path event. One SQL transaction per event; seats are locked in id order and every precondition is evaluated under those row locks, so a concurrent hold, purchase or other change cannot slip in between the check and the write. Requires **Idempotency-Key**; a replay returns the stored response and a retry after a crash reuses the same durable booking order. **Objects** (max 64 per call, per event): seat UUID or seat label (labels are resolved per event; a label that matches several seats returns 409 `ambiguous_label`; unknown references return 404 `objects_not_found`). General admission areas are addressed by UUID or name **with `quantity`** (1–10000): - `booked`: the places are first reserved in the same Redis structure buyers hold from (capacity minus not-for-sale places), then `sold_count` is incremented in the transaction with a `sold_count + quantity <= capacity` guard; the durable receipt belongs to the administrative booking order (cancel it with POST /orders/{orderId}/cancel). - `reservedByToken` (or POST …/actions/hold, GA only): holds the places atomically against capacity minus withheld, sold and held places and issues a **GA hold token** (`hold: { holdToken, holdUserId, holdExpiresAt }`), confirmable with POST /ga/confirm (`holdToken`, `userId` = `holdUserId`). Optional `userId` (customer identity of the hold; one hold per user and area, 409 `hold_exists`) and `holdExpiresInMinutes` (1–120). 409 `insufficient_capacity`. - `RELEASE` / `free` without `holdToken`: releases places of **administrative** bookings (newest receipts first, optionally only those of `orderId`), recording a release receipt per consumed booking and decrementing `sold_count` under the GA row lock (409 `insufficient_booked_places` with `available`). Buyer purchases are never released here. - `RELEASE` with `holdToken` (GA hold token): releases that many places held by the token (409 `insufficient_held_places`, `hold_token_conflict`). Every GA operation is idempotent per Idempotency-Key (deterministic receipts/holds/markers), and capacity can never be exceeded nor `sold_count` go below zero. Response `gaAreas: { <areaId>: { areaId, label, quantity, soldCount, status, heldCount?, releasedFrom? } }`. **`allowedPreviousStatuses` / `rejectedPreviousStatuses`**: `free`, `booked`, `resale`, `reservedByToken`, `retired` or a custom status. On violation nothing is written and 409 `illegal_previous_status` lists every offending object with its current status. For GA quantities the previous status follows from the operation: `free` for book/hold, `booked` for a release, `reservedByToken` for a release by `holdToken`. **`holdToken`**: with status `booked`, books seats held by that hold token. The hold session is frozen first, so the buyer cannot confirm the same seats concurrently; seats held by another token or not held by this one return 409 `hold_token_conflict`. Remaining seats of the session stay held. With `RELEASE` it releases GA places (see above). **`ticketType`** (per object, `{ objectId, ticketType }`, status `booked` only): ticket type id recorded on the new booking (order item and reservation, like a confirmed sale) and returned per object; it shows up in reports by ticket type. Other statuses return 400. **`keepExtraData`**: keeps the stored extraData; per-object `extraData` sent with it is merged on top (without it, the object's extraData is replaced by the one sent, or cleared). **`ticketBuyerId`** (opaque, ≤ 256 chars, never an internal user id) is recorded on new bookings, object statuses, status history and GA hold tokens; query it with GET /events/{eventId}/objects?ticketBuyerId=…. **`channelKeys`** (channel secret keys or channel ids) restricts the change to public objects and objects of the named channels (409 `channel_forbidden` otherwise). Without `channelKeys`, or with `ignoreChannels: true`, channel partitions are ignored (backward-compatible default). **`events`** (max 50, must include the path event): applies the same change to each event of the tenant, labels resolved per event. By default each event is atomic on its own (no cross-event atomicity): response 200 when every event succeeded, otherwise 207 with `results[]` (`{ eventId, ok, objects | status, error, message }`), `succeeded` and `failed`. Replaying the same Idempotency-Key returns the stored per-event outcome; retry failed events (listed with their error) with a new key. **`atomic: true`** makes the whole call all-or-nothing in one SQL transaction (same engine as POST /events/actions/change-object-status; at most 512 objects across the events): 200 with `atomic: true` when everything was applied, otherwise the status of the first failing event and `results[]` with `outcome: failed` (with `error`, `message`) or `rolled_back` per event — nothing was written. GA administrative holds cannot be atomic (400 `not_atomic`). **`seasonId`** (season or partial season id; XOR with `events`): fans out by unique label to every live member in one transaction (cap 50 members, 64 seats overall). Preconditions and channelKeys apply to every member seat.
443
+ # @param event_id [String]
444
+ # @param post_api_events_by_event_id_actions_change_object_status_request [PostApiEventsByEventIdActionsChangeObjectStatusRequest]
445
+ # @param [Hash] opts the optional parameters
446
+ # @option opts [String] :idempotency_key Required on transactional routes. Reuse the same key for every retry of one logical operation; the API replays the stored outcome.
447
+ # @return [nil]
448
+ def post_api_events_by_event_id_actions_put_up_for_resale(event_id, post_api_events_by_event_id_actions_change_object_status_request, opts = {})
449
+ post_api_events_by_event_id_actions_put_up_for_resale_with_http_info(event_id, post_api_events_by_event_id_actions_change_object_status_request, opts)
450
+ nil
451
+ end
452
+
453
+ # Put booked objects up for resale
454
+ # Resale retains the durable owner and sold status. Optional &#x60;resaleListingId&#x60; groups the objects into one listing (extraData.resaleListingId). Optional &#x60;resalePriceCents&#x60; is stored on extraData and merged into GET /seats on the next cache rebuild. Administrative status change on the path event. One SQL transaction per event; seats are locked in id order and every precondition is evaluated under those row locks, so a concurrent hold, purchase or other change cannot slip in between the check and the write. Requires **Idempotency-Key**; a replay returns the stored response and a retry after a crash reuses the same durable booking order. **Objects** (max 64 per call, per event): seat UUID or seat label (labels are resolved per event; a label that matches several seats returns 409 &#x60;ambiguous_label&#x60;; unknown references return 404 &#x60;objects_not_found&#x60;). General admission areas are addressed by UUID or name **with &#x60;quantity&#x60;** (1–10000): - &#x60;booked&#x60;: the places are first reserved in the same Redis structure buyers hold from (capacity minus not-for-sale places), then &#x60;sold_count&#x60; is incremented in the transaction with a &#x60;sold_count + quantity &lt;&#x3D; capacity&#x60; guard; the durable receipt belongs to the administrative booking order (cancel it with POST /orders/{orderId}/cancel). - &#x60;reservedByToken&#x60; (or POST …/actions/hold, GA only): holds the places atomically against capacity minus withheld, sold and held places and issues a **GA hold token** (&#x60;hold: { holdToken, holdUserId, holdExpiresAt }&#x60;), confirmable with POST /ga/confirm (&#x60;holdToken&#x60;, &#x60;userId&#x60; &#x3D; &#x60;holdUserId&#x60;). Optional &#x60;userId&#x60; (customer identity of the hold; one hold per user and area, 409 &#x60;hold_exists&#x60;) and &#x60;holdExpiresInMinutes&#x60; (1–120). 409 &#x60;insufficient_capacity&#x60;. - &#x60;RELEASE&#x60; / &#x60;free&#x60; without &#x60;holdToken&#x60;: releases places of **administrative** bookings (newest receipts first, optionally only those of &#x60;orderId&#x60;), recording a release receipt per consumed booking and decrementing &#x60;sold_count&#x60; under the GA row lock (409 &#x60;insufficient_booked_places&#x60; with &#x60;available&#x60;). Buyer purchases are never released here. - &#x60;RELEASE&#x60; with &#x60;holdToken&#x60; (GA hold token): releases that many places held by the token (409 &#x60;insufficient_held_places&#x60;, &#x60;hold_token_conflict&#x60;). Every GA operation is idempotent per Idempotency-Key (deterministic receipts/holds/markers), and capacity can never be exceeded nor &#x60;sold_count&#x60; go below zero. Response &#x60;gaAreas: { &lt;areaId&gt;: { areaId, label, quantity, soldCount, status, heldCount?, releasedFrom? } }&#x60;. **&#x60;allowedPreviousStatuses&#x60; / &#x60;rejectedPreviousStatuses&#x60;**: &#x60;free&#x60;, &#x60;booked&#x60;, &#x60;resale&#x60;, &#x60;reservedByToken&#x60;, &#x60;retired&#x60; or a custom status. On violation nothing is written and 409 &#x60;illegal_previous_status&#x60; lists every offending object with its current status. For GA quantities the previous status follows from the operation: &#x60;free&#x60; for book/hold, &#x60;booked&#x60; for a release, &#x60;reservedByToken&#x60; for a release by &#x60;holdToken&#x60;. **&#x60;holdToken&#x60;**: with status &#x60;booked&#x60;, books seats held by that hold token. The hold session is frozen first, so the buyer cannot confirm the same seats concurrently; seats held by another token or not held by this one return 409 &#x60;hold_token_conflict&#x60;. Remaining seats of the session stay held. With &#x60;RELEASE&#x60; it releases GA places (see above). **&#x60;ticketType&#x60;** (per object, &#x60;{ objectId, ticketType }&#x60;, status &#x60;booked&#x60; only): ticket type id recorded on the new booking (order item and reservation, like a confirmed sale) and returned per object; it shows up in reports by ticket type. Other statuses return 400. **&#x60;keepExtraData&#x60;**: keeps the stored extraData; per-object &#x60;extraData&#x60; sent with it is merged on top (without it, the object&#39;s extraData is replaced by the one sent, or cleared). **&#x60;ticketBuyerId&#x60;** (opaque, ≤ 256 chars, never an internal user id) is recorded on new bookings, object statuses, status history and GA hold tokens; query it with GET /events/{eventId}/objects?ticketBuyerId&#x3D;…. **&#x60;channelKeys&#x60;** (channel secret keys or channel ids) restricts the change to public objects and objects of the named channels (409 &#x60;channel_forbidden&#x60; otherwise). Without &#x60;channelKeys&#x60;, or with &#x60;ignoreChannels: true&#x60;, channel partitions are ignored (backward-compatible default). **&#x60;events&#x60;** (max 50, must include the path event): applies the same change to each event of the tenant, labels resolved per event. By default each event is atomic on its own (no cross-event atomicity): response 200 when every event succeeded, otherwise 207 with &#x60;results[]&#x60; (&#x60;{ eventId, ok, objects | status, error, message }&#x60;), &#x60;succeeded&#x60; and &#x60;failed&#x60;. Replaying the same Idempotency-Key returns the stored per-event outcome; retry failed events (listed with their error) with a new key. **&#x60;atomic: true&#x60;** makes the whole call all-or-nothing in one SQL transaction (same engine as POST /events/actions/change-object-status; at most 512 objects across the events): 200 with &#x60;atomic: true&#x60; when everything was applied, otherwise the status of the first failing event and &#x60;results[]&#x60; with &#x60;outcome: failed&#x60; (with &#x60;error&#x60;, &#x60;message&#x60;) or &#x60;rolled_back&#x60; per event — nothing was written. GA administrative holds cannot be atomic (400 &#x60;not_atomic&#x60;). **&#x60;seasonId&#x60;** (season or partial season id; XOR with &#x60;events&#x60;): fans out by unique label to every live member in one transaction (cap 50 members, 64 seats overall). Preconditions and channelKeys apply to every member seat.
455
+ # @param event_id [String]
456
+ # @param post_api_events_by_event_id_actions_change_object_status_request [PostApiEventsByEventIdActionsChangeObjectStatusRequest]
457
+ # @param [Hash] opts the optional parameters
458
+ # @option opts [String] :idempotency_key Required on transactional routes. Reuse the same key for every retry of one logical operation; the API replays the stored outcome.
459
+ # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
460
+ def post_api_events_by_event_id_actions_put_up_for_resale_with_http_info(event_id, post_api_events_by_event_id_actions_change_object_status_request, opts = {})
461
+ if @api_client.config.debugging
462
+ @api_client.config.logger.debug 'Calling API: ObjectStatusApi.post_api_events_by_event_id_actions_put_up_for_resale ...'
463
+ end
464
+ # verify the required parameter 'event_id' is set
465
+ if @api_client.config.client_side_validation && event_id.nil?
466
+ fail ArgumentError, "Missing the required parameter 'event_id' when calling ObjectStatusApi.post_api_events_by_event_id_actions_put_up_for_resale"
467
+ end
468
+ if @api_client.config.client_side_validation && event_id.to_s.length > 36
469
+ fail ArgumentError, 'invalid value for "event_id" when calling ObjectStatusApi.post_api_events_by_event_id_actions_put_up_for_resale, the character length must be smaller than or equal to 36.'
470
+ end
471
+
472
+ if @api_client.config.client_side_validation && event_id.to_s.length < 36
473
+ fail ArgumentError, 'invalid value for "event_id" when calling ObjectStatusApi.post_api_events_by_event_id_actions_put_up_for_resale, the character length must be great than or equal to 36.'
474
+ end
475
+
476
+ # verify the required parameter 'post_api_events_by_event_id_actions_change_object_status_request' is set
477
+ if @api_client.config.client_side_validation && post_api_events_by_event_id_actions_change_object_status_request.nil?
478
+ fail ArgumentError, "Missing the required parameter 'post_api_events_by_event_id_actions_change_object_status_request' when calling ObjectStatusApi.post_api_events_by_event_id_actions_put_up_for_resale"
479
+ end
480
+ if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length > 255
481
+ fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling ObjectStatusApi.post_api_events_by_event_id_actions_put_up_for_resale, the character length must be smaller than or equal to 255.'
482
+ end
483
+
484
+ if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length < 1
485
+ fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling ObjectStatusApi.post_api_events_by_event_id_actions_put_up_for_resale, the character length must be great than or equal to 1.'
486
+ end
487
+
488
+ # resource path
489
+ local_var_path = '/api/events/{eventId}/actions/put-up-for-resale'.sub('{' + 'eventId' + '}', CGI.escape(event_id.to_s))
490
+
491
+ # query parameters
492
+ query_params = opts[:query_params] || {}
493
+
494
+ # header parameters
495
+ header_params = opts[:header_params] || {}
496
+ # HTTP header 'Content-Type'
497
+ content_type = @api_client.select_header_content_type(['application/json', 'multipart/form-data', 'text/plain'])
498
+ if !content_type.nil?
499
+ header_params['Content-Type'] = content_type
500
+ end
501
+ header_params[:'Idempotency-Key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
502
+
503
+ # form parameters
504
+ form_params = opts[:form_params] || {}
505
+
506
+ # http body (model)
507
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(post_api_events_by_event_id_actions_change_object_status_request)
508
+
509
+ # return_type
510
+ return_type = opts[:debug_return_type]
511
+
512
+ # auth_names
513
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth', 'BearerAuth']
514
+
515
+ new_options = opts.merge(
516
+ :operation => :"ObjectStatusApi.post_api_events_by_event_id_actions_put_up_for_resale",
517
+ :header_params => header_params,
518
+ :query_params => query_params,
519
+ :form_params => form_params,
520
+ :body => post_body,
521
+ :auth_names => auth_names,
522
+ :return_type => return_type
523
+ )
524
+
525
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
526
+ if @api_client.config.debugging
527
+ @api_client.config.logger.debug "API called: ObjectStatusApi#post_api_events_by_event_id_actions_put_up_for_resale\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
528
+ end
529
+ return data, status_code, headers
530
+ end
531
+
532
+ # Release unsold objects; sales require explicit order cancellation
533
+ # Administrative status change on the path event. One SQL transaction per event; seats are locked in id order and every precondition is evaluated under those row locks, so a concurrent hold, purchase or other change cannot slip in between the check and the write. Requires **Idempotency-Key**; a replay returns the stored response and a retry after a crash reuses the same durable booking order. **Objects** (max 64 per call, per event): seat UUID or seat label (labels are resolved per event; a label that matches several seats returns 409 `ambiguous_label`; unknown references return 404 `objects_not_found`). General admission areas are addressed by UUID or name **with `quantity`** (1–10000): - `booked`: the places are first reserved in the same Redis structure buyers hold from (capacity minus not-for-sale places), then `sold_count` is incremented in the transaction with a `sold_count + quantity <= capacity` guard; the durable receipt belongs to the administrative booking order (cancel it with POST /orders/{orderId}/cancel). - `reservedByToken` (or POST …/actions/hold, GA only): holds the places atomically against capacity minus withheld, sold and held places and issues a **GA hold token** (`hold: { holdToken, holdUserId, holdExpiresAt }`), confirmable with POST /ga/confirm (`holdToken`, `userId` = `holdUserId`). Optional `userId` (customer identity of the hold; one hold per user and area, 409 `hold_exists`) and `holdExpiresInMinutes` (1–120). 409 `insufficient_capacity`. - `RELEASE` / `free` without `holdToken`: releases places of **administrative** bookings (newest receipts first, optionally only those of `orderId`), recording a release receipt per consumed booking and decrementing `sold_count` under the GA row lock (409 `insufficient_booked_places` with `available`). Buyer purchases are never released here. - `RELEASE` with `holdToken` (GA hold token): releases that many places held by the token (409 `insufficient_held_places`, `hold_token_conflict`). Every GA operation is idempotent per Idempotency-Key (deterministic receipts/holds/markers), and capacity can never be exceeded nor `sold_count` go below zero. Response `gaAreas: { <areaId>: { areaId, label, quantity, soldCount, status, heldCount?, releasedFrom? } }`. **`allowedPreviousStatuses` / `rejectedPreviousStatuses`**: `free`, `booked`, `resale`, `reservedByToken`, `retired` or a custom status. On violation nothing is written and 409 `illegal_previous_status` lists every offending object with its current status. For GA quantities the previous status follows from the operation: `free` for book/hold, `booked` for a release, `reservedByToken` for a release by `holdToken`. **`holdToken`**: with status `booked`, books seats held by that hold token. The hold session is frozen first, so the buyer cannot confirm the same seats concurrently; seats held by another token or not held by this one return 409 `hold_token_conflict`. Remaining seats of the session stay held. With `RELEASE` it releases GA places (see above). **`ticketType`** (per object, `{ objectId, ticketType }`, status `booked` only): ticket type id recorded on the new booking (order item and reservation, like a confirmed sale) and returned per object; it shows up in reports by ticket type. Other statuses return 400. **`keepExtraData`**: keeps the stored extraData; per-object `extraData` sent with it is merged on top (without it, the object's extraData is replaced by the one sent, or cleared). **`ticketBuyerId`** (opaque, ≤ 256 chars, never an internal user id) is recorded on new bookings, object statuses, status history and GA hold tokens; query it with GET /events/{eventId}/objects?ticketBuyerId=…. **`channelKeys`** (channel secret keys or channel ids) restricts the change to public objects and objects of the named channels (409 `channel_forbidden` otherwise). Without `channelKeys`, or with `ignoreChannels: true`, channel partitions are ignored (backward-compatible default). **`events`** (max 50, must include the path event): applies the same change to each event of the tenant, labels resolved per event. By default each event is atomic on its own (no cross-event atomicity): response 200 when every event succeeded, otherwise 207 with `results[]` (`{ eventId, ok, objects | status, error, message }`), `succeeded` and `failed`. Replaying the same Idempotency-Key returns the stored per-event outcome; retry failed events (listed with their error) with a new key. **`atomic: true`** makes the whole call all-or-nothing in one SQL transaction (same engine as POST /events/actions/change-object-status; at most 512 objects across the events): 200 with `atomic: true` when everything was applied, otherwise the status of the first failing event and `results[]` with `outcome: failed` (with `error`, `message`) or `rolled_back` per event — nothing was written. GA administrative holds cannot be atomic (400 `not_atomic`). **`seasonId`** (season or partial season id; XOR with `events`): fans out by unique label to every live member in one transaction (cap 50 members, 64 seats overall). Preconditions and channelKeys apply to every member seat.
534
+ # @param event_id [String]
535
+ # @param post_api_events_by_event_id_actions_change_object_status_request [PostApiEventsByEventIdActionsChangeObjectStatusRequest]
536
+ # @param [Hash] opts the optional parameters
537
+ # @option opts [String] :idempotency_key Required on transactional routes. Reuse the same key for every retry of one logical operation; the API replays the stored outcome.
538
+ # @return [nil]
539
+ def post_api_events_by_event_id_actions_release(event_id, post_api_events_by_event_id_actions_change_object_status_request, opts = {})
540
+ post_api_events_by_event_id_actions_release_with_http_info(event_id, post_api_events_by_event_id_actions_change_object_status_request, opts)
541
+ nil
542
+ end
543
+
544
+ # Release unsold objects; sales require explicit order cancellation
545
+ # Administrative status change on the path event. One SQL transaction per event; seats are locked in id order and every precondition is evaluated under those row locks, so a concurrent hold, purchase or other change cannot slip in between the check and the write. Requires **Idempotency-Key**; a replay returns the stored response and a retry after a crash reuses the same durable booking order. **Objects** (max 64 per call, per event): seat UUID or seat label (labels are resolved per event; a label that matches several seats returns 409 &#x60;ambiguous_label&#x60;; unknown references return 404 &#x60;objects_not_found&#x60;). General admission areas are addressed by UUID or name **with &#x60;quantity&#x60;** (1–10000): - &#x60;booked&#x60;: the places are first reserved in the same Redis structure buyers hold from (capacity minus not-for-sale places), then &#x60;sold_count&#x60; is incremented in the transaction with a &#x60;sold_count + quantity &lt;&#x3D; capacity&#x60; guard; the durable receipt belongs to the administrative booking order (cancel it with POST /orders/{orderId}/cancel). - &#x60;reservedByToken&#x60; (or POST …/actions/hold, GA only): holds the places atomically against capacity minus withheld, sold and held places and issues a **GA hold token** (&#x60;hold: { holdToken, holdUserId, holdExpiresAt }&#x60;), confirmable with POST /ga/confirm (&#x60;holdToken&#x60;, &#x60;userId&#x60; &#x3D; &#x60;holdUserId&#x60;). Optional &#x60;userId&#x60; (customer identity of the hold; one hold per user and area, 409 &#x60;hold_exists&#x60;) and &#x60;holdExpiresInMinutes&#x60; (1–120). 409 &#x60;insufficient_capacity&#x60;. - &#x60;RELEASE&#x60; / &#x60;free&#x60; without &#x60;holdToken&#x60;: releases places of **administrative** bookings (newest receipts first, optionally only those of &#x60;orderId&#x60;), recording a release receipt per consumed booking and decrementing &#x60;sold_count&#x60; under the GA row lock (409 &#x60;insufficient_booked_places&#x60; with &#x60;available&#x60;). Buyer purchases are never released here. - &#x60;RELEASE&#x60; with &#x60;holdToken&#x60; (GA hold token): releases that many places held by the token (409 &#x60;insufficient_held_places&#x60;, &#x60;hold_token_conflict&#x60;). Every GA operation is idempotent per Idempotency-Key (deterministic receipts/holds/markers), and capacity can never be exceeded nor &#x60;sold_count&#x60; go below zero. Response &#x60;gaAreas: { &lt;areaId&gt;: { areaId, label, quantity, soldCount, status, heldCount?, releasedFrom? } }&#x60;. **&#x60;allowedPreviousStatuses&#x60; / &#x60;rejectedPreviousStatuses&#x60;**: &#x60;free&#x60;, &#x60;booked&#x60;, &#x60;resale&#x60;, &#x60;reservedByToken&#x60;, &#x60;retired&#x60; or a custom status. On violation nothing is written and 409 &#x60;illegal_previous_status&#x60; lists every offending object with its current status. For GA quantities the previous status follows from the operation: &#x60;free&#x60; for book/hold, &#x60;booked&#x60; for a release, &#x60;reservedByToken&#x60; for a release by &#x60;holdToken&#x60;. **&#x60;holdToken&#x60;**: with status &#x60;booked&#x60;, books seats held by that hold token. The hold session is frozen first, so the buyer cannot confirm the same seats concurrently; seats held by another token or not held by this one return 409 &#x60;hold_token_conflict&#x60;. Remaining seats of the session stay held. With &#x60;RELEASE&#x60; it releases GA places (see above). **&#x60;ticketType&#x60;** (per object, &#x60;{ objectId, ticketType }&#x60;, status &#x60;booked&#x60; only): ticket type id recorded on the new booking (order item and reservation, like a confirmed sale) and returned per object; it shows up in reports by ticket type. Other statuses return 400. **&#x60;keepExtraData&#x60;**: keeps the stored extraData; per-object &#x60;extraData&#x60; sent with it is merged on top (without it, the object&#39;s extraData is replaced by the one sent, or cleared). **&#x60;ticketBuyerId&#x60;** (opaque, ≤ 256 chars, never an internal user id) is recorded on new bookings, object statuses, status history and GA hold tokens; query it with GET /events/{eventId}/objects?ticketBuyerId&#x3D;…. **&#x60;channelKeys&#x60;** (channel secret keys or channel ids) restricts the change to public objects and objects of the named channels (409 &#x60;channel_forbidden&#x60; otherwise). Without &#x60;channelKeys&#x60;, or with &#x60;ignoreChannels: true&#x60;, channel partitions are ignored (backward-compatible default). **&#x60;events&#x60;** (max 50, must include the path event): applies the same change to each event of the tenant, labels resolved per event. By default each event is atomic on its own (no cross-event atomicity): response 200 when every event succeeded, otherwise 207 with &#x60;results[]&#x60; (&#x60;{ eventId, ok, objects | status, error, message }&#x60;), &#x60;succeeded&#x60; and &#x60;failed&#x60;. Replaying the same Idempotency-Key returns the stored per-event outcome; retry failed events (listed with their error) with a new key. **&#x60;atomic: true&#x60;** makes the whole call all-or-nothing in one SQL transaction (same engine as POST /events/actions/change-object-status; at most 512 objects across the events): 200 with &#x60;atomic: true&#x60; when everything was applied, otherwise the status of the first failing event and &#x60;results[]&#x60; with &#x60;outcome: failed&#x60; (with &#x60;error&#x60;, &#x60;message&#x60;) or &#x60;rolled_back&#x60; per event — nothing was written. GA administrative holds cannot be atomic (400 &#x60;not_atomic&#x60;). **&#x60;seasonId&#x60;** (season or partial season id; XOR with &#x60;events&#x60;): fans out by unique label to every live member in one transaction (cap 50 members, 64 seats overall). Preconditions and channelKeys apply to every member seat.
546
+ # @param event_id [String]
547
+ # @param post_api_events_by_event_id_actions_change_object_status_request [PostApiEventsByEventIdActionsChangeObjectStatusRequest]
548
+ # @param [Hash] opts the optional parameters
549
+ # @option opts [String] :idempotency_key Required on transactional routes. Reuse the same key for every retry of one logical operation; the API replays the stored outcome.
550
+ # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
551
+ def post_api_events_by_event_id_actions_release_with_http_info(event_id, post_api_events_by_event_id_actions_change_object_status_request, opts = {})
552
+ if @api_client.config.debugging
553
+ @api_client.config.logger.debug 'Calling API: ObjectStatusApi.post_api_events_by_event_id_actions_release ...'
554
+ end
555
+ # verify the required parameter 'event_id' is set
556
+ if @api_client.config.client_side_validation && event_id.nil?
557
+ fail ArgumentError, "Missing the required parameter 'event_id' when calling ObjectStatusApi.post_api_events_by_event_id_actions_release"
558
+ end
559
+ if @api_client.config.client_side_validation && event_id.to_s.length > 36
560
+ fail ArgumentError, 'invalid value for "event_id" when calling ObjectStatusApi.post_api_events_by_event_id_actions_release, the character length must be smaller than or equal to 36.'
561
+ end
562
+
563
+ if @api_client.config.client_side_validation && event_id.to_s.length < 36
564
+ fail ArgumentError, 'invalid value for "event_id" when calling ObjectStatusApi.post_api_events_by_event_id_actions_release, the character length must be great than or equal to 36.'
565
+ end
566
+
567
+ # verify the required parameter 'post_api_events_by_event_id_actions_change_object_status_request' is set
568
+ if @api_client.config.client_side_validation && post_api_events_by_event_id_actions_change_object_status_request.nil?
569
+ fail ArgumentError, "Missing the required parameter 'post_api_events_by_event_id_actions_change_object_status_request' when calling ObjectStatusApi.post_api_events_by_event_id_actions_release"
570
+ end
571
+ if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length > 255
572
+ fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling ObjectStatusApi.post_api_events_by_event_id_actions_release, the character length must be smaller than or equal to 255.'
573
+ end
574
+
575
+ if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length < 1
576
+ fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling ObjectStatusApi.post_api_events_by_event_id_actions_release, the character length must be great than or equal to 1.'
577
+ end
578
+
579
+ # resource path
580
+ local_var_path = '/api/events/{eventId}/actions/release'.sub('{' + 'eventId' + '}', CGI.escape(event_id.to_s))
581
+
582
+ # query parameters
583
+ query_params = opts[:query_params] || {}
584
+
585
+ # header parameters
586
+ header_params = opts[:header_params] || {}
587
+ # HTTP header 'Content-Type'
588
+ content_type = @api_client.select_header_content_type(['application/json', 'multipart/form-data', 'text/plain'])
589
+ if !content_type.nil?
590
+ header_params['Content-Type'] = content_type
591
+ end
592
+ header_params[:'Idempotency-Key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
593
+
594
+ # form parameters
595
+ form_params = opts[:form_params] || {}
596
+
597
+ # http body (model)
598
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(post_api_events_by_event_id_actions_change_object_status_request)
599
+
600
+ # return_type
601
+ return_type = opts[:debug_return_type]
602
+
603
+ # auth_names
604
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth', 'BearerAuth']
605
+
606
+ new_options = opts.merge(
607
+ :operation => :"ObjectStatusApi.post_api_events_by_event_id_actions_release",
608
+ :header_params => header_params,
609
+ :query_params => query_params,
610
+ :form_params => form_params,
611
+ :body => post_body,
612
+ :auth_names => auth_names,
613
+ :return_type => return_type
614
+ )
615
+
616
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
617
+ if @api_client.config.debugging
618
+ @api_client.config.logger.debug "API called: ObjectStatusApi#post_api_events_by_event_id_actions_release\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
619
+ end
620
+ return data, status_code, headers
621
+ end
622
+
623
+ # Retire objects (not for sale, history kept)
624
+ # Administrative status change on the path event. One SQL transaction per event; seats are locked in id order and every precondition is evaluated under those row locks, so a concurrent hold, purchase or other change cannot slip in between the check and the write. Requires **Idempotency-Key**; a replay returns the stored response and a retry after a crash reuses the same durable booking order. **Objects** (max 64 per call, per event): seat UUID or seat label (labels are resolved per event; a label that matches several seats returns 409 `ambiguous_label`; unknown references return 404 `objects_not_found`). General admission areas are addressed by UUID or name **with `quantity`** (1–10000): - `booked`: the places are first reserved in the same Redis structure buyers hold from (capacity minus not-for-sale places), then `sold_count` is incremented in the transaction with a `sold_count + quantity <= capacity` guard; the durable receipt belongs to the administrative booking order (cancel it with POST /orders/{orderId}/cancel). - `reservedByToken` (or POST …/actions/hold, GA only): holds the places atomically against capacity minus withheld, sold and held places and issues a **GA hold token** (`hold: { holdToken, holdUserId, holdExpiresAt }`), confirmable with POST /ga/confirm (`holdToken`, `userId` = `holdUserId`). Optional `userId` (customer identity of the hold; one hold per user and area, 409 `hold_exists`) and `holdExpiresInMinutes` (1–120). 409 `insufficient_capacity`. - `RELEASE` / `free` without `holdToken`: releases places of **administrative** bookings (newest receipts first, optionally only those of `orderId`), recording a release receipt per consumed booking and decrementing `sold_count` under the GA row lock (409 `insufficient_booked_places` with `available`). Buyer purchases are never released here. - `RELEASE` with `holdToken` (GA hold token): releases that many places held by the token (409 `insufficient_held_places`, `hold_token_conflict`). Every GA operation is idempotent per Idempotency-Key (deterministic receipts/holds/markers), and capacity can never be exceeded nor `sold_count` go below zero. Response `gaAreas: { <areaId>: { areaId, label, quantity, soldCount, status, heldCount?, releasedFrom? } }`. **`allowedPreviousStatuses` / `rejectedPreviousStatuses`**: `free`, `booked`, `resale`, `reservedByToken`, `retired` or a custom status. On violation nothing is written and 409 `illegal_previous_status` lists every offending object with its current status. For GA quantities the previous status follows from the operation: `free` for book/hold, `booked` for a release, `reservedByToken` for a release by `holdToken`. **`holdToken`**: with status `booked`, books seats held by that hold token. The hold session is frozen first, so the buyer cannot confirm the same seats concurrently; seats held by another token or not held by this one return 409 `hold_token_conflict`. Remaining seats of the session stay held. With `RELEASE` it releases GA places (see above). **`ticketType`** (per object, `{ objectId, ticketType }`, status `booked` only): ticket type id recorded on the new booking (order item and reservation, like a confirmed sale) and returned per object; it shows up in reports by ticket type. Other statuses return 400. **`keepExtraData`**: keeps the stored extraData; per-object `extraData` sent with it is merged on top (without it, the object's extraData is replaced by the one sent, or cleared). **`ticketBuyerId`** (opaque, ≤ 256 chars, never an internal user id) is recorded on new bookings, object statuses, status history and GA hold tokens; query it with GET /events/{eventId}/objects?ticketBuyerId=…. **`channelKeys`** (channel secret keys or channel ids) restricts the change to public objects and objects of the named channels (409 `channel_forbidden` otherwise). Without `channelKeys`, or with `ignoreChannels: true`, channel partitions are ignored (backward-compatible default). **`events`** (max 50, must include the path event): applies the same change to each event of the tenant, labels resolved per event. By default each event is atomic on its own (no cross-event atomicity): response 200 when every event succeeded, otherwise 207 with `results[]` (`{ eventId, ok, objects | status, error, message }`), `succeeded` and `failed`. Replaying the same Idempotency-Key returns the stored per-event outcome; retry failed events (listed with their error) with a new key. **`atomic: true`** makes the whole call all-or-nothing in one SQL transaction (same engine as POST /events/actions/change-object-status; at most 512 objects across the events): 200 with `atomic: true` when everything was applied, otherwise the status of the first failing event and `results[]` with `outcome: failed` (with `error`, `message`) or `rolled_back` per event — nothing was written. GA administrative holds cannot be atomic (400 `not_atomic`). **`seasonId`** (season or partial season id; XOR with `events`): fans out by unique label to every live member in one transaction (cap 50 members, 64 seats overall). Preconditions and channelKeys apply to every member seat.
625
+ # @param event_id [String]
626
+ # @param post_api_events_by_event_id_actions_change_object_status_request [PostApiEventsByEventIdActionsChangeObjectStatusRequest]
627
+ # @param [Hash] opts the optional parameters
628
+ # @option opts [String] :idempotency_key Required on transactional routes. Reuse the same key for every retry of one logical operation; the API replays the stored outcome.
629
+ # @return [nil]
630
+ def post_api_events_by_event_id_actions_retire(event_id, post_api_events_by_event_id_actions_change_object_status_request, opts = {})
631
+ post_api_events_by_event_id_actions_retire_with_http_info(event_id, post_api_events_by_event_id_actions_change_object_status_request, opts)
632
+ nil
633
+ end
634
+
635
+ # Retire objects (not for sale, history kept)
636
+ # Administrative status change on the path event. One SQL transaction per event; seats are locked in id order and every precondition is evaluated under those row locks, so a concurrent hold, purchase or other change cannot slip in between the check and the write. Requires **Idempotency-Key**; a replay returns the stored response and a retry after a crash reuses the same durable booking order. **Objects** (max 64 per call, per event): seat UUID or seat label (labels are resolved per event; a label that matches several seats returns 409 &#x60;ambiguous_label&#x60;; unknown references return 404 &#x60;objects_not_found&#x60;). General admission areas are addressed by UUID or name **with &#x60;quantity&#x60;** (1–10000): - &#x60;booked&#x60;: the places are first reserved in the same Redis structure buyers hold from (capacity minus not-for-sale places), then &#x60;sold_count&#x60; is incremented in the transaction with a &#x60;sold_count + quantity &lt;&#x3D; capacity&#x60; guard; the durable receipt belongs to the administrative booking order (cancel it with POST /orders/{orderId}/cancel). - &#x60;reservedByToken&#x60; (or POST …/actions/hold, GA only): holds the places atomically against capacity minus withheld, sold and held places and issues a **GA hold token** (&#x60;hold: { holdToken, holdUserId, holdExpiresAt }&#x60;), confirmable with POST /ga/confirm (&#x60;holdToken&#x60;, &#x60;userId&#x60; &#x3D; &#x60;holdUserId&#x60;). Optional &#x60;userId&#x60; (customer identity of the hold; one hold per user and area, 409 &#x60;hold_exists&#x60;) and &#x60;holdExpiresInMinutes&#x60; (1–120). 409 &#x60;insufficient_capacity&#x60;. - &#x60;RELEASE&#x60; / &#x60;free&#x60; without &#x60;holdToken&#x60;: releases places of **administrative** bookings (newest receipts first, optionally only those of &#x60;orderId&#x60;), recording a release receipt per consumed booking and decrementing &#x60;sold_count&#x60; under the GA row lock (409 &#x60;insufficient_booked_places&#x60; with &#x60;available&#x60;). Buyer purchases are never released here. - &#x60;RELEASE&#x60; with &#x60;holdToken&#x60; (GA hold token): releases that many places held by the token (409 &#x60;insufficient_held_places&#x60;, &#x60;hold_token_conflict&#x60;). Every GA operation is idempotent per Idempotency-Key (deterministic receipts/holds/markers), and capacity can never be exceeded nor &#x60;sold_count&#x60; go below zero. Response &#x60;gaAreas: { &lt;areaId&gt;: { areaId, label, quantity, soldCount, status, heldCount?, releasedFrom? } }&#x60;. **&#x60;allowedPreviousStatuses&#x60; / &#x60;rejectedPreviousStatuses&#x60;**: &#x60;free&#x60;, &#x60;booked&#x60;, &#x60;resale&#x60;, &#x60;reservedByToken&#x60;, &#x60;retired&#x60; or a custom status. On violation nothing is written and 409 &#x60;illegal_previous_status&#x60; lists every offending object with its current status. For GA quantities the previous status follows from the operation: &#x60;free&#x60; for book/hold, &#x60;booked&#x60; for a release, &#x60;reservedByToken&#x60; for a release by &#x60;holdToken&#x60;. **&#x60;holdToken&#x60;**: with status &#x60;booked&#x60;, books seats held by that hold token. The hold session is frozen first, so the buyer cannot confirm the same seats concurrently; seats held by another token or not held by this one return 409 &#x60;hold_token_conflict&#x60;. Remaining seats of the session stay held. With &#x60;RELEASE&#x60; it releases GA places (see above). **&#x60;ticketType&#x60;** (per object, &#x60;{ objectId, ticketType }&#x60;, status &#x60;booked&#x60; only): ticket type id recorded on the new booking (order item and reservation, like a confirmed sale) and returned per object; it shows up in reports by ticket type. Other statuses return 400. **&#x60;keepExtraData&#x60;**: keeps the stored extraData; per-object &#x60;extraData&#x60; sent with it is merged on top (without it, the object&#39;s extraData is replaced by the one sent, or cleared). **&#x60;ticketBuyerId&#x60;** (opaque, ≤ 256 chars, never an internal user id) is recorded on new bookings, object statuses, status history and GA hold tokens; query it with GET /events/{eventId}/objects?ticketBuyerId&#x3D;…. **&#x60;channelKeys&#x60;** (channel secret keys or channel ids) restricts the change to public objects and objects of the named channels (409 &#x60;channel_forbidden&#x60; otherwise). Without &#x60;channelKeys&#x60;, or with &#x60;ignoreChannels: true&#x60;, channel partitions are ignored (backward-compatible default). **&#x60;events&#x60;** (max 50, must include the path event): applies the same change to each event of the tenant, labels resolved per event. By default each event is atomic on its own (no cross-event atomicity): response 200 when every event succeeded, otherwise 207 with &#x60;results[]&#x60; (&#x60;{ eventId, ok, objects | status, error, message }&#x60;), &#x60;succeeded&#x60; and &#x60;failed&#x60;. Replaying the same Idempotency-Key returns the stored per-event outcome; retry failed events (listed with their error) with a new key. **&#x60;atomic: true&#x60;** makes the whole call all-or-nothing in one SQL transaction (same engine as POST /events/actions/change-object-status; at most 512 objects across the events): 200 with &#x60;atomic: true&#x60; when everything was applied, otherwise the status of the first failing event and &#x60;results[]&#x60; with &#x60;outcome: failed&#x60; (with &#x60;error&#x60;, &#x60;message&#x60;) or &#x60;rolled_back&#x60; per event — nothing was written. GA administrative holds cannot be atomic (400 &#x60;not_atomic&#x60;). **&#x60;seasonId&#x60;** (season or partial season id; XOR with &#x60;events&#x60;): fans out by unique label to every live member in one transaction (cap 50 members, 64 seats overall). Preconditions and channelKeys apply to every member seat.
637
+ # @param event_id [String]
638
+ # @param post_api_events_by_event_id_actions_change_object_status_request [PostApiEventsByEventIdActionsChangeObjectStatusRequest]
639
+ # @param [Hash] opts the optional parameters
640
+ # @option opts [String] :idempotency_key Required on transactional routes. Reuse the same key for every retry of one logical operation; the API replays the stored outcome.
641
+ # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
642
+ def post_api_events_by_event_id_actions_retire_with_http_info(event_id, post_api_events_by_event_id_actions_change_object_status_request, opts = {})
643
+ if @api_client.config.debugging
644
+ @api_client.config.logger.debug 'Calling API: ObjectStatusApi.post_api_events_by_event_id_actions_retire ...'
645
+ end
646
+ # verify the required parameter 'event_id' is set
647
+ if @api_client.config.client_side_validation && event_id.nil?
648
+ fail ArgumentError, "Missing the required parameter 'event_id' when calling ObjectStatusApi.post_api_events_by_event_id_actions_retire"
649
+ end
650
+ if @api_client.config.client_side_validation && event_id.to_s.length > 36
651
+ fail ArgumentError, 'invalid value for "event_id" when calling ObjectStatusApi.post_api_events_by_event_id_actions_retire, the character length must be smaller than or equal to 36.'
652
+ end
653
+
654
+ if @api_client.config.client_side_validation && event_id.to_s.length < 36
655
+ fail ArgumentError, 'invalid value for "event_id" when calling ObjectStatusApi.post_api_events_by_event_id_actions_retire, the character length must be great than or equal to 36.'
656
+ end
657
+
658
+ # verify the required parameter 'post_api_events_by_event_id_actions_change_object_status_request' is set
659
+ if @api_client.config.client_side_validation && post_api_events_by_event_id_actions_change_object_status_request.nil?
660
+ fail ArgumentError, "Missing the required parameter 'post_api_events_by_event_id_actions_change_object_status_request' when calling ObjectStatusApi.post_api_events_by_event_id_actions_retire"
661
+ end
662
+ if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length > 255
663
+ fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling ObjectStatusApi.post_api_events_by_event_id_actions_retire, the character length must be smaller than or equal to 255.'
664
+ end
665
+
666
+ if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length < 1
667
+ fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling ObjectStatusApi.post_api_events_by_event_id_actions_retire, the character length must be great than or equal to 1.'
668
+ end
669
+
670
+ # resource path
671
+ local_var_path = '/api/events/{eventId}/actions/retire'.sub('{' + 'eventId' + '}', CGI.escape(event_id.to_s))
672
+
673
+ # query parameters
674
+ query_params = opts[:query_params] || {}
675
+
676
+ # header parameters
677
+ header_params = opts[:header_params] || {}
678
+ # HTTP header 'Content-Type'
679
+ content_type = @api_client.select_header_content_type(['application/json', 'multipart/form-data', 'text/plain'])
680
+ if !content_type.nil?
681
+ header_params['Content-Type'] = content_type
682
+ end
683
+ header_params[:'Idempotency-Key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
684
+
685
+ # form parameters
686
+ form_params = opts[:form_params] || {}
687
+
688
+ # http body (model)
689
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(post_api_events_by_event_id_actions_change_object_status_request)
690
+
691
+ # return_type
692
+ return_type = opts[:debug_return_type]
693
+
694
+ # auth_names
695
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth', 'BearerAuth']
696
+
697
+ new_options = opts.merge(
698
+ :operation => :"ObjectStatusApi.post_api_events_by_event_id_actions_retire",
699
+ :header_params => header_params,
700
+ :query_params => query_params,
701
+ :form_params => form_params,
702
+ :body => post_body,
703
+ :auth_names => auth_names,
704
+ :return_type => return_type
705
+ )
706
+
707
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
708
+ if @api_client.config.debugging
709
+ @api_client.config.logger.debug "API called: ObjectStatusApi#post_api_events_by_event_id_actions_retire\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
710
+ end
711
+ return data, status_code, headers
712
+ end
713
+
714
+ # Update extraData of objects without changing their status
715
+ # Sets (default) or merges (`merge: true`) `extraData` on up to 64 seats addressed by UUID or label; `extraData: null` clears it. Status, ownership, holds and for-sale flags are never touched. Runs under the same seat row locks as status changes, so it cannot interleave with a concurrent transition. Max 16 KiB of JSON per object. Requires **Idempotency-Key** (replays return the stored response). Every update is written to the audit log (`object.extra_data.update`).
716
+ # @param event_id [String]
717
+ # @param post_api_events_by_event_id_actions_update_extra_data_request [PostApiEventsByEventIdActionsUpdateExtraDataRequest]
718
+ # @param [Hash] opts the optional parameters
719
+ # @option opts [String] :idempotency_key Required on transactional routes. Reuse the same key for every retry of one logical operation; the API replays the stored outcome.
720
+ # @return [nil]
721
+ def post_api_events_by_event_id_actions_update_extra_data(event_id, post_api_events_by_event_id_actions_update_extra_data_request, opts = {})
722
+ post_api_events_by_event_id_actions_update_extra_data_with_http_info(event_id, post_api_events_by_event_id_actions_update_extra_data_request, opts)
723
+ nil
724
+ end
725
+
726
+ # Update extraData of objects without changing their status
727
+ # Sets (default) or merges (&#x60;merge: true&#x60;) &#x60;extraData&#x60; on up to 64 seats addressed by UUID or label; &#x60;extraData: null&#x60; clears it. Status, ownership, holds and for-sale flags are never touched. Runs under the same seat row locks as status changes, so it cannot interleave with a concurrent transition. Max 16 KiB of JSON per object. Requires **Idempotency-Key** (replays return the stored response). Every update is written to the audit log (&#x60;object.extra_data.update&#x60;).
728
+ # @param event_id [String]
729
+ # @param post_api_events_by_event_id_actions_update_extra_data_request [PostApiEventsByEventIdActionsUpdateExtraDataRequest]
730
+ # @param [Hash] opts the optional parameters
731
+ # @option opts [String] :idempotency_key Required on transactional routes. Reuse the same key for every retry of one logical operation; the API replays the stored outcome.
732
+ # @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
733
+ def post_api_events_by_event_id_actions_update_extra_data_with_http_info(event_id, post_api_events_by_event_id_actions_update_extra_data_request, opts = {})
734
+ if @api_client.config.debugging
735
+ @api_client.config.logger.debug 'Calling API: ObjectStatusApi.post_api_events_by_event_id_actions_update_extra_data ...'
736
+ end
737
+ # verify the required parameter 'event_id' is set
738
+ if @api_client.config.client_side_validation && event_id.nil?
739
+ fail ArgumentError, "Missing the required parameter 'event_id' when calling ObjectStatusApi.post_api_events_by_event_id_actions_update_extra_data"
740
+ end
741
+ if @api_client.config.client_side_validation && event_id.to_s.length > 36
742
+ fail ArgumentError, 'invalid value for "event_id" when calling ObjectStatusApi.post_api_events_by_event_id_actions_update_extra_data, the character length must be smaller than or equal to 36.'
743
+ end
744
+
745
+ if @api_client.config.client_side_validation && event_id.to_s.length < 36
746
+ fail ArgumentError, 'invalid value for "event_id" when calling ObjectStatusApi.post_api_events_by_event_id_actions_update_extra_data, the character length must be great than or equal to 36.'
747
+ end
748
+
749
+ # verify the required parameter 'post_api_events_by_event_id_actions_update_extra_data_request' is set
750
+ if @api_client.config.client_side_validation && post_api_events_by_event_id_actions_update_extra_data_request.nil?
751
+ fail ArgumentError, "Missing the required parameter 'post_api_events_by_event_id_actions_update_extra_data_request' when calling ObjectStatusApi.post_api_events_by_event_id_actions_update_extra_data"
752
+ end
753
+ if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length > 255
754
+ fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling ObjectStatusApi.post_api_events_by_event_id_actions_update_extra_data, the character length must be smaller than or equal to 255.'
755
+ end
756
+
757
+ if @api_client.config.client_side_validation && !opts[:'idempotency_key'].nil? && opts[:'idempotency_key'].to_s.length < 1
758
+ fail ArgumentError, 'invalid value for "opts[:"idempotency_key"]" when calling ObjectStatusApi.post_api_events_by_event_id_actions_update_extra_data, the character length must be great than or equal to 1.'
759
+ end
760
+
761
+ # resource path
762
+ local_var_path = '/api/events/{eventId}/actions/update-extra-data'.sub('{' + 'eventId' + '}', CGI.escape(event_id.to_s))
763
+
764
+ # query parameters
765
+ query_params = opts[:query_params] || {}
766
+
767
+ # header parameters
768
+ header_params = opts[:header_params] || {}
769
+ # HTTP header 'Content-Type'
770
+ content_type = @api_client.select_header_content_type(['application/json', 'multipart/form-data', 'text/plain'])
771
+ if !content_type.nil?
772
+ header_params['Content-Type'] = content_type
773
+ end
774
+ header_params[:'Idempotency-Key'] = opts[:'idempotency_key'] if !opts[:'idempotency_key'].nil?
775
+
776
+ # form parameters
777
+ form_params = opts[:form_params] || {}
778
+
779
+ # http body (model)
780
+ post_body = opts[:debug_body] || @api_client.object_to_http_body(post_api_events_by_event_id_actions_update_extra_data_request)
781
+
782
+ # return_type
783
+ return_type = opts[:debug_return_type]
784
+
785
+ # auth_names
786
+ auth_names = opts[:debug_auth_names] || ['ApiKeyAuth', 'BearerAuth']
787
+
788
+ new_options = opts.merge(
789
+ :operation => :"ObjectStatusApi.post_api_events_by_event_id_actions_update_extra_data",
790
+ :header_params => header_params,
791
+ :query_params => query_params,
792
+ :form_params => form_params,
793
+ :body => post_body,
794
+ :auth_names => auth_names,
795
+ :return_type => return_type
796
+ )
797
+
798
+ data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
799
+ if @api_client.config.debugging
800
+ @api_client.config.logger.debug "API called: ObjectStatusApi#post_api_events_by_event_id_actions_update_extra_data\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
801
+ end
802
+ return data, status_code, headers
803
+ end
804
+ end
805
+ end