@inferencesh/sdk 0.41.3 → 0.41.5

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.
package/CHANGELOG.md CHANGED
@@ -7,6 +7,16 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
7
7
 
8
8
  ## [Unreleased]
9
9
 
10
+ ## [0.41.5] - 2026-11-21
11
+
12
+ ### Added
13
+ - `OAuthAppDTO`: one of a provider's OAuth apps, with `default`, `usual` and `hook_url`; `CredentialConnectRequest.app_credential_id` names the app a connect goes through (api-v1589).
14
+
15
+ ## [0.41.4] - 2026-11-18
16
+
17
+ ### Added
18
+ - `InterruptDTO.origin` (`InterruptOrigin`): the sub-agent that asked, on an interrupt shown on an ancestor chat's `pending_interrupts`; run interrupt reason `subagent` (api-v1584).
19
+
10
20
  ## [0.41.3] - 2026-11-17
11
21
 
12
22
  ### Added
package/dist/types.d.ts CHANGED
@@ -916,6 +916,13 @@ export interface CredentialConnectRequest {
916
916
  * rather than reuse the one it remembers.
917
917
  */
918
918
  another_account?: boolean;
919
+ /**
920
+ * AppCredentialID is the OAuth app the login goes through: one of the
921
+ * provider's apps the caller can connect through
922
+ * (CredentialConfigDTO.Apps). Empty: the default one; refused when the
923
+ * caller has several and none is the default.
924
+ */
925
+ app_credential_id?: string;
919
926
  }
920
927
  /**
921
928
  * CredentialCompleteOAuthRequest is what the provider's redirect delivered:
@@ -2984,6 +2991,28 @@ export interface CredentialDTO extends BaseModelDTO, PermissionModelDTO {
2984
2991
  */
2985
2992
  secrets?: CredentialSecretRef[];
2986
2993
  }
2994
+ /**
2995
+ * OAuthAppDTO is one OAuth app a provider's logins can go through
2996
+ * (grant=credentials), as the caller sees it. DisplayName tells it apart
2997
+ * from the provider's other apps.
2998
+ */
2999
+ export interface OAuthAppDTO extends CredentialDTO {
3000
+ /**
3001
+ * HookURL is where the app delivers its events; empty when the
3002
+ * provider's apps deliver none.
3003
+ */
3004
+ hook_url?: string;
3005
+ /**
3006
+ * Default: a connect that names no app goes through this one.
3007
+ */
3008
+ default: boolean;
3009
+ /**
3010
+ * Usual: the owner's usual app for the provider (PUT
3011
+ * /credentials/{provider}/app). Another app (POST
3012
+ * /credentials/{provider}/apps) serves only a connect that names it.
3013
+ */
3014
+ usual: boolean;
3015
+ }
2987
3016
  /**
2988
3017
  * CredentialSecretRef names one secret linked to a credential: the row's
2989
3018
  * id, the key it is stored under and when its value last changed.
@@ -3076,6 +3105,14 @@ export interface CredentialConfigDTO {
3076
3105
  * deliver none.
3077
3106
  */
3078
3107
  hook_url?: string;
3108
+ /**
3109
+ * Apps is every OAuth app the caller can connect through for this
3110
+ * provider: the workspace's own, its org's and the platform's, App
3111
+ * among them. More than one when a workspace holds another app next to
3112
+ * its usual one; a connect then names the one it goes through
3113
+ * (CredentialConnectRequest.AppCredentialID).
3114
+ */
3115
+ apps?: (OAuthAppDTO | undefined)[];
3079
3116
  /**
3080
3117
  * AuthProviderID is set when the provider is one the team defined
3081
3118
  * itself (models.AuthProvider), so the UI can offer edit and remove.
@@ -4702,6 +4739,12 @@ export interface InterruptDTO extends BaseModelDTO, PermissionModelDTO {
4702
4739
  resolved_data?: any;
4703
4740
  expires_at?: string;
4704
4741
  meta?: any;
4742
+ /**
4743
+ * Origin is the sub-agent that asked, on an interrupt a sub-agent's run
4744
+ * raised. Shown on an ancestor chat (its pending_interrupts), ChatID
4745
+ * is the sub-agent's chat, not the one read.
4746
+ */
4747
+ origin?: InterruptOrigin;
4705
4748
  }
4706
4749
  /**
4707
4750
  * KnowledgeFile represents a file in a knowledge entry
@@ -8678,6 +8721,34 @@ export declare const InterruptReasonWait: InterruptReason;
8678
8721
  * answer in time refuses it for the sandbox. Meta is EgressLoginAskMeta.
8679
8722
  */
8680
8723
  export declare const InterruptReasonEgressLogin: InterruptReason;
8724
+ /**
8725
+ * InterruptReasonSubagent is a run's reason, never an interrupt's: the run
8726
+ * waits on a question one of its sub-agents' runs asked, shown on its chat
8727
+ * through an interrupt surface (INF-1291). The run's interrupt meta is
8728
+ * SubagentWaitMeta.
8729
+ */
8730
+ export declare const InterruptReasonSubagent: InterruptReason;
8731
+ /**
8732
+ * InterruptOrigin is the sub-agent an interrupt came from, on an interrupt
8733
+ * a sub-agent's run raised: what an ancestor chat's card names.
8734
+ */
8735
+ export interface InterruptOrigin {
8736
+ /**
8737
+ * AgentID and AgentRef ("namespace/name") are the sub-agent's.
8738
+ */
8739
+ agent_id?: string;
8740
+ agent_ref?: string;
8741
+ /**
8742
+ * ToolInvocationID is the call in the parent chat that delegated to
8743
+ * the sub-agent's chat (the interrupt's ChatID).
8744
+ */
8745
+ tool_invocation_id?: string;
8746
+ /**
8747
+ * Depth is the sub-agent chat's depth (Chat.Depth), 1 under a chat a
8748
+ * person started.
8749
+ */
8750
+ depth: number;
8751
+ }
8681
8752
  /**
8682
8753
  * MergeStrategy defines how a delta field should be merged by consumers.
8683
8754
  */
@@ -9996,7 +10067,7 @@ export declare const AgentRunStateRejected: AgentRunState;
9996
10067
  * InterruptReason describes why an agent run is in an interrupted state.
9997
10068
  * Aligns with AG-UI interrupt outcome reasons.
9998
10069
  */
9999
- export type InterruptReason = "wait" | "egress_login" | "tool_approval" | "client_tool" | "widget" | "auth" | "confirmation" | "hook_gate" | "input";
10070
+ export type InterruptReason = "wait" | "egress_login" | "subagent" | "tool_approval" | "client_tool" | "widget" | "auth" | "confirmation" | "hook_gate" | "input";
10000
10071
  export declare const InterruptReasonToolApproval: InterruptReason;
10001
10072
  export declare const InterruptReasonClientTool: InterruptReason;
10002
10073
  export declare const InterruptReasonWidget: InterruptReason;
package/dist/types.js CHANGED
@@ -1582,6 +1582,13 @@ export const InterruptReasonWait = "wait";
1582
1582
  * answer in time refuses it for the sandbox. Meta is EgressLoginAskMeta.
1583
1583
  */
1584
1584
  export const InterruptReasonEgressLogin = "egress_login";
1585
+ /**
1586
+ * InterruptReasonSubagent is a run's reason, never an interrupt's: the run
1587
+ * waits on a question one of its sub-agents' runs asked, shown on its chat
1588
+ * through an interrupt surface (INF-1291). The run's interrupt meta is
1589
+ * SubagentWaitMeta.
1590
+ */
1591
+ export const InterruptReasonSubagent = "subagent";
1585
1592
  export const MergeStrategyConcat = "concat";
1586
1593
  export const MergeStrategyReplace = "replace";
1587
1594
  export const MergeStrategyIndexed = "indexed";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@inferencesh/sdk",
3
- "version": "0.41.3",
3
+ "version": "0.41.5",
4
4
  "description": "Official JavaScript/TypeScript SDK for inference.sh - Run AI models with a simple API",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",