cadenya 0.26.0 → 0.27.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (42) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +8 -0
  3. data/README.md +1 -1
  4. data/lib/cadenya/models/account_info.rb +13 -1
  5. data/lib/cadenya/models/account_rotate_challenge_token_params.rb +14 -0
  6. data/lib/cadenya/models/agents/webhook_delivery_data.rb +1 -0
  7. data/lib/cadenya/models/agents/webhook_delivery_list_params.rb +1 -0
  8. data/lib/cadenya/models/objective_continue_params.rb +1 -26
  9. data/lib/cadenya/models/objective_event_data.rb +63 -1
  10. data/lib/cadenya/models/rotate_challenge_token_response.rb +18 -0
  11. data/lib/cadenya/models/tool_set_adapter_mcp.rb +38 -1
  12. data/lib/cadenya/models/tool_sets/tool_info.rb +14 -1
  13. data/lib/cadenya/models.rb +4 -0
  14. data/lib/cadenya/resources/account.rb +19 -0
  15. data/lib/cadenya/resources/objectives.rb +1 -3
  16. data/lib/cadenya/version.rb +1 -1
  17. data/lib/cadenya.rb +2 -0
  18. data/rbi/cadenya/models/account_info.rbi +19 -0
  19. data/rbi/cadenya/models/account_rotate_challenge_token_params.rbi +30 -0
  20. data/rbi/cadenya/models/agents/webhook_delivery_data.rbi +5 -0
  21. data/rbi/cadenya/models/agents/webhook_delivery_list_params.rbi +5 -0
  22. data/rbi/cadenya/models/objective_continue_params.rbi +0 -49
  23. data/rbi/cadenya/models/objective_event_data.rbi +128 -0
  24. data/rbi/cadenya/models/rotate_challenge_token_response.rbi +30 -0
  25. data/rbi/cadenya/models/tool_set_adapter_mcp.rbi +69 -0
  26. data/rbi/cadenya/models/tool_sets/tool_info.rbi +17 -0
  27. data/rbi/cadenya/models.rbi +5 -0
  28. data/rbi/cadenya/resources/account.rbi +10 -0
  29. data/rbi/cadenya/resources/objectives.rbi +0 -5
  30. data/sig/cadenya/models/account_info.rbs +11 -1
  31. data/sig/cadenya/models/account_rotate_challenge_token_params.rbs +15 -0
  32. data/sig/cadenya/models/agents/webhook_delivery_data.rbs +2 -0
  33. data/sig/cadenya/models/agents/webhook_delivery_list_params.rbs +2 -0
  34. data/sig/cadenya/models/objective_continue_params.rbs +1 -26
  35. data/sig/cadenya/models/objective_event_data.rbs +56 -0
  36. data/sig/cadenya/models/rotate_challenge_token_response.rbs +15 -0
  37. data/sig/cadenya/models/tool_set_adapter_mcp.rbs +32 -0
  38. data/sig/cadenya/models/tool_sets/tool_info.rbs +11 -1
  39. data/sig/cadenya/models.rbs +4 -0
  40. data/sig/cadenya/resources/account.rbs +4 -0
  41. data/sig/cadenya/resources/objectives.rbs +0 -1
  42. metadata +8 -2
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: c9e5f872c6b3d400630fe4c6ff1429e78b994dc389ab7e610a0b6d208837ac0b
4
- data.tar.gz: 8fab533c3fac313a45a7458b0c27d4d4be58bb8f27c0a33d8783a48ec246690f
3
+ metadata.gz: c6eb50e3dd9cd1e5abf056602489f69eb105ade97ee895cc3317800037f7fc38
4
+ data.tar.gz: e09e1f78f5785eb72204bf9f386bcab14a520860c398976ad0924c687104ae7d
5
5
  SHA512:
6
- metadata.gz: 5edd2c17b031c2044ab6dc3ffe5a94585c6f2860511951bd9721c546571287c176f25cd10648bb008385f989611d86f998dc560250267fb3bc0ba1425ba5579d
7
- data.tar.gz: f593a86264bf46b5ff61d546e63e93926bc2850ef10d6d8bc82f906c2ce587b03455bdf62d755a1a66f39a6d715383f0374668dd73f5e525e1d79850fcdaf9bc
6
+ metadata.gz: d04c3cecc0ff18faf6f7ed78f3534212d31dc3cc232810b2d3f27e479f9c2e25cc4dc2f14cabce32bdc2e1937e00043032608400d67c2d30cde27ce315230967
7
+ data.tar.gz: 52851b33c7aa1d0fcceaf8f82807900525f38074b0437c951f193ee1c0de8baadcb2624e80b840f970d0ec5220fb989b8d7c4eec07bc2a516c18e994a539ad69
data/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.27.0 (2026-07-03)
4
+
5
+ Full Changelog: [v0.26.0...v0.27.0](https://github.com/cadenya/cadenya-ruby/compare/v0.26.0...v0.27.0)
6
+
7
+ ### Features
8
+
9
+ * **api:** api update ([f407d32](https://github.com/cadenya/cadenya-ruby/commit/f407d328b0177f7048eb6d2a90916bd98351d3d3))
10
+
3
11
  ## 0.26.0 (2026-07-02)
4
12
 
5
13
  Full Changelog: [v0.25.0...v0.26.0](https://github.com/cadenya/cadenya-ruby/compare/v0.25.0...v0.26.0)
data/README.md CHANGED
@@ -17,7 +17,7 @@ To use this gem, install via Bundler by adding the following to your application
17
17
  <!-- x-release-please-start-version -->
18
18
 
19
19
  ```ruby
20
- gem "cadenya", "~> 0.26.0"
20
+ gem "cadenya", "~> 0.27.0"
21
21
  ```
22
22
 
23
23
  <!-- x-release-please-end -->
@@ -4,6 +4,16 @@ module Cadenya
4
4
  module Models
5
5
  class AccountInfo < Cadenya::Internal::Type::BaseModel
6
6
  response_only do
7
+ # @!attribute challenge_token
8
+ # The challenge token Cadenya sends in the X-Cadenya-Challenge-Token header on
9
+ # every MCP tools/list request. Server implementations can accept a valid
10
+ # challenge token in place of per-user auth when listing tools, while still
11
+ # requiring real auth on tools/call. Rotate with RotateChallengeToken; update any
12
+ # servers validating the token before rotating.
13
+ #
14
+ # @return [String, nil]
15
+ optional :challenge_token, String, api_name: :challengeToken
16
+
7
17
  # @!attribute global_api_key
8
18
  # An API key for the account. Use workspace-association RPCs to grant the key
9
19
  # access to specific workspaces; a key with zero workspaces is valid but cannot
@@ -21,12 +31,14 @@ module Cadenya
21
31
  optional :webhook_events_hmac_secret, String, api_name: :webhookEventsHmacSecret
22
32
  end
23
33
 
24
- # @!method initialize(global_api_key: nil, webhook_events_hmac_secret: nil)
34
+ # @!method initialize(challenge_token: nil, global_api_key: nil, webhook_events_hmac_secret: nil)
25
35
  # Some parameter documentations has been truncated, see
26
36
  # {Cadenya::Models::AccountInfo} for more details.
27
37
  #
28
38
  # Server-populated information about the account.
29
39
  #
40
+ # @param challenge_token [String] The challenge token Cadenya sends in the X-Cadenya-Challenge-Token header
41
+ #
30
42
  # @param global_api_key [Cadenya::Models::APIKey] An API key for the account. Use workspace-association RPCs to grant the
31
43
  #
32
44
  # @param webhook_events_hmac_secret [String] The generated secret that will sign all webhooks that are sent to your configure
@@ -0,0 +1,14 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Cadenya
4
+ module Models
5
+ # @see Cadenya::Resources::Account#rotate_challenge_token
6
+ class AccountRotateChallengeTokenParams < Cadenya::Internal::Type::BaseModel
7
+ extend Cadenya::Internal::Type::RequestParameters::Converter
8
+ include Cadenya::Internal::Type::RequestParameters
9
+
10
+ # @!method initialize(request_options: {})
11
+ # @param request_options [Cadenya::RequestOptions, Hash{Symbol=>Object}]
12
+ end
13
+ end
14
+ end
@@ -135,6 +135,7 @@ module Cadenya
135
135
  OBJECTIVE_EVENT_TYPE_SUB_AGENT_SPAWNED = :OBJECTIVE_EVENT_TYPE_SUB_AGENT_SPAWNED
136
136
  OBJECTIVE_EVENT_TYPE_SUB_AGENT_UPDATED = :OBJECTIVE_EVENT_TYPE_SUB_AGENT_UPDATED
137
137
  OBJECTIVE_EVENT_TYPE_FINALIZED = :OBJECTIVE_EVENT_TYPE_FINALIZED
138
+ OBJECTIVE_EVENT_TYPE_NOTICE = :OBJECTIVE_EVENT_TYPE_NOTICE
138
139
 
139
140
  # @!method self.values
140
141
  # @return [Array<Symbol>]
@@ -77,6 +77,7 @@ module Cadenya
77
77
  OBJECTIVE_EVENT_TYPE_SUB_AGENT_SPAWNED = :OBJECTIVE_EVENT_TYPE_SUB_AGENT_SPAWNED
78
78
  OBJECTIVE_EVENT_TYPE_SUB_AGENT_UPDATED = :OBJECTIVE_EVENT_TYPE_SUB_AGENT_UPDATED
79
79
  OBJECTIVE_EVENT_TYPE_FINALIZED = :OBJECTIVE_EVENT_TYPE_FINALIZED
80
+ OBJECTIVE_EVENT_TYPE_NOTICE = :OBJECTIVE_EVENT_TYPE_NOTICE
80
81
 
81
82
  # @!method self.values
82
83
  # @return [Array<Symbol>]
@@ -30,14 +30,7 @@ module Cadenya
30
30
  # @return [String, nil]
31
31
  optional :message, String
32
32
 
33
- # @!attribute secrets
34
- # Secrets that should be included with the message. Helpful for when you need to
35
- # update secrets on the objective (IE: A secret expires and needs to be refreshed)
36
- #
37
- # @return [Array<Cadenya::Models::ObjectiveContinueParams::Secret>, nil]
38
- optional :secrets, -> { Cadenya::Internal::Type::ArrayOf[Cadenya::ObjectiveContinueParams::Secret] }
39
-
40
- # @!method initialize(workspace_id:, objective_id:, enqueue: nil, message: nil, secrets: nil, request_options: {})
33
+ # @!method initialize(workspace_id:, objective_id:, enqueue: nil, message: nil, request_options: {})
41
34
  # Some parameter documentations has been truncated, see
42
35
  # {Cadenya::Models::ObjectiveContinueParams} for more details.
43
36
  #
@@ -49,25 +42,7 @@ module Cadenya
49
42
  #
50
43
  # @param message [String] The message to continue an objective that has completed (or you are enqueing)
51
44
  #
52
- # @param secrets [Array<Cadenya::Models::ObjectiveContinueParams::Secret>] Secrets that should be included with the message. Helpful for when you need to u
53
- #
54
45
  # @param request_options [Cadenya::RequestOptions, Hash{Symbol=>Object}]
55
-
56
- class Secret < Cadenya::Internal::Type::BaseModel
57
- # @!attribute name
58
- #
59
- # @return [String, nil]
60
- optional :name, String
61
-
62
- # @!attribute value
63
- #
64
- # @return [String, nil]
65
- optional :value, String
66
-
67
- # @!method initialize(name: nil, value: nil)
68
- # @param name [String]
69
- # @param value [String]
70
- end
71
46
  end
72
47
  end
73
48
  end
@@ -44,6 +44,16 @@ module Cadenya
44
44
  # @return [Cadenya::Models::MemoryRead, nil]
45
45
  optional :memory_read, -> { Cadenya::MemoryRead }, api_name: :memoryRead
46
46
 
47
+ # @!attribute notice
48
+ # Notice is a non-terminal diagnostic emitted by the runtime when something
49
+ # noteworthy but non-fatal happens during an objective — for example a
50
+ # just-in-time tool set failing to load, or a previously loaded tool being dropped
51
+ # because it was archived. Notices carry no structured payload; they exist to make
52
+ # the objective timeline self-explanatory.
53
+ #
54
+ # @return [Cadenya::Models::ObjectiveEventData::Notice, nil]
55
+ optional :notice, -> { Cadenya::ObjectiveEventData::Notice }
56
+
47
57
  # @!attribute sub_agent_spawned
48
58
  #
49
59
  # @return [Cadenya::Models::SubAgentSpawned, nil]
@@ -98,7 +108,7 @@ module Cadenya
98
108
  # @return [Cadenya::Models::UserMessage, nil]
99
109
  optional :user_message, -> { Cadenya::UserMessage }, api_name: :userMessage
100
110
 
101
- # @!method initialize(assistant_message: nil, cancelled: nil, context_window_compacted: nil, error: nil, finalized: nil, memory_read: nil, sub_agent_spawned: nil, sub_agent_updated: nil, tool_approval_requested: nil, tool_approved: nil, tool_called: nil, tool_denied: nil, tool_error: nil, tool_result: nil, type: nil, user_message: nil)
111
+ # @!method initialize(assistant_message: nil, cancelled: nil, context_window_compacted: nil, error: nil, finalized: nil, memory_read: nil, notice: nil, sub_agent_spawned: nil, sub_agent_updated: nil, tool_approval_requested: nil, tool_approved: nil, tool_called: nil, tool_denied: nil, tool_error: nil, tool_result: nil, type: nil, user_message: nil)
102
112
  # Some parameter documentations has been truncated, see
103
113
  # {Cadenya::Models::ObjectiveEventData} for more details.
104
114
  #
@@ -114,6 +124,8 @@ module Cadenya
114
124
  #
115
125
  # @param memory_read [Cadenya::Models::MemoryRead] MemoryRead is emitted each time the agent resolves a key against the
116
126
  #
127
+ # @param notice [Cadenya::Models::ObjectiveEventData::Notice] Notice is a non-terminal diagnostic emitted by the runtime when something
128
+ #
117
129
  # @param sub_agent_spawned [Cadenya::Models::SubAgentSpawned]
118
130
  #
119
131
  # @param sub_agent_updated [Cadenya::Models::SubAgentUpdated]
@@ -175,6 +187,56 @@ module Cadenya
175
187
  #
176
188
  # @param output [Object] If the objective was created with an output schema, and the agent
177
189
  end
190
+
191
+ # @see Cadenya::Models::ObjectiveEventData#notice
192
+ class Notice < Cadenya::Internal::Type::BaseModel
193
+ # @!attribute key
194
+ # Stable machine-readable identifier for the notice kind (for example
195
+ # "tool_set_load_failed", "tool_archived"). Clients can switch on it or use it as
196
+ # an i18n key; the message is the English fallback.
197
+ #
198
+ # @return [String, nil]
199
+ optional :key, String
200
+
201
+ # @!attribute level
202
+ #
203
+ # @return [Symbol, Cadenya::Models::ObjectiveEventData::Notice::Level, nil]
204
+ optional :level, enum: -> { Cadenya::ObjectiveEventData::Notice::Level }
205
+
206
+ # @!attribute message
207
+ # Human-readable description of what happened.
208
+ #
209
+ # @return [String, nil]
210
+ optional :message, String
211
+
212
+ # @!method initialize(key: nil, level: nil, message: nil)
213
+ # Some parameter documentations has been truncated, see
214
+ # {Cadenya::Models::ObjectiveEventData::Notice} for more details.
215
+ #
216
+ # Notice is a non-terminal diagnostic emitted by the runtime when something
217
+ # noteworthy but non-fatal happens during an objective — for example a
218
+ # just-in-time tool set failing to load, or a previously loaded tool being dropped
219
+ # because it was archived. Notices carry no structured payload; they exist to make
220
+ # the objective timeline self-explanatory.
221
+ #
222
+ # @param key [String] Stable machine-readable identifier for the notice kind (for example
223
+ #
224
+ # @param level [Symbol, Cadenya::Models::ObjectiveEventData::Notice::Level]
225
+ #
226
+ # @param message [String] Human-readable description of what happened.
227
+
228
+ # @see Cadenya::Models::ObjectiveEventData::Notice#level
229
+ module Level
230
+ extend Cadenya::Internal::Type::Enum
231
+
232
+ LEVEL_UNSPECIFIED = :LEVEL_UNSPECIFIED
233
+ LEVEL_INFO = :LEVEL_INFO
234
+ LEVEL_WARN = :LEVEL_WARN
235
+
236
+ # @!method self.values
237
+ # @return [Array<Symbol>]
238
+ end
239
+ end
178
240
  end
179
241
  end
180
242
  end
@@ -0,0 +1,18 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Cadenya
4
+ module Models
5
+ # @see Cadenya::Resources::Account#rotate_challenge_token
6
+ class RotateChallengeTokenResponse < Cadenya::Internal::Type::BaseModel
7
+ # @!attribute challenge_token
8
+ #
9
+ # @return [String, nil]
10
+ optional :challenge_token, String, api_name: :challengeToken
11
+
12
+ # @!method initialize(challenge_token: nil)
13
+ # Response containing the newly generated challenge token.
14
+ #
15
+ # @param challenge_token [String]
16
+ end
17
+ end
18
+ end
@@ -20,6 +20,12 @@ module Cadenya
20
20
  # @return [Cadenya::Models::ToolFilter, nil]
21
21
  optional :include_tools, -> { Cadenya::ToolFilter }, api_name: :includeTools
22
22
 
23
+ # @!attribute just_in_time
24
+ # Defines behavior for just-in-time capable tool set adapters (IE: MCP).
25
+ #
26
+ # @return [Cadenya::Models::ToolSetAdapterMcp::JustInTime, nil]
27
+ optional :just_in_time, -> { Cadenya::ToolSetAdapterMcp::JustInTime }, api_name: :justInTime
28
+
23
29
  # @!attribute tool_approvals
24
30
  # Approval filters that will automatically set the approval requirement on tools
25
31
  # synced from an external source
@@ -32,7 +38,7 @@ module Cadenya
32
38
  # @return [String, nil]
33
39
  optional :url, String
34
40
 
35
- # @!method initialize(exclude_tools: nil, headers: nil, include_tools: nil, tool_approvals: nil, url: nil)
41
+ # @!method initialize(exclude_tools: nil, headers: nil, include_tools: nil, just_in_time: nil, tool_approvals: nil, url: nil)
36
42
  # Some parameter documentations has been truncated, see
37
43
  # {Cadenya::Models::ToolSetAdapterMcp} for more details.
38
44
  #
@@ -42,9 +48,40 @@ module Cadenya
42
48
  #
43
49
  # @param include_tools [Cadenya::Models::ToolFilter] Top-level filter with simple boolean logic (no nesting)
44
50
  #
51
+ # @param just_in_time [Cadenya::Models::ToolSetAdapterMcp::JustInTime] Defines behavior for just-in-time capable tool set adapters (IE: MCP).
52
+ #
45
53
  # @param tool_approvals [Cadenya::Models::ApprovalRequirementFilter] Approval filters that will automatically set the approval requirement on tools s
46
54
  #
47
55
  # @param url [String]
56
+
57
+ # @see Cadenya::Models::ToolSetAdapterMcp#just_in_time
58
+ class JustInTime < Cadenya::Internal::Type::BaseModel
59
+ # @!attribute enabled
60
+ #
61
+ # @return [Boolean, nil]
62
+ optional :enabled, Cadenya::Internal::Type::Boolean
63
+
64
+ # @!attribute fail_objective_on_tool_list_error
65
+ # If set, an objective will automatically be failed if tools cannot be loaded in
66
+ # the initial stages of an objective being created. Tools are loaded
67
+ # asynchronously, so this setting is useful for ensuring that an objective
68
+ # continued any further if tools are not available.
69
+ #
70
+ # @return [Boolean, nil]
71
+ optional :fail_objective_on_tool_list_error,
72
+ Cadenya::Internal::Type::Boolean,
73
+ api_name: :failObjectiveOnToolListError
74
+
75
+ # @!method initialize(enabled: nil, fail_objective_on_tool_list_error: nil)
76
+ # Some parameter documentations has been truncated, see
77
+ # {Cadenya::Models::ToolSetAdapterMcp::JustInTime} for more details.
78
+ #
79
+ # Defines behavior for just-in-time capable tool set adapters (IE: MCP).
80
+ #
81
+ # @param enabled [Boolean]
82
+ #
83
+ # @param fail_objective_on_tool_list_error [Boolean] If set, an objective will automatically be failed if tools cannot be loaded
84
+ end
48
85
  end
49
86
  end
50
87
  end
@@ -18,12 +18,25 @@ module Cadenya
18
18
  # @return [Cadenya::Models::ResourceMetadata, nil]
19
19
  optional :tool_set, -> { Cadenya::ResourceMetadata }, api_name: :toolSet
20
20
 
21
- # @!method initialize(created_by: nil, tool_set: nil)
21
+ response_only do
22
+ # @!attribute signature
23
+ # Content signature identifying the tool within its tool set: a hash of the
24
+ # sanitized llm_tool_name, description, and canonical parameters. Two tools with
25
+ # the same llm_tool_name but different parameters or description (as MCP servers
26
+ # may return per user) have distinct signatures.
27
+ #
28
+ # @return [String, nil]
29
+ optional :signature, String
30
+ end
31
+
32
+ # @!method initialize(created_by: nil, signature: nil, tool_set: nil)
22
33
  # Some parameter documentations has been truncated, see
23
34
  # {Cadenya::Models::ToolSets::ToolInfo} for more details.
24
35
  #
25
36
  # @param created_by [Cadenya::Models::Profile] A profile identifies a user or non-human principal (such as an API key)
26
37
  #
38
+ # @param signature [String] Content signature identifying the tool within its tool set: a hash of the
39
+ #
27
40
  # @param tool_set [Cadenya::Models::ResourceMetadata] Standard metadata for persistent, named resources (e.g., agents, tools, prompts)
28
41
  end
29
42
  end
@@ -47,6 +47,8 @@ module Cadenya
47
47
 
48
48
  AccountRetrieveParams = Cadenya::Models::AccountRetrieveParams
49
49
 
50
+ AccountRotateChallengeTokenParams = Cadenya::Models::AccountRotateChallengeTokenParams
51
+
50
52
  AccountRotateWebhookSigningKeyParams = Cadenya::Models::AccountRotateWebhookSigningKeyParams
51
53
 
52
54
  AccountSpec = Cadenya::Models::AccountSpec
@@ -219,6 +221,8 @@ module Cadenya
219
221
 
220
222
  ResourceMetadata = Cadenya::Models::ResourceMetadata
221
223
 
224
+ RotateChallengeTokenResponse = Cadenya::Models::RotateChallengeTokenResponse
225
+
222
226
  RotateWebhookSigningKeyResponse = Cadenya::Models::RotateWebhookSigningKeyResponse
223
227
 
224
228
  SearchSearchToolsOrToolSetsParams = Cadenya::Models::SearchSearchToolsOrToolSetsParams
@@ -24,6 +24,25 @@ module Cadenya
24
24
  )
25
25
  end
26
26
 
27
+ # Rotates the challenge token sent in the X-Cadenya-Challenge-Token header on MCP
28
+ # tools/list requests. Returns only the new token.
29
+ #
30
+ # @overload rotate_challenge_token(request_options: {})
31
+ #
32
+ # @param request_options [Cadenya::RequestOptions, Hash{Symbol=>Object}, nil]
33
+ #
34
+ # @return [Cadenya::Models::RotateChallengeTokenResponse]
35
+ #
36
+ # @see Cadenya::Models::AccountRotateChallengeTokenParams
37
+ def rotate_challenge_token(params = {})
38
+ @client.request(
39
+ method: :post,
40
+ path: "v1/account:rotateChallengeToken",
41
+ model: Cadenya::RotateChallengeTokenResponse,
42
+ options: params[:request_options]
43
+ )
44
+ end
45
+
27
46
  # Rotates the webhook signing key for the account. Returns only the new key.
28
47
  #
29
48
  # @overload rotate_webhook_signing_key(request_options: {})
@@ -208,7 +208,7 @@ module Cadenya
208
208
  #
209
209
  # Continues an objective that has completed
210
210
  #
211
- # @overload continue(objective_id, workspace_id:, enqueue: nil, message: nil, secrets: nil, request_options: {})
211
+ # @overload continue(objective_id, workspace_id:, enqueue: nil, message: nil, request_options: {})
212
212
  #
213
213
  # @param objective_id [String] Path param: The ID of the objective. If you have assigned an external ID to the
214
214
  #
@@ -218,8 +218,6 @@ module Cadenya
218
218
  #
219
219
  # @param message [String] Body param: The message to continue an objective that has completed (or you are
220
220
  #
221
- # @param secrets [Array<Cadenya::Models::ObjectiveContinueParams::Secret>] Body param: Secrets that should be included with the message. Helpful for when y
222
- #
223
221
  # @param request_options [Cadenya::RequestOptions, Hash{Symbol=>Object}, nil]
224
222
  #
225
223
  # @return [Cadenya::Models::ObjectiveEvent]
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Cadenya
4
- VERSION = "0.26.0"
4
+ VERSION = "0.27.0"
5
5
  end
data/lib/cadenya.rb CHANGED
@@ -60,6 +60,7 @@ require_relative "cadenya/models/account"
60
60
  require_relative "cadenya/models/account_info"
61
61
  require_relative "cadenya/models/account_resource_metadata"
62
62
  require_relative "cadenya/models/account_retrieve_params"
63
+ require_relative "cadenya/models/account_rotate_challenge_token_params"
63
64
  require_relative "cadenya/models/account_rotate_webhook_signing_key_params"
64
65
  require_relative "cadenya/models/account_spec"
65
66
  require_relative "cadenya/models/agent"
@@ -223,6 +224,7 @@ require_relative "cadenya/models/profile"
223
224
  require_relative "cadenya/models/profile_spec"
224
225
  require_relative "cadenya/models/profile_whoami_params"
225
226
  require_relative "cadenya/models/resource_metadata"
227
+ require_relative "cadenya/models/rotate_challenge_token_response"
226
228
  require_relative "cadenya/models/rotate_webhook_signing_key_response"
227
229
  require_relative "cadenya/models/search_search_tools_or_tool_sets_params"
228
230
  require_relative "cadenya/models/search_search_tools_or_tool_sets_response"
@@ -6,6 +6,17 @@ module Cadenya
6
6
  OrHash =
7
7
  T.type_alias { T.any(Cadenya::AccountInfo, Cadenya::Internal::AnyHash) }
8
8
 
9
+ # The challenge token Cadenya sends in the X-Cadenya-Challenge-Token header on
10
+ # every MCP tools/list request. Server implementations can accept a valid
11
+ # challenge token in place of per-user auth when listing tools, while still
12
+ # requiring real auth on tools/call. Rotate with RotateChallengeToken; update any
13
+ # servers validating the token before rotating.
14
+ sig { returns(T.nilable(String)) }
15
+ attr_reader :challenge_token
16
+
17
+ sig { params(challenge_token: String).void }
18
+ attr_writer :challenge_token
19
+
9
20
  # An API key for the account. Use workspace-association RPCs to grant the key
10
21
  # access to specific workspaces; a key with zero workspaces is valid but cannot
11
22
  # access workspace-scoped resources.
@@ -27,11 +38,18 @@ module Cadenya
27
38
  # Server-populated information about the account.
28
39
  sig do
29
40
  params(
41
+ challenge_token: String,
30
42
  global_api_key: Cadenya::APIKey::OrHash,
31
43
  webhook_events_hmac_secret: String
32
44
  ).returns(T.attached_class)
33
45
  end
34
46
  def self.new(
47
+ # The challenge token Cadenya sends in the X-Cadenya-Challenge-Token header on
48
+ # every MCP tools/list request. Server implementations can accept a valid
49
+ # challenge token in place of per-user auth when listing tools, while still
50
+ # requiring real auth on tools/call. Rotate with RotateChallengeToken; update any
51
+ # servers validating the token before rotating.
52
+ challenge_token: nil,
35
53
  # An API key for the account. Use workspace-association RPCs to grant the key
36
54
  # access to specific workspaces; a key with zero workspaces is valid but cannot
37
55
  # access workspace-scoped resources.
@@ -46,6 +64,7 @@ module Cadenya
46
64
  sig do
47
65
  override.returns(
48
66
  {
67
+ challenge_token: String,
49
68
  global_api_key: Cadenya::APIKey,
50
69
  webhook_events_hmac_secret: String
51
70
  }
@@ -0,0 +1,30 @@
1
+ # typed: strong
2
+
3
+ module Cadenya
4
+ module Models
5
+ class AccountRotateChallengeTokenParams < Cadenya::Internal::Type::BaseModel
6
+ extend Cadenya::Internal::Type::RequestParameters::Converter
7
+ include Cadenya::Internal::Type::RequestParameters
8
+
9
+ OrHash =
10
+ T.type_alias do
11
+ T.any(
12
+ Cadenya::AccountRotateChallengeTokenParams,
13
+ Cadenya::Internal::AnyHash
14
+ )
15
+ end
16
+
17
+ sig do
18
+ params(request_options: Cadenya::RequestOptions::OrHash).returns(
19
+ T.attached_class
20
+ )
21
+ end
22
+ def self.new(request_options: {})
23
+ end
24
+
25
+ sig { override.returns({ request_options: Cadenya::RequestOptions }) }
26
+ def to_hash
27
+ end
28
+ end
29
+ end
30
+ end
@@ -228,6 +228,11 @@ module Cadenya
228
228
  :OBJECTIVE_EVENT_TYPE_FINALIZED,
229
229
  Cadenya::Agents::WebhookDeliveryData::EventType::TaggedSymbol
230
230
  )
231
+ OBJECTIVE_EVENT_TYPE_NOTICE =
232
+ T.let(
233
+ :OBJECTIVE_EVENT_TYPE_NOTICE,
234
+ Cadenya::Agents::WebhookDeliveryData::EventType::TaggedSymbol
235
+ )
231
236
 
232
237
  sig do
233
238
  override.returns(
@@ -197,6 +197,11 @@ module Cadenya
197
197
  :OBJECTIVE_EVENT_TYPE_FINALIZED,
198
198
  Cadenya::Agents::WebhookDeliveryListParams::EventType::TaggedSymbol
199
199
  )
200
+ OBJECTIVE_EVENT_TYPE_NOTICE =
201
+ T.let(
202
+ :OBJECTIVE_EVENT_TYPE_NOTICE,
203
+ Cadenya::Agents::WebhookDeliveryListParams::EventType::TaggedSymbol
204
+ )
200
205
 
201
206
  sig do
202
207
  override.returns(
@@ -32,27 +32,12 @@ module Cadenya
32
32
  sig { params(message: String).void }
33
33
  attr_writer :message
34
34
 
35
- # Secrets that should be included with the message. Helpful for when you need to
36
- # update secrets on the objective (IE: A secret expires and needs to be refreshed)
37
- sig do
38
- returns(T.nilable(T::Array[Cadenya::ObjectiveContinueParams::Secret]))
39
- end
40
- attr_reader :secrets
41
-
42
- sig do
43
- params(
44
- secrets: T::Array[Cadenya::ObjectiveContinueParams::Secret::OrHash]
45
- ).void
46
- end
47
- attr_writer :secrets
48
-
49
35
  sig do
50
36
  params(
51
37
  workspace_id: String,
52
38
  objective_id: String,
53
39
  enqueue: T::Boolean,
54
40
  message: String,
55
- secrets: T::Array[Cadenya::ObjectiveContinueParams::Secret::OrHash],
56
41
  request_options: Cadenya::RequestOptions::OrHash
57
42
  ).returns(T.attached_class)
58
43
  end
@@ -64,9 +49,6 @@ module Cadenya
64
49
  enqueue: nil,
65
50
  # The message to continue an objective that has completed (or you are enqueing)
66
51
  message: nil,
67
- # Secrets that should be included with the message. Helpful for when you need to
68
- # update secrets on the objective (IE: A secret expires and needs to be refreshed)
69
- secrets: nil,
70
52
  request_options: {}
71
53
  )
72
54
  end
@@ -78,43 +60,12 @@ module Cadenya
78
60
  objective_id: String,
79
61
  enqueue: T::Boolean,
80
62
  message: String,
81
- secrets: T::Array[Cadenya::ObjectiveContinueParams::Secret],
82
63
  request_options: Cadenya::RequestOptions
83
64
  }
84
65
  )
85
66
  end
86
67
  def to_hash
87
68
  end
88
-
89
- class Secret < Cadenya::Internal::Type::BaseModel
90
- OrHash =
91
- T.type_alias do
92
- T.any(
93
- Cadenya::ObjectiveContinueParams::Secret,
94
- Cadenya::Internal::AnyHash
95
- )
96
- end
97
-
98
- sig { returns(T.nilable(String)) }
99
- attr_reader :name
100
-
101
- sig { params(name: String).void }
102
- attr_writer :name
103
-
104
- sig { returns(T.nilable(String)) }
105
- attr_reader :value
106
-
107
- sig { params(value: String).void }
108
- attr_writer :value
109
-
110
- sig { params(name: String, value: String).returns(T.attached_class) }
111
- def self.new(name: nil, value: nil)
112
- end
113
-
114
- sig { override.returns({ name: String, value: String }) }
115
- def to_hash
116
- end
117
- end
118
69
  end
119
70
  end
120
71
  end