apologist 1.0.2

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 (137) hide show
  1. checksums.yaml +7 -0
  2. data/.fern/metadata.json +13 -0
  3. data/.fernignore +2 -0
  4. data/.rubocop.yml +108 -0
  5. data/CONTRIBUTING.md +120 -0
  6. data/README.md +169 -0
  7. data/Rakefile +20 -0
  8. data/custom.gemspec.rb +17 -0
  9. data/lib/Apologist/benchmarks/client.rb +160 -0
  10. data/lib/Apologist/benchmarks/types/benchmark_run_request.rb +39 -0
  11. data/lib/Apologist/benchmarks/types/benchmark_run_request_content.rb +16 -0
  12. data/lib/Apologist/benchmarks/types/benchmark_run_request_reasoning_effort.rb +15 -0
  13. data/lib/Apologist/benchmarks/types/benchmark_run_request_verbosity.rb +16 -0
  14. data/lib/Apologist/benchmarks/types/get_benchmark_run_request.rb +13 -0
  15. data/lib/Apologist/benchmarks/types/get_benchmark_run_response.rb +11 -0
  16. data/lib/Apologist/benchmarks/types/list_benchmark_runs_request.rb +33 -0
  17. data/lib/Apologist/benchmarks/types/list_benchmark_runs_response.rb +17 -0
  18. data/lib/Apologist/channels/client.rb +319 -0
  19. data/lib/Apologist/channels/types/get_discord_channel_status_request.rb +11 -0
  20. data/lib/Apologist/channels/types/get_discord_channel_status_response.rb +15 -0
  21. data/lib/Apologist/channels/types/get_instagram_privacy_policy_request.rb +11 -0
  22. data/lib/Apologist/channels/types/receive_discord_interaction_request.rb +17 -0
  23. data/lib/Apologist/channels/types/receive_facebook_message_request.rb +13 -0
  24. data/lib/Apologist/channels/types/receive_telegram_update_request.rb +13 -0
  25. data/lib/Apologist/channels/types/receive_twilio_message_request.rb +15 -0
  26. data/lib/Apologist/channels/types/verify_facebook_webhook_request.rb +17 -0
  27. data/lib/Apologist/channels/types/verify_facebook_webhook_request_hub_mode.rb +13 -0
  28. data/lib/Apologist/chat/client.rb +345 -0
  29. data/lib/Apologist/chat/types/feedback_request.rb +13 -0
  30. data/lib/Apologist/chat/types/flag_request.rb +13 -0
  31. data/lib/Apologist/chat/types/get_chat_completion_request.rb +11 -0
  32. data/lib/Apologist/chat/types/get_chat_completion_response.rb +11 -0
  33. data/lib/Apologist/chat/types/like_request.rb +13 -0
  34. data/lib/Apologist/chat/types/list_chat_completions_request.rb +45 -0
  35. data/lib/Apologist/chat/types/list_chat_completions_response.rb +17 -0
  36. data/lib/Apologist/chat/types/share_request.rb +17 -0
  37. data/lib/Apologist/client.rb +71 -0
  38. data/lib/Apologist/corpus/client.rb +244 -0
  39. data/lib/Apologist/corpus/types/corpus_search_request.rb +17 -0
  40. data/lib/Apologist/corpus/types/corpus_search_request_filters.rb +25 -0
  41. data/lib/Apologist/corpus/types/impression_request.rb +17 -0
  42. data/lib/Apologist/corpus/types/log_corpus_referral_redirect_request.rb +19 -0
  43. data/lib/Apologist/corpus/types/referral_request.rb +17 -0
  44. data/lib/Apologist/corpus/types/search_corpus_response.rb +11 -0
  45. data/lib/Apologist/corpus/types/view_request.rb +17 -0
  46. data/lib/Apologist/ct_as/client.rb +98 -0
  47. data/lib/Apologist/ct_as/types/cta_click_request.rb +13 -0
  48. data/lib/Apologist/ct_as/types/match_ctas_response.rb +11 -0
  49. data/lib/Apologist/environment.rb +7 -0
  50. data/lib/Apologist/errors/api_error.rb +8 -0
  51. data/lib/Apologist/errors/client_error.rb +17 -0
  52. data/lib/Apologist/errors/redirect_error.rb +8 -0
  53. data/lib/Apologist/errors/response_error.rb +42 -0
  54. data/lib/Apologist/errors/server_error.rb +11 -0
  55. data/lib/Apologist/errors/timeout_error.rb +8 -0
  56. data/lib/Apologist/evaluators/client.rb +164 -0
  57. data/lib/Apologist/evaluators/types/evaluate_content_response.rb +11 -0
  58. data/lib/Apologist/evaluators/types/evaluator_request.rb +31 -0
  59. data/lib/Apologist/evaluators/types/evaluator_request_content.rb +15 -0
  60. data/lib/Apologist/evaluators/types/evaluator_request_reasoning_effort.rb +15 -0
  61. data/lib/Apologist/evaluators/types/evaluator_request_verbosity.rb +16 -0
  62. data/lib/Apologist/evaluators/types/get_evaluation_request.rb +13 -0
  63. data/lib/Apologist/evaluators/types/get_evaluation_response.rb +11 -0
  64. data/lib/Apologist/evaluators/types/list_evaluations_request.rb +35 -0
  65. data/lib/Apologist/evaluators/types/list_evaluations_response.rb +17 -0
  66. data/lib/Apologist/internal/errors/constraint_error.rb +10 -0
  67. data/lib/Apologist/internal/errors/type_error.rb +10 -0
  68. data/lib/Apologist/internal/http/base_request.rb +51 -0
  69. data/lib/Apologist/internal/http/raw_client.rb +252 -0
  70. data/lib/Apologist/internal/iterators/cursor_item_iterator.rb +28 -0
  71. data/lib/Apologist/internal/iterators/cursor_page_iterator.rb +63 -0
  72. data/lib/Apologist/internal/iterators/item_iterator.rb +65 -0
  73. data/lib/Apologist/internal/iterators/offset_item_iterator.rb +30 -0
  74. data/lib/Apologist/internal/iterators/offset_page_iterator.rb +103 -0
  75. data/lib/Apologist/internal/json/request.rb +41 -0
  76. data/lib/Apologist/internal/json/serializable.rb +25 -0
  77. data/lib/Apologist/internal/multipart/multipart_encoder.rb +141 -0
  78. data/lib/Apologist/internal/multipart/multipart_form_data.rb +78 -0
  79. data/lib/Apologist/internal/multipart/multipart_form_data_part.rb +51 -0
  80. data/lib/Apologist/internal/multipart/multipart_request.rb +40 -0
  81. data/lib/Apologist/internal/types/array.rb +47 -0
  82. data/lib/Apologist/internal/types/boolean.rb +34 -0
  83. data/lib/Apologist/internal/types/enum.rb +56 -0
  84. data/lib/Apologist/internal/types/hash.rb +36 -0
  85. data/lib/Apologist/internal/types/model/field.rb +38 -0
  86. data/lib/Apologist/internal/types/model.rb +208 -0
  87. data/lib/Apologist/internal/types/type.rb +35 -0
  88. data/lib/Apologist/internal/types/union.rb +161 -0
  89. data/lib/Apologist/internal/types/unknown.rb +15 -0
  90. data/lib/Apologist/internal/types/utils.rb +116 -0
  91. data/lib/Apologist/internal/url_encoded/request.rb +41 -0
  92. data/lib/Apologist/shares/client.rb +52 -0
  93. data/lib/Apologist/shares/types/get_shared_messages_request.rb +11 -0
  94. data/lib/Apologist/shares/types/get_shared_messages_response.rb +11 -0
  95. data/lib/Apologist/types/chat_completion_request.rb +11 -0
  96. data/lib/Apologist/types/chat_completion_request_logprobs.rb +13 -0
  97. data/lib/Apologist/types/chat_completion_request_metadata.rb +29 -0
  98. data/lib/Apologist/types/chat_completion_request_reasoning_effort.rb +13 -0
  99. data/lib/Apologist/types/chat_completion_request_response_format.rb +11 -0
  100. data/lib/Apologist/types/chat_completion_request_response_format_json_schema.rb +17 -0
  101. data/lib/Apologist/types/chat_completion_request_response_format_type.rb +15 -0
  102. data/lib/Apologist/types/chat_completion_request_tool_choice.rb +13 -0
  103. data/lib/Apologist/types/chat_completion_request_tool_choice_zero.rb +13 -0
  104. data/lib/Apologist/types/chat_completion_request_verbosity.rb +14 -0
  105. data/lib/Apologist/types/chat_completion_response.rb +21 -0
  106. data/lib/Apologist/types/chat_completion_response_choices_item.rb +15 -0
  107. data/lib/Apologist/types/chat_completion_response_usage.rb +13 -0
  108. data/lib/Apologist/types/chat_message.rb +11 -0
  109. data/lib/Apologist/types/chat_message_role.rb +13 -0
  110. data/lib/Apologist/types/cta_match_request.rb +11 -0
  111. data/lib/Apologist/types/error.rb +11 -0
  112. data/lib/Apologist/types/success_response.rb +11 -0
  113. data/lib/Apologist/types/tag_ref.rb +11 -0
  114. data/lib/Apologist/types/user.rb +23 -0
  115. data/lib/Apologist/types/user_flag.rb +18 -0
  116. data/lib/Apologist/types/webhook_agent_ref.rb +11 -0
  117. data/lib/Apologist/types/webhook_cta.rb +13 -0
  118. data/lib/Apologist/types/webhook_evaluation.rb +14 -0
  119. data/lib/Apologist/types/webhook_event_info.rb +13 -0
  120. data/lib/Apologist/types/webhook_event_info_key.rb +28 -0
  121. data/lib/Apologist/types/webhook_named_ref.rb +11 -0
  122. data/lib/Apologist/types/webhook_notification_ref.rb +12 -0
  123. data/lib/Apologist/types/webhook_payload.rb +30 -0
  124. data/lib/Apologist/users/client.rb +193 -0
  125. data/lib/Apologist/users/types/get_user_request.rb +11 -0
  126. data/lib/Apologist/users/types/get_user_response.rb +11 -0
  127. data/lib/Apologist/users/types/list_user_flags_request.rb +13 -0
  128. data/lib/Apologist/users/types/list_user_flags_response.rb +17 -0
  129. data/lib/Apologist/users/types/list_users_request.rb +23 -0
  130. data/lib/Apologist/users/types/list_users_response.rb +17 -0
  131. data/lib/Apologist/users/types/update_user_response.rb +11 -0
  132. data/lib/Apologist/users/types/user_update_request.rb +17 -0
  133. data/lib/Apologist/users/types/user_update_request_tags_item.rb +15 -0
  134. data/lib/Apologist/version.rb +5 -0
  135. data/lib/Apologist.rb +131 -0
  136. data/reference.md +2927 -0
  137. metadata +183 -0
data/reference.md ADDED
@@ -0,0 +1,2927 @@
1
+ # Reference
2
+ ## Chat
3
+ <details><summary><code>client.chat.<a href="/lib/Apologist/chat/client.rb">list_chat_completions</a>() -> Apologist::Chat::Types::ListChatCompletionsResponse</code></summary>
4
+ <dl>
5
+ <dd>
6
+
7
+ #### 📝 Description
8
+
9
+ <dl>
10
+ <dd>
11
+
12
+ <dl>
13
+ <dd>
14
+
15
+ Returns a paginated list of chat completions (prompts) for the agent, with applied tags expanded as { id, name } and share metadata.
16
+ </dd>
17
+ </dl>
18
+ </dd>
19
+ </dl>
20
+
21
+ #### 🔌 Usage
22
+
23
+ <dl>
24
+ <dd>
25
+
26
+ <dl>
27
+ <dd>
28
+
29
+ ```ruby
30
+ client.chat.list_chat_completions
31
+ ```
32
+ </dd>
33
+ </dl>
34
+ </dd>
35
+ </dl>
36
+
37
+ #### ⚙️ Parameters
38
+
39
+ <dl>
40
+ <dd>
41
+
42
+ <dl>
43
+ <dd>
44
+
45
+ **page:** `Integer`
46
+
47
+ </dd>
48
+ </dl>
49
+
50
+ <dl>
51
+ <dd>
52
+
53
+ **per_page:** `Integer` — Results per page (clamped to 100).
54
+
55
+ </dd>
56
+ </dl>
57
+
58
+ <dl>
59
+ <dd>
60
+
61
+ **agent_id:** `String`
62
+
63
+ </dd>
64
+ </dl>
65
+
66
+ <dl>
67
+ <dd>
68
+
69
+ **channel_id:** `String`
70
+
71
+ </dd>
72
+ </dl>
73
+
74
+ <dl>
75
+ <dd>
76
+
77
+ **bible_id:** `String`
78
+
79
+ </dd>
80
+ </dl>
81
+
82
+ <dl>
83
+ <dd>
84
+
85
+ **cached:** `String`
86
+
87
+ </dd>
88
+ </dl>
89
+
90
+ <dl>
91
+ <dd>
92
+
93
+ **client:** `String`
94
+
95
+ </dd>
96
+ </dl>
97
+
98
+ <dl>
99
+ <dd>
100
+
101
+ **config_id:** `String`
102
+
103
+ </dd>
104
+ </dl>
105
+
106
+ <dl>
107
+ <dd>
108
+
109
+ **conversation_id:** `String`
110
+
111
+ </dd>
112
+ </dl>
113
+
114
+ <dl>
115
+ <dd>
116
+
117
+ **device_id:** `String`
118
+
119
+ </dd>
120
+ </dl>
121
+
122
+ <dl>
123
+ <dd>
124
+
125
+ **flagged:** `String`
126
+
127
+ </dd>
128
+ </dl>
129
+
130
+ <dl>
131
+ <dd>
132
+
133
+ **favorited:** `String`
134
+
135
+ </dd>
136
+ </dl>
137
+
138
+ <dl>
139
+ <dd>
140
+
141
+ **language:** `String`
142
+
143
+ </dd>
144
+ </dl>
145
+
146
+ <dl>
147
+ <dd>
148
+
149
+ **liked:** `String`
150
+
151
+ </dd>
152
+ </dl>
153
+
154
+ <dl>
155
+ <dd>
156
+
157
+ **session_id:** `String`
158
+
159
+ </dd>
160
+ </dl>
161
+
162
+ <dl>
163
+ <dd>
164
+
165
+ **user_id:** `String`
166
+
167
+ </dd>
168
+ </dl>
169
+
170
+ <dl>
171
+ <dd>
172
+
173
+ **min_timestamp:** `String`
174
+
175
+ </dd>
176
+ </dl>
177
+
178
+ <dl>
179
+ <dd>
180
+
181
+ **max_timestamp:** `String`
182
+
183
+ </dd>
184
+ </dl>
185
+
186
+ <dl>
187
+ <dd>
188
+
189
+ **request_options:** `Apologist::Chat::RequestOptions`
190
+
191
+ </dd>
192
+ </dl>
193
+ </dd>
194
+ </dl>
195
+
196
+
197
+ </dd>
198
+ </dl>
199
+ </details>
200
+
201
+ <details><summary><code>client.chat.<a href="/lib/Apologist/chat/client.rb">create_chat_completion</a>(request) -> Apologist::Types::ChatCompletionResponse</code></summary>
202
+ <dl>
203
+ <dd>
204
+
205
+ #### 📝 Description
206
+
207
+ <dl>
208
+ <dd>
209
+
210
+ <dl>
211
+ <dd>
212
+
213
+ Creates a chat completion using the agent's configured model. Supports both streaming and non-streaming responses.
214
+ </dd>
215
+ </dl>
216
+ </dd>
217
+ </dl>
218
+
219
+ #### 🔌 Usage
220
+
221
+ <dl>
222
+ <dd>
223
+
224
+ <dl>
225
+ <dd>
226
+
227
+ ```ruby
228
+ client.chat.create_chat_completion(request: {
229
+ key: "value"
230
+ })
231
+ ```
232
+ </dd>
233
+ </dl>
234
+ </dd>
235
+ </dl>
236
+
237
+ #### ⚙️ Parameters
238
+
239
+ <dl>
240
+ <dd>
241
+
242
+ <dl>
243
+ <dd>
244
+
245
+ **request:** `Apologist::Types::ChatCompletionRequest`
246
+
247
+ </dd>
248
+ </dl>
249
+
250
+ <dl>
251
+ <dd>
252
+
253
+ **request_options:** `Apologist::Chat::RequestOptions`
254
+
255
+ </dd>
256
+ </dl>
257
+ </dd>
258
+ </dl>
259
+
260
+
261
+ </dd>
262
+ </dl>
263
+ </details>
264
+
265
+ <details><summary><code>client.chat.<a href="/lib/Apologist/chat/client.rb">like_completion</a>(id:, request) -> Apologist::Types::SuccessResponse</code></summary>
266
+ <dl>
267
+ <dd>
268
+
269
+ #### 📝 Description
270
+
271
+ <dl>
272
+ <dd>
273
+
274
+ <dl>
275
+ <dd>
276
+
277
+ Updates the like status of a specific chat completion
278
+ </dd>
279
+ </dl>
280
+ </dd>
281
+ </dl>
282
+
283
+ #### 🔌 Usage
284
+
285
+ <dl>
286
+ <dd>
287
+
288
+ <dl>
289
+ <dd>
290
+
291
+ ```ruby
292
+ client.chat.like_completion(
293
+ id: "id",
294
+ liked: true
295
+ )
296
+ ```
297
+ </dd>
298
+ </dl>
299
+ </dd>
300
+ </dl>
301
+
302
+ #### ⚙️ Parameters
303
+
304
+ <dl>
305
+ <dd>
306
+
307
+ <dl>
308
+ <dd>
309
+
310
+ **id:** `String` — The ID of the chat completion
311
+
312
+ </dd>
313
+ </dl>
314
+
315
+ <dl>
316
+ <dd>
317
+
318
+ **liked:** `Internal::Types::Boolean`
319
+
320
+ </dd>
321
+ </dl>
322
+
323
+ <dl>
324
+ <dd>
325
+
326
+ **request_options:** `Apologist::Chat::RequestOptions`
327
+
328
+ </dd>
329
+ </dl>
330
+ </dd>
331
+ </dl>
332
+
333
+
334
+ </dd>
335
+ </dl>
336
+ </details>
337
+
338
+ <details><summary><code>client.chat.<a href="/lib/Apologist/chat/client.rb">flag_completion</a>(id:, request) -> Apologist::Types::SuccessResponse</code></summary>
339
+ <dl>
340
+ <dd>
341
+
342
+ #### 📝 Description
343
+
344
+ <dl>
345
+ <dd>
346
+
347
+ <dl>
348
+ <dd>
349
+
350
+ Updates the flagged status of a specific chat completion
351
+ </dd>
352
+ </dl>
353
+ </dd>
354
+ </dl>
355
+
356
+ #### 🔌 Usage
357
+
358
+ <dl>
359
+ <dd>
360
+
361
+ <dl>
362
+ <dd>
363
+
364
+ ```ruby
365
+ client.chat.flag_completion(
366
+ id: "id",
367
+ flagged: true
368
+ )
369
+ ```
370
+ </dd>
371
+ </dl>
372
+ </dd>
373
+ </dl>
374
+
375
+ #### ⚙️ Parameters
376
+
377
+ <dl>
378
+ <dd>
379
+
380
+ <dl>
381
+ <dd>
382
+
383
+ **id:** `String` — The ID of the chat completion
384
+
385
+ </dd>
386
+ </dl>
387
+
388
+ <dl>
389
+ <dd>
390
+
391
+ **flagged:** `Internal::Types::Boolean`
392
+
393
+ </dd>
394
+ </dl>
395
+
396
+ <dl>
397
+ <dd>
398
+
399
+ **request_options:** `Apologist::Chat::RequestOptions`
400
+
401
+ </dd>
402
+ </dl>
403
+ </dd>
404
+ </dl>
405
+
406
+
407
+ </dd>
408
+ </dl>
409
+ </details>
410
+
411
+ <details><summary><code>client.chat.<a href="/lib/Apologist/chat/client.rb">feedback_completion</a>(id:, request) -> Apologist::Types::SuccessResponse</code></summary>
412
+ <dl>
413
+ <dd>
414
+
415
+ #### 📝 Description
416
+
417
+ <dl>
418
+ <dd>
419
+
420
+ <dl>
421
+ <dd>
422
+
423
+ Adds user feedback to a specific chat completion
424
+ </dd>
425
+ </dl>
426
+ </dd>
427
+ </dl>
428
+
429
+ #### 🔌 Usage
430
+
431
+ <dl>
432
+ <dd>
433
+
434
+ <dl>
435
+ <dd>
436
+
437
+ ```ruby
438
+ client.chat.feedback_completion(
439
+ id: "id",
440
+ feedback: "feedback"
441
+ )
442
+ ```
443
+ </dd>
444
+ </dl>
445
+ </dd>
446
+ </dl>
447
+
448
+ #### ⚙️ Parameters
449
+
450
+ <dl>
451
+ <dd>
452
+
453
+ <dl>
454
+ <dd>
455
+
456
+ **id:** `String` — The ID of the chat completion
457
+
458
+ </dd>
459
+ </dl>
460
+
461
+ <dl>
462
+ <dd>
463
+
464
+ **feedback:** `String`
465
+
466
+ </dd>
467
+ </dl>
468
+
469
+ <dl>
470
+ <dd>
471
+
472
+ **request_options:** `Apologist::Chat::RequestOptions`
473
+
474
+ </dd>
475
+ </dl>
476
+ </dd>
477
+ </dl>
478
+
479
+
480
+ </dd>
481
+ </dl>
482
+ </details>
483
+
484
+ <details><summary><code>client.chat.<a href="/lib/Apologist/chat/client.rb">share_completion</a>(id:, request) -> Apologist::Types::SuccessResponse</code></summary>
485
+ <dl>
486
+ <dd>
487
+
488
+ #### 📝 Description
489
+
490
+ <dl>
491
+ <dd>
492
+
493
+ <dl>
494
+ <dd>
495
+
496
+ Creates a share record for a specific chat completion
497
+ </dd>
498
+ </dl>
499
+ </dd>
500
+ </dl>
501
+
502
+ #### 🔌 Usage
503
+
504
+ <dl>
505
+ <dd>
506
+
507
+ <dl>
508
+ <dd>
509
+
510
+ ```ruby
511
+ client.chat.share_completion(id: "id")
512
+ ```
513
+ </dd>
514
+ </dl>
515
+ </dd>
516
+ </dl>
517
+
518
+ #### ⚙️ Parameters
519
+
520
+ <dl>
521
+ <dd>
522
+
523
+ <dl>
524
+ <dd>
525
+
526
+ **id:** `String` — The ID of the chat completion
527
+
528
+ </dd>
529
+ </dl>
530
+
531
+ <dl>
532
+ <dd>
533
+
534
+ **conversation_id:** `String`
535
+
536
+ </dd>
537
+ </dl>
538
+
539
+ <dl>
540
+ <dd>
541
+
542
+ **session_id:** `String`
543
+
544
+ </dd>
545
+ </dl>
546
+
547
+ <dl>
548
+ <dd>
549
+
550
+ **user_id:** `String`
551
+
552
+ </dd>
553
+ </dl>
554
+
555
+ <dl>
556
+ <dd>
557
+
558
+ **request_options:** `Apologist::Chat::RequestOptions`
559
+
560
+ </dd>
561
+ </dl>
562
+ </dd>
563
+ </dl>
564
+
565
+
566
+ </dd>
567
+ </dl>
568
+ </details>
569
+
570
+ <details><summary><code>client.chat.<a href="/lib/Apologist/chat/client.rb">get_chat_completion</a>(id:) -> Apologist::Chat::Types::GetChatCompletionResponse</code></summary>
571
+ <dl>
572
+ <dd>
573
+
574
+ #### 📝 Description
575
+
576
+ <dl>
577
+ <dd>
578
+
579
+ <dl>
580
+ <dd>
581
+
582
+ Returns a single chat completion (prompt) by numeric id or UUID, including applied tags, guardrail/cta metadata, share metadata, and automation results.
583
+ </dd>
584
+ </dl>
585
+ </dd>
586
+ </dl>
587
+
588
+ #### 🔌 Usage
589
+
590
+ <dl>
591
+ <dd>
592
+
593
+ <dl>
594
+ <dd>
595
+
596
+ ```ruby
597
+ client.chat.get_chat_completion(id: "id")
598
+ ```
599
+ </dd>
600
+ </dl>
601
+ </dd>
602
+ </dl>
603
+
604
+ #### ⚙️ Parameters
605
+
606
+ <dl>
607
+ <dd>
608
+
609
+ <dl>
610
+ <dd>
611
+
612
+ **id:** `String` — The numeric id or UUID of the chat completion
613
+
614
+ </dd>
615
+ </dl>
616
+
617
+ <dl>
618
+ <dd>
619
+
620
+ **request_options:** `Apologist::Chat::RequestOptions`
621
+
622
+ </dd>
623
+ </dl>
624
+ </dd>
625
+ </dl>
626
+
627
+
628
+ </dd>
629
+ </dl>
630
+ </details>
631
+
632
+ ## Corpus
633
+ <details><summary><code>client.corpus.<a href="/lib/Apologist/corpus/client.rb">search_corpus</a>(request) -> Apologist::Corpus::Types::SearchCorpusResponse</code></summary>
634
+ <dl>
635
+ <dd>
636
+
637
+ #### 📝 Description
638
+
639
+ <dl>
640
+ <dd>
641
+
642
+ <dl>
643
+ <dd>
644
+
645
+ Performs a semantic search across the agent's corpus of knowledge
646
+ </dd>
647
+ </dl>
648
+ </dd>
649
+ </dl>
650
+
651
+ #### 🔌 Usage
652
+
653
+ <dl>
654
+ <dd>
655
+
656
+ <dl>
657
+ <dd>
658
+
659
+ ```ruby
660
+ client.corpus.search_corpus(query: "query")
661
+ ```
662
+ </dd>
663
+ </dl>
664
+ </dd>
665
+ </dl>
666
+
667
+ #### ⚙️ Parameters
668
+
669
+ <dl>
670
+ <dd>
671
+
672
+ <dl>
673
+ <dd>
674
+
675
+ **query:** `String`
676
+
677
+ </dd>
678
+ </dl>
679
+
680
+ <dl>
681
+ <dd>
682
+
683
+ **prompt_id:** `String`
684
+
685
+ </dd>
686
+ </dl>
687
+
688
+ <dl>
689
+ <dd>
690
+
691
+ **limit:** `Integer`
692
+
693
+ </dd>
694
+ </dl>
695
+
696
+ <dl>
697
+ <dd>
698
+
699
+ **filters:** `Apologist::Corpus::Types::CorpusSearchRequestFilters`
700
+
701
+ </dd>
702
+ </dl>
703
+
704
+ <dl>
705
+ <dd>
706
+
707
+ **request_options:** `Apologist::Corpus::RequestOptions`
708
+
709
+ </dd>
710
+ </dl>
711
+ </dd>
712
+ </dl>
713
+
714
+
715
+ </dd>
716
+ </dl>
717
+ </details>
718
+
719
+ <details><summary><code>client.corpus.<a href="/lib/Apologist/corpus/client.rb">log_corpus_view</a>(model:, id:, request) -> Apologist::Types::SuccessResponse</code></summary>
720
+ <dl>
721
+ <dd>
722
+
723
+ #### 📝 Description
724
+
725
+ <dl>
726
+ <dd>
727
+
728
+ <dl>
729
+ <dd>
730
+
731
+ Records that a user viewed a specific corpus item
732
+ </dd>
733
+ </dl>
734
+ </dd>
735
+ </dl>
736
+
737
+ #### 🔌 Usage
738
+
739
+ <dl>
740
+ <dd>
741
+
742
+ <dl>
743
+ <dd>
744
+
745
+ ```ruby
746
+ client.corpus.log_corpus_view(
747
+ model: "model",
748
+ id: "id",
749
+ prompt_id: "prompt_id"
750
+ )
751
+ ```
752
+ </dd>
753
+ </dl>
754
+ </dd>
755
+ </dl>
756
+
757
+ #### ⚙️ Parameters
758
+
759
+ <dl>
760
+ <dd>
761
+
762
+ <dl>
763
+ <dd>
764
+
765
+ **model:** `String` — The model type (e.g., 'source')
766
+
767
+ </dd>
768
+ </dl>
769
+
770
+ <dl>
771
+ <dd>
772
+
773
+ **id:** `String` — The ID of the corpus item
774
+
775
+ </dd>
776
+ </dl>
777
+
778
+ <dl>
779
+ <dd>
780
+
781
+ **prompt_id:** `String`
782
+
783
+ </dd>
784
+ </dl>
785
+
786
+ <dl>
787
+ <dd>
788
+
789
+ **user_id:** `String`
790
+
791
+ </dd>
792
+ </dl>
793
+
794
+ <dl>
795
+ <dd>
796
+
797
+ **request_options:** `Apologist::Corpus::RequestOptions`
798
+
799
+ </dd>
800
+ </dl>
801
+ </dd>
802
+ </dl>
803
+
804
+
805
+ </dd>
806
+ </dl>
807
+ </details>
808
+
809
+ <details><summary><code>client.corpus.<a href="/lib/Apologist/corpus/client.rb">log_corpus_impression</a>(model:, id:, request) -> Apologist::Types::SuccessResponse</code></summary>
810
+ <dl>
811
+ <dd>
812
+
813
+ #### 📝 Description
814
+
815
+ <dl>
816
+ <dd>
817
+
818
+ <dl>
819
+ <dd>
820
+
821
+ Records that a corpus item was shown to a user
822
+ </dd>
823
+ </dl>
824
+ </dd>
825
+ </dl>
826
+
827
+ #### 🔌 Usage
828
+
829
+ <dl>
830
+ <dd>
831
+
832
+ <dl>
833
+ <dd>
834
+
835
+ ```ruby
836
+ client.corpus.log_corpus_impression(
837
+ model: "model",
838
+ id: "id",
839
+ prompt_id: "prompt_id"
840
+ )
841
+ ```
842
+ </dd>
843
+ </dl>
844
+ </dd>
845
+ </dl>
846
+
847
+ #### ⚙️ Parameters
848
+
849
+ <dl>
850
+ <dd>
851
+
852
+ <dl>
853
+ <dd>
854
+
855
+ **model:** `String` — The model type (e.g., 'source')
856
+
857
+ </dd>
858
+ </dl>
859
+
860
+ <dl>
861
+ <dd>
862
+
863
+ **id:** `String` — The ID of the corpus item
864
+
865
+ </dd>
866
+ </dl>
867
+
868
+ <dl>
869
+ <dd>
870
+
871
+ **prompt_id:** `String`
872
+
873
+ </dd>
874
+ </dl>
875
+
876
+ <dl>
877
+ <dd>
878
+
879
+ **user_id:** `String`
880
+
881
+ </dd>
882
+ </dl>
883
+
884
+ <dl>
885
+ <dd>
886
+
887
+ **request_options:** `Apologist::Corpus::RequestOptions`
888
+
889
+ </dd>
890
+ </dl>
891
+ </dd>
892
+ </dl>
893
+
894
+
895
+ </dd>
896
+ </dl>
897
+ </details>
898
+
899
+ <details><summary><code>client.corpus.<a href="/lib/Apologist/corpus/client.rb">log_corpus_referral_redirect</a>(model:, id:) -> Apologist::Types::SuccessResponse</code></summary>
900
+ <dl>
901
+ <dd>
902
+
903
+ #### 📝 Description
904
+
905
+ <dl>
906
+ <dd>
907
+
908
+ <dl>
909
+ <dd>
910
+
911
+ Records a referral for a corpus item and, when a `url` is supplied, issues a 302 redirect to it. Without a `url`, responds with a success message. Requires either the search API entitlement or a same-origin request.
912
+ </dd>
913
+ </dl>
914
+ </dd>
915
+ </dl>
916
+
917
+ #### 🔌 Usage
918
+
919
+ <dl>
920
+ <dd>
921
+
922
+ <dl>
923
+ <dd>
924
+
925
+ ```ruby
926
+ client.corpus.log_corpus_referral_redirect(
927
+ model: "model",
928
+ id: "id",
929
+ prompt_id: "prompt_id"
930
+ )
931
+ ```
932
+ </dd>
933
+ </dl>
934
+ </dd>
935
+ </dl>
936
+
937
+ #### ⚙️ Parameters
938
+
939
+ <dl>
940
+ <dd>
941
+
942
+ <dl>
943
+ <dd>
944
+
945
+ **model:** `String` — The model type (e.g., 'source')
946
+
947
+ </dd>
948
+ </dl>
949
+
950
+ <dl>
951
+ <dd>
952
+
953
+ **id:** `String` — The numeric ID of the corpus item
954
+
955
+ </dd>
956
+ </dl>
957
+
958
+ <dl>
959
+ <dd>
960
+
961
+ **prompt_id:** `String`
962
+
963
+ </dd>
964
+ </dl>
965
+
966
+ <dl>
967
+ <dd>
968
+
969
+ **user_id:** `String`
970
+
971
+ </dd>
972
+ </dl>
973
+
974
+ <dl>
975
+ <dd>
976
+
977
+ **url:** `String` — URL-encoded destination to redirect to after logging the referral.
978
+
979
+ </dd>
980
+ </dl>
981
+
982
+ <dl>
983
+ <dd>
984
+
985
+ **request_options:** `Apologist::Corpus::RequestOptions`
986
+
987
+ </dd>
988
+ </dl>
989
+ </dd>
990
+ </dl>
991
+
992
+
993
+ </dd>
994
+ </dl>
995
+ </details>
996
+
997
+ <details><summary><code>client.corpus.<a href="/lib/Apologist/corpus/client.rb">log_corpus_referral</a>(model:, id:, request) -> Apologist::Types::SuccessResponse</code></summary>
998
+ <dl>
999
+ <dd>
1000
+
1001
+ #### 📝 Description
1002
+
1003
+ <dl>
1004
+ <dd>
1005
+
1006
+ <dl>
1007
+ <dd>
1008
+
1009
+ Records that a user was referred to a corpus item
1010
+ </dd>
1011
+ </dl>
1012
+ </dd>
1013
+ </dl>
1014
+
1015
+ #### 🔌 Usage
1016
+
1017
+ <dl>
1018
+ <dd>
1019
+
1020
+ <dl>
1021
+ <dd>
1022
+
1023
+ ```ruby
1024
+ client.corpus.log_corpus_referral(
1025
+ model: "model",
1026
+ id: "id",
1027
+ prompt_id: "prompt_id"
1028
+ )
1029
+ ```
1030
+ </dd>
1031
+ </dl>
1032
+ </dd>
1033
+ </dl>
1034
+
1035
+ #### ⚙️ Parameters
1036
+
1037
+ <dl>
1038
+ <dd>
1039
+
1040
+ <dl>
1041
+ <dd>
1042
+
1043
+ **model:** `String` — The model type (e.g., 'source')
1044
+
1045
+ </dd>
1046
+ </dl>
1047
+
1048
+ <dl>
1049
+ <dd>
1050
+
1051
+ **id:** `String` — The ID of the corpus item
1052
+
1053
+ </dd>
1054
+ </dl>
1055
+
1056
+ <dl>
1057
+ <dd>
1058
+
1059
+ **prompt_id:** `String`
1060
+
1061
+ </dd>
1062
+ </dl>
1063
+
1064
+ <dl>
1065
+ <dd>
1066
+
1067
+ **user_id:** `String`
1068
+
1069
+ </dd>
1070
+ </dl>
1071
+
1072
+ <dl>
1073
+ <dd>
1074
+
1075
+ **request_options:** `Apologist::Corpus::RequestOptions`
1076
+
1077
+ </dd>
1078
+ </dl>
1079
+ </dd>
1080
+ </dl>
1081
+
1082
+
1083
+ </dd>
1084
+ </dl>
1085
+ </details>
1086
+
1087
+ ## Evaluators
1088
+ <details><summary><code>client.evaluators.<a href="/lib/Apologist/evaluators/client.rb">list_evaluations</a>(id:) -> Apologist::Evaluators::Types::ListEvaluationsResponse</code></summary>
1089
+ <dl>
1090
+ <dd>
1091
+
1092
+ #### 📝 Description
1093
+
1094
+ <dl>
1095
+ <dd>
1096
+
1097
+ <dl>
1098
+ <dd>
1099
+
1100
+ Returns a paginated list of evaluations for the evaluator, scoped to the requesting agent.
1101
+ </dd>
1102
+ </dl>
1103
+ </dd>
1104
+ </dl>
1105
+
1106
+ #### 🔌 Usage
1107
+
1108
+ <dl>
1109
+ <dd>
1110
+
1111
+ <dl>
1112
+ <dd>
1113
+
1114
+ ```ruby
1115
+ client.evaluators.list_evaluations(id: "id")
1116
+ ```
1117
+ </dd>
1118
+ </dl>
1119
+ </dd>
1120
+ </dl>
1121
+
1122
+ #### ⚙️ Parameters
1123
+
1124
+ <dl>
1125
+ <dd>
1126
+
1127
+ <dl>
1128
+ <dd>
1129
+
1130
+ **id:** `String` — The ID or key of the evaluator
1131
+
1132
+ </dd>
1133
+ </dl>
1134
+
1135
+ <dl>
1136
+ <dd>
1137
+
1138
+ **page:** `Integer`
1139
+
1140
+ </dd>
1141
+ </dl>
1142
+
1143
+ <dl>
1144
+ <dd>
1145
+
1146
+ **per_page:** `Integer` — Results per page (clamped to 100).
1147
+
1148
+ </dd>
1149
+ </dl>
1150
+
1151
+ <dl>
1152
+ <dd>
1153
+
1154
+ **min_timestamp:** `String`
1155
+
1156
+ </dd>
1157
+ </dl>
1158
+
1159
+ <dl>
1160
+ <dd>
1161
+
1162
+ **max_timestamp:** `String`
1163
+
1164
+ </dd>
1165
+ </dl>
1166
+
1167
+ <dl>
1168
+ <dd>
1169
+
1170
+ **min_duration:** `String`
1171
+
1172
+ </dd>
1173
+ </dl>
1174
+
1175
+ <dl>
1176
+ <dd>
1177
+
1178
+ **max_duration:** `String`
1179
+
1180
+ </dd>
1181
+ </dl>
1182
+
1183
+ <dl>
1184
+ <dd>
1185
+
1186
+ **min_score:** `String`
1187
+
1188
+ </dd>
1189
+ </dl>
1190
+
1191
+ <dl>
1192
+ <dd>
1193
+
1194
+ **max_score:** `String`
1195
+
1196
+ </dd>
1197
+ </dl>
1198
+
1199
+ <dl>
1200
+ <dd>
1201
+
1202
+ **passed:** `String`
1203
+
1204
+ </dd>
1205
+ </dl>
1206
+
1207
+ <dl>
1208
+ <dd>
1209
+
1210
+ **benchmark:** `String`
1211
+
1212
+ </dd>
1213
+ </dl>
1214
+
1215
+ <dl>
1216
+ <dd>
1217
+
1218
+ **benchmark_run_id:** `String`
1219
+
1220
+ </dd>
1221
+ </dl>
1222
+
1223
+ <dl>
1224
+ <dd>
1225
+
1226
+ **benchmark_question_id:** `String`
1227
+
1228
+ </dd>
1229
+ </dl>
1230
+
1231
+ <dl>
1232
+ <dd>
1233
+
1234
+ **request_options:** `Apologist::Evaluators::RequestOptions`
1235
+
1236
+ </dd>
1237
+ </dl>
1238
+ </dd>
1239
+ </dl>
1240
+
1241
+
1242
+ </dd>
1243
+ </dl>
1244
+ </details>
1245
+
1246
+ <details><summary><code>client.evaluators.<a href="/lib/Apologist/evaluators/client.rb">evaluate_content</a>(id:, request) -> Apologist::Evaluators::Types::EvaluateContentResponse</code></summary>
1247
+ <dl>
1248
+ <dd>
1249
+
1250
+ #### 📝 Description
1251
+
1252
+ <dl>
1253
+ <dd>
1254
+
1255
+ <dl>
1256
+ <dd>
1257
+
1258
+ Runs an evaluation on the provided content using the specified evaluator
1259
+ </dd>
1260
+ </dl>
1261
+ </dd>
1262
+ </dl>
1263
+
1264
+ #### 🔌 Usage
1265
+
1266
+ <dl>
1267
+ <dd>
1268
+
1269
+ <dl>
1270
+ <dd>
1271
+
1272
+ ```ruby
1273
+ client.evaluators.evaluate_content(
1274
+ id: "id",
1275
+ content: "content"
1276
+ )
1277
+ ```
1278
+ </dd>
1279
+ </dl>
1280
+ </dd>
1281
+ </dl>
1282
+
1283
+ #### ⚙️ Parameters
1284
+
1285
+ <dl>
1286
+ <dd>
1287
+
1288
+ <dl>
1289
+ <dd>
1290
+
1291
+ **id:** `String` — The ID or key of the evaluator
1292
+
1293
+ </dd>
1294
+ </dl>
1295
+
1296
+ <dl>
1297
+ <dd>
1298
+
1299
+ **frequency_penalty:** `Integer`
1300
+
1301
+ </dd>
1302
+ </dl>
1303
+
1304
+ <dl>
1305
+ <dd>
1306
+
1307
+ **confidence_threshold:** `Integer`
1308
+
1309
+ </dd>
1310
+ </dl>
1311
+
1312
+ <dl>
1313
+ <dd>
1314
+
1315
+ **content:** `Apologist::Evaluators::Types::EvaluatorRequestContent`
1316
+
1317
+ </dd>
1318
+ </dl>
1319
+
1320
+ <dl>
1321
+ <dd>
1322
+
1323
+ **model:** `String`
1324
+
1325
+ </dd>
1326
+ </dl>
1327
+
1328
+ <dl>
1329
+ <dd>
1330
+
1331
+ **presence_penalty:** `Integer`
1332
+
1333
+ </dd>
1334
+ </dl>
1335
+
1336
+ <dl>
1337
+ <dd>
1338
+
1339
+ **reasoning_effort:** `Apologist::Evaluators::Types::EvaluatorRequestReasoningEffort`
1340
+
1341
+ </dd>
1342
+ </dl>
1343
+
1344
+ <dl>
1345
+ <dd>
1346
+
1347
+ **verbosity:** `Apologist::Evaluators::Types::EvaluatorRequestVerbosity`
1348
+
1349
+ </dd>
1350
+ </dl>
1351
+
1352
+ <dl>
1353
+ <dd>
1354
+
1355
+ **temperature:** `Integer`
1356
+
1357
+ </dd>
1358
+ </dl>
1359
+
1360
+ <dl>
1361
+ <dd>
1362
+
1363
+ **top_p:** `Integer`
1364
+
1365
+ </dd>
1366
+ </dl>
1367
+
1368
+ <dl>
1369
+ <dd>
1370
+
1371
+ **variables:** `Internal::Types::Hash[String, String]` — Flat string key/value pairs substituted into `{key}` placeholders in the evaluator prompt. Reserved keys (`options`, `option_descriptions`, `criteria`) cannot be overridden. Not persisted; omitted from the response.
1372
+
1373
+ </dd>
1374
+ </dl>
1375
+
1376
+ <dl>
1377
+ <dd>
1378
+
1379
+ **request_options:** `Apologist::Evaluators::RequestOptions`
1380
+
1381
+ </dd>
1382
+ </dl>
1383
+ </dd>
1384
+ </dl>
1385
+
1386
+
1387
+ </dd>
1388
+ </dl>
1389
+ </details>
1390
+
1391
+ <details><summary><code>client.evaluators.<a href="/lib/Apologist/evaluators/client.rb">get_evaluation</a>(id:, evaluation_id:) -> Apologist::Evaluators::Types::GetEvaluationResponse</code></summary>
1392
+ <dl>
1393
+ <dd>
1394
+
1395
+ #### 📝 Description
1396
+
1397
+ <dl>
1398
+ <dd>
1399
+
1400
+ <dl>
1401
+ <dd>
1402
+
1403
+ Returns a single evaluation for the evaluator, scoped to the requesting agent.
1404
+ </dd>
1405
+ </dl>
1406
+ </dd>
1407
+ </dl>
1408
+
1409
+ #### 🔌 Usage
1410
+
1411
+ <dl>
1412
+ <dd>
1413
+
1414
+ <dl>
1415
+ <dd>
1416
+
1417
+ ```ruby
1418
+ client.evaluators.get_evaluation(
1419
+ id: "id",
1420
+ evaluation_id: "evaluationId"
1421
+ )
1422
+ ```
1423
+ </dd>
1424
+ </dl>
1425
+ </dd>
1426
+ </dl>
1427
+
1428
+ #### ⚙️ Parameters
1429
+
1430
+ <dl>
1431
+ <dd>
1432
+
1433
+ <dl>
1434
+ <dd>
1435
+
1436
+ **id:** `String` — The id or key of the evaluator
1437
+
1438
+ </dd>
1439
+ </dl>
1440
+
1441
+ <dl>
1442
+ <dd>
1443
+
1444
+ **evaluation_id:** `String` — The id or UUID of the evaluation
1445
+
1446
+ </dd>
1447
+ </dl>
1448
+
1449
+ <dl>
1450
+ <dd>
1451
+
1452
+ **request_options:** `Apologist::Evaluators::RequestOptions`
1453
+
1454
+ </dd>
1455
+ </dl>
1456
+ </dd>
1457
+ </dl>
1458
+
1459
+
1460
+ </dd>
1461
+ </dl>
1462
+ </details>
1463
+
1464
+ ## CTAs
1465
+ <details><summary><code>client.ct_as.<a href="/lib/Apologist/ct_as/client.rb">match_ctas</a>(request) -> Apologist::CtAs::Types::MatchCtasResponse</code></summary>
1466
+ <dl>
1467
+ <dd>
1468
+
1469
+ #### 📝 Description
1470
+
1471
+ <dl>
1472
+ <dd>
1473
+
1474
+ <dl>
1475
+ <dd>
1476
+
1477
+ Finds matching CTAs based on conversation context, user, session, device, or messages
1478
+ </dd>
1479
+ </dl>
1480
+ </dd>
1481
+ </dl>
1482
+
1483
+ #### 🔌 Usage
1484
+
1485
+ <dl>
1486
+ <dd>
1487
+
1488
+ <dl>
1489
+ <dd>
1490
+
1491
+ ```ruby
1492
+ client.ct_as.match_ctas(request: {
1493
+ key: "value"
1494
+ })
1495
+ ```
1496
+ </dd>
1497
+ </dl>
1498
+ </dd>
1499
+ </dl>
1500
+
1501
+ #### ⚙️ Parameters
1502
+
1503
+ <dl>
1504
+ <dd>
1505
+
1506
+ <dl>
1507
+ <dd>
1508
+
1509
+ **request:** `Apologist::Types::CtaMatchRequest`
1510
+
1511
+ </dd>
1512
+ </dl>
1513
+
1514
+ <dl>
1515
+ <dd>
1516
+
1517
+ **request_options:** `Apologist::CtAs::RequestOptions`
1518
+
1519
+ </dd>
1520
+ </dl>
1521
+ </dd>
1522
+ </dl>
1523
+
1524
+
1525
+ </dd>
1526
+ </dl>
1527
+ </details>
1528
+
1529
+ <details><summary><code>client.ct_as.<a href="/lib/Apologist/ct_as/client.rb">log_cta_click</a>(id:, request) -> Apologist::Types::SuccessResponse</code></summary>
1530
+ <dl>
1531
+ <dd>
1532
+
1533
+ #### 📝 Description
1534
+
1535
+ <dl>
1536
+ <dd>
1537
+
1538
+ <dl>
1539
+ <dd>
1540
+
1541
+ Records that a user clicked on a specific CTA
1542
+ </dd>
1543
+ </dl>
1544
+ </dd>
1545
+ </dl>
1546
+
1547
+ #### 🔌 Usage
1548
+
1549
+ <dl>
1550
+ <dd>
1551
+
1552
+ <dl>
1553
+ <dd>
1554
+
1555
+ ```ruby
1556
+ client.ct_as.log_cta_click(
1557
+ id: "id",
1558
+ prompt_id: "prompt_id"
1559
+ )
1560
+ ```
1561
+ </dd>
1562
+ </dl>
1563
+ </dd>
1564
+ </dl>
1565
+
1566
+ #### ⚙️ Parameters
1567
+
1568
+ <dl>
1569
+ <dd>
1570
+
1571
+ <dl>
1572
+ <dd>
1573
+
1574
+ **id:** `String` — The ID of the CTA
1575
+
1576
+ </dd>
1577
+ </dl>
1578
+
1579
+ <dl>
1580
+ <dd>
1581
+
1582
+ **prompt_id:** `String`
1583
+
1584
+ </dd>
1585
+ </dl>
1586
+
1587
+ <dl>
1588
+ <dd>
1589
+
1590
+ **request_options:** `Apologist::CtAs::RequestOptions`
1591
+
1592
+ </dd>
1593
+ </dl>
1594
+ </dd>
1595
+ </dl>
1596
+
1597
+
1598
+ </dd>
1599
+ </dl>
1600
+ </details>
1601
+
1602
+ ## Users
1603
+ <details><summary><code>client.users.<a href="/lib/Apologist/users/client.rb">list_users</a>() -> Apologist::Users::Types::ListUsersResponse</code></summary>
1604
+ <dl>
1605
+ <dd>
1606
+
1607
+ #### 📝 Description
1608
+
1609
+ <dl>
1610
+ <dd>
1611
+
1612
+ <dl>
1613
+ <dd>
1614
+
1615
+ Returns a paginated list of users for the agent's team, with applied tags expanded as { id, name } and the persisted responder id.
1616
+ </dd>
1617
+ </dl>
1618
+ </dd>
1619
+ </dl>
1620
+
1621
+ #### 🔌 Usage
1622
+
1623
+ <dl>
1624
+ <dd>
1625
+
1626
+ <dl>
1627
+ <dd>
1628
+
1629
+ ```ruby
1630
+ client.users.list_users
1631
+ ```
1632
+ </dd>
1633
+ </dl>
1634
+ </dd>
1635
+ </dl>
1636
+
1637
+ #### ⚙️ Parameters
1638
+
1639
+ <dl>
1640
+ <dd>
1641
+
1642
+ <dl>
1643
+ <dd>
1644
+
1645
+ **page:** `Integer`
1646
+
1647
+ </dd>
1648
+ </dl>
1649
+
1650
+ <dl>
1651
+ <dd>
1652
+
1653
+ **per_page:** `Integer` — Results per page (clamped to 100).
1654
+
1655
+ </dd>
1656
+ </dl>
1657
+
1658
+ <dl>
1659
+ <dd>
1660
+
1661
+ **external_id:** `String`
1662
+
1663
+ </dd>
1664
+ </dl>
1665
+
1666
+ <dl>
1667
+ <dd>
1668
+
1669
+ **tags:** `String` — Comma-separated tag ids.
1670
+
1671
+ </dd>
1672
+ </dl>
1673
+
1674
+ <dl>
1675
+ <dd>
1676
+
1677
+ **responder_id:** `String`
1678
+
1679
+ </dd>
1680
+ </dl>
1681
+
1682
+ <dl>
1683
+ <dd>
1684
+
1685
+ **min_timestamp:** `String`
1686
+
1687
+ </dd>
1688
+ </dl>
1689
+
1690
+ <dl>
1691
+ <dd>
1692
+
1693
+ **max_timestamp:** `String`
1694
+
1695
+ </dd>
1696
+ </dl>
1697
+
1698
+ <dl>
1699
+ <dd>
1700
+
1701
+ **request_options:** `Apologist::Users::RequestOptions`
1702
+
1703
+ </dd>
1704
+ </dl>
1705
+ </dd>
1706
+ </dl>
1707
+
1708
+
1709
+ </dd>
1710
+ </dl>
1711
+ </details>
1712
+
1713
+ <details><summary><code>client.users.<a href="/lib/Apologist/users/client.rb">list_user_flags</a>() -> Apologist::Users::Types::ListUserFlagsResponse</code></summary>
1714
+ <dl>
1715
+ <dd>
1716
+
1717
+ #### 📝 Description
1718
+
1719
+ <dl>
1720
+ <dd>
1721
+
1722
+ <dl>
1723
+ <dd>
1724
+
1725
+ Returns a paginated list of user flag definitions for the agent's team (all columns from user_flags), ordered by id ascending.
1726
+ </dd>
1727
+ </dl>
1728
+ </dd>
1729
+ </dl>
1730
+
1731
+ #### 🔌 Usage
1732
+
1733
+ <dl>
1734
+ <dd>
1735
+
1736
+ <dl>
1737
+ <dd>
1738
+
1739
+ ```ruby
1740
+ client.users.list_user_flags
1741
+ ```
1742
+ </dd>
1743
+ </dl>
1744
+ </dd>
1745
+ </dl>
1746
+
1747
+ #### ⚙️ Parameters
1748
+
1749
+ <dl>
1750
+ <dd>
1751
+
1752
+ <dl>
1753
+ <dd>
1754
+
1755
+ **page:** `Integer`
1756
+
1757
+ </dd>
1758
+ </dl>
1759
+
1760
+ <dl>
1761
+ <dd>
1762
+
1763
+ **per_page:** `Integer` — Results per page (clamped to 100).
1764
+
1765
+ </dd>
1766
+ </dl>
1767
+
1768
+ <dl>
1769
+ <dd>
1770
+
1771
+ **request_options:** `Apologist::Users::RequestOptions`
1772
+
1773
+ </dd>
1774
+ </dl>
1775
+ </dd>
1776
+ </dl>
1777
+
1778
+
1779
+ </dd>
1780
+ </dl>
1781
+ </details>
1782
+
1783
+ <details><summary><code>client.users.<a href="/lib/Apologist/users/client.rb">get_user</a>(user_id:) -> Apologist::Users::Types::GetUserResponse</code></summary>
1784
+ <dl>
1785
+ <dd>
1786
+
1787
+ #### 📝 Description
1788
+
1789
+ <dl>
1790
+ <dd>
1791
+
1792
+ <dl>
1793
+ <dd>
1794
+
1795
+ Returns a single user by external id or internal id, with expanded tags and the persisted responder for the agent.
1796
+ </dd>
1797
+ </dl>
1798
+ </dd>
1799
+ </dl>
1800
+
1801
+ #### 🔌 Usage
1802
+
1803
+ <dl>
1804
+ <dd>
1805
+
1806
+ <dl>
1807
+ <dd>
1808
+
1809
+ ```ruby
1810
+ client.users.get_user(user_id: "user_id")
1811
+ ```
1812
+ </dd>
1813
+ </dl>
1814
+ </dd>
1815
+ </dl>
1816
+
1817
+ #### ⚙️ Parameters
1818
+
1819
+ <dl>
1820
+ <dd>
1821
+
1822
+ <dl>
1823
+ <dd>
1824
+
1825
+ **user_id:** `String` — The user's external id or internal id
1826
+
1827
+ </dd>
1828
+ </dl>
1829
+
1830
+ <dl>
1831
+ <dd>
1832
+
1833
+ **request_options:** `Apologist::Users::RequestOptions`
1834
+
1835
+ </dd>
1836
+ </dl>
1837
+ </dd>
1838
+ </dl>
1839
+
1840
+
1841
+ </dd>
1842
+ </dl>
1843
+ </details>
1844
+
1845
+ <details><summary><code>client.users.<a href="/lib/Apologist/users/client.rb">update_user</a>(user_id:, request) -> Apologist::Users::Types::UpdateUserResponse</code></summary>
1846
+ <dl>
1847
+ <dd>
1848
+
1849
+ #### 📝 Description
1850
+
1851
+ <dl>
1852
+ <dd>
1853
+
1854
+ <dl>
1855
+ <dd>
1856
+
1857
+ Updates a user's external_id and/or tags and upserts the persisted responder for the agent. Only provided fields are changed.
1858
+ </dd>
1859
+ </dl>
1860
+ </dd>
1861
+ </dl>
1862
+
1863
+ #### 🔌 Usage
1864
+
1865
+ <dl>
1866
+ <dd>
1867
+
1868
+ <dl>
1869
+ <dd>
1870
+
1871
+ ```ruby
1872
+ client.users.update_user(user_id: "user_id")
1873
+ ```
1874
+ </dd>
1875
+ </dl>
1876
+ </dd>
1877
+ </dl>
1878
+
1879
+ #### ⚙️ Parameters
1880
+
1881
+ <dl>
1882
+ <dd>
1883
+
1884
+ <dl>
1885
+ <dd>
1886
+
1887
+ **user_id:** `String` — The user's external id or internal id
1888
+
1889
+ </dd>
1890
+ </dl>
1891
+
1892
+ <dl>
1893
+ <dd>
1894
+
1895
+ **external_id:** `String` — Your external identifier for the user.
1896
+
1897
+ </dd>
1898
+ </dl>
1899
+
1900
+ <dl>
1901
+ <dd>
1902
+
1903
+ **tags:** `Internal::Types::Array[Apologist::Users::Types::UserUpdateRequestTagsItem]` — Applied tags as a mix of existing tag ids and/or default-language tag names. Unknown ids or names are rejected. Tags are mirror-owned and never created here.
1904
+
1905
+ </dd>
1906
+ </dl>
1907
+
1908
+ <dl>
1909
+ <dd>
1910
+
1911
+ **responder_id:** `Integer` — Responder to persist for this user on the requesting agent. Must be active on the agent.
1912
+
1913
+ </dd>
1914
+ </dl>
1915
+
1916
+ <dl>
1917
+ <dd>
1918
+
1919
+ **request_options:** `Apologist::Users::RequestOptions`
1920
+
1921
+ </dd>
1922
+ </dl>
1923
+ </dd>
1924
+ </dl>
1925
+
1926
+
1927
+ </dd>
1928
+ </dl>
1929
+ </details>
1930
+
1931
+ ## Benchmarks
1932
+ <details><summary><code>client.benchmarks.<a href="/lib/Apologist/benchmarks/client.rb">list_benchmark_runs</a>(id:) -> Apologist::Benchmarks::Types::ListBenchmarkRunsResponse</code></summary>
1933
+ <dl>
1934
+ <dd>
1935
+
1936
+ #### 📝 Description
1937
+
1938
+ <dl>
1939
+ <dd>
1940
+
1941
+ <dl>
1942
+ <dd>
1943
+
1944
+ Returns a paginated list of runs for a benchmark, scoped to the requesting agent. Each run carries nested evaluators, questions, and a flat evaluations array.
1945
+ </dd>
1946
+ </dl>
1947
+ </dd>
1948
+ </dl>
1949
+
1950
+ #### 🔌 Usage
1951
+
1952
+ <dl>
1953
+ <dd>
1954
+
1955
+ <dl>
1956
+ <dd>
1957
+
1958
+ ```ruby
1959
+ client.benchmarks.list_benchmark_runs(id: "id")
1960
+ ```
1961
+ </dd>
1962
+ </dl>
1963
+ </dd>
1964
+ </dl>
1965
+
1966
+ #### ⚙️ Parameters
1967
+
1968
+ <dl>
1969
+ <dd>
1970
+
1971
+ <dl>
1972
+ <dd>
1973
+
1974
+ **id:** `String` — The id or key of the benchmark
1975
+
1976
+ </dd>
1977
+ </dl>
1978
+
1979
+ <dl>
1980
+ <dd>
1981
+
1982
+ **page:** `Integer`
1983
+
1984
+ </dd>
1985
+ </dl>
1986
+
1987
+ <dl>
1988
+ <dd>
1989
+
1990
+ **per_page:** `Integer` — Results per page (clamped to 100).
1991
+
1992
+ </dd>
1993
+ </dl>
1994
+
1995
+ <dl>
1996
+ <dd>
1997
+
1998
+ **min_timestamp:** `String`
1999
+
2000
+ </dd>
2001
+ </dl>
2002
+
2003
+ <dl>
2004
+ <dd>
2005
+
2006
+ **max_timestamp:** `String`
2007
+
2008
+ </dd>
2009
+ </dl>
2010
+
2011
+ <dl>
2012
+ <dd>
2013
+
2014
+ **min_duration:** `String`
2015
+
2016
+ </dd>
2017
+ </dl>
2018
+
2019
+ <dl>
2020
+ <dd>
2021
+
2022
+ **max_duration:** `String`
2023
+
2024
+ </dd>
2025
+ </dl>
2026
+
2027
+ <dl>
2028
+ <dd>
2029
+
2030
+ **min_score:** `String`
2031
+
2032
+ </dd>
2033
+ </dl>
2034
+
2035
+ <dl>
2036
+ <dd>
2037
+
2038
+ **max_score:** `String`
2039
+
2040
+ </dd>
2041
+ </dl>
2042
+
2043
+ <dl>
2044
+ <dd>
2045
+
2046
+ **passed:** `String`
2047
+
2048
+ </dd>
2049
+ </dl>
2050
+
2051
+ <dl>
2052
+ <dd>
2053
+
2054
+ **min_responses:** `String`
2055
+
2056
+ </dd>
2057
+ </dl>
2058
+
2059
+ <dl>
2060
+ <dd>
2061
+
2062
+ **max_responses:** `String`
2063
+
2064
+ </dd>
2065
+ </dl>
2066
+
2067
+ <dl>
2068
+ <dd>
2069
+
2070
+ **request_options:** `Apologist::Benchmarks::RequestOptions`
2071
+
2072
+ </dd>
2073
+ </dl>
2074
+ </dd>
2075
+ </dl>
2076
+
2077
+
2078
+ </dd>
2079
+ </dl>
2080
+ </details>
2081
+
2082
+ <details><summary><code>client.benchmarks.<a href="/lib/Apologist/benchmarks/client.rb">run_benchmark</a>(id:, request) -> Internal::Types::Hash[String, Object]</code></summary>
2083
+ <dl>
2084
+ <dd>
2085
+
2086
+ #### 📝 Description
2087
+
2088
+ <dl>
2089
+ <dd>
2090
+
2091
+ <dl>
2092
+ <dd>
2093
+
2094
+ Executes a benchmark run and returns the aggregated result with nested evaluators, questions, and a flat evaluations array.
2095
+ </dd>
2096
+ </dl>
2097
+ </dd>
2098
+ </dl>
2099
+
2100
+ #### 🔌 Usage
2101
+
2102
+ <dl>
2103
+ <dd>
2104
+
2105
+ <dl>
2106
+ <dd>
2107
+
2108
+ ```ruby
2109
+ client.benchmarks.run_benchmark(id: "id")
2110
+ ```
2111
+ </dd>
2112
+ </dl>
2113
+ </dd>
2114
+ </dl>
2115
+
2116
+ #### ⚙️ Parameters
2117
+
2118
+ <dl>
2119
+ <dd>
2120
+
2121
+ <dl>
2122
+ <dd>
2123
+
2124
+ **id:** `String` — The id or key of the benchmark
2125
+
2126
+ </dd>
2127
+ </dl>
2128
+
2129
+ <dl>
2130
+ <dd>
2131
+
2132
+ **content:** `Apologist::Benchmarks::Types::BenchmarkRunRequestContent` — Content to evaluate. Required when `source_id` is supplied.
2133
+
2134
+ </dd>
2135
+ </dl>
2136
+
2137
+ <dl>
2138
+ <dd>
2139
+
2140
+ **completion_id:** `String` — Completion UUID whose stored response should be evaluated.
2141
+
2142
+ </dd>
2143
+ </dl>
2144
+
2145
+ <dl>
2146
+ <dd>
2147
+
2148
+ **source_id:** `Integer`
2149
+
2150
+ </dd>
2151
+ </dl>
2152
+
2153
+ <dl>
2154
+ <dd>
2155
+
2156
+ **model:** `String`
2157
+
2158
+ </dd>
2159
+ </dl>
2160
+
2161
+ <dl>
2162
+ <dd>
2163
+
2164
+ **num_responses:** `Integer`
2165
+
2166
+ </dd>
2167
+ </dl>
2168
+
2169
+ <dl>
2170
+ <dd>
2171
+
2172
+ **use_question_variants:** `Internal::Types::Boolean`
2173
+
2174
+ </dd>
2175
+ </dl>
2176
+
2177
+ <dl>
2178
+ <dd>
2179
+
2180
+ **reasoning_effort:** `Apologist::Benchmarks::Types::BenchmarkRunRequestReasoningEffort`
2181
+
2182
+ </dd>
2183
+ </dl>
2184
+
2185
+ <dl>
2186
+ <dd>
2187
+
2188
+ **verbosity:** `Apologist::Benchmarks::Types::BenchmarkRunRequestVerbosity`
2189
+
2190
+ </dd>
2191
+ </dl>
2192
+
2193
+ <dl>
2194
+ <dd>
2195
+
2196
+ **score_threshold:** `Integer`
2197
+
2198
+ </dd>
2199
+ </dl>
2200
+
2201
+ <dl>
2202
+ <dd>
2203
+
2204
+ **value_threshold:** `Integer`
2205
+
2206
+ </dd>
2207
+ </dl>
2208
+
2209
+ <dl>
2210
+ <dd>
2211
+
2212
+ **temperature:** `Integer`
2213
+
2214
+ </dd>
2215
+ </dl>
2216
+
2217
+ <dl>
2218
+ <dd>
2219
+
2220
+ **top_p:** `Integer`
2221
+
2222
+ </dd>
2223
+ </dl>
2224
+
2225
+ <dl>
2226
+ <dd>
2227
+
2228
+ **frequency_penalty:** `Integer`
2229
+
2230
+ </dd>
2231
+ </dl>
2232
+
2233
+ <dl>
2234
+ <dd>
2235
+
2236
+ **presence_penalty:** `Integer`
2237
+
2238
+ </dd>
2239
+ </dl>
2240
+
2241
+ <dl>
2242
+ <dd>
2243
+
2244
+ **request_options:** `Apologist::Benchmarks::RequestOptions`
2245
+
2246
+ </dd>
2247
+ </dl>
2248
+ </dd>
2249
+ </dl>
2250
+
2251
+
2252
+ </dd>
2253
+ </dl>
2254
+ </details>
2255
+
2256
+ <details><summary><code>client.benchmarks.<a href="/lib/Apologist/benchmarks/client.rb">get_benchmark_run</a>(id:, run_id:) -> Apologist::Benchmarks::Types::GetBenchmarkRunResponse</code></summary>
2257
+ <dl>
2258
+ <dd>
2259
+
2260
+ #### 📝 Description
2261
+
2262
+ <dl>
2263
+ <dd>
2264
+
2265
+ <dl>
2266
+ <dd>
2267
+
2268
+ Returns a single benchmark run by id or UUID, scoped to the requesting agent, including nested evaluators, questions, and evaluations.
2269
+ </dd>
2270
+ </dl>
2271
+ </dd>
2272
+ </dl>
2273
+
2274
+ #### 🔌 Usage
2275
+
2276
+ <dl>
2277
+ <dd>
2278
+
2279
+ <dl>
2280
+ <dd>
2281
+
2282
+ ```ruby
2283
+ client.benchmarks.get_benchmark_run(
2284
+ id: "id",
2285
+ run_id: "runId"
2286
+ )
2287
+ ```
2288
+ </dd>
2289
+ </dl>
2290
+ </dd>
2291
+ </dl>
2292
+
2293
+ #### ⚙️ Parameters
2294
+
2295
+ <dl>
2296
+ <dd>
2297
+
2298
+ <dl>
2299
+ <dd>
2300
+
2301
+ **id:** `String` — The id or key of the benchmark
2302
+
2303
+ </dd>
2304
+ </dl>
2305
+
2306
+ <dl>
2307
+ <dd>
2308
+
2309
+ **run_id:** `String` — The id or UUID of the run
2310
+
2311
+ </dd>
2312
+ </dl>
2313
+
2314
+ <dl>
2315
+ <dd>
2316
+
2317
+ **request_options:** `Apologist::Benchmarks::RequestOptions`
2318
+
2319
+ </dd>
2320
+ </dl>
2321
+ </dd>
2322
+ </dl>
2323
+
2324
+
2325
+ </dd>
2326
+ </dl>
2327
+ </details>
2328
+
2329
+ ## Channels
2330
+ <details><summary><code>client.channels.<a href="/lib/Apologist/channels/client.rb">get_discord_channel_status</a>(id:) -> Apologist::Channels::Types::GetDiscordChannelStatusResponse</code></summary>
2331
+ <dl>
2332
+ <dd>
2333
+
2334
+ #### 📝 Description
2335
+
2336
+ <dl>
2337
+ <dd>
2338
+
2339
+ <dl>
2340
+ <dd>
2341
+
2342
+ Returns the status of the Discord channel. Used as a lightweight health/verification endpoint.
2343
+ </dd>
2344
+ </dl>
2345
+ </dd>
2346
+ </dl>
2347
+
2348
+ #### 🔌 Usage
2349
+
2350
+ <dl>
2351
+ <dd>
2352
+
2353
+ <dl>
2354
+ <dd>
2355
+
2356
+ ```ruby
2357
+ client.channels.get_discord_channel_status(id: "id")
2358
+ ```
2359
+ </dd>
2360
+ </dl>
2361
+ </dd>
2362
+ </dl>
2363
+
2364
+ #### ⚙️ Parameters
2365
+
2366
+ <dl>
2367
+ <dd>
2368
+
2369
+ <dl>
2370
+ <dd>
2371
+
2372
+ **id:** `String` — The channel id
2373
+
2374
+ </dd>
2375
+ </dl>
2376
+
2377
+ <dl>
2378
+ <dd>
2379
+
2380
+ **request_options:** `Apologist::Channels::RequestOptions`
2381
+
2382
+ </dd>
2383
+ </dl>
2384
+ </dd>
2385
+ </dl>
2386
+
2387
+
2388
+ </dd>
2389
+ </dl>
2390
+ </details>
2391
+
2392
+ <details><summary><code>client.channels.<a href="/lib/Apologist/channels/client.rb">receive_discord_interaction</a>(id:, request) -> </code></summary>
2393
+ <dl>
2394
+ <dd>
2395
+
2396
+ #### 📝 Description
2397
+
2398
+ <dl>
2399
+ <dd>
2400
+
2401
+ <dl>
2402
+ <dd>
2403
+
2404
+ Receives Discord interaction callbacks for the channel. Requests are verified via Ed25519 signature headers; unsigned or invalid requests are rejected. Payload shape is defined by Discord.
2405
+ </dd>
2406
+ </dl>
2407
+ </dd>
2408
+ </dl>
2409
+
2410
+ #### 🔌 Usage
2411
+
2412
+ <dl>
2413
+ <dd>
2414
+
2415
+ <dl>
2416
+ <dd>
2417
+
2418
+ ```ruby
2419
+ client.channels.receive_discord_interaction(
2420
+ id: "id",
2421
+ signature_ed25519: "x-signature-ed25519",
2422
+ signature_timestamp: "x-signature-timestamp",
2423
+ body: {
2424
+ key: "value"
2425
+ }
2426
+ )
2427
+ ```
2428
+ </dd>
2429
+ </dl>
2430
+ </dd>
2431
+ </dl>
2432
+
2433
+ #### ⚙️ Parameters
2434
+
2435
+ <dl>
2436
+ <dd>
2437
+
2438
+ <dl>
2439
+ <dd>
2440
+
2441
+ **id:** `String` — The channel id
2442
+
2443
+ </dd>
2444
+ </dl>
2445
+
2446
+ <dl>
2447
+ <dd>
2448
+
2449
+ **signature_ed25519:** `String` — Discord request signature (hex).
2450
+
2451
+ </dd>
2452
+ </dl>
2453
+
2454
+ <dl>
2455
+ <dd>
2456
+
2457
+ **signature_timestamp:** `String` — Discord request timestamp.
2458
+
2459
+ </dd>
2460
+ </dl>
2461
+
2462
+ <dl>
2463
+ <dd>
2464
+
2465
+ **request:** `Internal::Types::Hash[String, Object]` — Discord interaction payload.
2466
+
2467
+ </dd>
2468
+ </dl>
2469
+
2470
+ <dl>
2471
+ <dd>
2472
+
2473
+ **request_options:** `Apologist::Channels::RequestOptions`
2474
+
2475
+ </dd>
2476
+ </dl>
2477
+ </dd>
2478
+ </dl>
2479
+
2480
+
2481
+ </dd>
2482
+ </dl>
2483
+ </details>
2484
+
2485
+ <details><summary><code>client.channels.<a href="/lib/Apologist/channels/client.rb">verify_facebook_webhook</a>(id:) -> String</code></summary>
2486
+ <dl>
2487
+ <dd>
2488
+
2489
+ #### 📝 Description
2490
+
2491
+ <dl>
2492
+ <dd>
2493
+
2494
+ <dl>
2495
+ <dd>
2496
+
2497
+ Handles the Meta webhook verification handshake, echoing `hub.challenge` when `hub.verify_token` matches the channel's configured token.
2498
+ </dd>
2499
+ </dl>
2500
+ </dd>
2501
+ </dl>
2502
+
2503
+ #### 🔌 Usage
2504
+
2505
+ <dl>
2506
+ <dd>
2507
+
2508
+ <dl>
2509
+ <dd>
2510
+
2511
+ ```ruby
2512
+ client.channels.verify_facebook_webhook(
2513
+ id: "id",
2514
+ hub_mode: "subscribe",
2515
+ hub_verify_token: "hub.verify_token"
2516
+ )
2517
+ ```
2518
+ </dd>
2519
+ </dl>
2520
+ </dd>
2521
+ </dl>
2522
+
2523
+ #### ⚙️ Parameters
2524
+
2525
+ <dl>
2526
+ <dd>
2527
+
2528
+ <dl>
2529
+ <dd>
2530
+
2531
+ **id:** `String` — The channel id
2532
+
2533
+ </dd>
2534
+ </dl>
2535
+
2536
+ <dl>
2537
+ <dd>
2538
+
2539
+ **hub_mode:** `Apologist::Channels::Types::VerifyFacebookWebhookRequestHubMode`
2540
+
2541
+ </dd>
2542
+ </dl>
2543
+
2544
+ <dl>
2545
+ <dd>
2546
+
2547
+ **hub_verify_token:** `String`
2548
+
2549
+ </dd>
2550
+ </dl>
2551
+
2552
+ <dl>
2553
+ <dd>
2554
+
2555
+ **hub_challenge:** `String`
2556
+
2557
+ </dd>
2558
+ </dl>
2559
+
2560
+ <dl>
2561
+ <dd>
2562
+
2563
+ **request_options:** `Apologist::Channels::RequestOptions`
2564
+
2565
+ </dd>
2566
+ </dl>
2567
+ </dd>
2568
+ </dl>
2569
+
2570
+
2571
+ </dd>
2572
+ </dl>
2573
+ </details>
2574
+
2575
+ <details><summary><code>client.channels.<a href="/lib/Apologist/channels/client.rb">receive_facebook_message</a>(id:, request) -> </code></summary>
2576
+ <dl>
2577
+ <dd>
2578
+
2579
+ #### 📝 Description
2580
+
2581
+ <dl>
2582
+ <dd>
2583
+
2584
+ <dl>
2585
+ <dd>
2586
+
2587
+ Receives Facebook/Messenger (and Instagram-style) message events for the channel. Payload shape is defined by Meta.
2588
+ </dd>
2589
+ </dl>
2590
+ </dd>
2591
+ </dl>
2592
+
2593
+ #### 🔌 Usage
2594
+
2595
+ <dl>
2596
+ <dd>
2597
+
2598
+ <dl>
2599
+ <dd>
2600
+
2601
+ ```ruby
2602
+ client.channels.receive_facebook_message(
2603
+ id: "id",
2604
+ body: {
2605
+ key: "value"
2606
+ }
2607
+ )
2608
+ ```
2609
+ </dd>
2610
+ </dl>
2611
+ </dd>
2612
+ </dl>
2613
+
2614
+ #### ⚙️ Parameters
2615
+
2616
+ <dl>
2617
+ <dd>
2618
+
2619
+ <dl>
2620
+ <dd>
2621
+
2622
+ **id:** `String` — The channel id
2623
+
2624
+ </dd>
2625
+ </dl>
2626
+
2627
+ <dl>
2628
+ <dd>
2629
+
2630
+ **request:** `Internal::Types::Hash[String, Object]` — Meta webhook payload.
2631
+
2632
+ </dd>
2633
+ </dl>
2634
+
2635
+ <dl>
2636
+ <dd>
2637
+
2638
+ **request_options:** `Apologist::Channels::RequestOptions`
2639
+
2640
+ </dd>
2641
+ </dl>
2642
+ </dd>
2643
+ </dl>
2644
+
2645
+
2646
+ </dd>
2647
+ </dl>
2648
+ </details>
2649
+
2650
+ <details><summary><code>client.channels.<a href="/lib/Apologist/channels/client.rb">get_instagram_privacy_policy</a>(id:) -> String</code></summary>
2651
+ <dl>
2652
+ <dd>
2653
+
2654
+ #### 📝 Description
2655
+
2656
+ <dl>
2657
+ <dd>
2658
+
2659
+ <dl>
2660
+ <dd>
2661
+
2662
+ Returns a static HTML privacy policy page for the Instagram integration.
2663
+ </dd>
2664
+ </dl>
2665
+ </dd>
2666
+ </dl>
2667
+
2668
+ #### 🔌 Usage
2669
+
2670
+ <dl>
2671
+ <dd>
2672
+
2673
+ <dl>
2674
+ <dd>
2675
+
2676
+ ```ruby
2677
+ client.channels.get_instagram_privacy_policy(id: "id")
2678
+ ```
2679
+ </dd>
2680
+ </dl>
2681
+ </dd>
2682
+ </dl>
2683
+
2684
+ #### ⚙️ Parameters
2685
+
2686
+ <dl>
2687
+ <dd>
2688
+
2689
+ <dl>
2690
+ <dd>
2691
+
2692
+ **id:** `String` — The channel id
2693
+
2694
+ </dd>
2695
+ </dl>
2696
+
2697
+ <dl>
2698
+ <dd>
2699
+
2700
+ **request_options:** `Apologist::Channels::RequestOptions`
2701
+
2702
+ </dd>
2703
+ </dl>
2704
+ </dd>
2705
+ </dl>
2706
+
2707
+
2708
+ </dd>
2709
+ </dl>
2710
+ </details>
2711
+
2712
+ <details><summary><code>client.channels.<a href="/lib/Apologist/channels/client.rb">receive_telegram_update</a>(id:, request) -> </code></summary>
2713
+ <dl>
2714
+ <dd>
2715
+
2716
+ #### 📝 Description
2717
+
2718
+ <dl>
2719
+ <dd>
2720
+
2721
+ <dl>
2722
+ <dd>
2723
+
2724
+ Receives Telegram bot update events for the channel. Non-message updates are acknowledged and ignored. Payload shape is defined by Telegram.
2725
+ </dd>
2726
+ </dl>
2727
+ </dd>
2728
+ </dl>
2729
+
2730
+ #### 🔌 Usage
2731
+
2732
+ <dl>
2733
+ <dd>
2734
+
2735
+ <dl>
2736
+ <dd>
2737
+
2738
+ ```ruby
2739
+ client.channels.receive_telegram_update(
2740
+ id: "id",
2741
+ body: {
2742
+ key: "value"
2743
+ }
2744
+ )
2745
+ ```
2746
+ </dd>
2747
+ </dl>
2748
+ </dd>
2749
+ </dl>
2750
+
2751
+ #### ⚙️ Parameters
2752
+
2753
+ <dl>
2754
+ <dd>
2755
+
2756
+ <dl>
2757
+ <dd>
2758
+
2759
+ **id:** `String` — The channel id
2760
+
2761
+ </dd>
2762
+ </dl>
2763
+
2764
+ <dl>
2765
+ <dd>
2766
+
2767
+ **request:** `Internal::Types::Hash[String, Object]` — Telegram update payload.
2768
+
2769
+ </dd>
2770
+ </dl>
2771
+
2772
+ <dl>
2773
+ <dd>
2774
+
2775
+ **request_options:** `Apologist::Channels::RequestOptions`
2776
+
2777
+ </dd>
2778
+ </dl>
2779
+ </dd>
2780
+ </dl>
2781
+
2782
+
2783
+ </dd>
2784
+ </dl>
2785
+ </details>
2786
+
2787
+ <details><summary><code>client.channels.<a href="/lib/Apologist/channels/client.rb">receive_twilio_message</a>(id:, request) -> </code></summary>
2788
+ <dl>
2789
+ <dd>
2790
+
2791
+ #### 📝 Description
2792
+
2793
+ <dl>
2794
+ <dd>
2795
+
2796
+ <dl>
2797
+ <dd>
2798
+
2799
+ Receives inbound Twilio messages for the channel as form-encoded data. Payload fields are defined by Twilio.
2800
+ </dd>
2801
+ </dl>
2802
+ </dd>
2803
+ </dl>
2804
+
2805
+ #### 🔌 Usage
2806
+
2807
+ <dl>
2808
+ <dd>
2809
+
2810
+ <dl>
2811
+ <dd>
2812
+
2813
+ ```ruby
2814
+ client.channels.receive_twilio_message(id: "id")
2815
+ ```
2816
+ </dd>
2817
+ </dl>
2818
+ </dd>
2819
+ </dl>
2820
+
2821
+ #### ⚙️ Parameters
2822
+
2823
+ <dl>
2824
+ <dd>
2825
+
2826
+ <dl>
2827
+ <dd>
2828
+
2829
+ **id:** `String` — The channel id
2830
+
2831
+ </dd>
2832
+ </dl>
2833
+
2834
+ <dl>
2835
+ <dd>
2836
+
2837
+ **from:** `String`
2838
+
2839
+ </dd>
2840
+ </dl>
2841
+
2842
+ <dl>
2843
+ <dd>
2844
+
2845
+ **body:** `String`
2846
+
2847
+ </dd>
2848
+ </dl>
2849
+
2850
+ <dl>
2851
+ <dd>
2852
+
2853
+ **request_options:** `Apologist::Channels::RequestOptions`
2854
+
2855
+ </dd>
2856
+ </dl>
2857
+ </dd>
2858
+ </dl>
2859
+
2860
+
2861
+ </dd>
2862
+ </dl>
2863
+ </details>
2864
+
2865
+ ## Shares
2866
+ <details><summary><code>client.shares.<a href="/lib/Apologist/shares/client.rb">get_shared_messages</a>(token:) -> Apologist::Shares::Types::GetSharedMessagesResponse</code></summary>
2867
+ <dl>
2868
+ <dd>
2869
+
2870
+ #### 📝 Description
2871
+
2872
+ <dl>
2873
+ <dd>
2874
+
2875
+ <dl>
2876
+ <dd>
2877
+
2878
+ Public, unauthenticated read of the messages behind a share token. The token is the bearer capability and enforces tenant isolation against the host agent. An empty or invalid token yields an empty messages array.
2879
+ </dd>
2880
+ </dl>
2881
+ </dd>
2882
+ </dl>
2883
+
2884
+ #### 🔌 Usage
2885
+
2886
+ <dl>
2887
+ <dd>
2888
+
2889
+ <dl>
2890
+ <dd>
2891
+
2892
+ ```ruby
2893
+ client.shares.get_shared_messages(token: "token")
2894
+ ```
2895
+ </dd>
2896
+ </dl>
2897
+ </dd>
2898
+ </dl>
2899
+
2900
+ #### ⚙️ Parameters
2901
+
2902
+ <dl>
2903
+ <dd>
2904
+
2905
+ <dl>
2906
+ <dd>
2907
+
2908
+ **token:** `String` — The share token
2909
+
2910
+ </dd>
2911
+ </dl>
2912
+
2913
+ <dl>
2914
+ <dd>
2915
+
2916
+ **request_options:** `Apologist::Shares::RequestOptions`
2917
+
2918
+ </dd>
2919
+ </dl>
2920
+ </dd>
2921
+ </dl>
2922
+
2923
+
2924
+ </dd>
2925
+ </dl>
2926
+ </details>
2927
+