sarvam-agents-client 0.2.3 → 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 (178) hide show
  1. package/README.md +16 -1
  2. package/dist/apis/AgentsApi.d.ts +4 -4
  3. package/dist/apis/AgentsApi.js +4 -4
  4. package/dist/apis/AppsApi.d.ts +1 -0
  5. package/dist/apis/AppsApi.js +3 -0
  6. package/dist/apis/FunctionToolsApi.d.ts +33 -0
  7. package/dist/apis/FunctionToolsApi.js +65 -0
  8. package/dist/apis/QueueApi.d.ts +1 -0
  9. package/dist/apis/QueueApi.js +3 -0
  10. package/dist/apis/ResponsesApi.d.ts +2 -0
  11. package/dist/apis/ResponsesApi.js +6 -0
  12. package/dist/apis/index.d.ts +1 -0
  13. package/dist/apis/index.js +1 -0
  14. package/dist/compose/agent.d.ts +26 -6
  15. package/dist/compose/agent.js +84 -7
  16. package/dist/compose/deploy.d.ts +3 -2
  17. package/dist/compose/errors.d.ts +22 -1
  18. package/dist/compose/errors.js +21 -1
  19. package/dist/compose/events.d.ts +38 -0
  20. package/dist/compose/events.js +59 -2
  21. package/dist/compose/functionTool.d.ts +101 -0
  22. package/dist/compose/functionTool.js +420 -0
  23. package/dist/compose/index.d.ts +7 -3
  24. package/dist/compose/index.js +3 -1
  25. package/dist/compose/output.d.ts +40 -0
  26. package/dist/compose/output.js +476 -0
  27. package/dist/compose/run.d.ts +44 -15
  28. package/dist/compose/run.js +164 -21
  29. package/dist/compose/runState.d.ts +28 -2
  30. package/dist/compose/runState.js +30 -0
  31. package/dist/compose/settingsTransport.d.ts +23 -3
  32. package/dist/compose/settingsTransport.js +295 -3
  33. package/dist/compose/transport.d.ts +21 -3
  34. package/dist/esm/apis/AgentsApi.d.ts +4 -4
  35. package/dist/esm/apis/AgentsApi.js +4 -4
  36. package/dist/esm/apis/AppsApi.d.ts +1 -0
  37. package/dist/esm/apis/AppsApi.js +3 -0
  38. package/dist/esm/apis/FunctionToolsApi.d.ts +33 -0
  39. package/dist/esm/apis/FunctionToolsApi.js +61 -0
  40. package/dist/esm/apis/QueueApi.d.ts +1 -0
  41. package/dist/esm/apis/QueueApi.js +3 -0
  42. package/dist/esm/apis/ResponsesApi.d.ts +2 -0
  43. package/dist/esm/apis/ResponsesApi.js +6 -0
  44. package/dist/esm/apis/index.d.ts +1 -0
  45. package/dist/esm/apis/index.js +1 -0
  46. package/dist/esm/compose/agent.d.ts +26 -6
  47. package/dist/esm/compose/agent.js +84 -7
  48. package/dist/esm/compose/deploy.d.ts +3 -2
  49. package/dist/esm/compose/errors.d.ts +22 -1
  50. package/dist/esm/compose/errors.js +21 -1
  51. package/dist/esm/compose/events.d.ts +38 -0
  52. package/dist/esm/compose/events.js +58 -2
  53. package/dist/esm/compose/functionTool.d.ts +101 -0
  54. package/dist/esm/compose/functionTool.js +406 -0
  55. package/dist/esm/compose/index.d.ts +7 -3
  56. package/dist/esm/compose/index.js +1 -0
  57. package/dist/esm/compose/output.d.ts +40 -0
  58. package/dist/esm/compose/output.js +466 -0
  59. package/dist/esm/compose/run.d.ts +44 -15
  60. package/dist/esm/compose/run.js +165 -22
  61. package/dist/esm/compose/runState.d.ts +28 -2
  62. package/dist/esm/compose/runState.js +31 -1
  63. package/dist/esm/compose/settingsTransport.d.ts +23 -3
  64. package/dist/esm/compose/settingsTransport.js +298 -7
  65. package/dist/esm/compose/transport.d.ts +21 -3
  66. package/dist/esm/models/AgentConversationDetail.d.ts +7 -0
  67. package/dist/esm/models/AgentConversationDetail.js +3 -0
  68. package/dist/esm/models/AppResource.d.ts +29 -0
  69. package/dist/esm/models/AppResource.js +16 -0
  70. package/dist/esm/models/AppToolsResponse.d.ts +3 -4
  71. package/dist/esm/models/AppToolsResponse.js +3 -2
  72. package/dist/esm/models/AppView.d.ts +48 -0
  73. package/dist/esm/models/AppView.js +23 -0
  74. package/dist/esm/models/ClarifyBody.d.ts +6 -0
  75. package/dist/esm/models/ClarifyBody.js +2 -0
  76. package/dist/esm/models/ConversationDetail.d.ts +7 -0
  77. package/dist/esm/models/ConversationDetail.js +3 -0
  78. package/dist/esm/models/ErrorDetail.d.ts +1 -0
  79. package/dist/esm/models/ErrorDetail.js +2 -1
  80. package/dist/esm/models/FunctionResultBody.d.ts +44 -0
  81. package/dist/esm/models/FunctionResultBody.js +49 -0
  82. package/dist/esm/models/McpSecurityAppealView.d.ts +50 -0
  83. package/dist/esm/models/McpSecurityAppealView.js +47 -0
  84. package/dist/esm/models/McpSecurityView.d.ts +105 -0
  85. package/dist/esm/models/McpSecurityView.js +66 -0
  86. package/dist/esm/models/MessagesResponse.d.ts +6 -0
  87. package/dist/esm/models/MessagesResponse.js +2 -0
  88. package/dist/esm/models/QueueMessageInput.d.ts +23 -0
  89. package/dist/esm/models/QueueMessageInput.js +14 -0
  90. package/dist/esm/models/RequiredAction.d.ts +77 -0
  91. package/dist/esm/models/RequiredAction.js +69 -0
  92. package/dist/esm/models/ResponseDetail.d.ts +40 -0
  93. package/dist/esm/models/ResponseDetail.js +12 -0
  94. package/dist/esm/models/ResponseInput.d.ts +23 -0
  95. package/dist/esm/models/ResponseInput.js +14 -0
  96. package/dist/esm/models/ToolResults200Response.d.ts +38 -0
  97. package/dist/esm/models/ToolResults200Response.js +47 -0
  98. package/dist/esm/models/ToolResultsBody.d.ts +39 -0
  99. package/dist/esm/models/ToolResultsBody.js +48 -0
  100. package/dist/esm/models/index.d.ts +6 -0
  101. package/dist/esm/models/index.js +6 -0
  102. package/dist/esm/streaming.d.ts +14 -2
  103. package/dist/esm/streaming.js +26 -4
  104. package/dist/models/AgentConversationDetail.d.ts +7 -0
  105. package/dist/models/AgentConversationDetail.js +3 -0
  106. package/dist/models/AppResource.d.ts +29 -0
  107. package/dist/models/AppResource.js +17 -1
  108. package/dist/models/AppToolsResponse.d.ts +3 -4
  109. package/dist/models/AppToolsResponse.js +3 -2
  110. package/dist/models/AppView.d.ts +48 -0
  111. package/dist/models/AppView.js +24 -1
  112. package/dist/models/ClarifyBody.d.ts +6 -0
  113. package/dist/models/ClarifyBody.js +2 -0
  114. package/dist/models/ConversationDetail.d.ts +7 -0
  115. package/dist/models/ConversationDetail.js +3 -0
  116. package/dist/models/ErrorDetail.d.ts +1 -0
  117. package/dist/models/ErrorDetail.js +2 -1
  118. package/dist/models/FunctionResultBody.d.ts +44 -0
  119. package/dist/models/FunctionResultBody.js +56 -0
  120. package/dist/models/McpSecurityAppealView.d.ts +50 -0
  121. package/dist/models/McpSecurityAppealView.js +54 -0
  122. package/dist/models/McpSecurityView.d.ts +105 -0
  123. package/dist/models/McpSecurityView.js +73 -0
  124. package/dist/models/MessagesResponse.d.ts +6 -0
  125. package/dist/models/MessagesResponse.js +2 -0
  126. package/dist/models/QueueMessageInput.d.ts +23 -0
  127. package/dist/models/QueueMessageInput.js +15 -1
  128. package/dist/models/RequiredAction.d.ts +77 -0
  129. package/dist/models/RequiredAction.js +77 -0
  130. package/dist/models/ResponseDetail.d.ts +40 -0
  131. package/dist/models/ResponseDetail.js +12 -0
  132. package/dist/models/ResponseInput.d.ts +23 -0
  133. package/dist/models/ResponseInput.js +15 -0
  134. package/dist/models/ToolResults200Response.d.ts +38 -0
  135. package/dist/models/ToolResults200Response.js +54 -0
  136. package/dist/models/ToolResultsBody.d.ts +39 -0
  137. package/dist/models/ToolResultsBody.js +55 -0
  138. package/dist/models/index.d.ts +6 -0
  139. package/dist/models/index.js +6 -0
  140. package/dist/streaming.d.ts +14 -2
  141. package/dist/streaming.js +27 -4
  142. package/package.json +4 -3
  143. package/src/apis/AgentsApi.ts +4 -4
  144. package/src/apis/AppsApi.ts +5 -0
  145. package/src/apis/FunctionToolsApi.ts +102 -0
  146. package/src/apis/QueueApi.ts +5 -0
  147. package/src/apis/ResponsesApi.ts +10 -0
  148. package/src/apis/index.ts +1 -0
  149. package/src/compose/agent.ts +108 -15
  150. package/src/compose/deploy.ts +6 -5
  151. package/src/compose/errors.ts +35 -2
  152. package/src/compose/events.ts +79 -1
  153. package/src/compose/functionTool.ts +441 -0
  154. package/src/compose/index.ts +7 -3
  155. package/src/compose/output.ts +436 -0
  156. package/src/compose/run.ts +208 -39
  157. package/src/compose/runState.ts +46 -6
  158. package/src/compose/settingsTransport.ts +297 -10
  159. package/src/compose/transport.ts +27 -3
  160. package/src/models/AgentConversationDetail.ts +15 -0
  161. package/src/models/AppResource.ts +42 -0
  162. package/src/models/AppToolsResponse.ts +11 -4
  163. package/src/models/AppView.ts +73 -0
  164. package/src/models/ClarifyBody.ts +8 -0
  165. package/src/models/ConversationDetail.ts +15 -0
  166. package/src/models/ErrorDetail.ts +2 -1
  167. package/src/models/FunctionResultBody.ts +83 -0
  168. package/src/models/McpSecurityAppealView.ts +89 -0
  169. package/src/models/McpSecurityView.ts +169 -0
  170. package/src/models/MessagesResponse.ts +8 -0
  171. package/src/models/QueueMessageInput.ts +28 -0
  172. package/src/models/RequiredAction.ts +128 -0
  173. package/src/models/ResponseDetail.ts +48 -0
  174. package/src/models/ResponseInput.ts +30 -0
  175. package/src/models/ToolResults200Response.ts +75 -0
  176. package/src/models/ToolResultsBody.ts +83 -0
  177. package/src/models/index.ts +6 -0
  178. package/src/streaming.ts +39 -3
@@ -11,6 +11,8 @@
11
11
  * https://openapi-generator.tech
12
12
  * Do not edit the class manually.
13
13
  */
14
+ import { McpSecurityViewFromJSON, McpSecurityViewToJSON, } from './McpSecurityView.js';
15
+ import { ScopeFromJSON, ScopeToJSON, } from './Scope.js';
14
16
  import { AppCategoryFromJSON, AppCategoryToJSON, } from './AppCategory.js';
15
17
  /**
16
18
  * @export
@@ -20,6 +22,15 @@ export const AppViewAuthTypeEnum = {
20
22
  ApiKey: 'api_key',
21
23
  None: 'none'
22
24
  };
25
+ /**
26
+ * @export
27
+ */
28
+ export const AppViewAuthKindEnum = {
29
+ Oauth: 'oauth',
30
+ ApiKey: 'api_key',
31
+ SharedKey: 'shared_key',
32
+ None: 'none'
33
+ };
23
34
  /**
24
35
  * Check if a given object implements the AppView interface.
25
36
  */
@@ -72,6 +83,12 @@ export function AppViewFromJSONTyped(json, ignoreDiscriminator) {
72
83
  'alreadyUsingUrl': json['alreadyUsingUrl'] == null ? undefined : json['alreadyUsingUrl'],
73
84
  'isManagedConnector': json['isManagedConnector'] == null ? undefined : json['isManagedConnector'],
74
85
  'connectorMode': json['connectorMode'] == null ? undefined : json['connectorMode'],
86
+ 'isCustom': json['isCustom'] == null ? undefined : json['isCustom'],
87
+ 'isOwnedByMe': json['isOwnedByMe'] == null ? undefined : json['isOwnedByMe'],
88
+ 'scope': json['scope'] == null ? undefined : ScopeFromJSON(json['scope']),
89
+ 'createdByName': json['createdByName'] == null ? undefined : json['createdByName'],
90
+ 'authKind': json['authKind'] == null ? undefined : json['authKind'],
91
+ 'security': json['security'] == null ? undefined : McpSecurityViewFromJSON(json['security']),
75
92
  };
76
93
  }
77
94
  export function AppViewToJSON(json) {
@@ -100,5 +117,11 @@ export function AppViewToJSONTyped(value, ignoreDiscriminator = false) {
100
117
  'alreadyUsingUrl': value['alreadyUsingUrl'],
101
118
  'isManagedConnector': value['isManagedConnector'],
102
119
  'connectorMode': value['connectorMode'],
120
+ 'isCustom': value['isCustom'],
121
+ 'isOwnedByMe': value['isOwnedByMe'],
122
+ 'scope': ScopeToJSON(value['scope']),
123
+ 'createdByName': value['createdByName'],
124
+ 'authKind': value['authKind'],
125
+ 'security': McpSecurityViewToJSON(value['security']),
103
126
  };
104
127
  }
@@ -35,6 +35,12 @@ export interface ClarifyBody {
35
35
  answers?: {
36
36
  [key: string]: any;
37
37
  };
38
+ /**
39
+ *
40
+ * @type {string}
41
+ * @memberof ClarifyBody
42
+ */
43
+ endUserId?: string | null;
38
44
  }
39
45
  /**
40
46
  * Check if a given object implements the ClarifyBody interface.
@@ -30,6 +30,7 @@ export function ClarifyBodyFromJSONTyped(json, ignoreDiscriminator) {
30
30
  'requestId': json['requestId'],
31
31
  'action': json['action'] == null ? undefined : json['action'],
32
32
  'answers': json['answers'] == null ? undefined : json['answers'],
33
+ 'endUserId': json['endUserId'] == null ? undefined : json['endUserId'],
33
34
  };
34
35
  }
35
36
  export function ClarifyBodyToJSON(json) {
@@ -43,5 +44,6 @@ export function ClarifyBodyToJSONTyped(value, ignoreDiscriminator = false) {
43
44
  'requestId': value['requestId'],
44
45
  'action': value['action'],
45
46
  'answers': value['answers'],
47
+ 'endUserId': value['endUserId'],
46
48
  };
47
49
  }
@@ -11,6 +11,7 @@
11
11
  */
12
12
  import type { UIMessage } from './UIMessage.js';
13
13
  import type { FieldHighlight } from './FieldHighlight.js';
14
+ import type { RequiredAction } from './RequiredAction.js';
14
15
  import type { QueuedTurnView } from './QueuedTurnView.js';
15
16
  /**
16
17
  * GET /conversations/{id} — the list view plus the projected history and
@@ -135,6 +136,12 @@ export interface ConversationDetail {
135
136
  * @memberof ConversationDetail
136
137
  */
137
138
  queuedTurns?: Array<QueuedTurnView>;
139
+ /**
140
+ *
141
+ * @type {Array<RequiredAction>}
142
+ * @memberof ConversationDetail
143
+ */
144
+ requiredActions?: Array<RequiredAction>;
138
145
  }
139
146
  /**
140
147
  * Check if a given object implements the ConversationDetail interface.
@@ -13,6 +13,7 @@
13
13
  */
14
14
  import { UIMessageFromJSON, UIMessageToJSON, } from './UIMessage.js';
15
15
  import { FieldHighlightFromJSON, FieldHighlightToJSON, } from './FieldHighlight.js';
16
+ import { RequiredActionFromJSON, RequiredActionToJSON, } from './RequiredAction.js';
16
17
  import { QueuedTurnViewFromJSON, QueuedTurnViewToJSON, } from './QueuedTurnView.js';
17
18
  /**
18
19
  * Check if a given object implements the ConversationDetail interface.
@@ -77,6 +78,7 @@ export function ConversationDetailFromJSONTyped(json, ignoreDiscriminator) {
77
78
  'hasMore': json['hasMore'] == null ? undefined : json['hasMore'],
78
79
  'nextBeforeCursor': json['nextBeforeCursor'] == null ? undefined : json['nextBeforeCursor'],
79
80
  'queuedTurns': json['queuedTurns'] == null ? undefined : (json['queuedTurns'].map(QueuedTurnViewFromJSON)),
81
+ 'requiredActions': json['requiredActions'] == null ? undefined : (json['requiredActions'].map(RequiredActionFromJSON)),
80
82
  };
81
83
  }
82
84
  export function ConversationDetailToJSON(json) {
@@ -106,5 +108,6 @@ export function ConversationDetailToJSONTyped(value, ignoreDiscriminator = false
106
108
  'hasMore': value['hasMore'],
107
109
  'nextBeforeCursor': value['nextBeforeCursor'],
108
110
  'queuedTurns': value['queuedTurns'] == null ? undefined : (value['queuedTurns'].map(QueuedTurnViewToJSON)),
111
+ 'requiredActions': value['requiredActions'] == null ? undefined : (value['requiredActions'].map(RequiredActionToJSON)),
109
112
  };
110
113
  }
@@ -58,6 +58,7 @@ export declare const ErrorDetailCodeEnum: {
58
58
  readonly Unavailable: "CHAT_UNAVAILABLE";
59
59
  readonly Upstream: "CHAT_UPSTREAM";
60
60
  readonly Internal: "CHAT_INTERNAL";
61
+ readonly BalanceExhausted: "CHAT_BALANCE_EXHAUSTED";
61
62
  };
62
63
  export type ErrorDetailCodeEnum = typeof ErrorDetailCodeEnum[keyof typeof ErrorDetailCodeEnum];
63
64
  /**
@@ -25,7 +25,8 @@ export const ErrorDetailCodeEnum = {
25
25
  RateLimit: 'CHAT_RATE_LIMIT',
26
26
  Unavailable: 'CHAT_UNAVAILABLE',
27
27
  Upstream: 'CHAT_UPSTREAM',
28
- Internal: 'CHAT_INTERNAL'
28
+ Internal: 'CHAT_INTERNAL',
29
+ BalanceExhausted: 'CHAT_BALANCE_EXHAUSTED'
29
30
  };
30
31
  /**
31
32
  * Check if a given object implements the ErrorDetail interface.
@@ -0,0 +1,44 @@
1
+ /**
2
+ * Sarvam Agents API
3
+ * Chat with a Sarvam agent, exchange files with it, and set it up (instructions, skills, knowledge bases, connectors, deploy) from your own code. Authenticate with a service token sent as a Bearer token, and send the header X-Panja-Origin: managed_agents on every request.
4
+ *
5
+ * The version of the OpenAPI document: 0.1.0
6
+ * Contact: support@sarvam.ai
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ * One call's result, as the app ran it.
14
+ * @export
15
+ * @interface FunctionResultBody
16
+ */
17
+ export interface FunctionResultBody {
18
+ /**
19
+ *
20
+ * @type {string}
21
+ * @memberof FunctionResultBody
22
+ */
23
+ toolCallId: string;
24
+ /**
25
+ *
26
+ * @type {string}
27
+ * @memberof FunctionResultBody
28
+ */
29
+ output: string;
30
+ /**
31
+ *
32
+ * @type {boolean}
33
+ * @memberof FunctionResultBody
34
+ */
35
+ isError?: boolean;
36
+ }
37
+ /**
38
+ * Check if a given object implements the FunctionResultBody interface.
39
+ */
40
+ export declare function instanceOfFunctionResultBody(value: object): value is FunctionResultBody;
41
+ export declare function FunctionResultBodyFromJSON(json: any): FunctionResultBody;
42
+ export declare function FunctionResultBodyFromJSONTyped(json: any, ignoreDiscriminator: boolean): FunctionResultBody;
43
+ export declare function FunctionResultBodyToJSON(json: any): FunctionResultBody;
44
+ export declare function FunctionResultBodyToJSONTyped(value?: FunctionResultBody | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,49 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Sarvam Agents API
5
+ * Chat with a Sarvam agent, exchange files with it, and set it up (instructions, skills, knowledge bases, connectors, deploy) from your own code. Authenticate with a service token sent as a Bearer token, and send the header X-Panja-Origin: managed_agents on every request.
6
+ *
7
+ * The version of the OpenAPI document: 0.1.0
8
+ * Contact: support@sarvam.ai
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ /**
15
+ * Check if a given object implements the FunctionResultBody interface.
16
+ */
17
+ export function instanceOfFunctionResultBody(value) {
18
+ if (!('toolCallId' in value) || value['toolCallId'] === undefined)
19
+ return false;
20
+ if (!('output' in value) || value['output'] === undefined)
21
+ return false;
22
+ return true;
23
+ }
24
+ export function FunctionResultBodyFromJSON(json) {
25
+ return FunctionResultBodyFromJSONTyped(json, false);
26
+ }
27
+ export function FunctionResultBodyFromJSONTyped(json, ignoreDiscriminator) {
28
+ if (json == null) {
29
+ return json;
30
+ }
31
+ return {
32
+ 'toolCallId': json['toolCallId'],
33
+ 'output': json['output'],
34
+ 'isError': json['isError'] == null ? undefined : json['isError'],
35
+ };
36
+ }
37
+ export function FunctionResultBodyToJSON(json) {
38
+ return FunctionResultBodyToJSONTyped(json, false);
39
+ }
40
+ export function FunctionResultBodyToJSONTyped(value, ignoreDiscriminator = false) {
41
+ if (value == null) {
42
+ return value;
43
+ }
44
+ return {
45
+ 'toolCallId': value['toolCallId'],
46
+ 'output': value['output'],
47
+ 'isError': value['isError'],
48
+ };
49
+ }
@@ -0,0 +1,50 @@
1
+ /**
2
+ * Sarvam Agents API
3
+ * Chat with a Sarvam agent, exchange files with it, and set it up (instructions, skills, knowledge bases, connectors, deploy) from your own code. Authenticate with a service token sent as a Bearer token, and send the header X-Panja-Origin: managed_agents on every request.
4
+ *
5
+ * The version of the OpenAPI document: 0.1.0
6
+ * Contact: support@sarvam.ai
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ /**
13
+ * Appeal metadata on a BYO security projection. Status ``none`` when idle.
14
+ * @export
15
+ * @interface McpSecurityAppealView
16
+ */
17
+ export interface McpSecurityAppealView {
18
+ /**
19
+ *
20
+ * @type {string}
21
+ * @memberof McpSecurityAppealView
22
+ */
23
+ status?: string;
24
+ /**
25
+ *
26
+ * @type {string}
27
+ * @memberof McpSecurityAppealView
28
+ */
29
+ contactEmail?: string | null;
30
+ /**
31
+ *
32
+ * @type {string}
33
+ * @memberof McpSecurityAppealView
34
+ */
35
+ contactPhone?: string | null;
36
+ /**
37
+ *
38
+ * @type {string}
39
+ * @memberof McpSecurityAppealView
40
+ */
41
+ denialReason?: string | null;
42
+ }
43
+ /**
44
+ * Check if a given object implements the McpSecurityAppealView interface.
45
+ */
46
+ export declare function instanceOfMcpSecurityAppealView(value: object): value is McpSecurityAppealView;
47
+ export declare function McpSecurityAppealViewFromJSON(json: any): McpSecurityAppealView;
48
+ export declare function McpSecurityAppealViewFromJSONTyped(json: any, ignoreDiscriminator: boolean): McpSecurityAppealView;
49
+ export declare function McpSecurityAppealViewToJSON(json: any): McpSecurityAppealView;
50
+ export declare function McpSecurityAppealViewToJSONTyped(value?: McpSecurityAppealView | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,47 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Sarvam Agents API
5
+ * Chat with a Sarvam agent, exchange files with it, and set it up (instructions, skills, knowledge bases, connectors, deploy) from your own code. Authenticate with a service token sent as a Bearer token, and send the header X-Panja-Origin: managed_agents on every request.
6
+ *
7
+ * The version of the OpenAPI document: 0.1.0
8
+ * Contact: support@sarvam.ai
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ /**
15
+ * Check if a given object implements the McpSecurityAppealView interface.
16
+ */
17
+ export function instanceOfMcpSecurityAppealView(value) {
18
+ return true;
19
+ }
20
+ export function McpSecurityAppealViewFromJSON(json) {
21
+ return McpSecurityAppealViewFromJSONTyped(json, false);
22
+ }
23
+ export function McpSecurityAppealViewFromJSONTyped(json, ignoreDiscriminator) {
24
+ if (json == null) {
25
+ return json;
26
+ }
27
+ return {
28
+ 'status': json['status'] == null ? undefined : json['status'],
29
+ 'contactEmail': json['contactEmail'] == null ? undefined : json['contactEmail'],
30
+ 'contactPhone': json['contactPhone'] == null ? undefined : json['contactPhone'],
31
+ 'denialReason': json['denialReason'] == null ? undefined : json['denialReason'],
32
+ };
33
+ }
34
+ export function McpSecurityAppealViewToJSON(json) {
35
+ return McpSecurityAppealViewToJSONTyped(json, false);
36
+ }
37
+ export function McpSecurityAppealViewToJSONTyped(value, ignoreDiscriminator = false) {
38
+ if (value == null) {
39
+ return value;
40
+ }
41
+ return {
42
+ 'status': value['status'],
43
+ 'contactEmail': value['contactEmail'],
44
+ 'contactPhone': value['contactPhone'],
45
+ 'denialReason': value['denialReason'],
46
+ };
47
+ }
@@ -0,0 +1,105 @@
1
+ /**
2
+ * Sarvam Agents API
3
+ * Chat with a Sarvam agent, exchange files with it, and set it up (instructions, skills, knowledge bases, connectors, deploy) from your own code. Authenticate with a service token sent as a Bearer token, and send the header X-Panja-Origin: managed_agents on every request.
4
+ *
5
+ * The version of the OpenAPI document: 0.1.0
6
+ * Contact: support@sarvam.ai
7
+ *
8
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
9
+ * https://openapi-generator.tech
10
+ * Do not edit the class manually.
11
+ */
12
+ import type { McpSecurityAppealView } from './McpSecurityAppealView.js';
13
+ /**
14
+ * Card-facing BYO security object (list, agent-bound apps, catalog, tools).
15
+ * @export
16
+ * @interface McpSecurityView
17
+ */
18
+ export interface McpSecurityView {
19
+ /**
20
+ *
21
+ * @type {string}
22
+ * @memberof McpSecurityView
23
+ */
24
+ state?: string | null;
25
+ /**
26
+ *
27
+ * @type {string}
28
+ * @memberof McpSecurityView
29
+ */
30
+ progress?: string | null;
31
+ /**
32
+ *
33
+ * @type {boolean}
34
+ * @memberof McpSecurityView
35
+ */
36
+ blocking?: boolean;
37
+ /**
38
+ *
39
+ * @type {boolean}
40
+ * @memberof McpSecurityView
41
+ */
42
+ enforced?: boolean;
43
+ /**
44
+ *
45
+ * @type {string}
46
+ * @memberof McpSecurityView
47
+ */
48
+ lastFailure?: string | null;
49
+ /**
50
+ *
51
+ * @type {string}
52
+ * @memberof McpSecurityView
53
+ */
54
+ message?: string | null;
55
+ /**
56
+ *
57
+ * @type {boolean}
58
+ * @memberof McpSecurityView
59
+ */
60
+ ownerActionRequired?: boolean | null;
61
+ /**
62
+ *
63
+ * @type {boolean}
64
+ * @memberof McpSecurityView
65
+ */
66
+ unverifiable?: boolean | null;
67
+ /**
68
+ *
69
+ * @type {number}
70
+ * @memberof McpSecurityView
71
+ */
72
+ auditAttempts?: number;
73
+ /**
74
+ *
75
+ * @type {number}
76
+ * @memberof McpSecurityView
77
+ */
78
+ auditAttemptLimit?: number;
79
+ /**
80
+ *
81
+ * @type {number}
82
+ * @memberof McpSecurityView
83
+ */
84
+ attemptsRemaining?: number;
85
+ /**
86
+ *
87
+ * @type {Array<string>}
88
+ * @memberof McpSecurityView
89
+ */
90
+ lastHoldReasons?: Array<string>;
91
+ /**
92
+ *
93
+ * @type {McpSecurityAppealView}
94
+ * @memberof McpSecurityView
95
+ */
96
+ appeal?: McpSecurityAppealView | null;
97
+ }
98
+ /**
99
+ * Check if a given object implements the McpSecurityView interface.
100
+ */
101
+ export declare function instanceOfMcpSecurityView(value: object): value is McpSecurityView;
102
+ export declare function McpSecurityViewFromJSON(json: any): McpSecurityView;
103
+ export declare function McpSecurityViewFromJSONTyped(json: any, ignoreDiscriminator: boolean): McpSecurityView;
104
+ export declare function McpSecurityViewToJSON(json: any): McpSecurityView;
105
+ export declare function McpSecurityViewToJSONTyped(value?: McpSecurityView | null, ignoreDiscriminator?: boolean): any;
@@ -0,0 +1,66 @@
1
+ /* tslint:disable */
2
+ /* eslint-disable */
3
+ /**
4
+ * Sarvam Agents API
5
+ * Chat with a Sarvam agent, exchange files with it, and set it up (instructions, skills, knowledge bases, connectors, deploy) from your own code. Authenticate with a service token sent as a Bearer token, and send the header X-Panja-Origin: managed_agents on every request.
6
+ *
7
+ * The version of the OpenAPI document: 0.1.0
8
+ * Contact: support@sarvam.ai
9
+ *
10
+ * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
11
+ * https://openapi-generator.tech
12
+ * Do not edit the class manually.
13
+ */
14
+ import { McpSecurityAppealViewFromJSON, McpSecurityAppealViewToJSON, } from './McpSecurityAppealView.js';
15
+ /**
16
+ * Check if a given object implements the McpSecurityView interface.
17
+ */
18
+ export function instanceOfMcpSecurityView(value) {
19
+ return true;
20
+ }
21
+ export function McpSecurityViewFromJSON(json) {
22
+ return McpSecurityViewFromJSONTyped(json, false);
23
+ }
24
+ export function McpSecurityViewFromJSONTyped(json, ignoreDiscriminator) {
25
+ if (json == null) {
26
+ return json;
27
+ }
28
+ return {
29
+ 'state': json['state'] == null ? undefined : json['state'],
30
+ 'progress': json['progress'] == null ? undefined : json['progress'],
31
+ 'blocking': json['blocking'] == null ? undefined : json['blocking'],
32
+ 'enforced': json['enforced'] == null ? undefined : json['enforced'],
33
+ 'lastFailure': json['lastFailure'] == null ? undefined : json['lastFailure'],
34
+ 'message': json['message'] == null ? undefined : json['message'],
35
+ 'ownerActionRequired': json['ownerActionRequired'] == null ? undefined : json['ownerActionRequired'],
36
+ 'unverifiable': json['unverifiable'] == null ? undefined : json['unverifiable'],
37
+ 'auditAttempts': json['auditAttempts'] == null ? undefined : json['auditAttempts'],
38
+ 'auditAttemptLimit': json['auditAttemptLimit'] == null ? undefined : json['auditAttemptLimit'],
39
+ 'attemptsRemaining': json['attemptsRemaining'] == null ? undefined : json['attemptsRemaining'],
40
+ 'lastHoldReasons': json['lastHoldReasons'] == null ? undefined : json['lastHoldReasons'],
41
+ 'appeal': json['appeal'] == null ? undefined : McpSecurityAppealViewFromJSON(json['appeal']),
42
+ };
43
+ }
44
+ export function McpSecurityViewToJSON(json) {
45
+ return McpSecurityViewToJSONTyped(json, false);
46
+ }
47
+ export function McpSecurityViewToJSONTyped(value, ignoreDiscriminator = false) {
48
+ if (value == null) {
49
+ return value;
50
+ }
51
+ return {
52
+ 'state': value['state'],
53
+ 'progress': value['progress'],
54
+ 'blocking': value['blocking'],
55
+ 'enforced': value['enforced'],
56
+ 'lastFailure': value['lastFailure'],
57
+ 'message': value['message'],
58
+ 'ownerActionRequired': value['ownerActionRequired'],
59
+ 'unverifiable': value['unverifiable'],
60
+ 'auditAttempts': value['auditAttempts'],
61
+ 'auditAttemptLimit': value['auditAttemptLimit'],
62
+ 'attemptsRemaining': value['attemptsRemaining'],
63
+ 'lastHoldReasons': value['lastHoldReasons'],
64
+ 'appeal': McpSecurityAppealViewToJSON(value['appeal']),
65
+ };
66
+ }
@@ -65,6 +65,12 @@ export interface MessagesResponse {
65
65
  * @memberof MessagesResponse
66
66
  */
67
67
  nextBeforeCursor?: string | null;
68
+ /**
69
+ *
70
+ * @type {string}
71
+ * @memberof MessagesResponse
72
+ */
73
+ resumeCursor?: string | null;
68
74
  /**
69
75
  *
70
76
  * @type {Array<QueuedTurnView>}
@@ -39,6 +39,7 @@ export function MessagesResponseFromJSONTyped(json, ignoreDiscriminator) {
39
39
  'nextCursor': json['nextCursor'] == null ? undefined : json['nextCursor'],
40
40
  'activeResponseId': json['activeResponseId'] == null ? undefined : json['activeResponseId'],
41
41
  'nextBeforeCursor': json['nextBeforeCursor'] == null ? undefined : json['nextBeforeCursor'],
42
+ 'resumeCursor': json['resumeCursor'] == null ? undefined : json['resumeCursor'],
42
43
  'queuedTurns': json['queuedTurns'] == null ? undefined : (json['queuedTurns'].map(QueuedTurnViewFromJSON)),
43
44
  };
44
45
  }
@@ -58,6 +59,7 @@ export function MessagesResponseToJSONTyped(value, ignoreDiscriminator = false)
58
59
  'nextCursor': value['nextCursor'],
59
60
  'activeResponseId': value['activeResponseId'],
60
61
  'nextBeforeCursor': value['nextBeforeCursor'],
62
+ 'resumeCursor': value['resumeCursor'],
61
63
  'queuedTurns': value['queuedTurns'] == null ? undefined : (value['queuedTurns'].map(QueuedTurnViewToJSON)),
62
64
  };
63
65
  }
@@ -40,6 +40,18 @@ export interface QueueMessageInput {
40
40
  * @memberof QueueMessageInput
41
41
  */
42
42
  retryOf?: string | null;
43
+ /**
44
+ *
45
+ * @type {string}
46
+ * @memberof QueueMessageInput
47
+ */
48
+ surface?: QueueMessageInputSurfaceEnum | null;
49
+ /**
50
+ *
51
+ * @type {string}
52
+ * @memberof QueueMessageInput
53
+ */
54
+ endUserId?: string | null;
43
55
  }
44
56
  /**
45
57
  * @export
@@ -49,6 +61,17 @@ export declare const QueueMessageInputDeliveryEnum: {
49
61
  readonly Now: "now";
50
62
  };
51
63
  export type QueueMessageInputDeliveryEnum = typeof QueueMessageInputDeliveryEnum[keyof typeof QueueMessageInputDeliveryEnum];
64
+ /**
65
+ * @export
66
+ */
67
+ export declare const QueueMessageInputSurfaceEnum: {
68
+ readonly Builder: "builder";
69
+ readonly Playground: "playground";
70
+ readonly Tests: "tests";
71
+ readonly Evals: "evals";
72
+ readonly Cowork: "cowork";
73
+ };
74
+ export type QueueMessageInputSurfaceEnum = typeof QueueMessageInputSurfaceEnum[keyof typeof QueueMessageInputSurfaceEnum];
52
75
  /**
53
76
  * Check if a given object implements the QueueMessageInput interface.
54
77
  */
@@ -19,6 +19,16 @@ export const QueueMessageInputDeliveryEnum = {
19
19
  Queue: 'queue',
20
20
  Now: 'now'
21
21
  };
22
+ /**
23
+ * @export
24
+ */
25
+ export const QueueMessageInputSurfaceEnum = {
26
+ Builder: 'builder',
27
+ Playground: 'playground',
28
+ Tests: 'tests',
29
+ Evals: 'evals',
30
+ Cowork: 'cowork'
31
+ };
22
32
  /**
23
33
  * Check if a given object implements the QueueMessageInput interface.
24
34
  */
@@ -39,6 +49,8 @@ export function QueueMessageInputFromJSONTyped(json, ignoreDiscriminator) {
39
49
  'delivery': json['delivery'] == null ? undefined : json['delivery'],
40
50
  'agentId': json['agentId'] == null ? undefined : json['agentId'],
41
51
  'retryOf': json['retryOf'] == null ? undefined : json['retryOf'],
52
+ 'surface': json['surface'] == null ? undefined : json['surface'],
53
+ 'endUserId': json['endUserId'] == null ? undefined : json['endUserId'],
42
54
  };
43
55
  }
44
56
  export function QueueMessageInputToJSON(json) {
@@ -53,5 +65,7 @@ export function QueueMessageInputToJSONTyped(value, ignoreDiscriminator = false)
53
65
  'delivery': value['delivery'],
54
66
  'agentId': value['agentId'],
55
67
  'retryOf': value['retryOf'],
68
+ 'surface': value['surface'],
69
+ 'endUserId': value['endUserId'],
56
70
  };
57
71
  }