@globus/sdk 0.1.5-alpha → 0.1.6-alpha.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 (296) hide show
  1. package/dist/commonjs/src/index.js +23 -0
  2. package/dist/commonjs/src/index.js.map +1 -0
  3. package/dist/commonjs/src/lib/core/authorization.js +97 -0
  4. package/dist/commonjs/src/lib/core/authorization.js.map +1 -0
  5. package/dist/commonjs/src/lib/core/consent.js +33 -0
  6. package/dist/commonjs/src/lib/core/consent.js.map +1 -0
  7. package/dist/commonjs/src/lib/core/errors.js +12 -0
  8. package/dist/commonjs/src/lib/core/errors.js.map +1 -0
  9. package/dist/commonjs/src/lib/core/fetch.js +21 -0
  10. package/dist/commonjs/src/lib/core/fetch.js.map +1 -0
  11. package/dist/commonjs/src/lib/core/global.js +96 -0
  12. package/dist/commonjs/src/lib/core/global.js.map +1 -0
  13. package/dist/commonjs/src/lib/core/internals/__mocks__/fetch.js +4 -0
  14. package/dist/commonjs/src/lib/core/internals/__mocks__/fetch.js.map +1 -0
  15. package/dist/commonjs/src/lib/core/internals/fetch.js +6 -0
  16. package/dist/commonjs/src/lib/core/internals/fetch.js.map +1 -0
  17. package/dist/commonjs/src/lib/core/storage/index.js +35 -0
  18. package/dist/commonjs/src/lib/core/storage/index.js.map +1 -0
  19. package/dist/commonjs/src/lib/core/storage/local-storage.js +20 -0
  20. package/dist/commonjs/src/lib/core/storage/local-storage.js.map +1 -0
  21. package/dist/commonjs/src/lib/core/storage/memory.js +35 -0
  22. package/dist/commonjs/src/lib/core/storage/memory.js.map +1 -0
  23. package/dist/commonjs/src/lib/core/url.js +19 -0
  24. package/dist/commonjs/src/lib/core/url.js.map +1 -0
  25. package/dist/commonjs/src/lib/sdk.js +8 -0
  26. package/dist/commonjs/src/lib/sdk.js.map +1 -0
  27. package/dist/commonjs/src/lib/services/auth/config.js +13 -0
  28. package/dist/commonjs/src/lib/services/auth/config.js.map +1 -0
  29. package/dist/commonjs/src/lib/services/auth/index.js +21 -0
  30. package/dist/commonjs/src/lib/services/auth/index.js.map +1 -0
  31. package/dist/commonjs/src/lib/services/auth/types.js +3 -0
  32. package/dist/commonjs/src/lib/services/auth/types.js.map +1 -0
  33. package/dist/commonjs/src/lib/services/flows/config.js +23 -0
  34. package/dist/commonjs/src/lib/services/flows/config.js.map +1 -0
  35. package/dist/commonjs/src/lib/services/flows/index.js +15 -0
  36. package/dist/commonjs/src/lib/services/flows/index.js.map +1 -0
  37. package/dist/commonjs/src/lib/services/flows/service/batch.js +4 -0
  38. package/dist/commonjs/src/lib/services/flows/service/batch.js.map +1 -0
  39. package/dist/commonjs/src/lib/services/flows/service/flows.js +30 -0
  40. package/dist/commonjs/src/lib/services/flows/service/flows.js.map +1 -0
  41. package/dist/commonjs/src/lib/services/flows/service/runs.js +17 -0
  42. package/dist/commonjs/src/lib/services/flows/service/runs.js.map +1 -0
  43. package/dist/commonjs/src/lib/services/globus-connect-server/index.js +33 -0
  44. package/dist/commonjs/src/lib/services/globus-connect-server/index.js.map +1 -0
  45. package/dist/commonjs/src/lib/services/globus-connect-server/service/endpoint.js +15 -0
  46. package/dist/commonjs/src/lib/services/globus-connect-server/service/endpoint.js.map +1 -0
  47. package/dist/commonjs/src/lib/services/globus-connect-server/service/versioning.js +16 -0
  48. package/dist/commonjs/src/lib/services/globus-connect-server/service/versioning.js.map +1 -0
  49. package/dist/commonjs/src/lib/services/search/config.js +21 -0
  50. package/dist/commonjs/src/lib/services/search/config.js.map +1 -0
  51. package/dist/commonjs/src/lib/services/search/index.js +13 -0
  52. package/dist/commonjs/src/lib/services/search/index.js.map +1 -0
  53. package/dist/commonjs/src/lib/services/search/service/query.js +20 -0
  54. package/dist/commonjs/src/lib/services/search/service/query.js.map +1 -0
  55. package/dist/commonjs/src/lib/services/shared.js +10 -0
  56. package/dist/commonjs/src/lib/services/shared.js.map +1 -0
  57. package/dist/commonjs/src/lib/services/transfer/config.js +13 -0
  58. package/dist/commonjs/src/lib/services/transfer/config.js.map +1 -0
  59. package/dist/commonjs/src/lib/services/transfer/index.js +17 -0
  60. package/dist/commonjs/src/lib/services/transfer/index.js.map +1 -0
  61. package/dist/commonjs/src/lib/services/transfer/service/endpoint-search.js +29 -0
  62. package/dist/commonjs/src/lib/services/transfer/service/endpoint-search.js.map +1 -0
  63. package/dist/commonjs/src/lib/services/transfer/service/endpoint.js +14 -0
  64. package/dist/commonjs/src/lib/services/transfer/service/endpoint.js.map +1 -0
  65. package/dist/commonjs/src/lib/services/transfer/service/file-operations.js +56 -0
  66. package/dist/commonjs/src/lib/services/transfer/service/file-operations.js.map +1 -0
  67. package/dist/commonjs/src/lib/services/transfer/service/task-submission.js +37 -0
  68. package/dist/commonjs/src/lib/services/transfer/service/task-submission.js.map +1 -0
  69. package/dist/commonjs/src/lib/services/transfer/shared.js +14 -0
  70. package/dist/commonjs/src/lib/services/transfer/shared.js.map +1 -0
  71. package/dist/commonjs/src/lib/services/types.js +3 -0
  72. package/dist/commonjs/src/lib/services/types.js.map +1 -0
  73. package/dist/commonjs/tsconfig.cjs.tsbuildinfo +1 -0
  74. package/dist/src/index.d.ts +6 -0
  75. package/dist/src/index.d.ts.map +1 -0
  76. package/dist/src/index.js +10 -0
  77. package/dist/src/index.js.map +1 -0
  78. package/dist/src/lib/core/authorization.d.ts +21 -0
  79. package/dist/src/lib/core/authorization.d.ts.map +1 -0
  80. package/dist/src/lib/core/authorization.js +72 -0
  81. package/dist/src/lib/core/authorization.js.map +1 -0
  82. package/dist/src/lib/core/consent.d.ts +6 -0
  83. package/dist/src/lib/core/consent.d.ts.map +1 -0
  84. package/dist/src/lib/core/consent.js +27 -0
  85. package/dist/src/lib/core/consent.js.map +1 -0
  86. package/dist/src/lib/core/errors.d.ts +5 -0
  87. package/dist/src/lib/core/errors.d.ts.map +1 -0
  88. package/dist/src/lib/core/errors.js +8 -0
  89. package/dist/src/lib/core/errors.js.map +1 -0
  90. package/dist/src/lib/core/fetch.d.ts +7 -0
  91. package/dist/src/lib/core/fetch.d.ts.map +1 -0
  92. package/dist/src/lib/core/fetch.js +17 -0
  93. package/dist/src/lib/core/fetch.js.map +1 -0
  94. package/dist/src/lib/core/global.d.ts +37 -0
  95. package/dist/src/lib/core/global.d.ts.map +1 -0
  96. package/dist/src/lib/core/global.js +89 -0
  97. package/dist/src/lib/core/global.js.map +1 -0
  98. package/dist/src/lib/core/internals/__mocks__/fetch.d.ts +2 -0
  99. package/dist/src/lib/core/internals/__mocks__/fetch.d.ts.map +1 -0
  100. package/dist/src/lib/core/internals/__mocks__/fetch.js +4 -0
  101. package/dist/src/lib/core/internals/__mocks__/fetch.js.map +1 -0
  102. package/dist/src/lib/core/internals/fetch.d.ts +2 -0
  103. package/dist/src/lib/core/internals/fetch.d.ts.map +1 -0
  104. package/dist/src/lib/core/internals/fetch.js +3 -0
  105. package/dist/src/lib/core/internals/fetch.js.map +1 -0
  106. package/dist/src/lib/core/storage/index.d.ts +19 -0
  107. package/dist/src/lib/core/storage/index.d.ts.map +1 -0
  108. package/dist/src/lib/core/storage/index.js +30 -0
  109. package/dist/src/lib/core/storage/index.js.map +1 -0
  110. package/dist/src/lib/core/storage/local-storage.d.ts +8 -0
  111. package/dist/src/lib/core/storage/local-storage.d.ts.map +1 -0
  112. package/dist/src/lib/core/storage/local-storage.js +16 -0
  113. package/dist/src/lib/core/storage/local-storage.js.map +1 -0
  114. package/dist/src/lib/core/storage/memory.d.ts +9 -0
  115. package/dist/src/lib/core/storage/memory.d.ts.map +1 -0
  116. package/dist/src/lib/core/storage/memory.js +21 -0
  117. package/dist/src/lib/core/storage/memory.js.map +1 -0
  118. package/dist/src/lib/core/url.d.ts +7 -0
  119. package/dist/src/lib/core/url.d.ts.map +1 -0
  120. package/dist/src/lib/core/url.js +14 -0
  121. package/dist/src/lib/core/url.js.map +1 -0
  122. package/dist/src/lib/sdk.d.ts +2 -0
  123. package/dist/src/lib/sdk.d.ts.map +1 -0
  124. package/dist/src/lib/sdk.js +4 -0
  125. package/dist/src/lib/sdk.js.map +1 -0
  126. package/dist/src/lib/services/auth/config.d.ts +4 -0
  127. package/dist/src/lib/services/auth/config.d.ts.map +1 -0
  128. package/dist/src/lib/services/auth/config.js +10 -0
  129. package/dist/src/lib/services/auth/config.js.map +1 -0
  130. package/dist/src/lib/services/auth/index.d.ts +17 -0
  131. package/dist/src/lib/services/auth/index.d.ts.map +1 -0
  132. package/dist/src/lib/services/auth/index.js +16 -0
  133. package/dist/src/lib/services/auth/index.js.map +1 -0
  134. package/dist/src/lib/services/auth/types.d.ts +15 -0
  135. package/dist/src/lib/services/auth/types.d.ts.map +1 -0
  136. package/dist/src/lib/services/auth/types.js +2 -0
  137. package/dist/src/lib/services/auth/types.js.map +1 -0
  138. package/dist/src/lib/services/flows/config.d.ts +14 -0
  139. package/dist/src/lib/services/flows/config.d.ts.map +1 -0
  140. package/dist/src/lib/services/flows/config.js +20 -0
  141. package/dist/src/lib/services/flows/config.js.map +1 -0
  142. package/dist/src/lib/services/flows/index.d.ts +12 -0
  143. package/dist/src/lib/services/flows/index.d.ts.map +1 -0
  144. package/dist/src/lib/services/flows/index.js +15 -0
  145. package/dist/src/lib/services/flows/index.js.map +1 -0
  146. package/dist/src/lib/services/flows/service/batch.d.ts +3 -0
  147. package/dist/src/lib/services/flows/service/batch.d.ts.map +1 -0
  148. package/dist/src/lib/services/flows/service/batch.js +2 -0
  149. package/dist/src/lib/services/flows/service/batch.js.map +1 -0
  150. package/dist/src/lib/services/flows/service/flows.d.ts +13 -0
  151. package/dist/src/lib/services/flows/service/flows.d.ts.map +1 -0
  152. package/dist/src/lib/services/flows/service/flows.js +27 -0
  153. package/dist/src/lib/services/flows/service/flows.js.map +1 -0
  154. package/dist/src/lib/services/flows/service/runs.d.ts +6 -0
  155. package/dist/src/lib/services/flows/service/runs.d.ts.map +1 -0
  156. package/dist/src/lib/services/flows/service/runs.js +14 -0
  157. package/dist/src/lib/services/flows/service/runs.js.map +1 -0
  158. package/dist/src/lib/services/globus-connect-server/index.d.ts +13 -0
  159. package/dist/src/lib/services/globus-connect-server/index.d.ts.map +1 -0
  160. package/dist/src/lib/services/globus-connect-server/index.js +30 -0
  161. package/dist/src/lib/services/globus-connect-server/index.js.map +1 -0
  162. package/dist/src/lib/services/globus-connect-server/service/endpoint.d.ts +5 -0
  163. package/dist/src/lib/services/globus-connect-server/service/endpoint.d.ts.map +1 -0
  164. package/dist/src/lib/services/globus-connect-server/service/endpoint.js +12 -0
  165. package/dist/src/lib/services/globus-connect-server/service/endpoint.js.map +1 -0
  166. package/dist/src/lib/services/globus-connect-server/service/versioning.d.ts +6 -0
  167. package/dist/src/lib/services/globus-connect-server/service/versioning.d.ts.map +1 -0
  168. package/dist/src/lib/services/globus-connect-server/service/versioning.js +13 -0
  169. package/dist/src/lib/services/globus-connect-server/service/versioning.js.map +1 -0
  170. package/dist/src/lib/services/search/config.d.ts +12 -0
  171. package/dist/src/lib/services/search/config.d.ts.map +1 -0
  172. package/dist/src/lib/services/search/config.js +18 -0
  173. package/dist/src/lib/services/search/config.js.map +1 -0
  174. package/dist/src/lib/services/search/index.d.ts +10 -0
  175. package/dist/src/lib/services/search/index.d.ts.map +1 -0
  176. package/dist/src/lib/services/search/index.js +11 -0
  177. package/dist/src/lib/services/search/index.js.map +1 -0
  178. package/dist/src/lib/services/search/service/query.d.ts +17 -0
  179. package/dist/src/lib/services/search/service/query.d.ts.map +1 -0
  180. package/dist/src/lib/services/search/service/query.js +17 -0
  181. package/dist/src/lib/services/search/service/query.js.map +1 -0
  182. package/dist/src/lib/services/shared.d.ts +6 -0
  183. package/dist/src/lib/services/shared.d.ts.map +1 -0
  184. package/dist/src/lib/services/shared.js +7 -0
  185. package/dist/src/lib/services/shared.js.map +1 -0
  186. package/dist/src/lib/services/transfer/config.d.ts +4 -0
  187. package/dist/src/lib/services/transfer/config.d.ts.map +1 -0
  188. package/dist/src/lib/services/transfer/config.js +10 -0
  189. package/dist/src/lib/services/transfer/config.js.map +1 -0
  190. package/dist/src/lib/services/transfer/index.d.ts +13 -0
  191. package/dist/src/lib/services/transfer/index.d.ts.map +1 -0
  192. package/dist/src/lib/services/transfer/index.js +17 -0
  193. package/dist/src/lib/services/transfer/index.js.map +1 -0
  194. package/dist/src/lib/services/transfer/service/endpoint-search.d.ts +6 -0
  195. package/dist/src/lib/services/transfer/service/endpoint-search.d.ts.map +1 -0
  196. package/dist/src/lib/services/transfer/service/endpoint-search.js +26 -0
  197. package/dist/src/lib/services/transfer/service/endpoint-search.js.map +1 -0
  198. package/dist/src/lib/services/transfer/service/endpoint.d.ts +5 -0
  199. package/dist/src/lib/services/transfer/service/endpoint.d.ts.map +1 -0
  200. package/dist/src/lib/services/transfer/service/endpoint.js +11 -0
  201. package/dist/src/lib/services/transfer/service/endpoint.js.map +1 -0
  202. package/dist/src/lib/services/transfer/service/file-operations.d.ts +37 -0
  203. package/dist/src/lib/services/transfer/service/file-operations.d.ts.map +1 -0
  204. package/dist/src/lib/services/transfer/service/file-operations.js +53 -0
  205. package/dist/src/lib/services/transfer/service/file-operations.js.map +1 -0
  206. package/dist/src/lib/services/transfer/service/task-submission.d.ts +21 -0
  207. package/dist/src/lib/services/transfer/service/task-submission.d.ts.map +1 -0
  208. package/dist/src/lib/services/transfer/service/task-submission.js +31 -0
  209. package/dist/src/lib/services/transfer/service/task-submission.js.map +1 -0
  210. package/dist/src/lib/services/transfer/shared.d.ts +3 -0
  211. package/dist/src/lib/services/transfer/shared.d.ts.map +1 -0
  212. package/dist/src/lib/services/transfer/shared.js +10 -0
  213. package/dist/src/lib/services/transfer/shared.js.map +1 -0
  214. package/dist/src/lib/services/types.d.ts +31 -0
  215. package/dist/src/lib/services/types.d.ts.map +1 -0
  216. package/dist/src/lib/services/types.js +2 -0
  217. package/dist/src/lib/services/types.js.map +1 -0
  218. package/dist/tsconfig.tsbuildinfo +1 -0
  219. package/package.json +6 -10
  220. package/dist/@types/tsconfig.tsbuildinfo +0 -1
  221. package/dist/browser.cjs.js +0 -1
  222. package/dist/browser.esm.js +0 -1
  223. package/dist/index.cjs.js +0 -1
  224. package/dist/index.esm.js +0 -1
  225. /package/dist/{@types → commonjs}/src/index.d.ts +0 -0
  226. /package/dist/{@types → commonjs}/src/index.d.ts.map +0 -0
  227. /package/dist/{@types → commonjs}/src/lib/core/authorization.d.ts +0 -0
  228. /package/dist/{@types → commonjs}/src/lib/core/authorization.d.ts.map +0 -0
  229. /package/dist/{@types → commonjs}/src/lib/core/consent.d.ts +0 -0
  230. /package/dist/{@types → commonjs}/src/lib/core/consent.d.ts.map +0 -0
  231. /package/dist/{@types → commonjs}/src/lib/core/errors.d.ts +0 -0
  232. /package/dist/{@types → commonjs}/src/lib/core/errors.d.ts.map +0 -0
  233. /package/dist/{@types → commonjs}/src/lib/core/fetch.d.ts +0 -0
  234. /package/dist/{@types → commonjs}/src/lib/core/fetch.d.ts.map +0 -0
  235. /package/dist/{@types → commonjs}/src/lib/core/global.d.ts +0 -0
  236. /package/dist/{@types → commonjs}/src/lib/core/global.d.ts.map +0 -0
  237. /package/dist/{@types → commonjs}/src/lib/core/internals/__mocks__/fetch.d.ts +0 -0
  238. /package/dist/{@types → commonjs}/src/lib/core/internals/__mocks__/fetch.d.ts.map +0 -0
  239. /package/dist/{@types → commonjs}/src/lib/core/internals/fetch.d.ts +0 -0
  240. /package/dist/{@types → commonjs}/src/lib/core/internals/fetch.d.ts.map +0 -0
  241. /package/dist/{@types → commonjs}/src/lib/core/storage/index.d.ts +0 -0
  242. /package/dist/{@types → commonjs}/src/lib/core/storage/index.d.ts.map +0 -0
  243. /package/dist/{@types → commonjs}/src/lib/core/storage/local-storage.d.ts +0 -0
  244. /package/dist/{@types → commonjs}/src/lib/core/storage/local-storage.d.ts.map +0 -0
  245. /package/dist/{@types → commonjs}/src/lib/core/storage/memory.d.ts +0 -0
  246. /package/dist/{@types → commonjs}/src/lib/core/storage/memory.d.ts.map +0 -0
  247. /package/dist/{@types → commonjs}/src/lib/core/url.d.ts +0 -0
  248. /package/dist/{@types → commonjs}/src/lib/core/url.d.ts.map +0 -0
  249. /package/dist/{@types → commonjs}/src/lib/sdk.d.ts +0 -0
  250. /package/dist/{@types → commonjs}/src/lib/sdk.d.ts.map +0 -0
  251. /package/dist/{@types → commonjs}/src/lib/services/auth/config.d.ts +0 -0
  252. /package/dist/{@types → commonjs}/src/lib/services/auth/config.d.ts.map +0 -0
  253. /package/dist/{@types → commonjs}/src/lib/services/auth/index.d.ts +0 -0
  254. /package/dist/{@types → commonjs}/src/lib/services/auth/index.d.ts.map +0 -0
  255. /package/dist/{@types → commonjs}/src/lib/services/auth/types.d.ts +0 -0
  256. /package/dist/{@types → commonjs}/src/lib/services/auth/types.d.ts.map +0 -0
  257. /package/dist/{@types → commonjs}/src/lib/services/flows/config.d.ts +0 -0
  258. /package/dist/{@types → commonjs}/src/lib/services/flows/config.d.ts.map +0 -0
  259. /package/dist/{@types → commonjs}/src/lib/services/flows/index.d.ts +0 -0
  260. /package/dist/{@types → commonjs}/src/lib/services/flows/index.d.ts.map +0 -0
  261. /package/dist/{@types → commonjs}/src/lib/services/flows/service/batch.d.ts +0 -0
  262. /package/dist/{@types → commonjs}/src/lib/services/flows/service/batch.d.ts.map +0 -0
  263. /package/dist/{@types → commonjs}/src/lib/services/flows/service/flows.d.ts +0 -0
  264. /package/dist/{@types → commonjs}/src/lib/services/flows/service/flows.d.ts.map +0 -0
  265. /package/dist/{@types → commonjs}/src/lib/services/flows/service/runs.d.ts +0 -0
  266. /package/dist/{@types → commonjs}/src/lib/services/flows/service/runs.d.ts.map +0 -0
  267. /package/dist/{@types → commonjs}/src/lib/services/globus-connect-server/index.d.ts +0 -0
  268. /package/dist/{@types → commonjs}/src/lib/services/globus-connect-server/index.d.ts.map +0 -0
  269. /package/dist/{@types → commonjs}/src/lib/services/globus-connect-server/service/endpoint.d.ts +0 -0
  270. /package/dist/{@types → commonjs}/src/lib/services/globus-connect-server/service/endpoint.d.ts.map +0 -0
  271. /package/dist/{@types → commonjs}/src/lib/services/globus-connect-server/service/versioning.d.ts +0 -0
  272. /package/dist/{@types → commonjs}/src/lib/services/globus-connect-server/service/versioning.d.ts.map +0 -0
  273. /package/dist/{@types → commonjs}/src/lib/services/search/config.d.ts +0 -0
  274. /package/dist/{@types → commonjs}/src/lib/services/search/config.d.ts.map +0 -0
  275. /package/dist/{@types → commonjs}/src/lib/services/search/index.d.ts +0 -0
  276. /package/dist/{@types → commonjs}/src/lib/services/search/index.d.ts.map +0 -0
  277. /package/dist/{@types → commonjs}/src/lib/services/search/service/query.d.ts +0 -0
  278. /package/dist/{@types → commonjs}/src/lib/services/search/service/query.d.ts.map +0 -0
  279. /package/dist/{@types → commonjs}/src/lib/services/shared.d.ts +0 -0
  280. /package/dist/{@types → commonjs}/src/lib/services/shared.d.ts.map +0 -0
  281. /package/dist/{@types → commonjs}/src/lib/services/transfer/config.d.ts +0 -0
  282. /package/dist/{@types → commonjs}/src/lib/services/transfer/config.d.ts.map +0 -0
  283. /package/dist/{@types → commonjs}/src/lib/services/transfer/index.d.ts +0 -0
  284. /package/dist/{@types → commonjs}/src/lib/services/transfer/index.d.ts.map +0 -0
  285. /package/dist/{@types → commonjs}/src/lib/services/transfer/service/endpoint-search.d.ts +0 -0
  286. /package/dist/{@types → commonjs}/src/lib/services/transfer/service/endpoint-search.d.ts.map +0 -0
  287. /package/dist/{@types → commonjs}/src/lib/services/transfer/service/endpoint.d.ts +0 -0
  288. /package/dist/{@types → commonjs}/src/lib/services/transfer/service/endpoint.d.ts.map +0 -0
  289. /package/dist/{@types → commonjs}/src/lib/services/transfer/service/file-operations.d.ts +0 -0
  290. /package/dist/{@types → commonjs}/src/lib/services/transfer/service/file-operations.d.ts.map +0 -0
  291. /package/dist/{@types → commonjs}/src/lib/services/transfer/service/task-submission.d.ts +0 -0
  292. /package/dist/{@types → commonjs}/src/lib/services/transfer/service/task-submission.d.ts.map +0 -0
  293. /package/dist/{@types → commonjs}/src/lib/services/transfer/shared.d.ts +0 -0
  294. /package/dist/{@types → commonjs}/src/lib/services/transfer/shared.d.ts.map +0 -0
  295. /package/dist/{@types → commonjs}/src/lib/services/types.d.ts +0 -0
  296. /package/dist/{@types → commonjs}/src/lib/services/types.d.ts.map +0 -0
@@ -0,0 +1,72 @@
1
+ var _PKCEAuthorization_instances, _PKCEAuthorization_pkce, _PKCEAuthorization_configuration, _PKCEAuthorization_response, _PKCEAuthorization_createPKCEInstance, _PKCEAuthorization_resetPKCE;
2
+ import { __awaiter, __classPrivateFieldGet, __classPrivateFieldSet } from "tslib";
3
+ import PKCE from "js-pkce";
4
+ import { getAuthorizationEndpoint, getTokenEndpoint } from "../services/auth";
5
+ import { addTokenResponse, getTokenForScope, reset as resetTokens, } from "./consent";
6
+ import { createStorage } from "./storage";
7
+ let storage;
8
+ export class PKCEAuthorization {
9
+ constructor(configuration) {
10
+ _PKCEAuthorization_instances.add(this);
11
+ _PKCEAuthorization_pkce.set(this, void 0);
12
+ _PKCEAuthorization_configuration.set(this, void 0);
13
+ _PKCEAuthorization_response.set(this, void 0);
14
+ storage = createStorage("localStorage");
15
+ if (!configuration.client_id) {
16
+ throw new Error("You must provide a `client_id`.");
17
+ }
18
+ __classPrivateFieldSet(this, _PKCEAuthorization_configuration, Object.assign({ client_id: configuration.client_id, authorization_endpoint: getAuthorizationEndpoint(), token_endpoint: getTokenEndpoint() }, configuration), "f");
19
+ __classPrivateFieldSet(this, _PKCEAuthorization_pkce, __classPrivateFieldGet(this, _PKCEAuthorization_instances, "m", _PKCEAuthorization_createPKCEInstance).call(this), "f");
20
+ }
21
+ reset() {
22
+ __classPrivateFieldGet(this, _PKCEAuthorization_instances, "m", _PKCEAuthorization_resetPKCE).call(this);
23
+ resetTokens();
24
+ }
25
+ redirect() {
26
+ this.reset();
27
+ window.location.replace(__classPrivateFieldGet(this, _PKCEAuthorization_pkce, "f").authorizeUrl());
28
+ }
29
+ handleCodeRedirect(options = { removeStateAndReplaceLocation: true }) {
30
+ return __awaiter(this, void 0, void 0, function* () {
31
+ const url = new URL(window.location.href);
32
+ const params = new URLSearchParams(url.search);
33
+ if (!params.get("code"))
34
+ return;
35
+ const response = yield __classPrivateFieldGet(this, _PKCEAuthorization_pkce, "f").exchangeForAccessToken(url.toString());
36
+ __classPrivateFieldSet(this, _PKCEAuthorization_response, response, "f");
37
+ addTokenResponse(__classPrivateFieldGet(this, _PKCEAuthorization_response, "f"));
38
+ // Remove PKCE-state from the URL since we have a token.
39
+ if (options.removeStateAndReplaceLocation) {
40
+ params.delete("code");
41
+ params.delete("state");
42
+ url.search = params.toString();
43
+ window.location.replace(url);
44
+ }
45
+ });
46
+ }
47
+ hasToken() {
48
+ return __classPrivateFieldGet(this, _PKCEAuthorization_configuration, "f").requested_scopes
49
+ .split(" ")
50
+ .every((scope) => Boolean(getTokenForScope(scope)));
51
+ }
52
+ revoke() {
53
+ this.reset();
54
+ }
55
+ }
56
+ _PKCEAuthorization_pkce = new WeakMap(), _PKCEAuthorization_configuration = new WeakMap(), _PKCEAuthorization_response = new WeakMap(), _PKCEAuthorization_instances = new WeakSet(), _PKCEAuthorization_createPKCEInstance = function _PKCEAuthorization_createPKCEInstance() {
57
+ return new PKCE(__classPrivateFieldGet(this, _PKCEAuthorization_configuration, "f"));
58
+ }, _PKCEAuthorization_resetPKCE = function _PKCEAuthorization_resetPKCE() {
59
+ /**
60
+ * Resets js-pkce state
61
+ * @see https://github.com/bpedroza/js-pkce/blob/master/src/PKCE.ts
62
+ */
63
+ sessionStorage.removeItem("pkce_state");
64
+ sessionStorage.removeItem("pkce_code_verifier");
65
+ };
66
+ export function pkce(configuration) {
67
+ return new PKCEAuthorization(configuration);
68
+ }
69
+ export function incremental(configuration) {
70
+ return new PKCEAuthorization(configuration);
71
+ }
72
+ //# sourceMappingURL=authorization.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"authorization.js","sourceRoot":"","sources":["../../../../src/lib/core/authorization.ts"],"names":[],"mappings":";;AAAA,OAAO,IAAI,MAAM,SAAS,CAAC;AAI3B,OAAO,EAAE,wBAAwB,EAA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 import ITokenResponse from "js-pkce/dist/ITokenResponse";
3
+ export declare function addTokenResponse(token: ITokenResponse | TokenResponse): void;
4
+ export declare function getTokenForScope(scope: string): string | null;
5
+ export declare function reset(): void;
6
+ //# sourceMappingURL=consent.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"consent.d.ts","sourceRoot":"","sources":["../../../../src/lib/core/consent.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAS,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAC7D,OAAO,cAAc,MAAM,6BAA6B,CAAC;AAazD,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,cAAc,GAAG,aAAa,QAKrE;AAED,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,MAAM,iBAM7C;AAED,wBAAgB,KAAK,SAEpB"}
@@ -0,0 +1,27 @@
1
+ import { getStorage } from "./storage";
2
+ function isValidToken(check) {
3
+ const maybe = check;
4
+ return Boolean(maybe.token_type && maybe.access_token);
5
+ }
6
+ function store(token) {
7
+ token.scope.split(" ").forEach((scope) => {
8
+ getStorage().set(scope, token);
9
+ });
10
+ }
11
+ export function addTokenResponse(token) {
12
+ store(token);
13
+ if ("other_tokens" in token) {
14
+ token.other_tokens.forEach(store);
15
+ }
16
+ }
17
+ export function getTokenForScope(scope) {
18
+ const token = getStorage().get(scope);
19
+ if (!token || !isValidToken(token)) {
20
+ return null;
21
+ }
22
+ return `${token.token_type} ${token.access_token}`;
23
+ }
24
+ export function reset() {
25
+ getStorage().clear();
26
+ }
27
+ //# sourceMappingURL=consent.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"consent.js","sourceRoot":"","sources":["../../../../src/lib/core/consent.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAIvC,SAAS,YAAY,CAAC,KAAc;IAClC,MAAM,KAAK,GAAG,KAAc,CAAC;IAC7B,OAAO,OAAO,CAAC,KAAK,CAAC,UAAU,IAAI,KAAK,CAAC,YAAY,CAAC,CAAC;AACzD,CAAC;AAED,SAAS,KAAK,CAAC,KAAqB;IAClC,KAAK,CAAC,KAAK,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,OAAO,CAAC,CAAC,KAAK,EAAE,EAAE;QACvC,UAAU,EAAE,CAAC,GAAG,CAAC,KAAK,EAAE,KAAK,CAAC,CAAC;IACjC,CAAC,CAAC,CAAC;AACL,CAAC;AAED,MAAM,UAAU,gBAAgB,CAAC,KAAqC;IACpE,KAAK,CAAC,KAAK,CAAC,CAAC;IACb,IAAI,cAAc,IAAI,KAAK,EAAE;QAC3B,KAAK,CAAC,YAAY,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;KACnC;AACH,CAAC;AAED,MAAM,UAAU,gBAAgB,CAAC,KAAa;IAC5C,MAAM,KAAK,GAAG,UAAU,EAAE,CAAC,GAAG,CAAC,KAAK,CAAC,CAAC;IACtC,IAAI,CAAC,KAAK,IAAI,CAAC,YAAY,CAAC,KAAK,CAAC,EAAE;QAClC,OAAO,IAAI,CAAC;KACb;IACD,OAAO,GAAG,KAAK,CAAC,UAAU,IAAI,KAAK,CAAC,YAAY,EAAE,CAAC;AACrD,CAAC;AAED,MAAM,UAAU,KAAK;IACnB,UAAU,EAAE,CAAC,KAAK,EAAE,CAAC;AACvB,CAAC"}
@@ -0,0 +1,5 @@
1
+ export declare class EnvironmentConfigurationError extends Error {
2
+ name: string;
3
+ constructor(variable: string, value: any);
4
+ }
5
+ //# sourceMappingURL=errors.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"errors.d.ts","sourceRoot":"","sources":["../../../../src/lib/core/errors.ts"],"names":[],"mappings":"AAAA,qBAAa,6BAA8B,SAAQ,KAAK;IAC7C,IAAI,SAAmC;gBACpC,QAAQ,EAAE,MAAM,EAAE,KAAK,EAAE,GAAG;CAIzC"}
@@ -0,0 +1,8 @@
1
+ export class EnvironmentConfigurationError extends Error {
2
+ constructor(variable, value) {
3
+ super();
4
+ this.name = 'EnvironmentConfigurationError';
5
+ this.message = `Invalid configuration value provided for ${variable} (${value}).`;
6
+ }
7
+ }
8
+ //# sourceMappingURL=errors.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"errors.js","sourceRoot":"","sources":["../../../../src/lib/core/errors.ts"],"names":[],"mappings":"AAAA,MAAM,OAAO,6BAA8B,SAAQ,KAAK;IAEtD,YAAY,QAAgB,EAAE,KAAU;QACtC,KAAK,EAAE,CAAC;QAFD,SAAI,GAAG,+BAA+B,CAAC;QAG9C,IAAI,CAAC,OAAO,GAAG,4CAA4C,QAAQ,KAAK,KAAK,IAAI,CAAC;IACpF,CAAC;CACF"}
@@ -0,0 +1,7 @@
1
+ type GlobusScope = string;
2
+ export type FetchOverrides = (Omit<RequestInit, "headers"> & {
3
+ headers?: Record<string, string>;
4
+ }) | undefined;
5
+ export declare function fetchWithScope(scope: GlobusScope, input: RequestInfo | URL, fetchOverrides?: FetchOverrides): Promise<Response>;
6
+ export {};
7
+ //# sourceMappingURL=fetch.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fetch.d.ts","sourceRoot":"","sources":["../../../../src/lib/core/fetch.ts"],"names":[],"mappings":"AAGA,KAAK,WAAW,GAAG,MAAM,CAAC;AAE1B,MAAM,MAAM,cAAc,GACtB,CAAC,IAAI,CAAC,WAAW,EAAE,SAAS,CAAC,GAAG;IAC9B,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;CAClC,CAAC,GACF,SAAS,CAAC;AAEd,wBAAgB,cAAc,CAC5B,KAAK,EAAE,WAAW,EAClB,KAAK,EAAE,WAAW,GAAG,GAAG,EACxB,cAAc,GAAE,cAAmB,qBAiBpC"}
@@ -0,0 +1,17 @@
1
+ import { fetch } from "./internals/fetch";
2
+ import { getTokenForScope } from "./consent";
3
+ export function fetchWithScope(scope, input, fetchOverrides = {}) {
4
+ const headers = fetchOverrides.headers || {};
5
+ /**
6
+ * If an `Authorization` override header was provided, we skip any
7
+ * sort of lookup and use the provided value.
8
+ */
9
+ if (!(headers === null || headers === void 0 ? void 0 : headers["Authorization"])) {
10
+ const token = getTokenForScope(scope);
11
+ if (token) {
12
+ headers["Authorization"] = token;
13
+ }
14
+ }
15
+ return fetch(input, Object.assign(Object.assign({}, fetchOverrides), { headers }));
16
+ }
17
+ //# sourceMappingURL=fetch.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fetch.js","sourceRoot":"","sources":["../../../../src/lib/core/fetch.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAC;AAC1C,OAAO,EAAE,gBAAgB,EAAE,MAAM,WAAW,CAAC;AAU7C,MAAM,UAAU,cAAc,CAC5B,KAAkB,EAClB,KAAwB,EACxB,iBAAiC,EAAE;IAEnC,MAAM,OAAO,GAAG,cAAc,CAAC,OAAO,IAAI,EAAE,CAAC;IAC7C;;;OAGG;IACH,IAAI,CAAC,CAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAG,eAAe,CAAC,CAAA,EAAE;QAC/B,MAAM,KAAK,GAAG,gBAAgB,CAAC,KAAK,CAAC,CAAC;QACtC,IAAI,KAAK,EAAE;YACT,OAAO,CAAC,eAAe,CAAC,GAAG,KAAK,CAAC;SAClC;KACF;IACD,OAAO,KAAK,CAAC,KAAK,kCACb,cAAc,KACjB,OAAO,IACP,CAAC;AACL,CAAC"}
@@ -0,0 +1,37 @@
1
+ /**
2
+ * Handlers for: GLOBUS_SDK_ENVIRONMENT
3
+ */
4
+ export declare const ENVIRONMENTS: {
5
+ readonly PRODUCTION: "production";
6
+ readonly PREVIEW: "preview";
7
+ readonly STAGING: "staging";
8
+ readonly SANDBOX: "sandbox";
9
+ readonly INTEGRATION: "integration";
10
+ readonly TEST: "test";
11
+ };
12
+ export type Environment = (typeof ENVIRONMENTS)[keyof typeof ENVIRONMENTS];
13
+ export declare function getEnvironment(): Environment;
14
+ export declare const SERVICES: {
15
+ AUTH: string;
16
+ TRANSFER: string;
17
+ FLOWS: string;
18
+ SEARCH: string;
19
+ };
20
+ export type Service = keyof typeof SERVICES;
21
+ export declare const SERVICE_HOSTS: Record<Service, Partial<Record<Environment, string>>>;
22
+ /**
23
+ * Handlers for: GLOBUS_SDK_VERIFY_SSL
24
+ * Since disabling SSL is at least not-recommended, we consider
25
+ * this value to always be true, but provide a warning when it set
26
+ * to one of the falsey values for informational purposes.
27
+ *
28
+ * Taking direction from `globus-sdk-python` for possible false values
29
+ * @see https://github.com/globus/globus-sdk-python/blob/18eced9c12e2ec41745d1be183148845198b999c/src/globus_sdk/config/env_vars.py#L20
30
+ */
31
+ export declare function getVerifySSL(): boolean;
32
+ /**
33
+ * Handlers for: GLOBUS_SDK_HTTP_TIMEOUT
34
+ */
35
+ export declare function getHttpTimeout(): number | null;
36
+ export declare function getServiceBaseUrl(service: Service, environment?: Environment): `https://${string}` | undefined;
37
+ //# sourceMappingURL=global.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"global.d.ts","sourceRoot":"","sources":["../../../../src/lib/core/global.ts"],"names":[],"mappings":"AAgCA;;GAEG;AACH,eAAO,MAAM,YAAY;;;;;;;CAOf,CAAC;AAEX,MAAM,MAAM,WAAW,GAAG,CAAC,OAAO,YAAY,CAAC,CAAC,MAAM,OAAO,YAAY,CAAC,CAAC;AAE3E,wBAAgB,cAAc,IAAI,WAAW,CAY5C;AAED,eAAO,MAAM,QAAQ;;;;;CAKpB,CAAC;AAEF,MAAM,MAAM,OAAO,GAAG,MAAM,OAAO,QAAQ,CAAC;AAE5C,eAAO,MAAM,aAAa,EAAE,MAAM,CAChC,OAAO,EACP,OAAO,CAAC,MAAM,CAAC,WAAW,EAAE,MAAM,CAAC,CAAC,CAMrC,CAAC;AAEF;;;;;;;;GAQG;AACH,wBAAgB,YAAY,IAAI,OAAO,CAUtC;AAED;;GAEG;AACH,wBAAgB,cAAc,kBAM7B;AAMD,wBAAgB,iBAAiB,CAC/B,OAAO,EAAE,OAAO,EAChB,WAAW,GAAE,WAA8B,mCAO5C"}
@@ -0,0 +1,89 @@
1
+ import * as AUTH from "../services/auth/config";
2
+ import * as TRANSFER from "../services/transfer/config";
3
+ import * as FLOWS from "../services/flows/config";
4
+ import * as SEARCH from "../services/search/config";
5
+ import { EnvironmentConfigurationError } from "./errors";
6
+ function getRuntime() {
7
+ return typeof window !== "undefined" ? window : process;
8
+ }
9
+ function isBrowser(runtime) {
10
+ return typeof window === typeof runtime;
11
+ }
12
+ function env(key, fallback = undefined) {
13
+ const runtime = getRuntime();
14
+ let envConfiguration;
15
+ if (isBrowser(runtime)) {
16
+ envConfiguration = runtime;
17
+ }
18
+ else {
19
+ envConfiguration = runtime.env;
20
+ }
21
+ if (key in envConfiguration) {
22
+ return envConfiguration[key];
23
+ }
24
+ return fallback;
25
+ }
26
+ /**
27
+ * Handlers for: GLOBUS_SDK_ENVIRONMENT
28
+ */
29
+ export const ENVIRONMENTS = {
30
+ PRODUCTION: "production",
31
+ PREVIEW: "preview",
32
+ STAGING: "staging",
33
+ SANDBOX: "sandbox",
34
+ INTEGRATION: "integration",
35
+ TEST: "test",
36
+ };
37
+ export function getEnvironment() {
38
+ const environment = env("GLOBUS_SDK_ENVIRONMENT", ENVIRONMENTS.PRODUCTION);
39
+ if (!environment || !Object.values(ENVIRONMENTS).includes(environment)) {
40
+ throw new EnvironmentConfigurationError("GLOBUS_SDK_ENVIRONMENT", environment);
41
+ }
42
+ return environment;
43
+ }
44
+ export const SERVICES = {
45
+ [AUTH.ID]: AUTH.ID,
46
+ [TRANSFER.ID]: TRANSFER.ID,
47
+ [FLOWS.ID]: FLOWS.ID,
48
+ [SEARCH.ID]: SEARCH.ID,
49
+ };
50
+ export const SERVICE_HOSTS = {
51
+ [AUTH.ID]: AUTH.HOSTS,
52
+ [TRANSFER.ID]: TRANSFER.HOSTS,
53
+ [FLOWS.ID]: FLOWS.HOSTS,
54
+ [SEARCH.ID]: SEARCH.HOSTS,
55
+ };
56
+ /**
57
+ * Handlers for: GLOBUS_SDK_VERIFY_SSL
58
+ * Since disabling SSL is at least not-recommended, we consider
59
+ * this value to always be true, but provide a warning when it set
60
+ * to one of the falsey values for informational purposes.
61
+ *
62
+ * Taking direction from `globus-sdk-python` for possible false values
63
+ * @see https://github.com/globus/globus-sdk-python/blob/18eced9c12e2ec41745d1be183148845198b999c/src/globus_sdk/config/env_vars.py#L20
64
+ */
65
+ export function getVerifySSL() {
66
+ const verifySSLTemp = env("GLOBUS_SDK_VERIFY_SSL", "true").toLowerCase();
67
+ if (["n", "no", "f", "false", "off", "0"].includes(verifySSLTemp)) {
68
+ console.warn("Setting GLOBUS_SDK_VERIFY_SSL to false is disallowed in the Globus Javascript SDK. It will always true in this context");
69
+ }
70
+ return true;
71
+ }
72
+ /**
73
+ * Handlers for: GLOBUS_SDK_HTTP_TIMEOUT
74
+ */
75
+ export function getHttpTimeout() {
76
+ const timeout = Number(env("GLOBUS_SDK_HTTP_TIMEOUT", "60"));
77
+ if (timeout === -1) {
78
+ return null;
79
+ }
80
+ return timeout;
81
+ }
82
+ function getServiceHost(service, environment) {
83
+ return SERVICE_HOSTS[service][environment];
84
+ }
85
+ export function getServiceBaseUrl(service, environment = getEnvironment()) {
86
+ const host = getServiceHost(service, environment);
87
+ return env(`GLOBUS_SDK_SERVICE_URL_${service}`, host ? `https://${host}` : undefined);
88
+ }
89
+ //# sourceMappingURL=global.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"global.js","sourceRoot":"","sources":["../../../../src/lib/core/global.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,IAAI,MAAM,yBAAyB,CAAC;AAChD,OAAO,KAAK,QAAQ,MAAM,6BAA6B,CAAC;AACxD,OAAO,KAAK,KAAK,MAAM,0BAA0B,CAAC;AAClD,OAAO,KAAK,MAAM,MAAM,2BAA2B,CAAC;AAEpD,OAAO,EAAE,6BAA6B,EAAE,MAAM,UAAU,CAAC;AAEzD,SAAS,UAAU;IACjB,OAAO,OAAO,MAAM,KAAK,W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AW,CAAC,CAAC;IAClD,OAAO,GAAG,CACR,0BAA0B,OAAO,EAAE,EACnC,IAAI,CAAC,CAAC,CAAC,WAAW,IAAI,EAAE,CAAC,CAAC,CAAC,SAAS,CACrC,CAAC;AACJ,CAAC"}
@@ -0,0 +1,2 @@
1
+ declare const actual: typeof import("../fetch");
2
+ //# sourceMappingURL=fetch.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fetch.d.ts","sourceRoot":"","sources":["../../../../../../src/lib/core/internals/__mocks__/fetch.ts"],"names":[],"mappings":"AAAA,QAAA,MAAM,MAAM,EAAE,cAAc,UAAU,CACN,CAAC"}
@@ -0,0 +1,4 @@
1
+ "use strict";
2
+ const actual = jest.requireActual("../fetch");
3
+ module.exports = Object.assign(Object.assign({}, actual), { fetch: jest.fn().mockResolvedValue({}) });
4
+ //# sourceMappingURL=fetch.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fetch.js","sourceRoot":"","sources":["../../../../../../src/lib/core/internals/__mocks__/fetch.ts"],"names":[],"mappings":";AAAA,MAAM,MAAM,GACV,IAAI,CAAC,aAAa,CAAC,UAAU,CAAC,CAAC;AAEjC,MAAM,CAAC,OAAO,mCACT,MAAM,KACT,KAAK,EAAE,IAAI,CAAC,EAAE,EAAE,CAAC,iBAAiB,CAAC,EAAE,CAAC,GACvC,CAAC"}
@@ -0,0 +1,2 @@
1
+ export declare const fetch: typeof globalThis.fetch;
2
+ //# sourceMappingURL=fetch.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fetch.d.ts","sourceRoot":"","sources":["../../../../../src/lib/core/internals/fetch.ts"],"names":[],"mappings":"AACA,eAAO,MAAM,KAAK,yBAAS,CAAC"}
@@ -0,0 +1,3 @@
1
+ import _fetch from "cross-fetch";
2
+ export const fetch = _fetch;
3
+ //# sourceMappingURL=fetch.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"fetch.js","sourceRoot":"","sources":["../../../../../src/lib/core/internals/fetch.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,aAAa,CAAC;AACjC,MAAM,CAAC,MAAM,KAAK,GAAG,MAAM,CAAC"}
@@ -0,0 +1,19 @@
1
+ /**
2
+ * Acts as a basic wrapper for storage layers to make their surface APIs consistent.
3
+ */
4
+ export interface StorageSystem {
5
+ get(key: string): any | undefined;
6
+ set(key: string, value: any): void;
7
+ remove(key: string): void;
8
+ clear(): void;
9
+ }
10
+ type StorageOptions = "localStorage" | "memory" | {
11
+ new (): StorageSystem;
12
+ };
13
+ /**
14
+ * Returns the active storage system or creates an instance for the running process.
15
+ */
16
+ export declare function createStorage(storageType?: StorageOptions): StorageSystem;
17
+ export default createStorage;
18
+ export declare function getStorage(): StorageSystem;
19
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/lib/core/storage/index.ts"],"names":[],"mappings":"AAEA;;GAEG;AACH,MAAM,WAAW,aAAa;IAC5B,GAAG,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,GAAG,SAAS,CAAC;IAClC,GAAG,CAAC,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,GAAG,GAAG,IAAI,CAAC;IACnC,MAAM,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,CAAC;IAC1B,KAAK,IAAI,IAAI,CAAC;CACf;AAGD,KAAK,cAAc,GACf,cAAc,GACd,QAAQ,GACR;IACE,QAAQ,aAAa,CAAC;CACvB,CAAC;AAEN;;GAEG;AACH,wBAAgB,aAAa,CAC3B,WAAW,GAAE,cAAyB,GACrC,aAAa,CAaf;AAED,eAAe,aAAa,CAAC;AAE7B,wBAAgB,UAAU,kBAKzB"}
@@ -0,0 +1,30 @@
1
+ import { MemoryStorage } from "./memory";
2
+ import { LocalStorage } from "./local-storage";
3
+ let storage;
4
+ /**
5
+ * Returns the active storage system or creates an instance for the running process.
6
+ */
7
+ export function createStorage(storageType = "memory") {
8
+ if (!storage) {
9
+ let Factory;
10
+ if (storageType === "localStorage") {
11
+ Factory = LocalStorage;
12
+ }
13
+ else if (storageType === "memory") {
14
+ Factory = MemoryStorage;
15
+ }
16
+ else {
17
+ Factory = storageType;
18
+ }
19
+ storage = new Factory();
20
+ }
21
+ return storage;
22
+ }
23
+ export default createStorage;
24
+ export function getStorage() {
25
+ if (!storage) {
26
+ throw Error("You must create a storage system.");
27
+ }
28
+ return storage;
29
+ }
30
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/lib/core/storage/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AACzC,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAW/C,IAAI,OAAkC,CAAC;AAQvC;;GAEG;AACH,MAAM,UAAU,aAAa,CAC3B,cAA8B,QAAQ;IAEtC,IAAI,CAAC,OAAO,EAAE;QACZ,IAAI,OAAO,CAAC;QACZ,IAAI,WAAW,KAAK,cAAc,EAAE;YAClC,OAAO,GAAG,YAAY,CAAC;SACxB;aAAM,IAAI,WAAW,KAAK,QAAQ,EAAE;YACnC,OAAO,GAAG,aAAa,CAAC;SACzB;aAAM;YACL,OAAO,GAAG,WAAW,CAAC;SACvB;QACD,OAAO,GAAG,IAAI,OAAO,EAAE,CAAC;KACzB;IACD,OAAO,OAAO,CAAC;AACjB,CAAC;AAED,eAAe,aAAa,CAAC;AAE7B,MAAM,UAAU,UAAU;IACxB,IAAI,CAAC,OAAO,EAAE;QACZ,MAAM,KAAK,CAAC,mCAAmC,CAAC,CAAC;KAClD;IACD,OAAO,OAAO,CAAC;AACjB,CAAC"}
@@ -0,0 +1,8 @@
1
+ import { StorageSystem } from "./index";
2
+ export declare class LocalStorage implements StorageSystem {
3
+ get(key: string): any;
4
+ set(key: string, value: any): void;
5
+ remove(key: string): void;
6
+ clear(): void;
7
+ }
8
+ //# sourceMappingURL=local-storage.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"local-storage.d.ts","sourceRoot":"","sources":["../../../../../src/lib/core/storage/local-storage.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAExC,qBAAa,YAAa,YAAW,aAAa;IAChD,GAAG,CAAC,GAAG,EAAE,MAAM;IAKf,GAAG,CAAC,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,GAAG;IAI3B,MAAM,CAAC,GAAG,EAAE,MAAM;IAIlB,KAAK;CAGN"}
@@ -0,0 +1,16 @@
1
+ export class LocalStorage {
2
+ get(key) {
3
+ const value = localStorage.getItem(key);
4
+ return value !== null ? JSON.parse(value) : null;
5
+ }
6
+ set(key, value) {
7
+ localStorage.setItem(key, JSON.stringify(value));
8
+ }
9
+ remove(key) {
10
+ localStorage.removeItem(key);
11
+ }
12
+ clear() {
13
+ localStorage.clear();
14
+ }
15
+ }
16
+ //# sourceMappingURL=local-storage.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"local-storage.js","sourceRoot":"","sources":["../../../../../src/lib/core/storage/local-storage.ts"],"names":[],"mappings":"AAEA,MAAM,OAAO,YAAY;IACvB,GAAG,CAAC,GAAW;QACb,MAAM,KAAK,GAAG,YAAY,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC;QACxC,OAAO,KAAK,KAAK,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC;IACnD,CAAC;IAED,GAAG,CAAC,GAAW,EAAE,KAAU;QACzB,YAAY,CAAC,OAAO,CAAC,GAAG,EAAE,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,CAAC,CAAC;IACnD,CAAC;IAED,MAAM,CAAC,GAAW;QAChB,YAAY,CAAC,UAAU,CAAC,GAAG,CAAC,CAAC;IAC/B,CAAC;IAED,KAAK;QACH,YAAY,CAAC,KAAK,EAAE,CAAC;IACvB,CAAC;CACF"}
@@ -0,0 +1,9 @@
1
+ import type { StorageSystem } from "./index";
2
+ export declare class MemoryStorage implements StorageSystem {
3
+ #private;
4
+ get(key: string): any;
5
+ set(key: string, value: any): void;
6
+ remove(key: string): void;
7
+ clear(): void;
8
+ }
9
+ //# sourceMappingURL=memory.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"memory.d.ts","sourceRoot":"","sources":["../../../../../src/lib/core/storage/memory.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAE7C,qBAAa,aAAc,YAAW,aAAa;;IAGjD,GAAG,CAAC,GAAG,EAAE,MAAM;IAIf,GAAG,CAAC,GAAG,EAAE,MAAM,EAAE,KAAK,EAAE,GAAG;IAI3B,MAAM,CAAC,GAAG,EAAE,MAAM;IAIlB,KAAK;CAGN"}
@@ -0,0 +1,21 @@
1
+ var _MemoryStorage_cache;
2
+ import { __classPrivateFieldGet, __classPrivateFieldSet } from "tslib";
3
+ export class MemoryStorage {
4
+ constructor() {
5
+ _MemoryStorage_cache.set(this, {});
6
+ }
7
+ get(key) {
8
+ return __classPrivateFieldGet(this, _MemoryStorage_cache, "f")[key];
9
+ }
10
+ set(key, value) {
11
+ __classPrivateFieldGet(this, _MemoryStorage_cache, "f")[key] = value;
12
+ }
13
+ remove(key) {
14
+ delete __classPrivateFieldGet(this, _MemoryStorage_cache, "f")[key];
15
+ }
16
+ clear() {
17
+ __classPrivateFieldSet(this, _MemoryStorage_cache, {}, "f");
18
+ }
19
+ }
20
+ _MemoryStorage_cache = new WeakMap();
21
+ //# sourceMappingURL=memory.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"memory.js","sourceRoot":"","sources":["../../../../../src/lib/core/storage/memory.ts"],"names":[],"mappings":";;AAEA,MAAM,OAAO,aAAa;IAA1B;QACE,+BAA8B,EAAE,EAAC;IAiBnC,CAAC;IAfC,GAAG,CAAC,GAAW;QACb,OAAO,uBAAA,IAAI,4BAAO,CAAC,GAAG,CAAC,CAAC;IAC1B,CAAC;IAED,GAAG,CAAC,GAAW,EAAE,KAAU;QACzB,uBAAA,IAAI,4BAAO,CAAC,GAAG,CAAC,GAAG,KAAK,CAAC;IAC3B,CAAC;IAED,MAAM,CAAC,GAAW;QAChB,OAAO,uBAAA,IAAI,4BAAO,CAAC,GAAG,CAAC,CAAC;IAC1B,CAAC;IAED,KAAK;QACH,uBAAA,IAAI,wBAAU,EAAE,MAAA,CAAC;IACnB,CAAC;CACF"}
@@ -0,0 +1,7 @@
1
+ import { Environment } from "./global";
2
+ import type { Service } from "./global";
3
+ export declare function getServiceURL(service: Service, path?: string, environment?: Environment): URL;
4
+ export declare function build(service: Service, path: string, options?: {
5
+ search?: ConstructorParameters<typeof URLSearchParams>[0];
6
+ }): string;
7
+ //# sourceMappingURL=url.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"url.d.ts","sourceRoot":"","sources":["../../../../src/lib/core/url.ts"],"names":[],"mappings":"AAAA,OAAO,EAAqC,WAAW,EAAE,MAAM,UAAU,CAAC;AAC1E,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,UAAU,CAAC;AAExC,wBAAgB,aAAa,CAC3B,OAAO,EAAE,OAAO,EAChB,IAAI,SAAK,EACT,WAAW,GAAE,WAA8B,GAC1C,GAAG,CAGL;AAED,wBAAgB,KAAK,CACnB,OAAO,EAAE,OAAO,EAChB,IAAI,EAAE,MAAM,EACZ,OAAO,CAAC,EAAE;IACR,MAAM,CAAC,EAAE,qBAAqB,CAAC,OAAO,eAAe,CAAC,CAAC,CAAC,CAAC,CAAC;CAC3D,UAQF"}
@@ -0,0 +1,14 @@
1
+ import { getServiceBaseUrl, getEnvironment } from "./global";
2
+ export function getServiceURL(service, path = "", environment = getEnvironment()) {
3
+ const base = getServiceBaseUrl(service, environment);
4
+ return new URL(path, base);
5
+ }
6
+ export function build(service, path, options) {
7
+ const url = getServiceURL(service, path);
8
+ if (options && options.search) {
9
+ const search = new URLSearchParams(options.search);
10
+ url.search = search.toString();
11
+ }
12
+ return url.toString();
13
+ }
14
+ //# sourceMappingURL=url.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"url.js","sourceRoot":"","sources":["../../../../src/lib/core/url.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,cAAc,EAAe,MAAM,UAAU,CAAC;AAG1E,MAAM,UAAU,aAAa,CAC3B,OAAgB,EAChB,IAAI,GAAG,EAAE,EACT,cAA2B,cAAc,EAAE;IAE3C,MAAM,IAAI,GAAG,iBAAiB,CAAC,OAAO,EAAE,WAAW,CAAC,CAAC;IACrD,OAAO,IAAI,GAAG,CAAC,IAAI,EAAE,IAAI,CAAC,CAAC;AAC7B,CAAC;AAED,MAAM,UAAU,KAAK,CACnB,OAAgB,EAChB,IAAY,EACZ,OAEC;IAED,MAAM,GAAG,GAAG,aAAa,CAAC,OAAO,EAAE,IAAI,CAAC,CAAC;IACzC,IAAI,OAAO,IAAI,OAAO,CAAC,MAAM,EAAE;QAC7B,MAAM,MAAM,GAAG,IAAI,eAAe,CAAC,OAAO,CAAC,MAAM,CAAC,CAAC;QACnD,GAAG,CAAC,MAAM,GAAG,MAAM,CAAC,QAAQ,EAAE,CAAC;KAChC;IACD,OAAO,GAAG,CAAC,QAAQ,EAAE,CAAC;AACxB,CAAC"}
@@ -0,0 +1,2 @@
1
+ export declare function sdk(): string;
2
+ //# sourceMappingURL=sdk.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sdk.d.ts","sourceRoot":"","sources":["../../../src/lib/sdk.ts"],"names":[],"mappings":"AAAA,wBAAgB,GAAG,IAAI,MAAM,CAE5B"}
@@ -0,0 +1,4 @@
1
+ export function sdk() {
2
+ return "@globus/sdk";
3
+ }
4
+ //# sourceMappingURL=sdk.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sdk.js","sourceRoot":"","sources":["../../../src/lib/sdk.ts"],"names":[],"mappings":"AAAA,MAAM,UAAU,GAAG;IACjB,OAAO,aAAa,CAAC;AACvB,CAAC"}
@@ -0,0 +1,4 @@
1
+ import type { Environment } from "../../core/global";
2
+ export declare const ID = "AUTH";
3
+ export declare const HOSTS: Partial<Record<Environment, string>>;
4
+ //# sourceMappingURL=config.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../../../../src/lib/services/auth/config.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,mBAAmB,CAAC;AAErD,eAAO,MAAM,EAAE,SAAS,CAAC;AACzB,eAAO,MAAM,KAAK,EAAE,OAAO,CAAC,MAAM,CAAC,WAAW,EAAE,MAAM,CAAC,CAOtD,CAAC"}
@@ -0,0 +1,10 @@
1
+ export const ID = "AUTH";
2
+ export const HOSTS = {
3
+ integration: "auth.integration.globuscs.info",
4
+ sandbox: "auth.sandbox.globuscs.info",
5
+ production: "auth.globus.org",
6
+ test: "auth.test.globuscs.info",
7
+ staging: "auth.staging.globuscs.info",
8
+ preview: "auth.preview.globus.org",
9
+ };
10
+ //# sourceMappingURL=config.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"config.js","sourceRoot":"","sources":["../../../../../src/lib/services/auth/config.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,EAAE,GAAG,MAAM,CAAC;AACzB,MAAM,CAAC,MAAM,KAAK,GAAyC;IACzD,WAAW,EAAE,gCAAgC;IAC7C,OAAO,EAAE,4BAA4B;IACrC,UAAU,EAAE,iBAAiB;IAC7B,IAAI,EAAE,yBAAyB;IAC/B,OAAO,EAAE,4BAA4B;IACrC,OAAO,EAAE,yBAAyB;CACnC,CAAC"}
@@ -0,0 +1,17 @@
1
+ import * as AUTH from "./config";
2
+ export declare const CONFIG: typeof AUTH;
3
+ import type ITokenResponse from "js-pkce/dist/ITokenResponse";
4
+ export declare function getAuthorizationEndpoint(): string;
5
+ export declare function getTokenEndpoint(): string;
6
+ export type Token = ITokenResponse & {
7
+ resource_server: string;
8
+ id_token?: string;
9
+ };
10
+ /**
11
+ * @see https://docs.globus.org/api/auth/reference/#authorization_code_grant_preferred
12
+ */
13
+ export type TokenResponse = Token & {
14
+ state: string;
15
+ other_tokens: Token[];
16
+ };
17
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/lib/services/auth/index.ts"],"names":[],"mappings":"AAQA,OAAO,KAAK,IAAI,MAAM,UAAU,CAAC;AACjC,eAAO,MAAM,MAAM,aAAO,CAAC;AAE3B,OAAO,KAAK,cAAc,MAAM,6BAA6B,CAAC;AAE9D,wBAAgB,wBAAwB,WAEvC;AAED,wBAAgB,gBAAgB,WAE/B;AAED,MAAM,MAAM,KAAK,GAAG,cAAc,GAAG;IACnC,eAAe,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB,CAAC;AACF;;GAEG;AACH,MAAM,MAAM,aAAa,GAAG,KAAK,GAAG;IAClC,KAAK,EAAE,MAAM,CAAC;IACd,YAAY,EAAE,KAAK,EAAE,CAAC;CACvB,CAAC"}
@@ -0,0 +1,16 @@
1
+ /**
2
+ * @description A wrapper around the Globus Auth service.
3
+ * @category Service
4
+ * @see [Globus Auth API Documentation](https://docs.globus.org/api/auth/)
5
+ * @module
6
+ */
7
+ import { build } from "../../core/url";
8
+ import * as AUTH from "./config";
9
+ export const CONFIG = AUTH;
10
+ export function getAuthorizationEndpoint() {
11
+ return build(AUTH.ID, "/v2/oauth2/authorize");
12
+ }
13
+ export function getTokenEndpoint() {
14
+ return build(AUTH.ID, "/v2/oauth2/token");
15
+ }
16
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/lib/services/auth/index.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,OAAO,EAAE,KAAK,EAAE,MAAM,gBAAgB,CAAC;AAEvC,OAAO,KAAK,IAAI,MAAM,UAAU,CAAC;AACjC,MAAM,CAAC,MAAM,MAAM,GAAG,IAAI,CAAC;AAI3B,MAAM,UAAU,wBAAwB;IACtC,OAAO,KAAK,CAAC,IAAI,CAAC,EAAE,EAAE,sBAAsB,CAAC,CAAC;AAChD,CAAC;AAED,MAAM,UAAU,gBAAgB;IAC9B,OAAO,KAAK,CAAC,IAAI,CAAC,EAAE,EAAE,kBAAkB,CAAC,CAAC;AAC5C,CAAC"}