mavenagi 0.0.0-alpha.4 → 0.0.0-alpha.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.
Files changed (184) hide show
  1. package/Client.d.ts +5 -5
  2. package/Client.js +3 -3
  3. package/README.md +15 -31
  4. package/api/resources/actions/client/Client.d.ts +19 -65
  5. package/api/resources/actions/client/Client.js +31 -292
  6. package/api/resources/actions/types/{Action.d.ts → ActionBase.d.ts} +1 -7
  7. package/api/resources/actions/types/ActionParameter.d.ts +1 -0
  8. package/api/resources/actions/types/ActionRequest.d.ts +21 -0
  9. package/api/resources/actions/types/ActionResponse.d.ts +25 -0
  10. package/api/resources/actions/types/index.d.ts +3 -4
  11. package/api/resources/actions/types/index.js +3 -4
  12. package/api/resources/commons/types/EntityId.d.ts +14 -0
  13. package/api/resources/commons/types/EntityIdBase.d.ts +10 -0
  14. package/api/resources/commons/types/EntityType.d.ts +14 -0
  15. package/api/resources/commons/types/EntityType.js +13 -0
  16. package/api/resources/commons/types/index.d.ts +3 -0
  17. package/api/resources/commons/types/index.js +3 -0
  18. package/api/resources/conversation/client/Client.d.ts +20 -3
  19. package/api/resources/conversation/client/Client.js +118 -25
  20. package/api/resources/conversation/types/ConversationBase.d.ts +0 -2
  21. package/api/resources/conversation/types/ConversationRequest.d.ts +2 -0
  22. package/api/resources/conversation/types/ConversationResponse.d.ts +2 -0
  23. package/api/resources/index.d.ts +1 -1
  24. package/api/resources/index.js +1 -1
  25. package/api/resources/knowledge/client/Client.d.ts +2 -2
  26. package/api/resources/knowledge/client/Client.js +21 -21
  27. package/api/resources/knowledge/types/KnowledgeBase.d.ts +1 -1
  28. package/api/resources/triggers/client/Client.d.ts +14 -12
  29. package/api/resources/triggers/client/Client.js +25 -23
  30. package/{dist/api/resources/triggers/types/EventTrigger.d.ts → api/resources/triggers/types/EventTriggerBase.d.ts} +1 -3
  31. package/api/resources/triggers/types/EventTriggerRequest.d.ts +18 -0
  32. package/api/resources/triggers/types/EventTriggerResponse.d.ts +22 -0
  33. package/api/resources/triggers/types/index.d.ts +3 -1
  34. package/api/resources/triggers/types/index.js +3 -1
  35. package/api/resources/{user → users}/client/Client.d.ts +12 -12
  36. package/api/resources/{user → users}/client/Client.js +11 -11
  37. package/dist/Client.d.ts +5 -5
  38. package/dist/Client.js +3 -3
  39. package/dist/api/resources/actions/client/Client.d.ts +19 -65
  40. package/dist/api/resources/actions/client/Client.js +31 -292
  41. package/dist/api/resources/actions/types/{Action.d.ts → ActionBase.d.ts} +1 -7
  42. package/dist/api/resources/actions/types/ActionParameter.d.ts +1 -0
  43. package/dist/api/resources/actions/types/ActionRequest.d.ts +21 -0
  44. package/dist/api/resources/actions/types/ActionResponse.d.ts +25 -0
  45. package/dist/api/resources/actions/types/ActionResponse.js +4 -0
  46. package/dist/api/resources/actions/types/index.d.ts +3 -4
  47. package/dist/api/resources/actions/types/index.js +3 -4
  48. package/dist/api/resources/commons/types/EntityId.d.ts +14 -0
  49. package/dist/api/resources/commons/types/EntityId.js +4 -0
  50. package/dist/api/resources/commons/types/EntityIdBase.d.ts +10 -0
  51. package/dist/api/resources/commons/types/EntityIdBase.js +4 -0
  52. package/dist/api/resources/commons/types/EntityType.d.ts +14 -0
  53. package/dist/api/resources/commons/types/EntityType.js +13 -0
  54. package/dist/api/resources/commons/types/index.d.ts +3 -0
  55. package/dist/api/resources/commons/types/index.js +3 -0
  56. package/dist/api/resources/conversation/client/Client.d.ts +20 -3
  57. package/dist/api/resources/conversation/client/Client.js +118 -25
  58. package/dist/api/resources/conversation/types/ConversationBase.d.ts +0 -2
  59. package/dist/api/resources/conversation/types/ConversationRequest.d.ts +2 -0
  60. package/dist/api/resources/conversation/types/ConversationResponse.d.ts +2 -0
  61. package/dist/api/resources/index.d.ts +1 -1
  62. package/dist/api/resources/index.js +1 -1
  63. package/dist/api/resources/knowledge/client/Client.d.ts +2 -2
  64. package/dist/api/resources/knowledge/client/Client.js +21 -21
  65. package/dist/api/resources/knowledge/types/KnowledgeBase.d.ts +1 -1
  66. package/dist/api/resources/triggers/client/Client.d.ts +14 -12
  67. package/dist/api/resources/triggers/client/Client.js +25 -23
  68. package/{api/resources/triggers/types/EventTrigger.d.ts → dist/api/resources/triggers/types/EventTriggerBase.d.ts} +1 -3
  69. package/dist/api/resources/triggers/types/EventTriggerBase.js +4 -0
  70. package/dist/api/resources/triggers/types/EventTriggerRequest.d.ts +18 -0
  71. package/dist/api/resources/triggers/types/EventTriggerRequest.js +4 -0
  72. package/dist/api/resources/triggers/types/EventTriggerResponse.d.ts +22 -0
  73. package/dist/api/resources/triggers/types/EventTriggerResponse.js +4 -0
  74. package/dist/api/resources/triggers/types/index.d.ts +3 -1
  75. package/dist/api/resources/triggers/types/index.js +3 -1
  76. package/dist/api/resources/{user → users}/client/Client.d.ts +12 -12
  77. package/dist/api/resources/{user → users}/client/Client.js +11 -11
  78. package/dist/serialization/resources/actions/types/{Action.d.ts → ActionBase.d.ts} +2 -5
  79. package/{serialization/resources/actions/types/Action.js → dist/serialization/resources/actions/types/ActionBase.js} +1 -4
  80. package/dist/serialization/resources/actions/types/ActionParameter.d.ts +1 -0
  81. package/dist/serialization/resources/actions/types/ActionParameter.js +1 -0
  82. package/dist/serialization/resources/actions/types/ActionRequest.d.ts +14 -0
  83. package/dist/serialization/resources/actions/types/ActionRequest.js +11 -0
  84. package/dist/serialization/resources/actions/types/ActionResponse.d.ts +14 -0
  85. package/dist/serialization/resources/actions/types/ActionResponse.js +11 -0
  86. package/dist/serialization/resources/actions/types/index.d.ts +3 -4
  87. package/dist/serialization/resources/actions/types/index.js +3 -4
  88. package/dist/serialization/resources/commons/types/EntityId.d.ts +17 -0
  89. package/dist/serialization/resources/commons/types/EntityId.js +14 -0
  90. package/{serialization/resources/actions/types/ActionSetBase.d.ts → dist/serialization/resources/commons/types/EntityIdBase.d.ts} +3 -4
  91. package/dist/serialization/resources/commons/types/EntityIdBase.js +7 -0
  92. package/dist/serialization/resources/commons/types/EntityType.d.ts +10 -0
  93. package/dist/serialization/resources/commons/types/EntityType.js +14 -0
  94. package/dist/serialization/resources/commons/types/index.d.ts +3 -0
  95. package/dist/serialization/resources/commons/types/index.js +3 -0
  96. package/dist/serialization/resources/conversation/client/addConversationMetadata.d.ts +13 -0
  97. package/dist/serialization/resources/conversation/client/addConversationMetadata.js +6 -0
  98. package/dist/serialization/resources/conversation/client/index.d.ts +1 -0
  99. package/dist/serialization/resources/conversation/client/index.js +1 -0
  100. package/dist/serialization/resources/conversation/types/ConversationBase.d.ts +0 -2
  101. package/dist/serialization/resources/conversation/types/ConversationBase.js +0 -2
  102. package/dist/serialization/resources/conversation/types/ConversationRequest.d.ts +2 -0
  103. package/dist/serialization/resources/conversation/types/ConversationRequest.js +2 -0
  104. package/dist/serialization/resources/conversation/types/ConversationResponse.d.ts +2 -0
  105. package/dist/serialization/resources/conversation/types/ConversationResponse.js +2 -0
  106. package/dist/serialization/resources/triggers/types/{EventTrigger.d.ts → EventTriggerBase.d.ts} +2 -3
  107. package/dist/serialization/resources/triggers/types/{EventTrigger.js → EventTriggerBase.js} +1 -2
  108. package/dist/serialization/resources/triggers/types/EventTriggerRequest.d.ts +14 -0
  109. package/dist/serialization/resources/triggers/types/EventTriggerRequest.js +11 -0
  110. package/dist/serialization/resources/triggers/types/EventTriggerResponse.d.ts +14 -0
  111. package/dist/serialization/resources/triggers/types/EventTriggerResponse.js +11 -0
  112. package/dist/serialization/resources/triggers/types/index.d.ts +3 -1
  113. package/dist/serialization/resources/triggers/types/index.js +3 -1
  114. package/package.json +1 -1
  115. package/serialization/resources/actions/types/{Action.d.ts → ActionBase.d.ts} +2 -5
  116. package/{dist/serialization/resources/actions/types/Action.js → serialization/resources/actions/types/ActionBase.js} +1 -4
  117. package/serialization/resources/actions/types/ActionParameter.d.ts +1 -0
  118. package/serialization/resources/actions/types/ActionParameter.js +1 -0
  119. package/serialization/resources/actions/types/ActionRequest.d.ts +14 -0
  120. package/serialization/resources/actions/types/ActionRequest.js +11 -0
  121. package/serialization/resources/actions/types/ActionResponse.d.ts +14 -0
  122. package/serialization/resources/actions/types/ActionResponse.js +11 -0
  123. package/serialization/resources/actions/types/index.d.ts +3 -4
  124. package/serialization/resources/actions/types/index.js +3 -4
  125. package/serialization/resources/commons/types/EntityId.d.ts +17 -0
  126. package/serialization/resources/commons/types/EntityId.js +14 -0
  127. package/{dist/serialization/resources/actions/types/ActionSetBase.d.ts → serialization/resources/commons/types/EntityIdBase.d.ts} +3 -4
  128. package/serialization/resources/commons/types/EntityIdBase.js +7 -0
  129. package/serialization/resources/commons/types/EntityType.d.ts +10 -0
  130. package/serialization/resources/commons/types/EntityType.js +14 -0
  131. package/serialization/resources/commons/types/index.d.ts +3 -0
  132. package/serialization/resources/commons/types/index.js +3 -0
  133. package/serialization/resources/conversation/client/addConversationMetadata.d.ts +13 -0
  134. package/serialization/resources/conversation/client/addConversationMetadata.js +6 -0
  135. package/serialization/resources/conversation/client/index.d.ts +1 -0
  136. package/serialization/resources/conversation/client/index.js +1 -0
  137. package/serialization/resources/conversation/types/ConversationBase.d.ts +0 -2
  138. package/serialization/resources/conversation/types/ConversationBase.js +0 -2
  139. package/serialization/resources/conversation/types/ConversationRequest.d.ts +2 -0
  140. package/serialization/resources/conversation/types/ConversationRequest.js +2 -0
  141. package/serialization/resources/conversation/types/ConversationResponse.d.ts +2 -0
  142. package/serialization/resources/conversation/types/ConversationResponse.js +2 -0
  143. package/serialization/resources/triggers/types/{EventTrigger.d.ts → EventTriggerBase.d.ts} +2 -3
  144. package/serialization/resources/triggers/types/{EventTrigger.js → EventTriggerBase.js} +1 -2
  145. package/serialization/resources/triggers/types/EventTriggerRequest.d.ts +14 -0
  146. package/serialization/resources/triggers/types/EventTriggerRequest.js +11 -0
  147. package/serialization/resources/triggers/types/EventTriggerResponse.d.ts +14 -0
  148. package/serialization/resources/triggers/types/EventTriggerResponse.js +11 -0
  149. package/serialization/resources/triggers/types/index.d.ts +3 -1
  150. package/serialization/resources/triggers/types/index.js +3 -1
  151. package/api/resources/actions/types/ActionSetBase.d.ts +0 -9
  152. package/api/resources/actions/types/ActionSetRequest.d.ts +0 -6
  153. package/api/resources/actions/types/ActionSetResponse.d.ts +0 -6
  154. package/dist/api/resources/actions/types/ActionSetBase.d.ts +0 -9
  155. package/dist/api/resources/actions/types/ActionSetRequest.d.ts +0 -6
  156. package/dist/api/resources/actions/types/ActionSetResponse.d.ts +0 -6
  157. package/dist/serialization/resources/actions/types/ActionSetBase.js +0 -8
  158. package/dist/serialization/resources/actions/types/ActionSetRequest.d.ts +0 -12
  159. package/dist/serialization/resources/actions/types/ActionSetRequest.js +0 -6
  160. package/dist/serialization/resources/actions/types/ActionSetResponse.d.ts +0 -12
  161. package/dist/serialization/resources/actions/types/ActionSetResponse.js +0 -6
  162. package/serialization/resources/actions/types/ActionSetBase.js +0 -8
  163. package/serialization/resources/actions/types/ActionSetRequest.d.ts +0 -12
  164. package/serialization/resources/actions/types/ActionSetRequest.js +0 -6
  165. package/serialization/resources/actions/types/ActionSetResponse.d.ts +0 -12
  166. package/serialization/resources/actions/types/ActionSetResponse.js +0 -6
  167. /package/api/resources/actions/types/{Action.js → ActionBase.js} +0 -0
  168. /package/api/resources/actions/types/{ActionSetBase.js → ActionRequest.js} +0 -0
  169. /package/api/resources/actions/types/{ActionSetRequest.js → ActionResponse.js} +0 -0
  170. /package/api/resources/{actions/types/ActionSetResponse.js → commons/types/EntityId.js} +0 -0
  171. /package/api/resources/{triggers/types/EventTrigger.js → commons/types/EntityIdBase.js} +0 -0
  172. /package/{dist/api/resources/actions/types/Action.js → api/resources/triggers/types/EventTriggerBase.js} +0 -0
  173. /package/{dist/api/resources/actions/types/ActionSetBase.js → api/resources/triggers/types/EventTriggerRequest.js} +0 -0
  174. /package/{dist/api/resources/actions/types/ActionSetRequest.js → api/resources/triggers/types/EventTriggerResponse.js} +0 -0
  175. /package/api/resources/{user → users}/client/index.d.ts +0 -0
  176. /package/api/resources/{user → users}/client/index.js +0 -0
  177. /package/api/resources/{user → users}/index.d.ts +0 -0
  178. /package/api/resources/{user → users}/index.js +0 -0
  179. /package/dist/api/resources/actions/types/{ActionSetResponse.js → ActionBase.js} +0 -0
  180. /package/dist/api/resources/{triggers/types/EventTrigger.js → actions/types/ActionRequest.js} +0 -0
  181. /package/dist/api/resources/{user → users}/client/index.d.ts +0 -0
  182. /package/dist/api/resources/{user → users}/client/index.js +0 -0
  183. /package/dist/api/resources/{user → users}/index.d.ts +0 -0
  184. /package/dist/api/resources/{user → users}/index.js +0 -0
@@ -33,8 +33,8 @@ export class Conversation {
33
33
  * @example
34
34
  * await client.conversation.initialize({
35
35
  * messages: [{}],
36
- * id: "string",
37
36
  * context: {},
37
+ * id: "string",
38
38
  * responseConfig: {
39
39
  * capabilities: [MavenAGI.Capability.Markdown],
40
40
  * isCopilot: true,
@@ -50,11 +50,11 @@ export class Conversation {
50
50
  method: "POST",
51
51
  headers: {
52
52
  Authorization: yield this._getAuthorizationHeader(),
53
- "X-Organization-Id": yield core.Supplier.get(this._options.organizationId),
54
- "X-Agent-Id": yield core.Supplier.get(this._options.agentId),
53
+ "X-Organization-Id": yield core.Supplier.get(this._options.xOrganizationId),
54
+ "X-Agent-Id": yield core.Supplier.get(this._options.xAgentId),
55
55
  "X-Fern-Language": "JavaScript",
56
56
  "X-Fern-SDK-Name": "mavenagi",
57
- "X-Fern-SDK-Version": "0.0.0-alpha.4",
57
+ "X-Fern-SDK-Version": "0.0.0-alpha.5",
58
58
  "X-Fern-Runtime": core.RUNTIME.type,
59
59
  "X-Fern-Runtime-Version": core.RUNTIME.version,
60
60
  },
@@ -138,11 +138,11 @@ export class Conversation {
138
138
  method: "GET",
139
139
  headers: {
140
140
  Authorization: yield this._getAuthorizationHeader(),
141
- "X-Organization-Id": yield core.Supplier.get(this._options.organizationId),
142
- "X-Agent-Id": yield core.Supplier.get(this._options.agentId),
141
+ "X-Organization-Id": yield core.Supplier.get(this._options.xOrganizationId),
142
+ "X-Agent-Id": yield core.Supplier.get(this._options.xAgentId),
143
143
  "X-Fern-Language": "JavaScript",
144
144
  "X-Fern-SDK-Name": "mavenagi",
145
- "X-Fern-SDK-Version": "0.0.0-alpha.4",
145
+ "X-Fern-SDK-Version": "0.0.0-alpha.5",
146
146
  "X-Fern-Runtime": core.RUNTIME.type,
147
147
  "X-Fern-Runtime-Version": core.RUNTIME.version,
148
148
  },
@@ -231,11 +231,11 @@ export class Conversation {
231
231
  method: "POST",
232
232
  headers: {
233
233
  Authorization: yield this._getAuthorizationHeader(),
234
- "X-Organization-Id": yield core.Supplier.get(this._options.organizationId),
235
- "X-Agent-Id": yield core.Supplier.get(this._options.agentId),
234
+ "X-Organization-Id": yield core.Supplier.get(this._options.xOrganizationId),
235
+ "X-Agent-Id": yield core.Supplier.get(this._options.xAgentId),
236
236
  "X-Fern-Language": "JavaScript",
237
237
  "X-Fern-SDK-Name": "mavenagi",
238
- "X-Fern-SDK-Version": "0.0.0-alpha.4",
238
+ "X-Fern-SDK-Version": "0.0.0-alpha.5",
239
239
  "X-Fern-Runtime": core.RUNTIME.type,
240
240
  "X-Fern-Runtime-Version": core.RUNTIME.version,
241
241
  },
@@ -327,11 +327,11 @@ export class Conversation {
327
327
  method: "POST",
328
328
  headers: {
329
329
  Authorization: yield this._getAuthorizationHeader(),
330
- "X-Organization-Id": yield core.Supplier.get(this._options.organizationId),
331
- "X-Agent-Id": yield core.Supplier.get(this._options.agentId),
330
+ "X-Organization-Id": yield core.Supplier.get(this._options.xOrganizationId),
331
+ "X-Agent-Id": yield core.Supplier.get(this._options.xAgentId),
332
332
  "X-Fern-Language": "JavaScript",
333
333
  "X-Fern-SDK-Name": "mavenagi",
334
- "X-Fern-SDK-Version": "0.0.0-alpha.4",
334
+ "X-Fern-SDK-Version": "0.0.0-alpha.5",
335
335
  "X-Fern-Runtime": core.RUNTIME.type,
336
336
  "X-Fern-Runtime-Version": core.RUNTIME.version,
337
337
  },
@@ -405,11 +405,11 @@ export class Conversation {
405
405
  method: "POST",
406
406
  headers: {
407
407
  Authorization: yield this._getAuthorizationHeader(),
408
- "X-Organization-Id": yield core.Supplier.get(this._options.organizationId),
409
- "X-Agent-Id": yield core.Supplier.get(this._options.agentId),
408
+ "X-Organization-Id": yield core.Supplier.get(this._options.xOrganizationId),
409
+ "X-Agent-Id": yield core.Supplier.get(this._options.xAgentId),
410
410
  "X-Fern-Language": "JavaScript",
411
411
  "X-Fern-SDK-Name": "mavenagi",
412
- "X-Fern-SDK-Version": "0.0.0-alpha.4",
412
+ "X-Fern-SDK-Version": "0.0.0-alpha.5",
413
413
  "X-Fern-Runtime": core.RUNTIME.type,
414
414
  "X-Fern-Runtime-Version": core.RUNTIME.version,
415
415
  },
@@ -507,11 +507,11 @@ export class Conversation {
507
507
  method: "POST",
508
508
  headers: {
509
509
  Authorization: yield this._getAuthorizationHeader(),
510
- "X-Organization-Id": yield core.Supplier.get(this._options.organizationId),
511
- "X-Agent-Id": yield core.Supplier.get(this._options.agentId),
510
+ "X-Organization-Id": yield core.Supplier.get(this._options.xOrganizationId),
511
+ "X-Agent-Id": yield core.Supplier.get(this._options.xAgentId),
512
512
  "X-Fern-Language": "JavaScript",
513
513
  "X-Fern-SDK-Name": "mavenagi",
514
- "X-Fern-SDK-Version": "0.0.0-alpha.4",
514
+ "X-Fern-SDK-Version": "0.0.0-alpha.5",
515
515
  "X-Fern-Runtime": core.RUNTIME.type,
516
516
  "X-Fern-Runtime-Version": core.RUNTIME.version,
517
517
  },
@@ -603,11 +603,11 @@ export class Conversation {
603
603
  method: "POST",
604
604
  headers: {
605
605
  Authorization: yield this._getAuthorizationHeader(),
606
- "X-Organization-Id": yield core.Supplier.get(this._options.organizationId),
607
- "X-Agent-Id": yield core.Supplier.get(this._options.agentId),
606
+ "X-Organization-Id": yield core.Supplier.get(this._options.xOrganizationId),
607
+ "X-Agent-Id": yield core.Supplier.get(this._options.xAgentId),
608
608
  "X-Fern-Language": "JavaScript",
609
609
  "X-Fern-SDK-Name": "mavenagi",
610
- "X-Fern-SDK-Version": "0.0.0-alpha.4",
610
+ "X-Fern-SDK-Version": "0.0.0-alpha.5",
611
611
  "X-Fern-Runtime": core.RUNTIME.type,
612
612
  "X-Fern-Runtime-Version": core.RUNTIME.version,
613
613
  },
@@ -704,11 +704,11 @@ export class Conversation {
704
704
  method: "POST",
705
705
  headers: {
706
706
  Authorization: yield this._getAuthorizationHeader(),
707
- "X-Organization-Id": yield core.Supplier.get(this._options.organizationId),
708
- "X-Agent-Id": yield core.Supplier.get(this._options.agentId),
707
+ "X-Organization-Id": yield core.Supplier.get(this._options.xOrganizationId),
708
+ "X-Agent-Id": yield core.Supplier.get(this._options.xAgentId),
709
709
  "X-Fern-Language": "JavaScript",
710
710
  "X-Fern-SDK-Name": "mavenagi",
711
- "X-Fern-SDK-Version": "0.0.0-alpha.4",
711
+ "X-Fern-SDK-Version": "0.0.0-alpha.5",
712
712
  "X-Fern-Runtime": core.RUNTIME.type,
713
713
  "X-Fern-Runtime-Version": core.RUNTIME.version,
714
714
  },
@@ -771,6 +771,99 @@ export class Conversation {
771
771
  }
772
772
  });
773
773
  }
774
+ /**
775
+ * Add metadata to an existing conversation's Context. If a metadata field already exists, it will be overwritten.
776
+ *
777
+ * @param {string} conversationId - The ID of a conversation the metadata being added belongs to
778
+ * @param {Record<string, string>} request
779
+ * @param {Conversation.RequestOptions} requestOptions - Request-specific configuration.
780
+ *
781
+ * @throws {@link MavenAGI.NotFoundError}
782
+ * @throws {@link MavenAGI.BadRequestError}
783
+ * @throws {@link MavenAGI.ServerError}
784
+ *
785
+ * @example
786
+ * await client.conversation.addConversationMetadata("string", {
787
+ * "string": "string"
788
+ * })
789
+ */
790
+ addConversationMetadata(conversationId, request, requestOptions) {
791
+ var _a, _b;
792
+ return __awaiter(this, void 0, void 0, function* () {
793
+ const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
794
+ url: urlJoin((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.MavenAGIEnvironment.Production, `/v1/conversations/${encodeURIComponent(conversationId)}/metadata`),
795
+ method: "POST",
796
+ headers: {
797
+ Authorization: yield this._getAuthorizationHeader(),
798
+ "X-Organization-Id": yield core.Supplier.get(this._options.xOrganizationId),
799
+ "X-Agent-Id": yield core.Supplier.get(this._options.xAgentId),
800
+ "X-Fern-Language": "JavaScript",
801
+ "X-Fern-SDK-Name": "mavenagi",
802
+ "X-Fern-SDK-Version": "0.0.0-alpha.5",
803
+ "X-Fern-Runtime": core.RUNTIME.type,
804
+ "X-Fern-Runtime-Version": core.RUNTIME.version,
805
+ },
806
+ contentType: "application/json",
807
+ body: yield serializers.conversation.addConversationMetadata.Request.jsonOrThrow(request, {
808
+ unrecognizedObjectKeys: "strip",
809
+ }),
810
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
811
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
812
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
813
+ });
814
+ if (_response.ok) {
815
+ return yield serializers.conversation.addConversationMetadata.Response.parseOrThrow(_response.body, {
816
+ unrecognizedObjectKeys: "passthrough",
817
+ allowUnrecognizedUnionMembers: true,
818
+ allowUnrecognizedEnumValues: true,
819
+ breadcrumbsPrefix: ["response"],
820
+ });
821
+ }
822
+ if (_response.error.reason === "status-code") {
823
+ switch (_response.error.statusCode) {
824
+ case 404:
825
+ throw new MavenAGI.NotFoundError(yield serializers.ErrorMessage.parseOrThrow(_response.error.body, {
826
+ unrecognizedObjectKeys: "passthrough",
827
+ allowUnrecognizedUnionMembers: true,
828
+ allowUnrecognizedEnumValues: true,
829
+ breadcrumbsPrefix: ["response"],
830
+ }));
831
+ case 400:
832
+ throw new MavenAGI.BadRequestError(yield serializers.ErrorMessage.parseOrThrow(_response.error.body, {
833
+ unrecognizedObjectKeys: "passthrough",
834
+ allowUnrecognizedUnionMembers: true,
835
+ allowUnrecognizedEnumValues: true,
836
+ breadcrumbsPrefix: ["response"],
837
+ }));
838
+ case 500:
839
+ throw new MavenAGI.ServerError(yield serializers.ErrorMessage.parseOrThrow(_response.error.body, {
840
+ unrecognizedObjectKeys: "passthrough",
841
+ allowUnrecognizedUnionMembers: true,
842
+ allowUnrecognizedEnumValues: true,
843
+ breadcrumbsPrefix: ["response"],
844
+ }));
845
+ default:
846
+ throw new errors.MavenAGIError({
847
+ statusCode: _response.error.statusCode,
848
+ body: _response.error.body,
849
+ });
850
+ }
851
+ }
852
+ switch (_response.error.reason) {
853
+ case "non-json":
854
+ throw new errors.MavenAGIError({
855
+ statusCode: _response.error.statusCode,
856
+ body: _response.error.rawBody,
857
+ });
858
+ case "timeout":
859
+ throw new errors.MavenAGITimeoutError();
860
+ case "unknown":
861
+ throw new errors.MavenAGIError({
862
+ message: _response.error.errorMessage,
863
+ });
864
+ }
865
+ });
866
+ }
774
867
  _getAuthorizationHeader() {
775
868
  var _a, _b;
776
869
  return __awaiter(this, void 0, void 0, function* () {
@@ -5,8 +5,6 @@ import * as MavenAGI from "../../../index";
5
5
  export interface ConversationBase {
6
6
  /** Externally supplied ID to uniquely identify this conversation */
7
7
  id: string;
8
- /** The context of the conversation */
9
- context?: MavenAGI.ConversationContext;
10
8
  /** Optional configurations for responses to this conversation */
11
9
  responseConfig?: MavenAGI.ResponseConfig;
12
10
  }
@@ -5,4 +5,6 @@ import * as MavenAGI from "../../../index";
5
5
  export interface ConversationRequest extends MavenAGI.ConversationBase {
6
6
  /** The messages in the conversation */
7
7
  messages: MavenAGI.ConversationMessageRequest[];
8
+ /** The context of the conversation */
9
+ context?: MavenAGI.ConversationContext;
8
10
  }
@@ -5,4 +5,6 @@ import * as MavenAGI from "../../../index";
5
5
  export interface ConversationResponse extends MavenAGI.ConversationBase {
6
6
  /** The messages in the conversation */
7
7
  messages: MavenAGI.ConversationMessageResponse[];
8
+ /** The context of the conversation */
9
+ context: MavenAGI.ConversationContext;
8
10
  }
@@ -9,4 +9,4 @@ export * from "./knowledge/types";
9
9
  export * as triggers from "./triggers";
10
10
  export * from "./triggers/types";
11
11
  export * from "./commons/errors";
12
- export * as user from "./user";
12
+ export * as users from "./users";
@@ -9,4 +9,4 @@ export * from "./knowledge/types";
9
9
  export * as triggers from "./triggers";
10
10
  export * from "./triggers/types";
11
11
  export * from "./commons/errors";
12
- export * as user from "./user";
12
+ export * as users from "./users";
@@ -9,8 +9,8 @@ export declare namespace Knowledge {
9
9
  environment?: core.Supplier<environments.MavenAGIEnvironment | string>;
10
10
  appId?: core.Supplier<string | undefined>;
11
11
  appSecret?: core.Supplier<string | undefined>;
12
- organizationId: core.Supplier<string>;
13
- agentId: core.Supplier<string>;
12
+ xOrganizationId: core.Supplier<string>;
13
+ xAgentId: core.Supplier<string>;
14
14
  fetcher?: core.FetchFunction;
15
15
  }
16
16
  interface RequestOptions {
@@ -46,11 +46,11 @@ export class Knowledge {
46
46
  method: "POST",
47
47
  headers: {
48
48
  Authorization: yield this._getAuthorizationHeader(),
49
- "X-Organization-Id": yield core.Supplier.get(this._options.organizationId),
50
- "X-Agent-Id": yield core.Supplier.get(this._options.agentId),
49
+ "X-Organization-Id": yield core.Supplier.get(this._options.xOrganizationId),
50
+ "X-Agent-Id": yield core.Supplier.get(this._options.xAgentId),
51
51
  "X-Fern-Language": "JavaScript",
52
52
  "X-Fern-SDK-Name": "mavenagi",
53
- "X-Fern-SDK-Version": "0.0.0-alpha.4",
53
+ "X-Fern-SDK-Version": "0.0.0-alpha.5",
54
54
  "X-Fern-Runtime": core.RUNTIME.type,
55
55
  "X-Fern-Runtime-Version": core.RUNTIME.version,
56
56
  },
@@ -134,11 +134,11 @@ export class Knowledge {
134
134
  method: "GET",
135
135
  headers: {
136
136
  Authorization: yield this._getAuthorizationHeader(),
137
- "X-Organization-Id": yield core.Supplier.get(this._options.organizationId),
138
- "X-Agent-Id": yield core.Supplier.get(this._options.agentId),
137
+ "X-Organization-Id": yield core.Supplier.get(this._options.xOrganizationId),
138
+ "X-Agent-Id": yield core.Supplier.get(this._options.xAgentId),
139
139
  "X-Fern-Language": "JavaScript",
140
140
  "X-Fern-SDK-Name": "mavenagi",
141
- "X-Fern-SDK-Version": "0.0.0-alpha.4",
141
+ "X-Fern-SDK-Version": "0.0.0-alpha.5",
142
142
  "X-Fern-Runtime": core.RUNTIME.type,
143
143
  "X-Fern-Runtime-Version": core.RUNTIME.version,
144
144
  },
@@ -224,11 +224,11 @@ export class Knowledge {
224
224
  method: "POST",
225
225
  headers: {
226
226
  Authorization: yield this._getAuthorizationHeader(),
227
- "X-Organization-Id": yield core.Supplier.get(this._options.organizationId),
228
- "X-Agent-Id": yield core.Supplier.get(this._options.agentId),
227
+ "X-Organization-Id": yield core.Supplier.get(this._options.xOrganizationId),
228
+ "X-Agent-Id": yield core.Supplier.get(this._options.xAgentId),
229
229
  "X-Fern-Language": "JavaScript",
230
230
  "X-Fern-SDK-Name": "mavenagi",
231
- "X-Fern-SDK-Version": "0.0.0-alpha.4",
231
+ "X-Fern-SDK-Version": "0.0.0-alpha.5",
232
232
  "X-Fern-Runtime": core.RUNTIME.type,
233
233
  "X-Fern-Runtime-Version": core.RUNTIME.version,
234
234
  },
@@ -314,11 +314,11 @@ export class Knowledge {
314
314
  method: "POST",
315
315
  headers: {
316
316
  Authorization: yield this._getAuthorizationHeader(),
317
- "X-Organization-Id": yield core.Supplier.get(this._options.organizationId),
318
- "X-Agent-Id": yield core.Supplier.get(this._options.agentId),
317
+ "X-Organization-Id": yield core.Supplier.get(this._options.xOrganizationId),
318
+ "X-Agent-Id": yield core.Supplier.get(this._options.xAgentId),
319
319
  "X-Fern-Language": "JavaScript",
320
320
  "X-Fern-SDK-Name": "mavenagi",
321
- "X-Fern-SDK-Version": "0.0.0-alpha.4",
321
+ "X-Fern-SDK-Version": "0.0.0-alpha.5",
322
322
  "X-Fern-Runtime": core.RUNTIME.type,
323
323
  "X-Fern-Runtime-Version": core.RUNTIME.version,
324
324
  },
@@ -408,11 +408,11 @@ export class Knowledge {
408
408
  method: "POST",
409
409
  headers: {
410
410
  Authorization: yield this._getAuthorizationHeader(),
411
- "X-Organization-Id": yield core.Supplier.get(this._options.organizationId),
412
- "X-Agent-Id": yield core.Supplier.get(this._options.agentId),
411
+ "X-Organization-Id": yield core.Supplier.get(this._options.xOrganizationId),
412
+ "X-Agent-Id": yield core.Supplier.get(this._options.xAgentId),
413
413
  "X-Fern-Language": "JavaScript",
414
414
  "X-Fern-SDK-Name": "mavenagi",
415
- "X-Fern-SDK-Version": "0.0.0-alpha.4",
415
+ "X-Fern-SDK-Version": "0.0.0-alpha.5",
416
416
  "X-Fern-Runtime": core.RUNTIME.type,
417
417
  "X-Fern-Runtime-Version": core.RUNTIME.version,
418
418
  },
@@ -507,11 +507,11 @@ export class Knowledge {
507
507
  method: "PUT",
508
508
  headers: {
509
509
  Authorization: yield this._getAuthorizationHeader(),
510
- "X-Organization-Id": yield core.Supplier.get(this._options.organizationId),
511
- "X-Agent-Id": yield core.Supplier.get(this._options.agentId),
510
+ "X-Organization-Id": yield core.Supplier.get(this._options.xOrganizationId),
511
+ "X-Agent-Id": yield core.Supplier.get(this._options.xAgentId),
512
512
  "X-Fern-Language": "JavaScript",
513
513
  "X-Fern-SDK-Name": "mavenagi",
514
- "X-Fern-SDK-Version": "0.0.0-alpha.4",
514
+ "X-Fern-SDK-Version": "0.0.0-alpha.5",
515
515
  "X-Fern-Runtime": core.RUNTIME.type,
516
516
  "X-Fern-Runtime-Version": core.RUNTIME.version,
517
517
  },
@@ -598,11 +598,11 @@ export class Knowledge {
598
598
  method: "DELETE",
599
599
  headers: {
600
600
  Authorization: yield this._getAuthorizationHeader(),
601
- "X-Organization-Id": yield core.Supplier.get(this._options.organizationId),
602
- "X-Agent-Id": yield core.Supplier.get(this._options.agentId),
601
+ "X-Organization-Id": yield core.Supplier.get(this._options.xOrganizationId),
602
+ "X-Agent-Id": yield core.Supplier.get(this._options.xAgentId),
603
603
  "X-Fern-Language": "JavaScript",
604
604
  "X-Fern-SDK-Name": "mavenagi",
605
- "X-Fern-SDK-Version": "0.0.0-alpha.4",
605
+ "X-Fern-SDK-Version": "0.0.0-alpha.5",
606
606
  "X-Fern-Runtime": core.RUNTIME.type,
607
607
  "X-Fern-Runtime-Version": core.RUNTIME.version,
608
608
  },
@@ -5,7 +5,7 @@ import * as MavenAGI from "../../../index";
5
5
  export interface KnowledgeBase extends MavenAGI.KnowledgeBaseId {
6
6
  /** The name of the knowledge base */
7
7
  displayName: string;
8
- /** The type of the knowledge base */
8
+ /** The type of the knowledge base. Can not be changed once created. */
9
9
  type: MavenAGI.KnowledgeBaseType;
10
10
  /** The URL to pull content from for RSS and URL knowledge bases. */
11
11
  url?: string;
@@ -9,8 +9,8 @@ export declare namespace Triggers {
9
9
  environment?: core.Supplier<environments.MavenAGIEnvironment | string>;
10
10
  appId?: core.Supplier<string | undefined>;
11
11
  appSecret?: core.Supplier<string | undefined>;
12
- organizationId: core.Supplier<string>;
13
- agentId: core.Supplier<string>;
12
+ xOrganizationId: core.Supplier<string>;
13
+ xAgentId: core.Supplier<string>;
14
14
  fetcher?: core.FetchFunction;
15
15
  }
16
16
  interface RequestOptions {
@@ -25,7 +25,7 @@ export declare class Triggers {
25
25
  /**
26
26
  * Update an event trigger or create it if it doesn't exist.
27
27
  *
28
- * @param {MavenAGI.EventTrigger} request
28
+ * @param {MavenAGI.EventTriggerRequest} request
29
29
  * @param {Triggers.RequestOptions} requestOptions - Request-specific configuration.
30
30
  *
31
31
  * @throws {@link MavenAGI.NotFoundError}
@@ -34,16 +34,18 @@ export declare class Triggers {
34
34
  *
35
35
  * @example
36
36
  * await client.triggers.registerTrigger({
37
- * id: "string",
38
- * description: "string",
37
+ * entityId: {
38
+ * referenceId: "store-in-snowflake"
39
+ * },
40
+ * description: "Stores conversation data in Snowflake",
39
41
  * type: MavenAGI.EventTriggerType.ConversationCreated
40
42
  * })
41
43
  */
42
- registerTrigger(request: MavenAGI.EventTrigger, requestOptions?: Triggers.RequestOptions): Promise<MavenAGI.EventTrigger>;
44
+ registerTrigger(request: MavenAGI.EventTriggerRequest, requestOptions?: Triggers.RequestOptions): Promise<MavenAGI.EventTriggerResponse>;
43
45
  /**
44
46
  * Get an event trigger by its supplied ID
45
47
  *
46
- * @param {string} triggerId - The ID of the event trigger to get
48
+ * @param {string} referenceId - The reference ID of the event trigger to get. All other entity ID fields are inferred from the request.
47
49
  * @param {Triggers.RequestOptions} requestOptions - Request-specific configuration.
48
50
  *
49
51
  * @throws {@link MavenAGI.NotFoundError}
@@ -51,13 +53,13 @@ export declare class Triggers {
51
53
  * @throws {@link MavenAGI.ServerError}
52
54
  *
53
55
  * @example
54
- * await client.triggers.getTrigger("string")
56
+ * await client.triggers.getTrigger("store-in-snowflake")
55
57
  */
56
- getTrigger(triggerId: string, requestOptions?: Triggers.RequestOptions): Promise<MavenAGI.EventTrigger>;
58
+ getTrigger(referenceId: string, requestOptions?: Triggers.RequestOptions): Promise<MavenAGI.EventTriggerResponse>;
57
59
  /**
58
60
  * Unregister an event trigger
59
61
  *
60
- * @param {string} triggerId - The ID of the event trigger to unregister
62
+ * @param {string} referenceId - The reference ID of the event trigger to unregister. All other entity ID fields are inferred from the request.
61
63
  * @param {Triggers.RequestOptions} requestOptions - Request-specific configuration.
62
64
  *
63
65
  * @throws {@link MavenAGI.NotFoundError}
@@ -65,8 +67,8 @@ export declare class Triggers {
65
67
  * @throws {@link MavenAGI.ServerError}
66
68
  *
67
69
  * @example
68
- * await client.triggers.unregisterTrigger("string")
70
+ * await client.triggers.unregisterTrigger("store-in-snowflake")
69
71
  */
70
- unregisterTrigger(triggerId: string, requestOptions?: Triggers.RequestOptions): Promise<void>;
72
+ unregisterTrigger(referenceId: string, requestOptions?: Triggers.RequestOptions): Promise<void>;
71
73
  protected _getAuthorizationHeader(): Promise<string | undefined>;
72
74
  }
@@ -23,7 +23,7 @@ export class Triggers {
23
23
  /**
24
24
  * Update an event trigger or create it if it doesn't exist.
25
25
  *
26
- * @param {MavenAGI.EventTrigger} request
26
+ * @param {MavenAGI.EventTriggerRequest} request
27
27
  * @param {Triggers.RequestOptions} requestOptions - Request-specific configuration.
28
28
  *
29
29
  * @throws {@link MavenAGI.NotFoundError}
@@ -32,8 +32,10 @@ export class Triggers {
32
32
  *
33
33
  * @example
34
34
  * await client.triggers.registerTrigger({
35
- * id: "string",
36
- * description: "string",
35
+ * entityId: {
36
+ * referenceId: "store-in-snowflake"
37
+ * },
38
+ * description: "Stores conversation data in Snowflake",
37
39
  * type: MavenAGI.EventTriggerType.ConversationCreated
38
40
  * })
39
41
  */
@@ -45,22 +47,22 @@ export class Triggers {
45
47
  method: "PUT",
46
48
  headers: {
47
49
  Authorization: yield this._getAuthorizationHeader(),
48
- "X-Organization-Id": yield core.Supplier.get(this._options.organizationId),
49
- "X-Agent-Id": yield core.Supplier.get(this._options.agentId),
50
+ "X-Organization-Id": yield core.Supplier.get(this._options.xOrganizationId),
51
+ "X-Agent-Id": yield core.Supplier.get(this._options.xAgentId),
50
52
  "X-Fern-Language": "JavaScript",
51
53
  "X-Fern-SDK-Name": "mavenagi",
52
- "X-Fern-SDK-Version": "0.0.0-alpha.4",
54
+ "X-Fern-SDK-Version": "0.0.0-alpha.5",
53
55
  "X-Fern-Runtime": core.RUNTIME.type,
54
56
  "X-Fern-Runtime-Version": core.RUNTIME.version,
55
57
  },
56
58
  contentType: "application/json",
57
- body: yield serializers.EventTrigger.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
59
+ body: yield serializers.EventTriggerRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
58
60
  timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
59
61
  maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
60
62
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
61
63
  });
62
64
  if (_response.ok) {
63
- return yield serializers.EventTrigger.parseOrThrow(_response.body, {
65
+ return yield serializers.EventTriggerResponse.parseOrThrow(_response.body, {
64
66
  unrecognizedObjectKeys: "passthrough",
65
67
  allowUnrecognizedUnionMembers: true,
66
68
  allowUnrecognizedEnumValues: true,
@@ -115,7 +117,7 @@ export class Triggers {
115
117
  /**
116
118
  * Get an event trigger by its supplied ID
117
119
  *
118
- * @param {string} triggerId - The ID of the event trigger to get
120
+ * @param {string} referenceId - The reference ID of the event trigger to get. All other entity ID fields are inferred from the request.
119
121
  * @param {Triggers.RequestOptions} requestOptions - Request-specific configuration.
120
122
  *
121
123
  * @throws {@link MavenAGI.NotFoundError}
@@ -123,21 +125,21 @@ export class Triggers {
123
125
  * @throws {@link MavenAGI.ServerError}
124
126
  *
125
127
  * @example
126
- * await client.triggers.getTrigger("string")
128
+ * await client.triggers.getTrigger("store-in-snowflake")
127
129
  */
128
- getTrigger(triggerId, requestOptions) {
130
+ getTrigger(referenceId, requestOptions) {
129
131
  var _a, _b;
130
132
  return __awaiter(this, void 0, void 0, function* () {
131
133
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
132
- url: urlJoin((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.MavenAGIEnvironment.Production, `/v1/triggers/${encodeURIComponent(triggerId)}`),
134
+ url: urlJoin((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.MavenAGIEnvironment.Production, `/v1/triggers/${encodeURIComponent(referenceId)}`),
133
135
  method: "GET",
134
136
  headers: {
135
137
  Authorization: yield this._getAuthorizationHeader(),
136
- "X-Organization-Id": yield core.Supplier.get(this._options.organizationId),
137
- "X-Agent-Id": yield core.Supplier.get(this._options.agentId),
138
+ "X-Organization-Id": yield core.Supplier.get(this._options.xOrganizationId),
139
+ "X-Agent-Id": yield core.Supplier.get(this._options.xAgentId),
138
140
  "X-Fern-Language": "JavaScript",
139
141
  "X-Fern-SDK-Name": "mavenagi",
140
- "X-Fern-SDK-Version": "0.0.0-alpha.4",
142
+ "X-Fern-SDK-Version": "0.0.0-alpha.5",
141
143
  "X-Fern-Runtime": core.RUNTIME.type,
142
144
  "X-Fern-Runtime-Version": core.RUNTIME.version,
143
145
  },
@@ -147,7 +149,7 @@ export class Triggers {
147
149
  abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
148
150
  });
149
151
  if (_response.ok) {
150
- return yield serializers.EventTrigger.parseOrThrow(_response.body, {
152
+ return yield serializers.EventTriggerResponse.parseOrThrow(_response.body, {
151
153
  unrecognizedObjectKeys: "passthrough",
152
154
  allowUnrecognizedUnionMembers: true,
153
155
  allowUnrecognizedEnumValues: true,
@@ -202,7 +204,7 @@ export class Triggers {
202
204
  /**
203
205
  * Unregister an event trigger
204
206
  *
205
- * @param {string} triggerId - The ID of the event trigger to unregister
207
+ * @param {string} referenceId - The reference ID of the event trigger to unregister. All other entity ID fields are inferred from the request.
206
208
  * @param {Triggers.RequestOptions} requestOptions - Request-specific configuration.
207
209
  *
208
210
  * @throws {@link MavenAGI.NotFoundError}
@@ -210,21 +212,21 @@ export class Triggers {
210
212
  * @throws {@link MavenAGI.ServerError}
211
213
  *
212
214
  * @example
213
- * await client.triggers.unregisterTrigger("string")
215
+ * await client.triggers.unregisterTrigger("store-in-snowflake")
214
216
  */
215
- unregisterTrigger(triggerId, requestOptions) {
217
+ unregisterTrigger(referenceId, requestOptions) {
216
218
  var _a, _b;
217
219
  return __awaiter(this, void 0, void 0, function* () {
218
220
  const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
219
- url: urlJoin((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.MavenAGIEnvironment.Production, `/v1/triggers/${encodeURIComponent(triggerId)}`),
221
+ url: urlJoin((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.MavenAGIEnvironment.Production, `/v1/triggers/${encodeURIComponent(referenceId)}`),
220
222
  method: "DELETE",
221
223
  headers: {
222
224
  Authorization: yield this._getAuthorizationHeader(),
223
- "X-Organization-Id": yield core.Supplier.get(this._options.organizationId),
224
- "X-Agent-Id": yield core.Supplier.get(this._options.agentId),
225
+ "X-Organization-Id": yield core.Supplier.get(this._options.xOrganizationId),
226
+ "X-Agent-Id": yield core.Supplier.get(this._options.xAgentId),
225
227
  "X-Fern-Language": "JavaScript",
226
228
  "X-Fern-SDK-Name": "mavenagi",
227
- "X-Fern-SDK-Version": "0.0.0-alpha.4",
229
+ "X-Fern-SDK-Version": "0.0.0-alpha.5",
228
230
  "X-Fern-Runtime": core.RUNTIME.type,
229
231
  "X-Fern-Runtime-Version": core.RUNTIME.version,
230
232
  },
@@ -2,9 +2,7 @@
2
2
  * This file was auto-generated by Fern from our API Definition.
3
3
  */
4
4
  import * as MavenAGI from "../../../index";
5
- export interface EventTrigger {
6
- /** Externally supplied ID to uniquely identify this event trigger */
7
- id: string;
5
+ export interface EventTriggerBase {
8
6
  /** The description of what the event trigger does, shown in the Maven Dashboard */
9
7
  description: string;
10
8
  /** The type of event trigger this app wishes to handle */
@@ -0,0 +1,4 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ export {};
@@ -0,0 +1,18 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ import * as MavenAGI from "../../../index";
5
+ /**
6
+ * @example
7
+ * {
8
+ * entityId: {
9
+ * referenceId: "store-in-snowflake"
10
+ * },
11
+ * description: "Stores conversation data in Snowflake",
12
+ * type: MavenAGI.EventTriggerType.ConversationCreated
13
+ * }
14
+ */
15
+ export interface EventTriggerRequest extends MavenAGI.EventTriggerBase {
16
+ /** ID that uniquely identifies this event trigger */
17
+ entityId: MavenAGI.EntityIdBase;
18
+ }
@@ -0,0 +1,4 @@
1
+ /**
2
+ * This file was auto-generated by Fern from our API Definition.
3
+ */
4
+ export {};