tungo-sdk 0.2.0 → 0.3.1

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 (228) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +64 -1
  3. data/README.md +6 -6
  4. data/lib/tungo/client.rb +16 -8
  5. data/lib/tungo/helpers.rb +3 -1
  6. data/lib/tungo/internal/sse.rb +91 -0
  7. data/lib/tungo/internal/util.rb +31 -0
  8. data/lib/tungo/models/api_key.rb +9 -1
  9. data/lib/tungo/models/api_key_create.rb +9 -2
  10. data/lib/tungo/models/api_key_created.rb +9 -1
  11. data/lib/tungo/models/api_key_details.rb +9 -1
  12. data/lib/tungo/models/api_key_patch.rb +7 -0
  13. data/lib/tungo/models/api_key_rolled.rb +19 -4
  14. data/lib/tungo/models/api_key_self.rb +9 -1
  15. data/lib/tungo/models/api_key_updated.rb +9 -1
  16. data/lib/tungo/models/api_key_usage_by_model_item.rb +1 -1
  17. data/lib/tungo/models/audit_entry.rb +16 -6
  18. data/lib/tungo/models/audit_entry_action.rb +70 -3
  19. data/lib/tungo/models/audit_entry_object.rb +43 -0
  20. data/lib/tungo/models/audit_entry_object_purpose.rb +25 -0
  21. data/lib/tungo/models/batch_statement.rb +38 -0
  22. data/lib/tungo/models/batch_statement_account.rb +50 -0
  23. data/lib/tungo/models/batch_summary.rb +6 -0
  24. data/lib/tungo/models/card_session.rb +6 -0
  25. data/lib/tungo/models/card_session_state.rb +28 -0
  26. data/lib/tungo/models/card_session_state_failure_code.rb +20 -0
  27. data/lib/tungo/models/card_session_state_status.rb +19 -0
  28. data/lib/tungo/models/chat_assistant_message.rb +22 -0
  29. data/lib/tungo/models/chat_choice_answer.rb +9 -1
  30. data/lib/tungo/models/chat_choice_question.rb +9 -1
  31. data/lib/tungo/models/chat_citation.rb +62 -5
  32. data/lib/tungo/models/chat_dialog.rb +17 -1
  33. data/lib/tungo/models/chat_dialog_patch.rb +2 -1
  34. data/lib/tungo/models/chat_dialog_rated.rb +25 -0
  35. data/lib/tungo/models/chat_dialog_rating.rb +25 -0
  36. data/lib/tungo/models/chat_dialog_rating_body.rb +21 -0
  37. data/lib/tungo/models/chat_dialog_renamed.rb +4 -0
  38. data/lib/tungo/models/chat_dialog_summary.rb +6 -2
  39. data/lib/tungo/models/chat_event.rb +6 -2
  40. data/lib/tungo/models/chat_event_citation.rb +54 -5
  41. data/lib/tungo/models/chat_event_done.rb +8 -1
  42. data/lib/tungo/models/chat_event_next.rb +27 -0
  43. data/lib/tungo/models/chat_event_title.rb +22 -0
  44. data/lib/tungo/models/chat_history_batch.rb +21 -0
  45. data/lib/tungo/models/chat_history_block.rb +3 -1
  46. data/lib/tungo/models/chat_history_error.rb +3 -3
  47. data/lib/tungo/models/chat_history_error_code.rb +4 -3
  48. data/lib/tungo/models/chat_history_mention.rb +29 -0
  49. data/lib/tungo/models/chat_history_mention_type.rb +20 -0
  50. data/lib/tungo/models/chat_history_question.rb +6 -1
  51. data/lib/tungo/models/chat_history_question_answer.rb +31 -0
  52. data/lib/tungo/models/chat_history_question_answer_via.rb +17 -0
  53. data/lib/tungo/models/chat_mention.rb +22 -0
  54. data/lib/tungo/models/chat_mention_item.rb +33 -0
  55. data/lib/tungo/models/chat_mention_item_type.rb +20 -0
  56. data/lib/tungo/models/chat_mention_search.rb +21 -0
  57. data/lib/tungo/models/chat_mention_type.rb +20 -0
  58. data/lib/tungo/models/chat_mention_unavailable.rb +23 -0
  59. data/lib/tungo/models/chat_mention_unavailable_reason.rb +19 -0
  60. data/lib/tungo/models/chat_mention_unavailable_type.rb +20 -0
  61. data/lib/tungo/models/chat_message_rated.rb +31 -0
  62. data/lib/tungo/models/chat_message_rating.rb +30 -0
  63. data/lib/tungo/models/chat_message_rating_body.rb +27 -0
  64. data/lib/tungo/models/chat_message_rating_body_vote.rb +17 -0
  65. data/lib/tungo/models/chat_message_rating_vote.rb +17 -0
  66. data/lib/tungo/models/chat_message_request.rb +14 -0
  67. data/lib/tungo/models/chat_message_request_effort.rb +22 -0
  68. data/lib/tungo/models/chat_next_action.rb +31 -0
  69. data/lib/tungo/models/chat_next_action_code.rb +21 -0
  70. data/lib/tungo/models/chat_next_action_params_value.rb +20 -0
  71. data/lib/tungo/models/chat_rating_dismissed.rb +21 -0
  72. data/lib/tungo/models/chat_rating_options.rb +25 -0
  73. data/lib/tungo/models/chat_rating_options_dialog_scores.rb +20 -0
  74. data/lib/tungo/models/chat_rating_options_reason_item.rb +20 -0
  75. data/lib/tungo/models/chat_suggestion.rb +41 -0
  76. data/lib/tungo/models/chat_suggestion_action.rb +17 -0
  77. data/lib/tungo/models/chat_suggestion_group.rb +26 -0
  78. data/lib/tungo/models/chat_suggestions.rb +25 -0
  79. data/lib/tungo/models/chat_suggestions_locale.rb +17 -0
  80. data/lib/tungo/models/chat_title_source.rb +20 -0
  81. data/lib/tungo/models/chat_turn_error.rb +9 -5
  82. data/lib/tungo/models/chat_turn_error_code.rb +4 -3
  83. data/lib/tungo/models/chat_turn_error_limit_kind.rb +7 -1
  84. data/lib/tungo/models/chat_turn_result.rb +11 -0
  85. data/lib/tungo/models/chat_user_message.rb +5 -0
  86. data/lib/tungo/models/company.rb +2 -2
  87. data/lib/tungo/models/company_legal_form.rb +2 -1
  88. data/lib/tungo/models/company_list_item.rb +2 -2
  89. data/lib/tungo/models/error_detail.rb +32 -2
  90. data/lib/tungo/models/error_detail_free_blocked_reason.rb +25 -0
  91. data/lib/tungo/models/get_workspace_platform_audit_response.rb +11 -0
  92. data/lib/tungo/models/list_company_chat_rating_options_lang.rb +17 -0
  93. data/lib/tungo/models/list_company_chat_suggestions_lang.rb +18 -0
  94. data/lib/tungo/models/list_company_proposals_approval_requested.rb +17 -0
  95. data/lib/tungo/models/list_workspace_platform_requests_response.rb +11 -0
  96. data/lib/tungo/models/pay_form.rb +6 -0
  97. data/lib/tungo/models/platform_account_purchase_limits.rb +6 -0
  98. data/lib/tungo/models/platform_ledger_entry.rb +7 -0
  99. data/lib/tungo/models/platform_ledger_entry_documents.rb +33 -0
  100. data/lib/tungo/models/platform_ledger_entry_documents_receipt_status.rb +20 -0
  101. data/lib/tungo/models/platform_request.rb +7 -0
  102. data/lib/tungo/models/proposal_approval_request.rb +27 -0
  103. data/lib/tungo/models/proposal_approval_request_body.rb +15 -0
  104. data/lib/tungo/models/proposal_approval_request_result.rb +31 -0
  105. data/lib/tungo/models/proposal_approval_requested.rb +32 -0
  106. data/lib/tungo/models/proposal_card.rb +16 -1
  107. data/lib/tungo/models/proposal_card_status_reason.rb +23 -0
  108. data/lib/tungo/models/proposal_history_event.rb +7 -0
  109. data/lib/tungo/models/proposal_list_item.rb +16 -1
  110. data/lib/tungo/models/proposal_list_item_status_reason.rb +23 -0
  111. data/lib/tungo/models/proposal_origin.rb +33 -0
  112. data/lib/tungo/models/proposal_origin_source.rb +21 -0
  113. data/lib/tungo/models/proposal_page.rb +9 -2
  114. data/lib/tungo/models/usage_rate.rb +15 -2
  115. data/lib/tungo/models.rb +58 -0
  116. data/lib/tungo/money.rb +14 -1
  117. data/lib/tungo/request_options.rb +3 -1
  118. data/lib/tungo/resources/automations.rb +6 -3
  119. data/lib/tungo/resources/chat.rb +175 -2
  120. data/lib/tungo/resources/proposals.rb +49 -2
  121. data/lib/tungo/transport.rb +9 -1
  122. data/lib/tungo/version.rb +1 -1
  123. data/sig/tungo/models/api_key.rbs +2 -1
  124. data/sig/tungo/models/api_key_create.rbs +3 -2
  125. data/sig/tungo/models/api_key_created.rbs +2 -1
  126. data/sig/tungo/models/api_key_details.rbs +2 -1
  127. data/sig/tungo/models/api_key_patch.rbs +2 -1
  128. data/sig/tungo/models/api_key_rolled.rbs +4 -2
  129. data/sig/tungo/models/api_key_self.rbs +2 -1
  130. data/sig/tungo/models/api_key_updated.rbs +2 -1
  131. data/sig/tungo/models/audit_entry.rbs +2 -1
  132. data/sig/tungo/models/audit_entry_action.rbs +67 -0
  133. data/sig/tungo/models/audit_entry_object.rbs +16 -0
  134. data/sig/tungo/models/audit_entry_object_purpose.rbs +19 -0
  135. data/sig/tungo/models/batch_statement.rbs +16 -0
  136. data/sig/tungo/models/batch_statement_account.rbs +19 -0
  137. data/sig/tungo/models/batch_summary.rbs +2 -1
  138. data/sig/tungo/models/card_session.rbs +2 -1
  139. data/sig/tungo/models/card_session_state.rbs +14 -0
  140. data/sig/tungo/models/card_session_state_failure_code.rbs +14 -0
  141. data/sig/tungo/models/card_session_state_status.rbs +14 -0
  142. data/sig/tungo/models/chat_assistant_message.rbs +5 -1
  143. data/sig/tungo/models/chat_choice_answer.rbs +2 -1
  144. data/sig/tungo/models/chat_choice_question.rbs +2 -1
  145. data/sig/tungo/models/chat_citation.rbs +11 -1
  146. data/sig/tungo/models/chat_dialog.rbs +4 -1
  147. data/sig/tungo/models/chat_dialog_rated.rbs +14 -0
  148. data/sig/tungo/models/chat_dialog_rating.rbs +14 -0
  149. data/sig/tungo/models/chat_dialog_rating_body.rbs +13 -0
  150. data/sig/tungo/models/chat_dialog_renamed.rbs +2 -1
  151. data/sig/tungo/models/chat_dialog_summary.rbs +2 -1
  152. data/sig/tungo/models/chat_event.rbs +1 -1
  153. data/sig/tungo/models/chat_event_citation.rbs +10 -1
  154. data/sig/tungo/models/chat_event_done.rbs +2 -1
  155. data/sig/tungo/models/chat_event_next.rbs +14 -0
  156. data/sig/tungo/models/chat_event_title.rbs +13 -0
  157. data/sig/tungo/models/chat_history_batch.rbs +13 -0
  158. data/sig/tungo/models/chat_history_block.rbs +1 -1
  159. data/sig/tungo/models/chat_history_error_code.rbs +1 -0
  160. data/sig/tungo/models/chat_history_mention.rbs +14 -0
  161. data/sig/tungo/models/chat_history_mention_type.rbs +14 -0
  162. data/sig/tungo/models/chat_history_question.rbs +2 -1
  163. data/sig/tungo/models/chat_history_question_answer.rbs +15 -0
  164. data/sig/tungo/models/chat_history_question_answer_via.rbs +13 -0
  165. data/sig/tungo/models/chat_mention.rbs +13 -0
  166. data/sig/tungo/models/chat_mention_item.rbs +15 -0
  167. data/sig/tungo/models/chat_mention_item_type.rbs +14 -0
  168. data/sig/tungo/models/chat_mention_search.rbs +13 -0
  169. data/sig/tungo/models/chat_mention_type.rbs +14 -0
  170. data/sig/tungo/models/chat_mention_unavailable.rbs +13 -0
  171. data/sig/tungo/models/chat_mention_unavailable_reason.rbs +14 -0
  172. data/sig/tungo/models/chat_mention_unavailable_type.rbs +14 -0
  173. data/sig/tungo/models/chat_message_rated.rbs +15 -0
  174. data/sig/tungo/models/chat_message_rating.rbs +15 -0
  175. data/sig/tungo/models/chat_message_rating_body.rbs +14 -0
  176. data/sig/tungo/models/chat_message_rating_body_vote.rbs +13 -0
  177. data/sig/tungo/models/chat_message_rating_vote.rbs +13 -0
  178. data/sig/tungo/models/chat_message_request.rbs +3 -1
  179. data/sig/tungo/models/chat_message_request_effort.rbs +16 -0
  180. data/sig/tungo/models/chat_next_action.rbs +14 -0
  181. data/sig/tungo/models/chat_next_action_code.rbs +15 -0
  182. data/sig/tungo/models/chat_next_action_params_value.rbs +12 -0
  183. data/sig/tungo/models/chat_rating_dismissed.rbs +13 -0
  184. data/sig/tungo/models/chat_rating_options.rbs +14 -0
  185. data/sig/tungo/models/chat_rating_options_dialog_scores.rbs +13 -0
  186. data/sig/tungo/models/chat_rating_options_reason_item.rbs +13 -0
  187. data/sig/tungo/models/chat_suggestion.rbs +17 -0
  188. data/sig/tungo/models/chat_suggestion_action.rbs +13 -0
  189. data/sig/tungo/models/chat_suggestion_group.rbs +14 -0
  190. data/sig/tungo/models/chat_suggestions.rbs +14 -0
  191. data/sig/tungo/models/chat_suggestions_locale.rbs +13 -0
  192. data/sig/tungo/models/chat_title_source.rbs +14 -0
  193. data/sig/tungo/models/chat_turn_error_code.rbs +1 -0
  194. data/sig/tungo/models/chat_turn_error_limit_kind.rbs +4 -0
  195. data/sig/tungo/models/chat_turn_result.rbs +3 -1
  196. data/sig/tungo/models/chat_user_message.rbs +2 -1
  197. data/sig/tungo/models/company.rbs +2 -2
  198. data/sig/tungo/models/company_list_item.rbs +2 -2
  199. data/sig/tungo/models/error_detail.rbs +6 -1
  200. data/sig/tungo/models/error_detail_free_blocked_reason.rbs +19 -0
  201. data/sig/tungo/models/get_workspace_platform_audit_response.rbs +3 -1
  202. data/sig/tungo/models/list_company_chat_rating_options_lang.rbs +13 -0
  203. data/sig/tungo/models/list_company_chat_suggestions_lang.rbs +13 -0
  204. data/sig/tungo/models/list_company_proposals_approval_requested.rbs +13 -0
  205. data/sig/tungo/models/list_workspace_platform_requests_response.rbs +3 -1
  206. data/sig/tungo/models/pay_form.rbs +2 -1
  207. data/sig/tungo/models/platform_account_purchase_limits.rbs +2 -1
  208. data/sig/tungo/models/platform_ledger_entry.rbs +2 -1
  209. data/sig/tungo/models/platform_ledger_entry_documents.rbs +15 -0
  210. data/sig/tungo/models/platform_ledger_entry_documents_receipt_status.rbs +15 -0
  211. data/sig/tungo/models/platform_request.rbs +2 -1
  212. data/sig/tungo/models/proposal_approval_request.rbs +14 -0
  213. data/sig/tungo/models/proposal_approval_request_body.rbs +12 -0
  214. data/sig/tungo/models/proposal_approval_request_result.rbs +15 -0
  215. data/sig/tungo/models/proposal_approval_requested.rbs +15 -0
  216. data/sig/tungo/models/proposal_card.rbs +4 -1
  217. data/sig/tungo/models/proposal_card_status_reason.rbs +13 -0
  218. data/sig/tungo/models/proposal_history_event.rbs +2 -1
  219. data/sig/tungo/models/proposal_list_item.rbs +4 -1
  220. data/sig/tungo/models/proposal_list_item_status_reason.rbs +13 -0
  221. data/sig/tungo/models/proposal_origin.rbs +15 -0
  222. data/sig/tungo/models/proposal_origin_source.rbs +15 -0
  223. data/sig/tungo/models/proposal_page.rbs +2 -1
  224. data/sig/tungo/models/usage_rate.rbs +3 -1
  225. data/sig/tungo/resources/automations.rbs +1 -1
  226. data/sig/tungo/resources/chat.rbs +9 -2
  227. data/sig/tungo/resources/proposals.rbs +3 -2
  228. metadata +117 -1
@@ -8,6 +8,10 @@ module Tungo
8
8
  type input = String
9
9
  DAY: String
10
10
  DIALOG: String
11
+ TURN: String
12
+ PLAN: String
13
+ DISABLED: String
14
+ METER: String
11
15
  end
12
16
  end
13
17
  end
@@ -7,13 +7,15 @@ module Tungo
7
7
  def citations: () -> Array[Tungo::Models::ChatCitation]
8
8
  def dialog_id: () -> String
9
9
  def errors: () -> Array[Tungo::Models::ChatTurnError]
10
+ def followups: () -> Array[String]
11
+ def next_action: () -> Tungo::Models::ChatNextAction?
10
12
  def pending_question: () -> Tungo::Models::ChatPendingQuestion?
11
13
  def proposals: () -> Array[Tungo::Models::ChatTurnProposal]
12
14
  def questions: () -> Array[Tungo::Models::ChatQuestion]
13
15
  def stop_reason: () -> String?
14
16
  def turn_no: () -> (Integer | BigDecimal)
15
17
  def usage: () -> Tungo::Models::ChatTurnUsage?
16
- def initialize: (?answer: String, ?citations: Array[Tungo::input[Tungo::Models::ChatCitation]], ?dialog_id: String, ?errors: Array[Tungo::input[Tungo::Models::ChatTurnError]], ?pending_question: Tungo::input[Tungo::Models::ChatPendingQuestion]?, ?proposals: Array[Tungo::input[Tungo::Models::ChatTurnProposal]], ?questions: Array[Tungo::input[Tungo::Models::ChatQuestion]], ?stop_reason: String?, ?turn_no: (Integer | Float | BigDecimal), ?usage: Tungo::input[Tungo::Models::ChatTurnUsage], **untyped) -> void
18
+ def initialize: (?answer: String, ?citations: Array[Tungo::input[Tungo::Models::ChatCitation]], ?dialog_id: String, ?errors: Array[Tungo::input[Tungo::Models::ChatTurnError]], ?followups: Array[String], ?next_action: Tungo::input[Tungo::Models::ChatNextAction]?, ?pending_question: Tungo::input[Tungo::Models::ChatPendingQuestion]?, ?proposals: Array[Tungo::input[Tungo::Models::ChatTurnProposal]], ?questions: Array[Tungo::input[Tungo::Models::ChatQuestion]], ?stop_reason: String?, ?turn_no: (Integer | Float | BigDecimal), ?usage: Tungo::input[Tungo::Models::ChatTurnUsage], **untyped) -> void
17
19
  def self.from_wire: (Hash[String, untyped] | Hash[Symbol, untyped] data, ?api_response: Tungo::APIResponse?) -> Tungo::Models::ChatTurnResult
18
20
  def with: (**untyped) -> Tungo::Models::ChatTurnResult
19
21
  end
@@ -6,10 +6,11 @@ module Tungo
6
6
  def at: () -> String
7
7
  def attachments: () -> Array[Tungo::Models::ChatAttachmentMeta]?
8
8
  def id: () -> String
9
+ def mentions: () -> Array[Tungo::Models::ChatHistoryMention]?
9
10
  def pending: () -> bool?
10
11
  def role: () -> String
11
12
  def text: () -> String
12
- def initialize: (?at: (String | Time), ?attachments: Array[Tungo::input[Tungo::Models::ChatAttachmentMeta]], ?id: String, ?pending: bool, ?role: String, ?text: String, **untyped) -> void
13
+ def initialize: (?at: (String | Time), ?attachments: Array[Tungo::input[Tungo::Models::ChatAttachmentMeta]], ?id: String, ?mentions: Array[Tungo::input[Tungo::Models::ChatHistoryMention]], ?pending: bool, ?role: String, ?text: String, **untyped) -> void
13
14
  def self.from_wire: (Hash[String, untyped] | Hash[Symbol, untyped] data, ?api_response: Tungo::APIResponse?) -> Tungo::Models::ChatUserMessage
14
15
  def with: (**untyped) -> Tungo::Models::ChatUserMessage
15
16
  end
@@ -6,14 +6,14 @@ module Tungo
6
6
  def bin: () -> String?
7
7
  def created_at: () -> String
8
8
  def id: () -> String
9
- def legal_form: () -> Tungo::Models::CompanyLegalForm::t
9
+ def legal_form: () -> Tungo::Models::CompanyLegalForm::t?
10
10
  def name: () -> String
11
11
  def permissions: () -> Array[Tungo::Models::CompanyPermission::t]
12
12
  def role: () -> String
13
13
  def role_name: () -> String
14
14
  def status: () -> Tungo::Models::CompanyStatus::t
15
15
  def workspace_id: () -> String
16
- def initialize: (?bin: String?, ?created_at: (String | Time), ?id: String, ?legal_form: Tungo::Models::CompanyLegalForm::input, ?name: String, ?permissions: Array[Tungo::Models::CompanyPermission::input], ?role: String, ?role_name: String, ?status: Tungo::Models::CompanyStatus::input, ?workspace_id: String, **untyped) -> void
16
+ def initialize: (?bin: String?, ?created_at: (String | Time), ?id: String, ?legal_form: Tungo::Models::CompanyLegalForm::input?, ?name: String, ?permissions: Array[Tungo::Models::CompanyPermission::input], ?role: String, ?role_name: String, ?status: Tungo::Models::CompanyStatus::input, ?workspace_id: String, **untyped) -> void
17
17
  def self.from_wire: (Hash[String, untyped] | Hash[Symbol, untyped] data, ?api_response: Tungo::APIResponse?) -> Tungo::Models::Company
18
18
  def with: (**untyped) -> Tungo::Models::Company
19
19
  end
@@ -7,14 +7,14 @@ module Tungo
7
7
  def counts: () -> Tungo::Models::CompanyCounts
8
8
  def created_at: () -> String
9
9
  def id: () -> String
10
- def legal_form: () -> Tungo::Models::CompanyLegalForm::t
10
+ def legal_form: () -> Tungo::Models::CompanyLegalForm::t?
11
11
  def name: () -> String
12
12
  def permissions: () -> Array[Tungo::Models::CompanyPermission::t]
13
13
  def role: () -> String
14
14
  def role_name: () -> String
15
15
  def status: () -> Tungo::Models::CompanyStatus::t
16
16
  def workspace_id: () -> String
17
- def initialize: (?bin: String?, ?counts: Tungo::input[Tungo::Models::CompanyCounts], ?created_at: (String | Time), ?id: String, ?legal_form: Tungo::Models::CompanyLegalForm::input, ?name: String, ?permissions: Array[Tungo::Models::CompanyPermission::input], ?role: String, ?role_name: String, ?status: Tungo::Models::CompanyStatus::input, ?workspace_id: String, **untyped) -> void
17
+ def initialize: (?bin: String?, ?counts: Tungo::input[Tungo::Models::CompanyCounts], ?created_at: (String | Time), ?id: String, ?legal_form: Tungo::Models::CompanyLegalForm::input?, ?name: String, ?permissions: Array[Tungo::Models::CompanyPermission::input], ?role: String, ?role_name: String, ?status: Tungo::Models::CompanyStatus::input, ?workspace_id: String, **untyped) -> void
18
18
  def self.from_wire: (Hash[String, untyped] | Hash[Symbol, untyped] data, ?api_response: Tungo::APIResponse?) -> Tungo::Models::CompanyListItem
19
19
  def with: (**untyped) -> Tungo::Models::CompanyListItem
20
20
  end
@@ -4,15 +4,20 @@ module Tungo
4
4
  module Models
5
5
  class ErrorDetail < Tungo::Model
6
6
  def allowed_methods: () -> Array[Tungo::Models::ErrorDetailAllowedMethodItem::t]?
7
+ def amount_tiyn: () -> Integer?
7
8
  def code: () -> String?
8
9
  def fields: () -> Array[Tungo::Models::FieldError]?
10
+ def free_blocked_reason: () -> Tungo::Models::ErrorDetailFreeBlockedReason::t?
9
11
  def message: () -> String
12
+ def next_request_at: () -> String?
13
+ def payment_id: () -> String?
10
14
  def permission: () -> String?
11
15
  def permissions: () -> Array[String]?
12
16
  def resets_at: () -> String?
17
+ def retry_after_seconds: () -> Integer?
13
18
  def role: () -> String?
14
19
  def type: () -> Tungo::Models::ErrorDetailType::t
15
- def initialize: (?allowed_methods: Array[Tungo::Models::ErrorDetailAllowedMethodItem::input], ?code: String, ?fields: Array[Tungo::input[Tungo::Models::FieldError]], ?message: String, ?permission: String, ?permissions: Array[String], ?resets_at: (String | Time), ?role: String, ?type: Tungo::Models::ErrorDetailType::input, **untyped) -> void
20
+ def initialize: (?allowed_methods: Array[Tungo::Models::ErrorDetailAllowedMethodItem::input], ?amount_tiyn: Integer, ?code: String, ?fields: Array[Tungo::input[Tungo::Models::FieldError]], ?free_blocked_reason: Tungo::Models::ErrorDetailFreeBlockedReason::input, ?message: String, ?next_request_at: (String | Time), ?payment_id: String?, ?permission: String, ?permissions: Array[String], ?resets_at: (String | Time), ?retry_after_seconds: Integer, ?role: String, ?type: Tungo::Models::ErrorDetailType::input, **untyped) -> void
16
21
  def self.from_wire: (Hash[String, untyped] | Hash[Symbol, untyped] data, ?api_response: Tungo::APIResponse?) -> Tungo::Models::ErrorDetail
17
22
  def with: (**untyped) -> Tungo::Models::ErrorDetail
18
23
  end
@@ -0,0 +1,19 @@
1
+ # Code generated by tungo-sdkgen from the Tungo Platform API contract. DO NOT EDIT.
2
+
3
+ module Tungo
4
+ module Models
5
+ module ErrorDetailFreeBlockedReason
6
+ extend Tungo::Internal::Enum
7
+ type t = String
8
+ type input = String
9
+ ADMIN_DECISION: String
10
+ TEMPORARY_EMAIL: String
11
+ HIDDEN_EMAIL: String
12
+ EMAIL_USED: String
13
+ DEVICE_USED: String
14
+ NETWORK_LIMIT: String
15
+ COMPANY_USED: String
16
+ OTHER: String
17
+ end
18
+ end
19
+ end
@@ -5,7 +5,9 @@ module Tungo
5
5
  class GetWorkspacePlatformAuditResponse < Tungo::Model
6
6
  def data: () -> Array[Tungo::Models::AuditEntry]
7
7
  def next_cursor: () -> String?
8
- def initialize: (?data: Array[Tungo::input[Tungo::Models::AuditEntry]], ?next_cursor: String?, **untyped) -> void
8
+ def total: () -> Integer
9
+ def total_more: () -> bool
10
+ def initialize: (?data: Array[Tungo::input[Tungo::Models::AuditEntry]], ?next_cursor: String?, ?total: Integer, ?total_more: bool, **untyped) -> void
9
11
  def self.from_wire: (Hash[String, untyped] | Hash[Symbol, untyped] data, ?api_response: Tungo::APIResponse?) -> Tungo::Models::GetWorkspacePlatformAuditResponse
10
12
  def with: (**untyped) -> Tungo::Models::GetWorkspacePlatformAuditResponse
11
13
  end
@@ -0,0 +1,13 @@
1
+ # Code generated by tungo-sdkgen from the Tungo Platform API contract. DO NOT EDIT.
2
+
3
+ module Tungo
4
+ module Models
5
+ module ListCompanyChatRatingOptionsLang
6
+ extend Tungo::Internal::Enum
7
+ type t = String
8
+ type input = String
9
+ RU: String
10
+ KK: String
11
+ end
12
+ end
13
+ end
@@ -0,0 +1,13 @@
1
+ # Code generated by tungo-sdkgen from the Tungo Platform API contract. DO NOT EDIT.
2
+
3
+ module Tungo
4
+ module Models
5
+ module ListCompanyChatSuggestionsLang
6
+ extend Tungo::Internal::Enum
7
+ type t = String
8
+ type input = String
9
+ RU: String
10
+ KK: String
11
+ end
12
+ end
13
+ end
@@ -0,0 +1,13 @@
1
+ # Code generated by tungo-sdkgen from the Tungo Platform API contract. DO NOT EDIT.
2
+
3
+ module Tungo
4
+ module Models
5
+ module ListCompanyProposalsApprovalRequested
6
+ extend Tungo::Internal::Enum
7
+ type t = String
8
+ type input = String
9
+ TRUE: String
10
+ FALSE: String
11
+ end
12
+ end
13
+ end
@@ -5,7 +5,9 @@ module Tungo
5
5
  class ListWorkspacePlatformRequestsResponse < Tungo::Model
6
6
  def data: () -> Array[Tungo::Models::PlatformRequest]
7
7
  def next_cursor: () -> String?
8
- def initialize: (?data: Array[Tungo::input[Tungo::Models::PlatformRequest]], ?next_cursor: String?, **untyped) -> void
8
+ def total: () -> Integer
9
+ def total_more: () -> bool
10
+ def initialize: (?data: Array[Tungo::input[Tungo::Models::PlatformRequest]], ?next_cursor: String?, ?total: Integer, ?total_more: bool, **untyped) -> void
9
11
  def self.from_wire: (Hash[String, untyped] | Hash[Symbol, untyped] data, ?api_response: Tungo::APIResponse?) -> Tungo::Models::ListWorkspacePlatformRequestsResponse
10
12
  def with: (**untyped) -> Tungo::Models::ListWorkspacePlatformRequestsResponse
11
13
  end
@@ -7,7 +7,8 @@ module Tungo
7
7
  def payment_id: () -> String
8
8
  def payment_object: () -> Hash[String, untyped]
9
9
  def script_url: () -> String
10
- def initialize: (?amount_tiyn: Integer, ?payment_id: String, ?payment_object: Hash[String | Symbol, untyped], ?script_url: String, **untyped) -> void
10
+ def test_mode: () -> bool
11
+ def initialize: (?amount_tiyn: Integer, ?payment_id: String, ?payment_object: Hash[String | Symbol, untyped], ?script_url: String, ?test_mode: bool, **untyped) -> void
11
12
  def self.from_wire: (Hash[String, untyped] | Hash[Symbol, untyped] data, ?api_response: Tungo::APIResponse?) -> Tungo::Models::PayForm
12
13
  def with: (**untyped) -> Tungo::Models::PayForm
13
14
  end
@@ -6,7 +6,8 @@ module Tungo
6
6
  def daily_max_tiyn: () -> Integer
7
7
  def max_tiyn: () -> Integer
8
8
  def min_tiyn: () -> Integer
9
- def initialize: (?daily_max_tiyn: Integer, ?max_tiyn: Integer, ?min_tiyn: Integer, **untyped) -> void
9
+ def today_tiyn: () -> Integer
10
+ def initialize: (?daily_max_tiyn: Integer, ?max_tiyn: Integer, ?min_tiyn: Integer, ?today_tiyn: Integer, **untyped) -> void
10
11
  def self.from_wire: (Hash[String, untyped] | Hash[Symbol, untyped] data, ?api_response: Tungo::APIResponse?) -> Tungo::Models::PlatformAccountPurchaseLimits
11
12
  def with: (**untyped) -> Tungo::Models::PlatformAccountPurchaseLimits
12
13
  end
@@ -7,13 +7,14 @@ module Tungo
7
7
  def api_key_id: () -> String?
8
8
  def at: () -> String
9
9
  def balance_after_tiyn: () -> Integer
10
+ def documents: () -> Tungo::Models::PlatformLedgerEntryDocuments?
10
11
  def id: () -> String
11
12
  def kind: () -> Tungo::Models::PlatformLedgerEntryKind::t
12
13
  def model: () -> String?
13
14
  def note: () -> String?
14
15
  def payment_id: () -> String?
15
16
  def request_id: () -> String?
16
- def initialize: (?amount_tiyn: Integer, ?api_key_id: String?, ?at: (String | Time), ?balance_after_tiyn: Integer, ?id: String, ?kind: Tungo::Models::PlatformLedgerEntryKind::input, ?model: String?, ?note: String?, ?payment_id: String?, ?request_id: String?, **untyped) -> void
17
+ def initialize: (?amount_tiyn: Integer, ?api_key_id: String?, ?at: (String | Time), ?balance_after_tiyn: Integer, ?documents: Tungo::input[Tungo::Models::PlatformLedgerEntryDocuments]?, ?id: String, ?kind: Tungo::Models::PlatformLedgerEntryKind::input, ?model: String?, ?note: String?, ?payment_id: String?, ?request_id: String?, **untyped) -> void
17
18
  def self.from_wire: (Hash[String, untyped] | Hash[Symbol, untyped] data, ?api_response: Tungo::APIResponse?) -> Tungo::Models::PlatformLedgerEntry
18
19
  def with: (**untyped) -> Tungo::Models::PlatformLedgerEntry
19
20
  end
@@ -0,0 +1,15 @@
1
+ # Code generated by tungo-sdkgen from the Tungo Platform API contract. DO NOT EDIT.
2
+
3
+ module Tungo
4
+ module Models
5
+ class PlatformLedgerEntryDocuments < Tungo::Model
6
+ def act_number: () -> String?
7
+ def invoice_number: () -> String?
8
+ def receipt_status: () -> Tungo::Models::PlatformLedgerEntryDocumentsReceiptStatus::t?
9
+ def receipt_url: () -> String?
10
+ def initialize: (?act_number: String?, ?invoice_number: String?, ?receipt_status: Tungo::Models::PlatformLedgerEntryDocumentsReceiptStatus::input?, ?receipt_url: String?, **untyped) -> void
11
+ def self.from_wire: (Hash[String, untyped] | Hash[Symbol, untyped] data, ?api_response: Tungo::APIResponse?) -> Tungo::Models::PlatformLedgerEntryDocuments
12
+ def with: (**untyped) -> Tungo::Models::PlatformLedgerEntryDocuments
13
+ end
14
+ end
15
+ end
@@ -0,0 +1,15 @@
1
+ # Code generated by tungo-sdkgen from the Tungo Platform API contract. DO NOT EDIT.
2
+
3
+ module Tungo
4
+ module Models
5
+ module PlatformLedgerEntryDocumentsReceiptStatus
6
+ extend Tungo::Internal::Enum
7
+ type t = String
8
+ type input = String
9
+ NOT_REQUIRED: String
10
+ PENDING: String
11
+ ISSUED: String
12
+ FAILED: String
13
+ end
14
+ end
15
+ end
@@ -7,6 +7,7 @@ module Tungo
7
7
  def at: () -> String
8
8
  def client_request_id: () -> String?
9
9
  def company_id: () -> String?
10
+ def cost_tiyn: () -> Integer?
10
11
  def duration_ms: () -> Integer
11
12
  def id: () -> String
12
13
  def ip: () -> String?
@@ -15,7 +16,7 @@ module Tungo
15
16
  def query: () -> String?
16
17
  def request_id: () -> String
17
18
  def status: () -> Integer
18
- def initialize: (?api_key_id: String, ?at: (String | Time), ?client_request_id: String?, ?company_id: String?, ?duration_ms: Integer, ?id: String, ?ip: String?, ?method_: String, ?path: String, ?query: String?, ?request_id: String, ?status: Integer, **untyped) -> void
19
+ def initialize: (?api_key_id: String, ?at: (String | Time), ?client_request_id: String?, ?company_id: String?, ?cost_tiyn: Integer?, ?duration_ms: Integer, ?id: String, ?ip: String?, ?method_: String, ?path: String, ?query: String?, ?request_id: String, ?status: Integer, **untyped) -> void
19
20
  def self.from_wire: (Hash[String, untyped] | Hash[Symbol, untyped] data, ?api_response: Tungo::APIResponse?) -> Tungo::Models::PlatformRequest
20
21
  def with: (**untyped) -> Tungo::Models::PlatformRequest
21
22
  end
@@ -0,0 +1,14 @@
1
+ # Code generated by tungo-sdkgen from the Tungo Platform API contract. DO NOT EDIT.
2
+
3
+ module Tungo
4
+ module Models
5
+ class ProposalApprovalRequest < Tungo::Model
6
+ def can_request: () -> bool
7
+ def href: () -> String
8
+ def requested: () -> Tungo::Models::ProposalApprovalRequested?
9
+ def initialize: (?can_request: bool, ?href: String, ?requested: Tungo::input[Tungo::Models::ProposalApprovalRequested]?, **untyped) -> void
10
+ def self.from_wire: (Hash[String, untyped] | Hash[Symbol, untyped] data, ?api_response: Tungo::APIResponse?) -> Tungo::Models::ProposalApprovalRequest
11
+ def with: (**untyped) -> Tungo::Models::ProposalApprovalRequest
12
+ end
13
+ end
14
+ end
@@ -0,0 +1,12 @@
1
+ # Code generated by tungo-sdkgen from the Tungo Platform API contract. DO NOT EDIT.
2
+
3
+ module Tungo
4
+ module Models
5
+ class ProposalApprovalRequestBody < Tungo::Model
6
+ def note: () -> String?
7
+ def initialize: (?note: String?, **untyped) -> void
8
+ def self.from_wire: (Hash[String, untyped] | Hash[Symbol, untyped] data, ?api_response: Tungo::APIResponse?) -> Tungo::Models::ProposalApprovalRequestBody
9
+ def with: (**untyped) -> Tungo::Models::ProposalApprovalRequestBody
10
+ end
11
+ end
12
+ end
@@ -0,0 +1,15 @@
1
+ # Code generated by tungo-sdkgen from the Tungo Platform API contract. DO NOT EDIT.
2
+
3
+ module Tungo
4
+ module Models
5
+ class ProposalApprovalRequestResult < Tungo::Model
6
+ def notified: () -> bool
7
+ def ok: () -> bool
8
+ def proposal: () -> Tungo::Models::ProposalCard
9
+ def repeated: () -> bool
10
+ def initialize: (?notified: bool, ?ok: bool, ?proposal: Tungo::input[Tungo::Models::ProposalCard], ?repeated: bool, **untyped) -> void
11
+ def self.from_wire: (Hash[String, untyped] | Hash[Symbol, untyped] data, ?api_response: Tungo::APIResponse?) -> Tungo::Models::ProposalApprovalRequestResult
12
+ def with: (**untyped) -> Tungo::Models::ProposalApprovalRequestResult
13
+ end
14
+ end
15
+ end
@@ -0,0 +1,15 @@
1
+ # Code generated by tungo-sdkgen from the Tungo Platform API contract. DO NOT EDIT.
2
+
3
+ module Tungo
4
+ module Models
5
+ class ProposalApprovalRequested < Tungo::Model
6
+ def at: () -> String
7
+ def by: () -> String
8
+ def by_name: () -> String?
9
+ def note: () -> String?
10
+ def initialize: (?at: (String | Time), ?by: String, ?by_name: String?, ?note: String, **untyped) -> void
11
+ def self.from_wire: (Hash[String, untyped] | Hash[Symbol, untyped] data, ?api_response: Tungo::APIResponse?) -> Tungo::Models::ProposalApprovalRequested
12
+ def with: (**untyped) -> Tungo::Models::ProposalApprovalRequested
13
+ end
14
+ end
15
+ end
@@ -6,6 +6,7 @@ module Tungo
6
6
  def actions: () -> Array[Tungo::Models::ProposalAction]
7
7
  def advance_offset: () -> Tungo::Models::ProposalAdvanceOffset?
8
8
  def approval: () -> Tungo::Models::ProposalApproval
9
+ def approval_request: () -> Tungo::Models::ProposalApprovalRequest
9
10
  def blocker_count: () -> Integer
10
11
  def blockers: () -> Array[String]
11
12
  def counterparty: () -> Tungo::Models::ProposalParty?
@@ -23,10 +24,12 @@ module Tungo
23
24
  def level_title: () -> String
24
25
  def line_count: () -> Integer
25
26
  def lines: () -> Array[Tungo::Models::ProposalLine]
27
+ def origin: () -> Tungo::Models::ProposalOrigin
26
28
  def postings: () -> Array[Tungo::Models::ProposalPosting]
27
29
  def result: () -> Tungo::Models::ProposalResult?
28
30
  def source: () -> Tungo::Models::ProposalSource
29
31
  def status: () -> Tungo::Models::ProposalStatus::t
32
+ def status_reason: () -> Tungo::Models::ProposalCardStatusReason?
30
33
  def status_title: () -> String
31
34
  def summary: () -> String
32
35
  def title: () -> String
@@ -34,7 +37,7 @@ module Tungo
34
37
  def vat: () -> Tungo::Models::Money
35
38
  def warning_count: () -> Integer
36
39
  def warnings: () -> Array[String]
37
- def initialize: (?actions: Array[Tungo::input[Tungo::Models::ProposalAction]], ?advance_offset: Tungo::input[Tungo::Models::ProposalAdvanceOffset], ?approval: Tungo::input[Tungo::Models::ProposalApproval], ?blocker_count: Integer, ?blockers: Array[String], ?counterparty: Tungo::input[Tungo::Models::ProposalParty], ?created_at: (String | Time), ?dialog_id: String?, ?document_number: String, ?header: Tungo::input[Tungo::Models::ProposalHeader], ?history: Array[Tungo::input[Tungo::Models::ProposalHistoryEvent]], ?href: String, ?id: String, ?intent: Hash[String | Symbol, untyped], ?kind: Tungo::Models::ProposalKind::input, ?kind_title: String, ?level: Tungo::Models::AutonomyLevel::input, ?level_title: String, ?line_count: Integer, ?lines: Array[Tungo::input[Tungo::Models::ProposalLine]], ?postings: Array[Tungo::input[Tungo::Models::ProposalPosting]], ?result: Tungo::input[Tungo::Models::ProposalResult], ?source: Tungo::input[Tungo::Models::ProposalSource], ?status: Tungo::Models::ProposalStatus::input, ?status_title: String, ?summary: String, ?title: String, ?total: Tungo::input[Tungo::Models::Money], ?vat: Tungo::input[Tungo::Models::Money], ?warning_count: Integer, ?warnings: Array[String], **untyped) -> void
40
+ def initialize: (?actions: Array[Tungo::input[Tungo::Models::ProposalAction]], ?advance_offset: Tungo::input[Tungo::Models::ProposalAdvanceOffset], ?approval: Tungo::input[Tungo::Models::ProposalApproval], ?approval_request: Tungo::input[Tungo::Models::ProposalApprovalRequest], ?blocker_count: Integer, ?blockers: Array[String], ?counterparty: Tungo::input[Tungo::Models::ProposalParty], ?created_at: (String | Time), ?dialog_id: String?, ?document_number: String, ?header: Tungo::input[Tungo::Models::ProposalHeader], ?history: Array[Tungo::input[Tungo::Models::ProposalHistoryEvent]], ?href: String, ?id: String, ?intent: Hash[String | Symbol, untyped], ?kind: Tungo::Models::ProposalKind::input, ?kind_title: String, ?level: Tungo::Models::AutonomyLevel::input, ?level_title: String, ?line_count: Integer, ?lines: Array[Tungo::input[Tungo::Models::ProposalLine]], ?origin: Tungo::input[Tungo::Models::ProposalOrigin], ?postings: Array[Tungo::input[Tungo::Models::ProposalPosting]], ?result: Tungo::input[Tungo::Models::ProposalResult], ?source: Tungo::input[Tungo::Models::ProposalSource], ?status: Tungo::Models::ProposalStatus::input, ?status_reason: Tungo::input[Tungo::Models::ProposalCardStatusReason]?, ?status_title: String, ?summary: String, ?title: String, ?total: Tungo::input[Tungo::Models::Money], ?vat: Tungo::input[Tungo::Models::Money], ?warning_count: Integer, ?warnings: Array[String], **untyped) -> void
38
41
  def self.from_wire: (Hash[String, untyped] | Hash[Symbol, untyped] data, ?api_response: Tungo::APIResponse?) -> Tungo::Models::ProposalCard
39
42
  def with: (**untyped) -> Tungo::Models::ProposalCard
40
43
  end
@@ -0,0 +1,13 @@
1
+ # Code generated by tungo-sdkgen from the Tungo Platform API contract. DO NOT EDIT.
2
+
3
+ module Tungo
4
+ module Models
5
+ class ProposalCardStatusReason < Tungo::Model
6
+ def code: () -> String?
7
+ def message: () -> String
8
+ def initialize: (?code: String?, ?message: String, **untyped) -> void
9
+ def self.from_wire: (Hash[String, untyped] | Hash[Symbol, untyped] data, ?api_response: Tungo::APIResponse?) -> Tungo::Models::ProposalCardStatusReason
10
+ def with: (**untyped) -> Tungo::Models::ProposalCardStatusReason
11
+ end
12
+ end
13
+ end
@@ -5,10 +5,11 @@ module Tungo
5
5
  class ProposalHistoryEvent < Tungo::Model
6
6
  def actor: () -> String
7
7
  def at: () -> String
8
+ def code: () -> String?
8
9
  def note: () -> String?
9
10
  def status: () -> Tungo::Models::ProposalStatus::t
10
11
  def status_title: () -> String
11
- def initialize: (?actor: String, ?at: (String | Time), ?note: String, ?status: Tungo::Models::ProposalStatus::input, ?status_title: String, **untyped) -> void
12
+ def initialize: (?actor: String, ?at: (String | Time), ?code: String, ?note: String, ?status: Tungo::Models::ProposalStatus::input, ?status_title: String, **untyped) -> void
12
13
  def self.from_wire: (Hash[String, untyped] | Hash[Symbol, untyped] data, ?api_response: Tungo::APIResponse?) -> Tungo::Models::ProposalHistoryEvent
13
14
  def with: (**untyped) -> Tungo::Models::ProposalHistoryEvent
14
15
  end
@@ -4,6 +4,7 @@ module Tungo
4
4
  module Models
5
5
  class ProposalListItem < Tungo::Model
6
6
  def approval: () -> Tungo::Models::ProposalApproval
7
+ def approval_request: () -> Tungo::Models::ProposalApprovalRequest
7
8
  def blocker_count: () -> Integer
8
9
  def counterparty: () -> Tungo::Models::ProposalParty?
9
10
  def created_at: () -> String
@@ -16,13 +17,15 @@ module Tungo
16
17
  def level: () -> Tungo::Models::AutonomyLevel::t
17
18
  def level_title: () -> String
18
19
  def line_count: () -> Integer
20
+ def origin: () -> Tungo::Models::ProposalOrigin
19
21
  def status: () -> Tungo::Models::ProposalStatus::t
22
+ def status_reason: () -> Tungo::Models::ProposalListItemStatusReason?
20
23
  def status_title: () -> String
21
24
  def title: () -> String
22
25
  def total: () -> Tungo::Models::Money
23
26
  def vat: () -> Tungo::Models::Money
24
27
  def warning_count: () -> Integer
25
- def initialize: (?approval: Tungo::input[Tungo::Models::ProposalApproval], ?blocker_count: Integer, ?counterparty: Tungo::input[Tungo::Models::ProposalParty], ?created_at: (String | Time), ?dialog_id: String?, ?document_number: String, ?href: String, ?id: String, ?kind: Tungo::Models::ProposalKind::input, ?kind_title: String, ?level: Tungo::Models::AutonomyLevel::input, ?level_title: String, ?line_count: Integer, ?status: Tungo::Models::ProposalStatus::input, ?status_title: String, ?title: String, ?total: Tungo::input[Tungo::Models::Money], ?vat: Tungo::input[Tungo::Models::Money], ?warning_count: Integer, **untyped) -> void
28
+ def initialize: (?approval: Tungo::input[Tungo::Models::ProposalApproval], ?approval_request: Tungo::input[Tungo::Models::ProposalApprovalRequest], ?blocker_count: Integer, ?counterparty: Tungo::input[Tungo::Models::ProposalParty], ?created_at: (String | Time), ?dialog_id: String?, ?document_number: String, ?href: String, ?id: String, ?kind: Tungo::Models::ProposalKind::input, ?kind_title: String, ?level: Tungo::Models::AutonomyLevel::input, ?level_title: String, ?line_count: Integer, ?origin: Tungo::input[Tungo::Models::ProposalOrigin], ?status: Tungo::Models::ProposalStatus::input, ?status_reason: Tungo::input[Tungo::Models::ProposalListItemStatusReason]?, ?status_title: String, ?title: String, ?total: Tungo::input[Tungo::Models::Money], ?vat: Tungo::input[Tungo::Models::Money], ?warning_count: Integer, **untyped) -> void
26
29
  def self.from_wire: (Hash[String, untyped] | Hash[Symbol, untyped] data, ?api_response: Tungo::APIResponse?) -> Tungo::Models::ProposalListItem
27
30
  def with: (**untyped) -> Tungo::Models::ProposalListItem
28
31
  end
@@ -0,0 +1,13 @@
1
+ # Code generated by tungo-sdkgen from the Tungo Platform API contract. DO NOT EDIT.
2
+
3
+ module Tungo
4
+ module Models
5
+ class ProposalListItemStatusReason < Tungo::Model
6
+ def code: () -> String?
7
+ def message: () -> String
8
+ def initialize: (?code: String?, ?message: String, **untyped) -> void
9
+ def self.from_wire: (Hash[String, untyped] | Hash[Symbol, untyped] data, ?api_response: Tungo::APIResponse?) -> Tungo::Models::ProposalListItemStatusReason
10
+ def with: (**untyped) -> Tungo::Models::ProposalListItemStatusReason
11
+ end
12
+ end
13
+ end
@@ -0,0 +1,15 @@
1
+ # Code generated by tungo-sdkgen from the Tungo Platform API contract. DO NOT EDIT.
2
+
3
+ module Tungo
4
+ module Models
5
+ class ProposalOrigin < Tungo::Model
6
+ def batch_id: () -> String?
7
+ def dialog_id: () -> String?
8
+ def run_id: () -> String?
9
+ def source: () -> Tungo::Models::ProposalOriginSource::t
10
+ def initialize: (?batch_id: String?, ?dialog_id: String?, ?run_id: String?, ?source: Tungo::Models::ProposalOriginSource::input, **untyped) -> void
11
+ def self.from_wire: (Hash[String, untyped] | Hash[Symbol, untyped] data, ?api_response: Tungo::APIResponse?) -> Tungo::Models::ProposalOrigin
12
+ def with: (**untyped) -> Tungo::Models::ProposalOrigin
13
+ end
14
+ end
15
+ end
@@ -0,0 +1,15 @@
1
+ # Code generated by tungo-sdkgen from the Tungo Platform API contract. DO NOT EDIT.
2
+
3
+ module Tungo
4
+ module Models
5
+ module ProposalOriginSource
6
+ extend Tungo::Internal::Enum
7
+ type t = String
8
+ type input = String
9
+ CHAT: String
10
+ STATEMENT: String
11
+ ESF: String
12
+ AUTOMATION: String
13
+ end
14
+ end
15
+ end
@@ -3,11 +3,12 @@
3
3
  module Tungo
4
4
  module Models
5
5
  class ProposalPage < Tungo::Model
6
+ def approval_requested_count: () -> Integer
6
7
  def counts: () -> Hash[String, (Integer | BigDecimal)]
7
8
  def data: () -> Array[Tungo::Models::ProposalListItem]
8
9
  def next_cursor: () -> String?
9
10
  def total: () -> (Integer | BigDecimal)
10
- def initialize: (?counts: Hash[String | Symbol, (Integer | Float | BigDecimal)], ?data: Array[Tungo::input[Tungo::Models::ProposalListItem]], ?next_cursor: String?, ?total: (Integer | Float | BigDecimal), **untyped) -> void
11
+ def initialize: (?approval_requested_count: Integer, ?counts: Hash[String | Symbol, (Integer | Float | BigDecimal)], ?data: Array[Tungo::input[Tungo::Models::ProposalListItem]], ?next_cursor: String?, ?total: (Integer | Float | BigDecimal), **untyped) -> void
11
12
  def self.from_wire: (Hash[String, untyped] | Hash[Symbol, untyped] data, ?api_response: Tungo::APIResponse?) -> Tungo::Models::ProposalPage
12
13
  def with: (**untyped) -> Tungo::Models::ProposalPage
13
14
  end
@@ -4,12 +4,14 @@ module Tungo
4
4
  module Models
5
5
  class UsageRate < Tungo::Model
6
6
  def cache_read_per_mtok_tiyn: () -> Integer
7
+ def cache_write_1h_per_mtok_tiyn: () -> Integer
7
8
  def cache_write_per_mtok_tiyn: () -> Integer
8
9
  def effective_from: () -> String
9
10
  def input_per_mtok_tiyn: () -> Integer
10
11
  def model: () -> String
11
12
  def output_per_mtok_tiyn: () -> Integer
12
- def initialize: (?cache_read_per_mtok_tiyn: Integer, ?cache_write_per_mtok_tiyn: Integer, ?effective_from: (String | Time), ?input_per_mtok_tiyn: Integer, ?model: String, ?output_per_mtok_tiyn: Integer, **untyped) -> void
13
+ def title: () -> String
14
+ def initialize: (?cache_read_per_mtok_tiyn: Integer, ?cache_write_1h_per_mtok_tiyn: Integer, ?cache_write_per_mtok_tiyn: Integer, ?effective_from: (String | Time), ?input_per_mtok_tiyn: Integer, ?model: String, ?output_per_mtok_tiyn: Integer, ?title: String, **untyped) -> void
13
15
  def self.from_wire: (Hash[String, untyped] | Hash[Symbol, untyped] data, ?api_response: Tungo::APIResponse?) -> Tungo::Models::UsageRate
14
16
  def with: (**untyped) -> Tungo::Models::UsageRate
15
17
  end
@@ -4,7 +4,7 @@ module Tungo
4
4
  module Resources
5
5
  class Automations
6
6
  def initialize: (Tungo::Client client) -> void
7
- def post_hook: (String token, ?untyped payload, ?event_id: String, ?signature: String, ?secret: String?, ?content_type: String, ?request_options: Tungo::request_options?) -> Tungo::Models::AutomationHookAccepted
7
+ def post_hook: (String token, ?untyped payload, ?event_id: String, ?signature: String, ?secret: String?, ?signature_header: String?, ?content_type: String, ?request_options: Tungo::request_options?) -> Tungo::Models::AutomationHookAccepted
8
8
  def list_hooks: (?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::Models::ListCompanyAutomationsHooksResponse
9
9
  def create_hook: (name: String, ?id_path: String?, ?signature_header: String, ?signature_secret: String?, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::Models::AutomationHookWithToken
10
10
  def get_hook: (String id, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::Models::AutomationHook
@@ -6,15 +6,22 @@ module Tungo
6
6
  def initialize: (Tungo::Client client) -> void
7
7
  def list: (?cursor: String, ?limit: Integer, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::Page[Tungo::Models::ChatDialogSummary, Tungo::Models::ChatDialogList]
8
8
  def list_all: (?cursor: String, ?limit: Integer, ?company_id: String?, ?request_options: Tungo::request_options?) -> Enumerator[Tungo::Models::ChatDialogSummary, void]
9
- def create: (?attachments: Array[Tungo::input[Tungo::Models::ChatAttachment]], ?capabilities: Array[String], ?dialog_id: String?, ?message: String, ?mode: Tungo::Models::ChatMessageRequestMode::input, ?new_dialog: bool, ?proposal_id: String?, ?turn: Integer?, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::Models::ChatTurnResult
10
- def create_stream: (?attachments: Array[Tungo::input[Tungo::Models::ChatAttachment]], ?capabilities: Array[String], ?dialog_id: String?, ?message: String, ?mode: Tungo::Models::ChatMessageRequestMode::input, ?new_dialog: bool, ?proposal_id: String?, ?turn: Integer?, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::ChatStream
9
+ def create: (?attachments: Array[Tungo::input[Tungo::Models::ChatAttachment]], ?capabilities: Array[String], ?dialog_id: String?, ?effort: Tungo::Models::ChatMessageRequestEffort::input?, ?mentions: Array[Tungo::input[Tungo::Models::ChatMention]], ?message: String, ?mode: Tungo::Models::ChatMessageRequestMode::input, ?new_dialog: bool, ?proposal_id: String?, ?turn: Integer?, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::Models::ChatTurnResult
10
+ def create_stream: (?attachments: Array[Tungo::input[Tungo::Models::ChatAttachment]], ?capabilities: Array[String], ?dialog_id: String?, ?effort: Tungo::Models::ChatMessageRequestEffort::input?, ?mentions: Array[Tungo::input[Tungo::Models::ChatMention]], ?message: String, ?mode: Tungo::Models::ChatMessageRequestMode::input, ?new_dialog: bool, ?proposal_id: String?, ?turn: Integer?, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::ChatStream
11
11
  def count_tokens: (?attachments: Array[Tungo::input[Tungo::Models::ChatAttachment]], ?dialog_id: String, ?message: String, ?mode: Tungo::Models::ChatTokenCountRequestMode::input, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::Models::ChatTokenCount
12
+ def list_mentions: (?limit: Integer, ?q: String, ?types: String, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::Models::ChatMentionSearch
13
+ def get_rating_options: (?lang: Tungo::Models::ListCompanyChatRatingOptionsLang::input, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::Models::ChatRatingOptions
14
+ def list_suggestions: (?lang: Tungo::Models::ListCompanyChatSuggestionsLang::input, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::Models::ChatSuggestions
12
15
  def get: (String id, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::Models::ChatDialog
13
16
  def update: (String id, title: String, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::Models::ChatDialogRenamed
14
17
  def delete: (String id, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::Models::ChatDialogDeleted
15
18
  def answer: (String id, answers: Array[Tungo::input[Tungo::Models::ChatChoiceAnswer]], choice_id: String, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::Models::ChatTurnResult
16
19
  def answer_stream: (String id, answers: Array[Tungo::input[Tungo::Models::ChatChoiceAnswer]], choice_id: String, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::ChatStream
17
20
  def list_events: (String id, ?turn: Integer?, ?last_event_id: String?, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::ChatStream
21
+ def rate_message: (String id, String turn, vote: Tungo::Models::ChatMessageRatingBodyVote::input, ?comment: String?, ?reason: String?, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::Models::ChatMessageRated
22
+ def delete_message_rating: (String id, String turn, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::Models::ChatMessageRated
23
+ def rate: (String id, score: Integer, ?comment: String?, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::Models::ChatDialogRated
24
+ def dismiss_rating: (String id, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::Models::ChatRatingDismissed
18
25
  def stop: (String id, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::Models::ChatStopResult
19
26
  end
20
27
  end
@@ -4,12 +4,13 @@ module Tungo
4
4
  module Resources
5
5
  class Proposals
6
6
  def initialize: (Tungo::Client client) -> void
7
- def list: (?cursor: String, ?date_from: (String | Date), ?date_to: (String | Date), ?kind: String, ?limit: Integer, ?q: String, ?status: String, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::Page[Tungo::Models::ProposalListItem, Tungo::Models::ProposalPage]
8
- def list_all: (?cursor: String, ?date_from: (String | Date), ?date_to: (String | Date), ?kind: String, ?limit: Integer, ?q: String, ?status: String, ?company_id: String?, ?request_options: Tungo::request_options?) -> Enumerator[Tungo::Models::ProposalListItem, void]
7
+ def list: (?approval_requested: Tungo::Models::ListCompanyProposalsApprovalRequested::input, ?batch_id: String, ?cursor: String, ?date_from: (String | Date), ?date_to: (String | Date), ?kind: String, ?limit: Integer, ?q: String, ?source: String, ?status: String, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::Page[Tungo::Models::ProposalListItem, Tungo::Models::ProposalPage]
8
+ def list_all: (?approval_requested: Tungo::Models::ListCompanyProposalsApprovalRequested::input, ?batch_id: String, ?cursor: String, ?date_from: (String | Date), ?date_to: (String | Date), ?kind: String, ?limit: Integer, ?q: String, ?source: String, ?status: String, ?company_id: String?, ?request_options: Tungo::request_options?) -> Enumerator[Tungo::Models::ProposalListItem, void]
9
9
  def approve_batch: (?async: bool, ?batch_id: String, ?exclude: Array[String], ?idempotency_key: String, ?ids: Array[String], ?note: String, ?post: bool, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::Models::ApproveBatchCompanyProposalsResponse::t
10
10
  def get: (String id, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::Models::ProposalCard
11
11
  def approve: (String id, ?idempotency_key: String, ?note: String, ?post: bool, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::Models::ProposalDecision
12
12
  def reject: (String id, reason: String, ?confirm_unknown_write: bool, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::Models::ProposalDecision
13
+ def request_approval: (String id, ?note: String?, ?company_id: String?, ?request_options: Tungo::request_options?) -> Tungo::Models::ProposalApprovalRequestResult
13
14
  end
14
15
  end
15
16
  end