@flowcore/sdk 1.51.0 → 1.53.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 (273) hide show
  1. package/CHANGELOG.md +21 -0
  2. package/README.md +2 -2
  3. package/esm/commands/adapter/reset-adapter.d.ts +2 -2
  4. package/esm/commands/adapter/reset-adapter.d.ts.map +1 -1
  5. package/esm/commands/adapter/reset-adapter.js +1 -1
  6. package/esm/commands/iam/permissions/get-user-permissions.d.ts +1 -1
  7. package/esm/commands/iam/permissions/get-user-permissions.d.ts.map +1 -1
  8. package/esm/commands/iam/permissions/get-user-permissions.js +2 -1
  9. package/esm/commands/iam/policies/create-policy.d.ts +1 -1
  10. package/esm/commands/iam/policies/create-policy.d.ts.map +1 -1
  11. package/esm/commands/iam/policies/create-policy.js +2 -1
  12. package/esm/commands/iam/policies/get-policy.d.ts +1 -1
  13. package/esm/commands/iam/policies/get-policy.d.ts.map +1 -1
  14. package/esm/commands/iam/policies/get-policy.js +2 -1
  15. package/esm/commands/iam/policies/id/archive-policy.d.ts +1 -1
  16. package/esm/commands/iam/policies/id/archive-policy.d.ts.map +1 -1
  17. package/esm/commands/iam/policies/id/archive-policy.js +2 -1
  18. package/esm/commands/iam/policies/id/get-policy.d.ts +1 -1
  19. package/esm/commands/iam/policies/id/get-policy.d.ts.map +1 -1
  20. package/esm/commands/iam/policies/id/get-policy.js +2 -1
  21. package/esm/commands/iam/policies/id/update-policy.d.ts +1 -1
  22. package/esm/commands/iam/policies/id/update-policy.d.ts.map +1 -1
  23. package/esm/commands/iam/policies/id/update-policy.js +2 -1
  24. package/esm/commands/iam/policy-associations/get-key-policies.d.ts +1 -1
  25. package/esm/commands/iam/policy-associations/get-key-policies.d.ts.map +1 -1
  26. package/esm/commands/iam/policy-associations/get-key-policies.js +2 -1
  27. package/esm/commands/iam/policy-associations/get-organization-policies.d.ts +1 -1
  28. package/esm/commands/iam/policy-associations/get-organization-policies.d.ts.map +1 -1
  29. package/esm/commands/iam/policy-associations/get-organization-policies.js +2 -1
  30. package/esm/commands/iam/policy-associations/get-policy-associations.d.ts +1 -1
  31. package/esm/commands/iam/policy-associations/get-policy-associations.d.ts.map +1 -1
  32. package/esm/commands/iam/policy-associations/get-policy-associations.js +2 -1
  33. package/esm/commands/iam/policy-associations/get-role-policies.d.ts +1 -1
  34. package/esm/commands/iam/policy-associations/get-role-policies.d.ts.map +1 -1
  35. package/esm/commands/iam/policy-associations/get-role-policies.js +2 -1
  36. package/esm/commands/iam/policy-associations/get-user-policies.d.ts +1 -1
  37. package/esm/commands/iam/policy-associations/get-user-policies.d.ts.map +1 -1
  38. package/esm/commands/iam/policy-associations/get-user-policies.js +2 -1
  39. package/esm/commands/iam/policy-associations/link-key-policy.d.ts +1 -1
  40. package/esm/commands/iam/policy-associations/link-key-policy.d.ts.map +1 -1
  41. package/esm/commands/iam/policy-associations/link-key-policy.js +2 -1
  42. package/esm/commands/iam/policy-associations/link-role-policy.d.ts +1 -1
  43. package/esm/commands/iam/policy-associations/link-role-policy.d.ts.map +1 -1
  44. package/esm/commands/iam/policy-associations/link-role-policy.js +2 -1
  45. package/esm/commands/iam/policy-associations/link-user-policy.d.ts +1 -1
  46. package/esm/commands/iam/policy-associations/link-user-policy.d.ts.map +1 -1
  47. package/esm/commands/iam/policy-associations/link-user-policy.js +2 -1
  48. package/esm/commands/iam/policy-associations/unlink-key-policy.d.ts +1 -1
  49. package/esm/commands/iam/policy-associations/unlink-key-policy.d.ts.map +1 -1
  50. package/esm/commands/iam/policy-associations/unlink-key-policy.js +2 -1
  51. package/esm/commands/iam/policy-associations/unlink-role-policy.d.ts +1 -1
  52. package/esm/commands/iam/policy-associations/unlink-role-policy.d.ts.map +1 -1
  53. package/esm/commands/iam/policy-associations/unlink-role-policy.js +2 -1
  54. package/esm/commands/iam/policy-associations/unlink-user-policy.d.ts +1 -1
  55. package/esm/commands/iam/policy-associations/unlink-user-policy.d.ts.map +1 -1
  56. package/esm/commands/iam/policy-associations/unlink-user-policy.js +2 -1
  57. package/esm/commands/iam/role-associations/get-key-roles.d.ts +1 -1
  58. package/esm/commands/iam/role-associations/get-key-roles.d.ts.map +1 -1
  59. package/esm/commands/iam/role-associations/get-key-roles.js +2 -1
  60. package/esm/commands/iam/role-associations/get-organization-roles.d.ts +1 -1
  61. package/esm/commands/iam/role-associations/get-organization-roles.d.ts.map +1 -1
  62. package/esm/commands/iam/role-associations/get-organization-roles.js +2 -1
  63. package/esm/commands/iam/role-associations/get-role-associations.d.ts +1 -1
  64. package/esm/commands/iam/role-associations/get-role-associations.d.ts.map +1 -1
  65. package/esm/commands/iam/role-associations/get-role-associations.js +2 -1
  66. package/esm/commands/iam/role-associations/get-user-roles.d.ts +1 -1
  67. package/esm/commands/iam/role-associations/get-user-roles.d.ts.map +1 -1
  68. package/esm/commands/iam/role-associations/get-user-roles.js +2 -1
  69. package/esm/commands/iam/role-associations/link-key-role.d.ts +1 -1
  70. package/esm/commands/iam/role-associations/link-key-role.d.ts.map +1 -1
  71. package/esm/commands/iam/role-associations/link-key-role.js +2 -1
  72. package/esm/commands/iam/role-associations/link-user-role.d.ts +1 -1
  73. package/esm/commands/iam/role-associations/link-user-role.d.ts.map +1 -1
  74. package/esm/commands/iam/role-associations/link-user-role.js +2 -1
  75. package/esm/commands/iam/role-associations/unlink-key-role.d.ts +1 -1
  76. package/esm/commands/iam/role-associations/unlink-key-role.d.ts.map +1 -1
  77. package/esm/commands/iam/role-associations/unlink-key-role.js +2 -1
  78. package/esm/commands/iam/role-associations/unlink-user-role.d.ts +1 -1
  79. package/esm/commands/iam/role-associations/unlink-user-role.d.ts.map +1 -1
  80. package/esm/commands/iam/role-associations/unlink-user-role.js +2 -1
  81. package/esm/commands/iam/roles/create-role.d.ts +1 -1
  82. package/esm/commands/iam/roles/create-role.d.ts.map +1 -1
  83. package/esm/commands/iam/roles/create-role.js +2 -1
  84. package/esm/commands/iam/roles/get-roles.d.ts +1 -1
  85. package/esm/commands/iam/roles/get-roles.d.ts.map +1 -1
  86. package/esm/commands/iam/roles/get-roles.js +2 -1
  87. package/esm/commands/iam/roles/id/archive-role.d.ts +1 -1
  88. package/esm/commands/iam/roles/id/archive-role.d.ts.map +1 -1
  89. package/esm/commands/iam/roles/id/archive-role.js +2 -1
  90. package/esm/commands/iam/roles/id/get-role.d.ts +1 -1
  91. package/esm/commands/iam/roles/id/get-role.d.ts.map +1 -1
  92. package/esm/commands/iam/roles/id/get-role.js +2 -1
  93. package/esm/commands/iam/roles/id/update-role.d.ts +1 -1
  94. package/esm/commands/iam/roles/id/update-role.d.ts.map +1 -1
  95. package/esm/commands/iam/roles/id/update-role.js +2 -1
  96. package/esm/commands/iam/tenant-iam-audit/get-audit-for-tenant.d.ts +1 -1
  97. package/esm/commands/iam/tenant-iam-audit/get-audit-for-tenant.d.ts.map +1 -1
  98. package/esm/commands/iam/tenant-iam-audit/get-audit-for-tenant.js +2 -1
  99. package/esm/commands/iam/validate/validate-key.d.ts +1 -1
  100. package/esm/commands/iam/validate/validate-key.d.ts.map +1 -1
  101. package/esm/commands/iam/validate/validate-key.js +2 -1
  102. package/esm/commands/iam/validate/validate-user.d.ts +1 -1
  103. package/esm/commands/iam/validate/validate-user.d.ts.map +1 -1
  104. package/esm/commands/iam/validate/validate-user.js +2 -1
  105. package/esm/commands/index.d.ts +2 -0
  106. package/esm/commands/index.d.ts.map +1 -1
  107. package/esm/commands/index.js +2 -0
  108. package/esm/commands/secret/secret.create.d.ts +23 -8
  109. package/esm/commands/secret/secret.create.d.ts.map +1 -1
  110. package/esm/commands/secret/secret.create.js +27 -39
  111. package/esm/commands/secret/secret.delete.d.ts +20 -8
  112. package/esm/commands/secret/secret.delete.d.ts.map +1 -1
  113. package/esm/commands/secret/secret.delete.js +27 -41
  114. package/esm/commands/secret/secret.edit.d.ts +45 -0
  115. package/esm/commands/secret/secret.edit.d.ts.map +1 -0
  116. package/esm/commands/secret/secret.edit.js +40 -0
  117. package/esm/commands/secret/secret.list.d.ts +20 -7
  118. package/esm/commands/secret/secret.list.d.ts.map +1 -1
  119. package/esm/commands/secret/secret.list.js +27 -41
  120. package/esm/commands/variable/variable.create.d.ts +21 -7
  121. package/esm/commands/variable/variable.create.d.ts.map +1 -1
  122. package/esm/commands/variable/variable.create.js +26 -44
  123. package/esm/commands/variable/variable.delete.d.ts +20 -8
  124. package/esm/commands/variable/variable.delete.d.ts.map +1 -1
  125. package/esm/commands/variable/variable.delete.js +27 -44
  126. package/esm/commands/variable/variable.edit.d.ts +45 -0
  127. package/esm/commands/variable/variable.edit.d.ts.map +1 -0
  128. package/esm/commands/variable/variable.edit.js +40 -0
  129. package/esm/commands/variable/variable.list.d.ts +19 -7
  130. package/esm/commands/variable/variable.list.d.ts.map +1 -1
  131. package/esm/commands/variable/variable.list.js +27 -47
  132. package/esm/contracts/secret.d.ts +16 -0
  133. package/esm/contracts/secret.d.ts.map +1 -0
  134. package/esm/contracts/secret.js +11 -0
  135. package/esm/contracts/variable.d.ts +5 -1
  136. package/esm/contracts/variable.d.ts.map +1 -1
  137. package/esm/contracts/variable.js +4 -0
  138. package/package.json +1 -1
  139. package/script/commands/adapter/reset-adapter.d.ts +2 -2
  140. package/script/commands/adapter/reset-adapter.d.ts.map +1 -1
  141. package/script/commands/adapter/reset-adapter.js +2 -2
  142. package/script/commands/iam/permissions/get-user-permissions.d.ts +1 -1
  143. package/script/commands/iam/permissions/get-user-permissions.d.ts.map +1 -1
  144. package/script/commands/iam/permissions/get-user-permissions.js +4 -3
  145. package/script/commands/iam/policies/create-policy.d.ts +1 -1
  146. package/script/commands/iam/policies/create-policy.d.ts.map +1 -1
  147. package/script/commands/iam/policies/create-policy.js +4 -3
  148. package/script/commands/iam/policies/get-policy.d.ts +1 -1
  149. package/script/commands/iam/policies/get-policy.d.ts.map +1 -1
  150. package/script/commands/iam/policies/get-policy.js +4 -3
  151. package/script/commands/iam/policies/id/archive-policy.d.ts +1 -1
  152. package/script/commands/iam/policies/id/archive-policy.d.ts.map +1 -1
  153. package/script/commands/iam/policies/id/archive-policy.js +4 -3
  154. package/script/commands/iam/policies/id/get-policy.d.ts +1 -1
  155. package/script/commands/iam/policies/id/get-policy.d.ts.map +1 -1
  156. package/script/commands/iam/policies/id/get-policy.js +4 -3
  157. package/script/commands/iam/policies/id/update-policy.d.ts +1 -1
  158. package/script/commands/iam/policies/id/update-policy.d.ts.map +1 -1
  159. package/script/commands/iam/policies/id/update-policy.js +4 -3
  160. package/script/commands/iam/policy-associations/get-key-policies.d.ts +1 -1
  161. package/script/commands/iam/policy-associations/get-key-policies.d.ts.map +1 -1
  162. package/script/commands/iam/policy-associations/get-key-policies.js +5 -4
  163. package/script/commands/iam/policy-associations/get-organization-policies.d.ts +1 -1
  164. package/script/commands/iam/policy-associations/get-organization-policies.d.ts.map +1 -1
  165. package/script/commands/iam/policy-associations/get-organization-policies.js +5 -4
  166. package/script/commands/iam/policy-associations/get-policy-associations.d.ts +1 -1
  167. package/script/commands/iam/policy-associations/get-policy-associations.d.ts.map +1 -1
  168. package/script/commands/iam/policy-associations/get-policy-associations.js +7 -6
  169. package/script/commands/iam/policy-associations/get-role-policies.d.ts +1 -1
  170. package/script/commands/iam/policy-associations/get-role-policies.d.ts.map +1 -1
  171. package/script/commands/iam/policy-associations/get-role-policies.js +5 -4
  172. package/script/commands/iam/policy-associations/get-user-policies.d.ts +1 -1
  173. package/script/commands/iam/policy-associations/get-user-policies.d.ts.map +1 -1
  174. package/script/commands/iam/policy-associations/get-user-policies.js +4 -3
  175. package/script/commands/iam/policy-associations/link-key-policy.d.ts +1 -1
  176. package/script/commands/iam/policy-associations/link-key-policy.d.ts.map +1 -1
  177. package/script/commands/iam/policy-associations/link-key-policy.js +4 -3
  178. package/script/commands/iam/policy-associations/link-role-policy.d.ts +1 -1
  179. package/script/commands/iam/policy-associations/link-role-policy.d.ts.map +1 -1
  180. package/script/commands/iam/policy-associations/link-role-policy.js +4 -3
  181. package/script/commands/iam/policy-associations/link-user-policy.d.ts +1 -1
  182. package/script/commands/iam/policy-associations/link-user-policy.d.ts.map +1 -1
  183. package/script/commands/iam/policy-associations/link-user-policy.js +4 -3
  184. package/script/commands/iam/policy-associations/unlink-key-policy.d.ts +1 -1
  185. package/script/commands/iam/policy-associations/unlink-key-policy.d.ts.map +1 -1
  186. package/script/commands/iam/policy-associations/unlink-key-policy.js +4 -3
  187. package/script/commands/iam/policy-associations/unlink-role-policy.d.ts +1 -1
  188. package/script/commands/iam/policy-associations/unlink-role-policy.d.ts.map +1 -1
  189. package/script/commands/iam/policy-associations/unlink-role-policy.js +4 -3
  190. package/script/commands/iam/policy-associations/unlink-user-policy.d.ts +1 -1
  191. package/script/commands/iam/policy-associations/unlink-user-policy.d.ts.map +1 -1
  192. package/script/commands/iam/policy-associations/unlink-user-policy.js +4 -3
  193. package/script/commands/iam/role-associations/get-key-roles.d.ts +1 -1
  194. package/script/commands/iam/role-associations/get-key-roles.d.ts.map +1 -1
  195. package/script/commands/iam/role-associations/get-key-roles.js +4 -3
  196. package/script/commands/iam/role-associations/get-organization-roles.d.ts +1 -1
  197. package/script/commands/iam/role-associations/get-organization-roles.d.ts.map +1 -1
  198. package/script/commands/iam/role-associations/get-organization-roles.js +4 -3
  199. package/script/commands/iam/role-associations/get-role-associations.d.ts +1 -1
  200. package/script/commands/iam/role-associations/get-role-associations.d.ts.map +1 -1
  201. package/script/commands/iam/role-associations/get-role-associations.js +4 -3
  202. package/script/commands/iam/role-associations/get-user-roles.d.ts +1 -1
  203. package/script/commands/iam/role-associations/get-user-roles.d.ts.map +1 -1
  204. package/script/commands/iam/role-associations/get-user-roles.js +4 -3
  205. package/script/commands/iam/role-associations/link-key-role.d.ts +1 -1
  206. package/script/commands/iam/role-associations/link-key-role.d.ts.map +1 -1
  207. package/script/commands/iam/role-associations/link-key-role.js +4 -3
  208. package/script/commands/iam/role-associations/link-user-role.d.ts +1 -1
  209. package/script/commands/iam/role-associations/link-user-role.d.ts.map +1 -1
  210. package/script/commands/iam/role-associations/link-user-role.js +4 -3
  211. package/script/commands/iam/role-associations/unlink-key-role.d.ts +1 -1
  212. package/script/commands/iam/role-associations/unlink-key-role.d.ts.map +1 -1
  213. package/script/commands/iam/role-associations/unlink-key-role.js +4 -3
  214. package/script/commands/iam/role-associations/unlink-user-role.d.ts +1 -1
  215. package/script/commands/iam/role-associations/unlink-user-role.d.ts.map +1 -1
  216. package/script/commands/iam/role-associations/unlink-user-role.js +4 -3
  217. package/script/commands/iam/roles/create-role.d.ts +1 -1
  218. package/script/commands/iam/roles/create-role.d.ts.map +1 -1
  219. package/script/commands/iam/roles/create-role.js +4 -3
  220. package/script/commands/iam/roles/get-roles.d.ts +1 -1
  221. package/script/commands/iam/roles/get-roles.d.ts.map +1 -1
  222. package/script/commands/iam/roles/get-roles.js +4 -3
  223. package/script/commands/iam/roles/id/archive-role.d.ts +1 -1
  224. package/script/commands/iam/roles/id/archive-role.d.ts.map +1 -1
  225. package/script/commands/iam/roles/id/archive-role.js +4 -3
  226. package/script/commands/iam/roles/id/get-role.d.ts +1 -1
  227. package/script/commands/iam/roles/id/get-role.d.ts.map +1 -1
  228. package/script/commands/iam/roles/id/get-role.js +4 -3
  229. package/script/commands/iam/roles/id/update-role.d.ts +1 -1
  230. package/script/commands/iam/roles/id/update-role.d.ts.map +1 -1
  231. package/script/commands/iam/roles/id/update-role.js +4 -3
  232. package/script/commands/iam/tenant-iam-audit/get-audit-for-tenant.d.ts +1 -1
  233. package/script/commands/iam/tenant-iam-audit/get-audit-for-tenant.d.ts.map +1 -1
  234. package/script/commands/iam/tenant-iam-audit/get-audit-for-tenant.js +4 -3
  235. package/script/commands/iam/validate/validate-key.d.ts +1 -1
  236. package/script/commands/iam/validate/validate-key.d.ts.map +1 -1
  237. package/script/commands/iam/validate/validate-key.js +4 -3
  238. package/script/commands/iam/validate/validate-user.d.ts +1 -1
  239. package/script/commands/iam/validate/validate-user.d.ts.map +1 -1
  240. package/script/commands/iam/validate/validate-user.js +4 -3
  241. package/script/commands/index.d.ts +2 -0
  242. package/script/commands/index.d.ts.map +1 -1
  243. package/script/commands/index.js +2 -0
  244. package/script/commands/secret/secret.create.d.ts +23 -8
  245. package/script/commands/secret/secret.create.d.ts.map +1 -1
  246. package/script/commands/secret/secret.create.js +27 -39
  247. package/script/commands/secret/secret.delete.d.ts +20 -8
  248. package/script/commands/secret/secret.delete.d.ts.map +1 -1
  249. package/script/commands/secret/secret.delete.js +27 -41
  250. package/script/commands/secret/secret.edit.d.ts +45 -0
  251. package/script/commands/secret/secret.edit.d.ts.map +1 -0
  252. package/script/commands/secret/secret.edit.js +44 -0
  253. package/script/commands/secret/secret.list.d.ts +20 -7
  254. package/script/commands/secret/secret.list.d.ts.map +1 -1
  255. package/script/commands/secret/secret.list.js +27 -41
  256. package/script/commands/variable/variable.create.d.ts +21 -7
  257. package/script/commands/variable/variable.create.d.ts.map +1 -1
  258. package/script/commands/variable/variable.create.js +26 -44
  259. package/script/commands/variable/variable.delete.d.ts +20 -8
  260. package/script/commands/variable/variable.delete.d.ts.map +1 -1
  261. package/script/commands/variable/variable.delete.js +27 -44
  262. package/script/commands/variable/variable.edit.d.ts +45 -0
  263. package/script/commands/variable/variable.edit.d.ts.map +1 -0
  264. package/script/commands/variable/variable.edit.js +44 -0
  265. package/script/commands/variable/variable.list.d.ts +19 -7
  266. package/script/commands/variable/variable.list.d.ts.map +1 -1
  267. package/script/commands/variable/variable.list.js +27 -47
  268. package/script/contracts/secret.d.ts +16 -0
  269. package/script/contracts/secret.d.ts.map +1 -0
  270. package/script/contracts/secret.js +14 -0
  271. package/script/contracts/variable.d.ts +5 -1
  272. package/script/contracts/variable.d.ts.map +1 -1
  273. package/script/contracts/variable.js +4 -0
@@ -0,0 +1,45 @@
1
+ import { Command } from "../../common/command.js";
2
+ import { type Variable } from "../../contracts/variable.js";
3
+ /**
4
+ * The input for the variable edit command
5
+ */
6
+ export interface VariableEditInput {
7
+ /** The tenant id */
8
+ tenantId: string;
9
+ /** The key of the variable */
10
+ key: string;
11
+ /** The value of the variable */
12
+ value?: string;
13
+ /** The description of the variable */
14
+ description?: string;
15
+ }
16
+ /**
17
+ * Edit a variable
18
+ */
19
+ export declare class VariableEditCommand extends Command<VariableEditInput, Variable> {
20
+ /**
21
+ * Whether the command should retry on failure
22
+ */
23
+ protected retryOnFailure: boolean;
24
+ /**
25
+ * Get the method
26
+ */
27
+ protected getMethod(): string;
28
+ /**
29
+ * Get the base url
30
+ */
31
+ protected getBaseUrl(): string;
32
+ /**
33
+ * Get the path
34
+ */
35
+ protected getPath(): string;
36
+ /**
37
+ * The allowed modes for the command
38
+ */
39
+ protected allowedModes: ("apiKey" | "bearer")[];
40
+ /**
41
+ * Parse the response
42
+ */
43
+ protected parseResponse(rawResponse: unknown): Variable;
44
+ }
45
+ //# sourceMappingURL=variable.edit.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"variable.edit.d.ts","sourceRoot":"","sources":["../../../src/commands/variable/variable.edit.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,yBAAyB,CAAA;AAEjD,OAAO,EAAE,KAAK,QAAQ,EAAkB,MAAM,6BAA6B,CAAA;AAE3E;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC,oBAAoB;IACpB,QAAQ,EAAE,MAAM,CAAA;IAChB,8BAA8B;IAC9B,GAAG,EAAE,MAAM,CAAA;IACX,gCAAgC;IAChC,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,sCAAsC;IACtC,WAAW,CAAC,EAAE,MAAM,CAAA;CACrB;AAED;;GAEG;AACH,qBAAa,mBAAoB,SAAQ,OAAO,CAAC,iBAAiB,EAAE,QAAQ,CAAC;IAC3E;;OAEG;IACH,UAAmB,cAAc,EAAE,OAAO,CAAQ;IAElD;;OAEG;cACgB,SAAS,IAAI,MAAM;IAGtC;;OAEG;cACgB,UAAU,IAAI,MAAM;IAIvC;;OAEG;cACgB,OAAO,IAAI,MAAM;IAIpC;;OAEG;IACH,UAAmB,YAAY,EAAE,CAAC,QAAQ,GAAG,QAAQ,CAAC,EAAE,CAAa;IAErE;;OAEG;cACgB,aAAa,CAAC,WAAW,EAAE,OAAO,GAAG,QAAQ;CAGjE"}
@@ -0,0 +1,44 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.VariableEditCommand = void 0;
4
+ const command_js_1 = require("../../common/command.js");
5
+ const parse_response_helper_js_1 = require("../../utils/parse-response-helper.js");
6
+ const variable_js_1 = require("../../contracts/variable.js");
7
+ /**
8
+ * Edit a variable
9
+ */
10
+ class VariableEditCommand extends command_js_1.Command {
11
+ /**
12
+ * Whether the command should retry on failure
13
+ */
14
+ retryOnFailure = false;
15
+ /**
16
+ * Get the method
17
+ */
18
+ getMethod() {
19
+ return "PATCH";
20
+ }
21
+ /**
22
+ * Get the base url
23
+ */
24
+ getBaseUrl() {
25
+ return "https://tenant-store.api.flowcore.io";
26
+ }
27
+ /**
28
+ * Get the path
29
+ */
30
+ getPath() {
31
+ return `/api/v1/tenants/${this.input.tenantId}/variables/${this.input.key}`;
32
+ }
33
+ /**
34
+ * The allowed modes for the command
35
+ */
36
+ allowedModes = ["bearer"];
37
+ /**
38
+ * Parse the response
39
+ */
40
+ parseResponse(rawResponse) {
41
+ return (0, parse_response_helper_js_1.parseResponseHelper)(variable_js_1.VariableSchema, rawResponse);
42
+ }
43
+ }
44
+ exports.VariableEditCommand = VariableEditCommand;
@@ -1,5 +1,5 @@
1
- import { GraphQlCommand } from "../../common/command-graphql.js";
2
- import type { Variable } from "../../contracts/variable.js";
1
+ import { Command } from "../../common/command.js";
2
+ import { type Variable } from "../../contracts/variable.js";
3
3
  /**
4
4
  * The input for the variable list command
5
5
  */
@@ -10,7 +10,23 @@ export interface VariableListInput {
10
10
  /**
11
11
  * List variables
12
12
  */
13
- export declare class VariableListCommand extends GraphQlCommand<VariableListInput, Variable[]> {
13
+ export declare class VariableListCommand extends Command<VariableListInput, Variable[]> {
14
+ /**
15
+ * Whether the command should retry on failure
16
+ */
17
+ protected retryOnFailure: boolean;
18
+ /**
19
+ * Get the method
20
+ */
21
+ protected getMethod(): string;
22
+ /**
23
+ * Get the base url
24
+ */
25
+ protected getBaseUrl(): string;
26
+ /**
27
+ * Get the path
28
+ */
29
+ protected getPath(): string;
14
30
  /**
15
31
  * The allowed modes for the command
16
32
  */
@@ -19,9 +35,5 @@ export declare class VariableListCommand extends GraphQlCommand<VariableListInpu
19
35
  * Parse the response
20
36
  */
21
37
  protected parseResponse(rawResponse: unknown): Variable[];
22
- /**
23
- * Get the body for the request
24
- */
25
- protected getBody(): Record<string, unknown>;
26
38
  }
27
39
  //# sourceMappingURL=variable.list.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"variable.list.d.ts","sourceRoot":"","sources":["../../../src/commands/variable/variable.list.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,cAAc,EAAE,MAAM,iCAAiC,CAAA;AAEhE,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,6BAA6B,CAAA;AAG3D;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC,oBAAoB;IACpB,QAAQ,EAAE,MAAM,CAAA;CACjB;AAkCD;;GAEG;AACH,qBAAa,mBAAoB,SAAQ,cAAc,CAAC,iBAAiB,EAAE,QAAQ,EAAE,CAAC;IACpF;;OAEG;IACH,UAAmB,YAAY,EAAE,CAAC,QAAQ,GAAG,QAAQ,CAAC,EAAE,CAAa;IAErE;;OAEG;cACgB,aAAa,CAAC,WAAW,EAAE,OAAO,GAAG,QAAQ,EAAE;IAWlE;;OAEG;cACgB,OAAO,IAAI,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC;CAMtD"}
1
+ {"version":3,"file":"variable.list.d.ts","sourceRoot":"","sources":["../../../src/commands/variable/variable.list.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,yBAAyB,CAAA;AAEjD,OAAO,EAAE,KAAK,QAAQ,EAAkB,MAAM,6BAA6B,CAAA;AAG3E;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC,oBAAoB;IACpB,QAAQ,EAAE,MAAM,CAAA;CACjB;AAED;;GAEG;AACH,qBAAa,mBAAoB,SAAQ,OAAO,CAAC,iBAAiB,EAAE,QAAQ,EAAE,CAAC;IAC7E;;OAEG;IACH,UAAmB,cAAc,EAAE,OAAO,CAAQ;IAElD;;OAEG;cACgB,SAAS,IAAI,MAAM;IAGtC;;OAEG;cACgB,UAAU,IAAI,MAAM;IAIvC;;OAEG;cACgB,OAAO,IAAI,MAAM;IAIpC;;OAEG;IACH,UAAmB,YAAY,EAAE,CAAC,QAAQ,GAAG,QAAQ,CAAC,EAAE,CAAa;IAErE;;OAEG;cACgB,aAAa,CAAC,WAAW,EAAE,OAAO,GAAG,QAAQ,EAAE;CAGnE"}
@@ -1,40 +1,36 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.VariableListCommand = void 0;
4
- const typebox_1 = require("@sinclair/typebox");
5
- const command_graphql_js_1 = require("../../common/command-graphql.js");
4
+ const command_js_1 = require("../../common/command.js");
6
5
  const parse_response_helper_js_1 = require("../../utils/parse-response-helper.js");
7
- const command_error_js_1 = require("../../exceptions/command-error.js");
8
- const graphQlQueryById = `
9
- query FLOWCORE_SDK_VARIABLE_LIST($tenantId: ID!) {
10
- organization(search: {id: $tenantId}) {
11
- variables {
12
- key
13
- value
14
- }
15
- }
16
- }
17
- `;
18
- const responseSchema = typebox_1.Type.Object({
19
- errors: typebox_1.Type.Optional(typebox_1.Type.Array(typebox_1.Type.Object({
20
- message: typebox_1.Type.String(),
21
- }))),
22
- data: typebox_1.Type.Union([
23
- typebox_1.Type.Object({
24
- organization: typebox_1.Type.Object({
25
- variables: typebox_1.Type.Array(typebox_1.Type.Object({
26
- key: typebox_1.Type.String(),
27
- value: typebox_1.Type.String(),
28
- })),
29
- }),
30
- }),
31
- typebox_1.Type.Null(),
32
- ]),
33
- });
6
+ const variable_js_1 = require("../../contracts/variable.js");
7
+ const typebox_1 = require("@sinclair/typebox");
34
8
  /**
35
9
  * List variables
36
10
  */
37
- class VariableListCommand extends command_graphql_js_1.GraphQlCommand {
11
+ class VariableListCommand extends command_js_1.Command {
12
+ /**
13
+ * Whether the command should retry on failure
14
+ */
15
+ retryOnFailure = false;
16
+ /**
17
+ * Get the method
18
+ */
19
+ getMethod() {
20
+ return "GET";
21
+ }
22
+ /**
23
+ * Get the base url
24
+ */
25
+ getBaseUrl() {
26
+ return "https://tenant-store.api.flowcore.io";
27
+ }
28
+ /**
29
+ * Get the path
30
+ */
31
+ getPath() {
32
+ return `/api/v1/tenants/${this.input.tenantId}/variables`;
33
+ }
38
34
  /**
39
35
  * The allowed modes for the command
40
36
  */
@@ -43,23 +39,7 @@ class VariableListCommand extends command_graphql_js_1.GraphQlCommand {
43
39
  * Parse the response
44
40
  */
45
41
  parseResponse(rawResponse) {
46
- const response = (0, parse_response_helper_js_1.parseResponseHelper)(responseSchema, rawResponse);
47
- if (response.errors) {
48
- throw new command_error_js_1.CommandError(this.constructor.name, response.errors[0].message);
49
- }
50
- if (!response.data) {
51
- throw new command_error_js_1.CommandError(this.constructor.name, "Failed to list variables");
52
- }
53
- return response.data.organization.variables;
54
- }
55
- /**
56
- * Get the body for the request
57
- */
58
- getBody() {
59
- return {
60
- query: graphQlQueryById,
61
- variables: this.input,
62
- };
42
+ return (0, parse_response_helper_js_1.parseResponseHelper)(typebox_1.Type.Array(variable_js_1.VariableSchema), rawResponse);
63
43
  }
64
44
  }
65
45
  exports.VariableListCommand = VariableListCommand;
@@ -0,0 +1,16 @@
1
+ import { type Static, type TNull, type TObject, type TString, type TUnion } from "@sinclair/typebox";
2
+ /**
3
+ * The schema for a secret
4
+ */
5
+ export declare const SecretSchema: TObject<{
6
+ tenantId: TString;
7
+ key: TString;
8
+ description: TString;
9
+ createdAt: TString;
10
+ updatedAt: TUnion<[TString, TNull]>;
11
+ }>;
12
+ /**
13
+ * The type for a secret
14
+ */
15
+ export type Secret = Static<typeof SecretSchema>;
16
+ //# sourceMappingURL=secret.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"secret.d.ts","sourceRoot":"","sources":["../../src/contracts/secret.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,MAAM,EAAE,KAAK,KAAK,EAAE,KAAK,OAAO,EAAE,KAAK,OAAO,EAAE,KAAK,MAAM,EAAQ,MAAM,mBAAmB,CAAA;AAE1G;;GAEG;AACH,eAAO,MAAM,YAAY,EAAE,OAAO,CAAC;IACjC,QAAQ,EAAE,OAAO,CAAA;IACjB,GAAG,EAAE,OAAO,CAAA;IACZ,WAAW,EAAE,OAAO,CAAA;IACpB,SAAS,EAAE,OAAO,CAAA;IAClB,SAAS,EAAE,MAAM,CAAC,CAAC,OAAO,EAAE,KAAK,CAAC,CAAC,CAAA;CACpC,CAMC,CAAA;AAEF;;GAEG;AACH,MAAM,MAAM,MAAM,GAAG,MAAM,CAAC,OAAO,YAAY,CAAC,CAAA"}
@@ -0,0 +1,14 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.SecretSchema = void 0;
4
+ const typebox_1 = require("@sinclair/typebox");
5
+ /**
6
+ * The schema for a secret
7
+ */
8
+ exports.SecretSchema = typebox_1.Type.Object({
9
+ tenantId: typebox_1.Type.String(),
10
+ key: typebox_1.Type.String(),
11
+ description: typebox_1.Type.String(),
12
+ createdAt: typebox_1.Type.String(),
13
+ updatedAt: typebox_1.Type.Union([typebox_1.Type.String(), typebox_1.Type.Null()]),
14
+ });
@@ -1,10 +1,14 @@
1
- import { type Static, type TObject, type TString } from "@sinclair/typebox";
1
+ import { type Static, type TNull, type TObject, type TString, type TUnion } from "@sinclair/typebox";
2
2
  /**
3
3
  * The schema for a variable
4
4
  */
5
5
  export declare const VariableSchema: TObject<{
6
+ tenantId: TString;
6
7
  key: TString;
8
+ description: TString;
7
9
  value: TString;
10
+ createdAt: TString;
11
+ updatedAt: TUnion<[TString, TNull]>;
8
12
  }>;
9
13
  /**
10
14
  * The type for a variable
@@ -1 +1 @@
1
- {"version":3,"file":"variable.d.ts","sourceRoot":"","sources":["../../src/contracts/variable.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,MAAM,EAAE,KAAK,OAAO,EAAE,KAAK,OAAO,EAAQ,MAAM,mBAAmB,CAAA;AAEjF;;GAEG;AACH,eAAO,MAAM,cAAc,EAAE,OAAO,CAAC;IACnC,GAAG,EAAE,OAAO,CAAA;IACZ,KAAK,EAAE,OAAO,CAAA;CACf,CAGC,CAAA;AACF;;GAEG;AACH,MAAM,MAAM,QAAQ,GAAG,MAAM,CAAC,OAAO,cAAc,CAAC,CAAA"}
1
+ {"version":3,"file":"variable.d.ts","sourceRoot":"","sources":["../../src/contracts/variable.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,MAAM,EAAE,KAAK,KAAK,EAAE,KAAK,OAAO,EAAE,KAAK,OAAO,EAAE,KAAK,MAAM,EAAQ,MAAM,mBAAmB,CAAA;AAE1G;;GAEG;AACH,eAAO,MAAM,cAAc,EAAE,OAAO,CAAC;IACnC,QAAQ,EAAE,OAAO,CAAA;IACjB,GAAG,EAAE,OAAO,CAAA;IACZ,WAAW,EAAE,OAAO,CAAA;IACpB,KAAK,EAAE,OAAO,CAAA;IACd,SAAS,EAAE,OAAO,CAAA;IAClB,SAAS,EAAE,MAAM,CAAC,CAAC,OAAO,EAAE,KAAK,CAAC,CAAC,CAAA;CACpC,CAOC,CAAA;AAEF;;GAEG;AACH,MAAM,MAAM,QAAQ,GAAG,MAAM,CAAC,OAAO,cAAc,CAAC,CAAA"}
@@ -6,6 +6,10 @@ const typebox_1 = require("@sinclair/typebox");
6
6
  * The schema for a variable
7
7
  */
8
8
  exports.VariableSchema = typebox_1.Type.Object({
9
+ tenantId: typebox_1.Type.String(),
9
10
  key: typebox_1.Type.String(),
11
+ description: typebox_1.Type.String(),
10
12
  value: typebox_1.Type.String(),
13
+ createdAt: typebox_1.Type.String(),
14
+ updatedAt: typebox_1.Type.Union([typebox_1.Type.String(), typebox_1.Type.Null()]),
11
15
  });