@runloop/reflex-client 0.15.1 → 0.16.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 (158) hide show
  1. package/dist/generated/agent-groups.d.ts +1 -1
  2. package/dist/generated/agent-groups.js +1 -1
  3. package/dist/generated/agents.d.ts +15 -1
  4. package/dist/generated/agents.d.ts.map +1 -1
  5. package/dist/generated/agents.js +16 -0
  6. package/dist/generated/agents.js.map +1 -1
  7. package/dist/generated/auth.d.ts +16 -2
  8. package/dist/generated/auth.d.ts.map +1 -1
  9. package/dist/generated/auth.js +17 -1
  10. package/dist/generated/auth.js.map +1 -1
  11. package/dist/generated/model/acknowledgeDeviceAuthTokenBody.d.ts +11 -0
  12. package/dist/generated/model/acknowledgeDeviceAuthTokenBody.d.ts.map +1 -0
  13. package/dist/generated/model/acknowledgeDeviceAuthTokenBody.js +8 -0
  14. package/dist/generated/model/acknowledgeDeviceAuthTokenBody.js.map +1 -0
  15. package/dist/generated/model/attachAgentMcpServers200.d.ts +13 -0
  16. package/dist/generated/model/attachAgentMcpServers200.d.ts.map +1 -0
  17. package/dist/generated/model/attachAgentMcpServers200.js +2 -0
  18. package/dist/generated/model/attachAgentMcpServers200.js.map +1 -0
  19. package/dist/generated/model/attachAgentMcpServers200Activation.d.ts +14 -0
  20. package/dist/generated/model/attachAgentMcpServers200Activation.d.ts.map +1 -0
  21. package/dist/generated/model/attachAgentMcpServers200Activation.js +8 -0
  22. package/dist/generated/model/attachAgentMcpServers200Activation.js.map +1 -0
  23. package/dist/generated/model/attachAgentMcpServersBody.d.ts +14 -0
  24. package/dist/generated/model/attachAgentMcpServersBody.d.ts.map +1 -0
  25. package/dist/generated/model/attachAgentMcpServersBody.js +8 -0
  26. package/dist/generated/model/attachAgentMcpServersBody.js.map +1 -0
  27. package/dist/generated/model/availableSecretCategory.d.ts +0 -1
  28. package/dist/generated/model/availableSecretCategory.d.ts.map +1 -1
  29. package/dist/generated/model/availableSecretCategory.js +0 -1
  30. package/dist/generated/model/availableSecretCategory.js.map +1 -1
  31. package/dist/generated/model/createOrganizationInviteResponse.d.ts +14 -0
  32. package/dist/generated/model/createOrganizationInviteResponse.d.ts.map +1 -0
  33. package/dist/generated/model/createOrganizationInviteResponse.js +2 -0
  34. package/dist/generated/model/createOrganizationInviteResponse.js.map +1 -0
  35. package/dist/generated/model/index.d.ts +8 -0
  36. package/dist/generated/model/index.d.ts.map +1 -1
  37. package/dist/generated/model/index.js +8 -0
  38. package/dist/generated/model/index.js.map +1 -1
  39. package/dist/generated/model/listAgentsParams.d.ts +4 -0
  40. package/dist/generated/model/listAgentsParams.d.ts.map +1 -1
  41. package/dist/generated/model/listOrgInvitesParams.d.ts +2 -1
  42. package/dist/generated/model/listOrgInvitesParams.d.ts.map +1 -1
  43. package/dist/generated/model/listOrgInvitesParams.js +0 -6
  44. package/dist/generated/model/listOrgInvitesParams.js.map +1 -1
  45. package/dist/generated/model/listOrgInvitesStatus.d.ts +16 -0
  46. package/dist/generated/model/listOrgInvitesStatus.d.ts.map +1 -0
  47. package/dist/generated/model/listOrgInvitesStatus.js +15 -0
  48. package/dist/generated/model/listOrgInvitesStatus.js.map +1 -0
  49. package/dist/generated/model/organizationInvite.d.ts +27 -0
  50. package/dist/generated/model/organizationInvite.d.ts.map +1 -0
  51. package/dist/generated/model/organizationInvite.js +2 -0
  52. package/dist/generated/model/organizationInvite.js.map +1 -0
  53. package/dist/generated/model/organizationInviteStatus.d.ts +15 -0
  54. package/dist/generated/model/organizationInviteStatus.d.ts.map +1 -0
  55. package/dist/generated/model/organizationInviteStatus.js +14 -0
  56. package/dist/generated/model/organizationInviteStatus.js.map +1 -0
  57. package/dist/generated/model/startDeviceAuth201.d.ts +1 -0
  58. package/dist/generated/model/startDeviceAuth201.d.ts.map +1 -1
  59. package/dist/generated/model/startDeviceAuthBody.d.ts +1 -0
  60. package/dist/generated/model/startDeviceAuthBody.d.ts.map +1 -1
  61. package/dist/generated/organizations.d.ts +6 -6
  62. package/dist/generated/organizations.d.ts.map +1 -1
  63. package/dist/generated/organizations.js.map +1 -1
  64. package/dist/react/agent-groups.d.ts +2 -2
  65. package/dist/react/agent-groups.js +2 -2
  66. package/dist/react/agents.d.ts +33 -0
  67. package/dist/react/agents.d.ts.map +1 -1
  68. package/dist/react/agents.js +29 -0
  69. package/dist/react/agents.js.map +1 -1
  70. package/dist/react/auth.d.ts +29 -1
  71. package/dist/react/auth.d.ts.map +1 -1
  72. package/dist/react/auth.js +30 -1
  73. package/dist/react/auth.js.map +1 -1
  74. package/dist/react/model/acknowledgeDeviceAuthTokenBody.d.ts +11 -0
  75. package/dist/react/model/acknowledgeDeviceAuthTokenBody.d.ts.map +1 -0
  76. package/dist/react/model/acknowledgeDeviceAuthTokenBody.js +8 -0
  77. package/dist/react/model/acknowledgeDeviceAuthTokenBody.js.map +1 -0
  78. package/dist/react/model/attachAgentMcpServers200.d.ts +13 -0
  79. package/dist/react/model/attachAgentMcpServers200.d.ts.map +1 -0
  80. package/dist/react/model/attachAgentMcpServers200.js +2 -0
  81. package/dist/react/model/attachAgentMcpServers200.js.map +1 -0
  82. package/dist/react/model/attachAgentMcpServers200Activation.d.ts +14 -0
  83. package/dist/react/model/attachAgentMcpServers200Activation.d.ts.map +1 -0
  84. package/dist/react/model/attachAgentMcpServers200Activation.js +8 -0
  85. package/dist/react/model/attachAgentMcpServers200Activation.js.map +1 -0
  86. package/dist/react/model/attachAgentMcpServersBody.d.ts +14 -0
  87. package/dist/react/model/attachAgentMcpServersBody.d.ts.map +1 -0
  88. package/dist/react/model/attachAgentMcpServersBody.js +8 -0
  89. package/dist/react/model/attachAgentMcpServersBody.js.map +1 -0
  90. package/dist/react/model/availableSecretCategory.d.ts +0 -1
  91. package/dist/react/model/availableSecretCategory.d.ts.map +1 -1
  92. package/dist/react/model/availableSecretCategory.js +0 -1
  93. package/dist/react/model/availableSecretCategory.js.map +1 -1
  94. package/dist/react/model/createOrganizationInviteResponse.d.ts +14 -0
  95. package/dist/react/model/createOrganizationInviteResponse.d.ts.map +1 -0
  96. package/dist/react/model/createOrganizationInviteResponse.js +2 -0
  97. package/dist/react/model/createOrganizationInviteResponse.js.map +1 -0
  98. package/dist/react/model/listAgentsParams.d.ts +4 -0
  99. package/dist/react/model/listAgentsParams.d.ts.map +1 -1
  100. package/dist/react/model/listOrgInvitesParams.d.ts +2 -1
  101. package/dist/react/model/listOrgInvitesParams.d.ts.map +1 -1
  102. package/dist/react/model/listOrgInvitesParams.js +0 -6
  103. package/dist/react/model/listOrgInvitesParams.js.map +1 -1
  104. package/dist/react/model/listOrgInvitesStatus.d.ts +16 -0
  105. package/dist/react/model/listOrgInvitesStatus.d.ts.map +1 -0
  106. package/dist/react/model/listOrgInvitesStatus.js +15 -0
  107. package/dist/react/model/listOrgInvitesStatus.js.map +1 -0
  108. package/dist/react/model/organizationInvite.d.ts +27 -0
  109. package/dist/react/model/organizationInvite.d.ts.map +1 -0
  110. package/dist/react/model/organizationInvite.js +2 -0
  111. package/dist/react/model/organizationInvite.js.map +1 -0
  112. package/dist/react/model/organizationInviteStatus.d.ts +15 -0
  113. package/dist/react/model/organizationInviteStatus.d.ts.map +1 -0
  114. package/dist/react/model/organizationInviteStatus.js +14 -0
  115. package/dist/react/model/organizationInviteStatus.js.map +1 -0
  116. package/dist/react/model/startDeviceAuth201.d.ts +1 -0
  117. package/dist/react/model/startDeviceAuth201.d.ts.map +1 -1
  118. package/dist/react/model/startDeviceAuthBody.d.ts +1 -0
  119. package/dist/react/model/startDeviceAuthBody.d.ts.map +1 -1
  120. package/dist/react/organizations.d.ts +3 -2
  121. package/dist/react/organizations.d.ts.map +1 -1
  122. package/dist/react/organizations.js.map +1 -1
  123. package/package.json +1 -1
  124. package/src/generated/agent-groups.ts +1 -1
  125. package/src/generated/agents.ts +39 -0
  126. package/src/generated/auth.ts +38 -1
  127. package/src/generated/model/acknowledgeDeviceAuthTokenBody.ts +11 -0
  128. package/src/generated/model/attachAgentMcpServers200.ts +13 -0
  129. package/src/generated/model/attachAgentMcpServers200Activation.ts +14 -0
  130. package/src/generated/model/attachAgentMcpServersBody.ts +14 -0
  131. package/src/generated/model/availableSecretCategory.ts +0 -1
  132. package/src/generated/model/createOrganizationInviteResponse.ts +14 -0
  133. package/src/generated/model/index.ts +8 -0
  134. package/src/generated/model/listAgentsParams.ts +4 -0
  135. package/src/generated/model/listOrgInvitesParams.ts +2 -1
  136. package/src/generated/model/listOrgInvitesStatus.ts +18 -0
  137. package/src/generated/model/organizationInvite.ts +27 -0
  138. package/src/generated/model/organizationInviteStatus.ts +17 -0
  139. package/src/generated/model/startDeviceAuth201.ts +1 -0
  140. package/src/generated/model/startDeviceAuthBody.ts +1 -0
  141. package/src/generated/organizations.ts +6 -5
  142. package/src/react/agent-groups.ts +2 -2
  143. package/src/react/agents.ts +73 -0
  144. package/src/react/auth.ts +69 -1
  145. package/src/react/model/acknowledgeDeviceAuthTokenBody.ts +11 -0
  146. package/src/react/model/attachAgentMcpServers200.ts +13 -0
  147. package/src/react/model/attachAgentMcpServers200Activation.ts +14 -0
  148. package/src/react/model/attachAgentMcpServersBody.ts +14 -0
  149. package/src/react/model/availableSecretCategory.ts +0 -1
  150. package/src/react/model/createOrganizationInviteResponse.ts +14 -0
  151. package/src/react/model/listAgentsParams.ts +4 -0
  152. package/src/react/model/listOrgInvitesParams.ts +2 -1
  153. package/src/react/model/listOrgInvitesStatus.ts +18 -0
  154. package/src/react/model/organizationInvite.ts +27 -0
  155. package/src/react/model/organizationInviteStatus.ts +17 -0
  156. package/src/react/model/startDeviceAuth201.ts +1 -0
  157. package/src/react/model/startDeviceAuthBody.ts +1 -0
  158. package/src/react/organizations.ts +6 -2
@@ -0,0 +1,17 @@
1
+ /**
2
+ * Generated by orval v8.18.0 🍺
3
+ * Do not edit manually.
4
+ * Reflex API
5
+ * OpenAPI spec version: 1.0.0
6
+ */
7
+
8
+ export type OrganizationInviteStatus = typeof OrganizationInviteStatus[keyof typeof OrganizationInviteStatus];
9
+
10
+
11
+ export const OrganizationInviteStatus = {
12
+ pending: 'pending',
13
+ consumed: 'consumed',
14
+ revoked: 'revoked',
15
+ expired: 'expired',
16
+ declined: 'declined',
17
+ } as const;
@@ -12,4 +12,5 @@ export type StartDeviceAuth201 = {
12
12
  verificationUriComplete: string;
13
13
  interval: number;
14
14
  expiresIn: number;
15
+ acknowledgementRequired?: boolean;
15
16
  };
@@ -16,4 +16,5 @@ export type StartDeviceAuthBody = {
16
16
  * @maxLength 80
17
17
  */
18
18
  clientName?: string;
19
+ supportsAcknowledgement?: boolean;
19
20
  };
@@ -16,6 +16,7 @@ import type {
16
16
  CreateOrgModelProviderSecretBody,
17
17
  CreateOrgTeamBody,
18
18
  CreateOrganizationBody,
19
+ CreateOrganizationInviteResponse,
19
20
  CreateTeamModelProviderSecretBody,
20
21
  CreateTeamSecretBody,
21
22
  GetIdpConfig200,
@@ -484,12 +485,12 @@ export const listOrgInvites = async (id: string,
484
485
  );}
485
486
 
486
487
 
487
- export type createOrgInviteResponse200 = {
488
- data: void
489
- status: 200
488
+ export type createOrgInviteResponse201 = {
489
+ data: CreateOrganizationInviteResponse
490
+ status: 201
490
491
  }
491
492
 
492
- export type createOrgInviteResponseSuccess = (createOrgInviteResponse200) & {
493
+ export type createOrgInviteResponseSuccess = (createOrgInviteResponse201) & {
493
494
  headers: Headers;
494
495
  };
495
496
  ;
@@ -559,7 +560,7 @@ export const revokeOrgInvite = async (id: string,
559
560
 
560
561
 
561
562
  export type resendOrgInviteResponse200 = {
562
- data: void
563
+ data: CreateOrganizationInviteResponse
563
564
  status: 200
564
565
  }
565
566
 
@@ -322,7 +322,7 @@ export const useDeleteAgentGroup = <TError = unknown,
322
322
  return useMutation(getDeleteAgentGroupMutationOptions(options));
323
323
  }
324
324
  /**
325
- * @summary Add agents to a group.
325
+ * @summary File agents into a group, moving them out of any other group.
326
326
  */
327
327
  export const addAgentGroupMembers = (
328
328
  groupId: string,
@@ -373,7 +373,7 @@ const {mutation: mutationOptions, request: requestOptions} = options ?
373
373
  export type AddAgentGroupMembersMutationError = unknown
374
374
 
375
375
  /**
376
- * @summary Add agents to a group.
376
+ * @summary File agents into a group, moving them out of any other group.
377
377
  */
378
378
  export const useAddAgentGroupMembers = <TError = unknown,
379
379
  TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof addAgentGroupMembers>>, TError,{groupId: string;data: AgentGroupMembersRequest}, TContext>, request?: SecondParameter<typeof apiFetch>}
@@ -50,6 +50,14 @@ import type {
50
50
  ArchiveAllAgentsBody
51
51
  } from './model/archiveAllAgentsBody.js';
52
52
 
53
+ import type {
54
+ AttachAgentMcpServers200
55
+ } from './model/attachAgentMcpServers200.js';
56
+
57
+ import type {
58
+ AttachAgentMcpServersBody
59
+ } from './model/attachAgentMcpServersBody.js';
60
+
53
61
  import type {
54
62
  AxonEvent
55
63
  } from './model/axonEvent.js';
@@ -1021,6 +1029,71 @@ export const useSetAgentMark = <TError = unknown,
1021
1029
  return useMutation(getSetAgentMarkMutationOptions(options));
1022
1030
  }
1023
1031
  /**
1032
+ * Mints live MCP hub tokens for the devbox and registers each server in the agent's native config immediately, then records the ids on the agent's `mcp-servers` attachment. The devbox must be running (409 `agent_devbox_not_running` otherwise); a registration the box reports as failed is a 502 `mcp_registration_failed` with nothing persisted. `activation` reports whether the agent process that is running right now loaded the servers (`active`, usable on its next turn) or whether they wait on disk for its next start (`deferred`) — both are successful attaches. Already-attached ids are skipped, unknown or disabled ids are dropped (compare the returned agent's attachments to detect a partial drop), and the request 404s `mcp_config_not_found` only when no id resolves. Local (stdio) servers are rejected because their subprocess secrets only exist as create-time devbox params.
1033
+ * @summary Attach MCP servers to a running agent's devbox.
1034
+ */
1035
+ export const attachAgentMcpServers = (
1036
+ id: string,
1037
+ attachAgentMcpServersBody: AttachAgentMcpServersBody,
1038
+ options?: SecondParameter<typeof apiFetch>,signal?: AbortSignal
1039
+ ) => {
1040
+
1041
+
1042
+ return apiFetch<AttachAgentMcpServers200>(
1043
+ {url: `/agents/${encodeURIComponent(String(id))}/mcp-servers`, method: 'POST',
1044
+ headers: {'Content-Type': 'application/json', },
1045
+ data: attachAgentMcpServersBody, signal
1046
+ },
1047
+ options);
1048
+ }
1049
+
1050
+
1051
+
1052
+ export const getAttachAgentMcpServersMutationOptions = <TError = unknown,
1053
+ TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof attachAgentMcpServers>>, TError,{id: string;data: AttachAgentMcpServersBody}, TContext>, request?: SecondParameter<typeof apiFetch>}
1054
+ ): UseMutationOptions<Awaited<ReturnType<typeof attachAgentMcpServers>>, TError,{id: string;data: AttachAgentMcpServersBody}, TContext> => {
1055
+
1056
+ const mutationKey = ['attachAgentMcpServers'];
1057
+ const {mutation: mutationOptions, request: requestOptions} = options ?
1058
+ options.mutation && 'mutationKey' in options.mutation && options.mutation.mutationKey ?
1059
+ options
1060
+ : {...options, mutation: {...options.mutation, mutationKey}}
1061
+ : {mutation: { mutationKey, }, request: undefined};
1062
+
1063
+
1064
+
1065
+
1066
+ const mutationFn: MutationFunction<Awaited<ReturnType<typeof attachAgentMcpServers>>, {id: string;data: AttachAgentMcpServersBody}> = (props) => {
1067
+ const {id,data} = props ?? {};
1068
+
1069
+ return attachAgentMcpServers(id,data,requestOptions)
1070
+ }
1071
+
1072
+
1073
+
1074
+
1075
+
1076
+
1077
+ return { mutationFn, ...mutationOptions }}
1078
+
1079
+ export type AttachAgentMcpServersMutationResult = NonNullable<Awaited<ReturnType<typeof attachAgentMcpServers>>>
1080
+ export type AttachAgentMcpServersMutationBody = AttachAgentMcpServersBody
1081
+ export type AttachAgentMcpServersMutationError = unknown
1082
+
1083
+ /**
1084
+ * @summary Attach MCP servers to a running agent's devbox.
1085
+ */
1086
+ export const useAttachAgentMcpServers = <TError = unknown,
1087
+ TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof attachAgentMcpServers>>, TError,{id: string;data: AttachAgentMcpServersBody}, TContext>, request?: SecondParameter<typeof apiFetch>}
1088
+ ): UseMutationResult<
1089
+ Awaited<ReturnType<typeof attachAgentMcpServers>>,
1090
+ TError,
1091
+ {id: string;data: AttachAgentMcpServersBody},
1092
+ TContext
1093
+ > => {
1094
+ return useMutation(getAttachAgentMcpServersMutationOptions(options));
1095
+ }
1096
+ /**
1024
1097
  * Returns 201 with the acknowledging event once the message reaches the agent. With mailbox command delivery, a send whose outcome is still unknown at the bounded wait returns 202 with { status: "pending", commandId }: the message is accepted and durable, delivery just has not been confirmed yet.
1025
1098
  * @summary Send a message to the agent's chat.
1026
1099
  */
package/src/react/auth.ts CHANGED
@@ -18,6 +18,10 @@ import type {
18
18
  UseQueryResult
19
19
  } from '@tanstack/react-query';
20
20
 
21
+ import type {
22
+ AcknowledgeDeviceAuthTokenBody
23
+ } from './model/acknowledgeDeviceAuthTokenBody.js';
24
+
21
25
  import type {
22
26
  DevLogin200
23
27
  } from './model/devLogin200.js';
@@ -165,6 +169,70 @@ export const useDevLogin = <TError = unknown,
165
169
  return useMutation(getDevLoginMutationOptions(options));
166
170
  }
167
171
  /**
172
+ * Idempotently erases the encrypted handoff after the client has durably stored the returned API key.
173
+ * @summary Acknowledge that a device credential was saved.
174
+ */
175
+ export const acknowledgeDeviceAuthToken = (
176
+ acknowledgeDeviceAuthTokenBody: AcknowledgeDeviceAuthTokenBody,
177
+ options?: SecondParameter<typeof apiFetch>,signal?: AbortSignal
178
+ ) => {
179
+
180
+
181
+ return apiFetch<void>(
182
+ {url: `/auth/device/acknowledge`, method: 'POST',
183
+ headers: {'Content-Type': 'application/json', },
184
+ data: acknowledgeDeviceAuthTokenBody, signal
185
+ },
186
+ options);
187
+ }
188
+
189
+
190
+
191
+ export const getAcknowledgeDeviceAuthTokenMutationOptions = <TError = unknown,
192
+ TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof acknowledgeDeviceAuthToken>>, TError,{data: AcknowledgeDeviceAuthTokenBody}, TContext>, request?: SecondParameter<typeof apiFetch>}
193
+ ): UseMutationOptions<Awaited<ReturnType<typeof acknowledgeDeviceAuthToken>>, TError,{data: AcknowledgeDeviceAuthTokenBody}, TContext> => {
194
+
195
+ const mutationKey = ['acknowledgeDeviceAuthToken'];
196
+ const {mutation: mutationOptions, request: requestOptions} = options ?
197
+ options.mutation && 'mutationKey' in options.mutation && options.mutation.mutationKey ?
198
+ options
199
+ : {...options, mutation: {...options.mutation, mutationKey}}
200
+ : {mutation: { mutationKey, }, request: undefined};
201
+
202
+
203
+
204
+
205
+ const mutationFn: MutationFunction<Awaited<ReturnType<typeof acknowledgeDeviceAuthToken>>, {data: AcknowledgeDeviceAuthTokenBody}> = (props) => {
206
+ const {data} = props ?? {};
207
+
208
+ return acknowledgeDeviceAuthToken(data,requestOptions)
209
+ }
210
+
211
+
212
+
213
+
214
+
215
+
216
+ return { mutationFn, ...mutationOptions }}
217
+
218
+ export type AcknowledgeDeviceAuthTokenMutationResult = NonNullable<Awaited<ReturnType<typeof acknowledgeDeviceAuthToken>>>
219
+ export type AcknowledgeDeviceAuthTokenMutationBody = AcknowledgeDeviceAuthTokenBody
220
+ export type AcknowledgeDeviceAuthTokenMutationError = unknown
221
+
222
+ /**
223
+ * @summary Acknowledge that a device credential was saved.
224
+ */
225
+ export const useAcknowledgeDeviceAuthToken = <TError = unknown,
226
+ TContext = unknown>(options?: { mutation?:UseMutationOptions<Awaited<ReturnType<typeof acknowledgeDeviceAuthToken>>, TError,{data: AcknowledgeDeviceAuthTokenBody}, TContext>, request?: SecondParameter<typeof apiFetch>}
227
+ ): UseMutationResult<
228
+ Awaited<ReturnType<typeof acknowledgeDeviceAuthToken>>,
229
+ TError,
230
+ {data: AcknowledgeDeviceAuthTokenBody},
231
+ TContext
232
+ > => {
233
+ return useMutation(getAcknowledgeDeviceAuthTokenMutationOptions(options));
234
+ }
235
+ /**
168
236
  * @summary Start a device sign-in and return the device and user codes.
169
237
  */
170
238
  export const startDeviceAuth = (
@@ -228,7 +296,7 @@ export const useStartDeviceAuth = <TError = unknown,
228
296
  return useMutation(getStartDeviceAuthMutationOptions(options));
229
297
  }
230
298
  /**
231
- * Responds 202 while approval is pending. On approval the minted API key is returned exactly once and the device code is deleted.
299
+ * Responds 202 while approval is pending. On approval the minted API key remains replayable until the client acknowledges durable storage.
232
300
  * @summary Poll a device sign-in for its result.
233
301
  */
234
302
  export const pollDeviceAuthToken = (
@@ -0,0 +1,11 @@
1
+ /**
2
+ * Generated by orval v8.18.0 🍺
3
+ * Do not edit manually.
4
+ * Reflex API
5
+ * OpenAPI spec version: 1.0.0
6
+ */
7
+
8
+ export type AcknowledgeDeviceAuthTokenBody = {
9
+ /** @minLength 1 */
10
+ deviceCode: string;
11
+ };
@@ -0,0 +1,13 @@
1
+ /**
2
+ * Generated by orval v8.18.0 🍺
3
+ * Do not edit manually.
4
+ * Reflex API
5
+ * OpenAPI spec version: 1.0.0
6
+ */
7
+ import type { Agent } from './agent.js';
8
+ import type { AttachAgentMcpServers200Activation } from './attachAgentMcpServers200Activation.js';
9
+
10
+ export type AttachAgentMcpServers200 = {
11
+ agent: Agent;
12
+ activation: AttachAgentMcpServers200Activation;
13
+ };
@@ -0,0 +1,14 @@
1
+ /**
2
+ * Generated by orval v8.18.0 🍺
3
+ * Do not edit manually.
4
+ * Reflex API
5
+ * OpenAPI spec version: 1.0.0
6
+ */
7
+
8
+ export type AttachAgentMcpServers200Activation = {
9
+ state: 'active';
10
+ serverNames: string[];
11
+ } | {
12
+ state: 'deferred';
13
+ reason: 'restart-required' | 'agent-unreachable';
14
+ };
@@ -0,0 +1,14 @@
1
+ /**
2
+ * Generated by orval v8.18.0 🍺
3
+ * Do not edit manually.
4
+ * Reflex API
5
+ * OpenAPI spec version: 1.0.0
6
+ */
7
+
8
+ export type AttachAgentMcpServersBody = {
9
+ /**
10
+ * @minItems 1
11
+ * @items.minLength 1
12
+ */
13
+ mcpServerIds: string[];
14
+ };
@@ -9,7 +9,6 @@ export type AvailableSecretCategory = typeof AvailableSecretCategory[keyof typeo
9
9
 
10
10
 
11
11
  export const AvailableSecretCategory = {
12
- integration: 'integration',
13
12
  custom: 'custom',
14
13
  user: 'user',
15
14
  team: 'team',
@@ -0,0 +1,14 @@
1
+ /**
2
+ * Generated by orval v8.18.0 🍺
3
+ * Do not edit manually.
4
+ * Reflex API
5
+ * OpenAPI spec version: 1.0.0
6
+ */
7
+ import type { OrganizationInvite } from './organizationInvite.js';
8
+
9
+ export interface CreateOrganizationInviteResponse {
10
+ invite: OrganizationInvite;
11
+ redeemUrl: string;
12
+ emailSent: boolean;
13
+ reissued: boolean;
14
+ }
@@ -22,4 +22,8 @@ limit?: number;
22
22
  */
23
23
  cursor?: number;
24
24
  search?: string;
25
+ status?: string;
26
+ mark?: 'any' | 'blocked' | 'in_review' | 'completed';
27
+ groupId?: string;
28
+ labelId?: string;
25
29
  };
@@ -4,7 +4,8 @@
4
4
  * Reflex API
5
5
  * OpenAPI spec version: 1.0.0
6
6
  */
7
+ import type { ListOrgInvitesStatus } from './listOrgInvitesStatus.js';
7
8
 
8
9
  export type ListOrgInvitesParams = {
9
- status?: string;
10
+ status?: ListOrgInvitesStatus;
10
11
  };
@@ -0,0 +1,18 @@
1
+ /**
2
+ * Generated by orval v8.18.0 🍺
3
+ * Do not edit manually.
4
+ * Reflex API
5
+ * OpenAPI spec version: 1.0.0
6
+ */
7
+
8
+ export type ListOrgInvitesStatus = typeof ListOrgInvitesStatus[keyof typeof ListOrgInvitesStatus];
9
+
10
+
11
+ export const ListOrgInvitesStatus = {
12
+ pending: 'pending',
13
+ active: 'active',
14
+ consumed: 'consumed',
15
+ revoked: 'revoked',
16
+ declined: 'declined',
17
+ all: 'all',
18
+ } as const;
@@ -0,0 +1,27 @@
1
+ /**
2
+ * Generated by orval v8.18.0 🍺
3
+ * Do not edit manually.
4
+ * Reflex API
5
+ * OpenAPI spec version: 1.0.0
6
+ */
7
+ import type { OrganizationInviteStatus } from './organizationInviteStatus.js';
8
+
9
+ export interface OrganizationInvite {
10
+ id: string;
11
+ organizationId: string;
12
+ /** @pattern ^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$ */
13
+ email: string;
14
+ invitedByUserId: string;
15
+ reissuedAt: number | null;
16
+ reissuedByUserId: string | null;
17
+ createdAt: number;
18
+ expiresAt: number;
19
+ consumedAt: number | null;
20
+ consumedByUserId: string | null;
21
+ revokedAt: number | null;
22
+ revokedByUserId: string | null;
23
+ declinedAt: number | null;
24
+ declinedByUserId: string | null;
25
+ status: OrganizationInviteStatus;
26
+ tokenLast4: string;
27
+ }
@@ -0,0 +1,17 @@
1
+ /**
2
+ * Generated by orval v8.18.0 🍺
3
+ * Do not edit manually.
4
+ * Reflex API
5
+ * OpenAPI spec version: 1.0.0
6
+ */
7
+
8
+ export type OrganizationInviteStatus = typeof OrganizationInviteStatus[keyof typeof OrganizationInviteStatus];
9
+
10
+
11
+ export const OrganizationInviteStatus = {
12
+ pending: 'pending',
13
+ consumed: 'consumed',
14
+ revoked: 'revoked',
15
+ expired: 'expired',
16
+ declined: 'declined',
17
+ } as const;
@@ -12,4 +12,5 @@ export type StartDeviceAuth201 = {
12
12
  verificationUriComplete: string;
13
13
  interval: number;
14
14
  expiresIn: number;
15
+ acknowledgementRequired?: boolean;
15
16
  };
@@ -16,4 +16,5 @@ export type StartDeviceAuthBody = {
16
16
  * @maxLength 80
17
17
  */
18
18
  clientName?: string;
19
+ supportsAcknowledgement?: boolean;
19
20
  };
@@ -62,6 +62,10 @@ import type {
62
62
  CreateOrganizationBody
63
63
  } from './model/createOrganizationBody.js';
64
64
 
65
+ import type {
66
+ CreateOrganizationInviteResponse
67
+ } from './model/createOrganizationInviteResponse.js';
68
+
65
69
  import type {
66
70
  CreateTeamModelProviderSecretBody
67
71
  } from './model/createTeamModelProviderSecretBody.js';
@@ -988,7 +992,7 @@ export const createOrgInvite = (
988
992
  ) => {
989
993
 
990
994
 
991
- return apiFetch<void>(
995
+ return apiFetch<CreateOrganizationInviteResponse>(
992
996
  {url: `/organizations/${encodeURIComponent(String(id))}/invites`, method: 'POST',
993
997
  headers: {'Content-Type': 'application/json', },
994
998
  data: createOrgInviteBody, signal
@@ -1115,7 +1119,7 @@ export const resendOrgInvite = (
1115
1119
  ) => {
1116
1120
 
1117
1121
 
1118
- return apiFetch<void>(
1122
+ return apiFetch<CreateOrganizationInviteResponse>(
1119
1123
  {url: `/organizations/${encodeURIComponent(String(id))}/invites/${encodeURIComponent(String(inviteId))}/resend`, method: 'POST', signal
1120
1124
  },
1121
1125
  options);