@globus/sdk 1.17.0 → 1.18.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cjs/lib/services/auth/index.d.ts +1 -0
- package/cjs/lib/services/auth/index.d.ts.map +1 -1
- package/cjs/lib/services/auth/index.js +2 -1
- package/cjs/lib/services/auth/index.js.map +1 -1
- package/cjs/lib/services/auth/service/oauth2/index.d.ts +2 -0
- package/cjs/lib/services/auth/service/oauth2/index.d.ts.map +1 -0
- package/cjs/lib/services/auth/service/oauth2/index.js +6 -0
- package/cjs/lib/services/auth/service/oauth2/index.js.map +1 -0
- package/cjs/lib/services/auth/service/oauth2/token.d.ts +46 -0
- package/cjs/lib/services/auth/service/oauth2/token.d.ts.map +1 -0
- package/cjs/lib/services/auth/service/oauth2/token.js +48 -0
- package/cjs/lib/services/auth/service/oauth2/token.js.map +1 -0
- package/cjs/lib/services/groups/service/groups.d.ts.map +1 -1
- package/cjs/lib/services/groups/service/groups.js +13 -12
- package/cjs/lib/services/groups/service/groups.js.map +1 -1
- package/cjs/lib/services/groups/service/membership.d.ts.map +1 -1
- package/cjs/lib/services/groups/service/membership.js +7 -4
- package/cjs/lib/services/groups/service/membership.js.map +1 -1
- package/cjs/lib/services/groups/service/policies.d.ts +1 -1
- package/cjs/lib/services/groups/service/policies.d.ts.map +1 -1
- package/cjs/lib/services/groups/service/policies.js +7 -5
- package/cjs/lib/services/groups/service/policies.js.map +1 -1
- package/cjs/lib/services/shared.d.ts +2 -2
- package/cjs/lib/services/shared.d.ts.map +1 -1
- package/cjs/lib/services/shared.js +37 -5
- package/cjs/lib/services/shared.js.map +1 -1
- package/cjs/lib/services/transfer/config.js +1 -1
- package/cjs/lib/services/transfer/config.js.map +1 -1
- package/cjs/lib/services/types.d.ts +18 -2
- package/cjs/lib/services/types.d.ts.map +1 -1
- package/esm/lib/services/auth/index.d.ts +1 -0
- package/esm/lib/services/auth/index.d.ts.map +1 -1
- package/esm/lib/services/auth/index.js +1 -0
- package/esm/lib/services/auth/index.js.map +1 -1
- package/esm/lib/services/auth/service/oauth2/index.d.ts +2 -0
- package/esm/lib/services/auth/service/oauth2/index.d.ts.map +1 -0
- package/esm/lib/services/auth/service/oauth2/index.js +2 -0
- package/esm/lib/services/auth/service/oauth2/index.js.map +1 -0
- package/esm/lib/services/auth/service/oauth2/token.d.ts +46 -0
- package/esm/lib/services/auth/service/oauth2/token.d.ts.map +1 -0
- package/esm/lib/services/auth/service/oauth2/token.js +45 -0
- package/esm/lib/services/auth/service/oauth2/token.js.map +1 -0
- package/esm/lib/services/groups/service/groups.d.ts.map +1 -1
- package/esm/lib/services/groups/service/groups.js +13 -12
- package/esm/lib/services/groups/service/groups.js.map +1 -1
- package/esm/lib/services/groups/service/membership.d.ts.map +1 -1
- package/esm/lib/services/groups/service/membership.js +7 -4
- package/esm/lib/services/groups/service/membership.js.map +1 -1
- package/esm/lib/services/groups/service/policies.d.ts +1 -1
- package/esm/lib/services/groups/service/policies.d.ts.map +1 -1
- package/esm/lib/services/groups/service/policies.js +7 -5
- package/esm/lib/services/groups/service/policies.js.map +1 -1
- package/esm/lib/services/shared.d.ts +2 -2
- package/esm/lib/services/shared.d.ts.map +1 -1
- package/esm/lib/services/shared.js +36 -5
- package/esm/lib/services/shared.js.map +1 -1
- package/esm/lib/services/transfer/config.js +1 -1
- package/esm/lib/services/transfer/config.js.map +1 -1
- package/esm/lib/services/types.d.ts +18 -2
- package/esm/lib/services/types.d.ts.map +1 -1
- package/package.json +1 -1
- package/umd/globus.production.js +1 -1
- package/cjs/lib/core/fetch.d.ts +0 -18
- package/cjs/lib/core/fetch.d.ts.map +0 -1
- package/cjs/lib/core/fetch.js +0 -34
- package/cjs/lib/core/fetch.js.map +0 -1
- package/cjs/lib/core/internals/fetch.d.ts +0 -2
- package/cjs/lib/core/internals/fetch.d.ts.map +0 -1
- package/cjs/lib/core/internals/fetch.js +0 -7
- package/cjs/lib/core/internals/fetch.js.map +0 -1
- package/esm/lib/core/fetch.d.ts +0 -18
- package/esm/lib/core/fetch.d.ts.map +0 -1
- package/esm/lib/core/fetch.js +0 -30
- package/esm/lib/core/fetch.js.map +0 -1
- package/esm/lib/core/internals/fetch.d.ts +0 -2
- package/esm/lib/core/internals/fetch.d.ts.map +0 -1
- package/esm/lib/core/internals/fetch.js +0 -3
- package/esm/lib/core/internals/fetch.js.map +0 -1
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"fetch.js","sourceRoot":"","sources":["../../../../../src/lib/core/internals/fetch.ts"],"names":[],"mappings":";;;;AAAA,sEAAiC;AAEpB,QAAA,KAAK,GAAG,qBAAM,CAAC"}
|
package/esm/lib/core/fetch.d.ts
DELETED
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { fetch } from './internals/fetch.js';
|
|
2
|
-
type GlobusScope = string;
|
|
3
|
-
/**
|
|
4
|
-
* Properties that will be passed to underlying `fetch` calls to override behavior.
|
|
5
|
-
* @see https://developer.mozilla.org/en-US/docs/Web/API/fetch#parameters
|
|
6
|
-
*/
|
|
7
|
-
export type FetchOverrides = (Omit<RequestInit, 'headers'> & {
|
|
8
|
-
headers?: Record<string, string>;
|
|
9
|
-
/**
|
|
10
|
-
* Provide an implementation of `fetch` to be used.
|
|
11
|
-
* This is currently **not** advertised since we do not dynamically import `cross-fetch` yet.
|
|
12
|
-
* @private
|
|
13
|
-
*/
|
|
14
|
-
__callable?: typeof fetch;
|
|
15
|
-
}) | undefined;
|
|
16
|
-
export declare function fetchWithScope(scope: GlobusScope, input: RequestInfo | URL, fetchOverrides?: FetchOverrides): Promise<Response>;
|
|
17
|
-
export {};
|
|
18
|
-
//# sourceMappingURL=fetch.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"fetch.d.ts","sourceRoot":"","sources":["../../../../src/lib/core/fetch.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,EAAE,MAAM,sBAAsB,CAAC;AAG7C,KAAK,WAAW,GAAG,MAAM,CAAC;AAE1B;;;GAGG;AACH,MAAM,MAAM,cAAc,GACtB,CAAC,IAAI,CAAC,WAAW,EAAE,SAAS,CAAC,GAAG;IAC9B,OAAO,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACjC;;;;OAIG;IACH,UAAU,CAAC,EAAE,OAAO,KAAK,CAAC;CAC3B,CAAC,GACF,SAAS,CAAC;AAEd,wBAAgB,cAAc,CAC5B,KAAK,EAAE,WAAW,EAClB,KAAK,EAAE,WAAW,GAAG,GAAG,EACxB,cAAc,GAAE,cAAmB,qBAkCpC"}
|
package/esm/lib/core/fetch.js
DELETED
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
/* eslint-disable no-underscore-dangle */
|
|
2
|
-
import { fetch } from './internals/fetch.js';
|
|
3
|
-
import { getTokenForScope } from './consent.js';
|
|
4
|
-
export function fetchWithScope(scope, input, fetchOverrides = {}) {
|
|
5
|
-
const headers = fetchOverrides.headers || {};
|
|
6
|
-
/**
|
|
7
|
-
* If an `Authorization` override header was provided, we skip any
|
|
8
|
-
* sort of lookup and use the provided value.
|
|
9
|
-
*/
|
|
10
|
-
if (!(headers === null || headers === void 0 ? void 0 : headers['Authorization'])) {
|
|
11
|
-
const token = getTokenForScope(scope);
|
|
12
|
-
if (token) {
|
|
13
|
-
headers['Authorization'] = token;
|
|
14
|
-
}
|
|
15
|
-
}
|
|
16
|
-
/**
|
|
17
|
-
* If `Content-Type` header was not provided, and there is a body, we assume it is JSON.
|
|
18
|
-
*/
|
|
19
|
-
if (!(headers === null || headers === void 0 ? void 0 : headers['Content-Type']) && (fetchOverrides === null || fetchOverrides === void 0 ? void 0 : fetchOverrides.body)) {
|
|
20
|
-
headers['Content-Type'] = 'application/json';
|
|
21
|
-
}
|
|
22
|
-
/**
|
|
23
|
-
* If a `__callable` override was provided, we use it instead of the default `fetch`.
|
|
24
|
-
*/
|
|
25
|
-
if (fetchOverrides === null || fetchOverrides === void 0 ? void 0 : fetchOverrides.__callable) {
|
|
26
|
-
return fetchOverrides.__callable(input, Object.assign(Object.assign({}, fetchOverrides), { headers }));
|
|
27
|
-
}
|
|
28
|
-
return fetch(input, Object.assign(Object.assign({}, fetchOverrides), { headers }));
|
|
29
|
-
}
|
|
30
|
-
//# sourceMappingURL=fetch.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"fetch.js","sourceRoot":"","sources":["../../../../src/lib/core/fetch.ts"],"names":[],"mappings":"AAAA,yCAAyC;AACzC,OAAO,EAAE,KAAK,EAAE,MAAM,sBAAsB,CAAC;AAC7C,OAAO,EAAE,gBAAgB,EAAE,MAAM,cAAc,CAAC;AAoBhD,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;;OAEG;IACH,IAAI,CAAC,CAAA,OAAO,aAAP,OAAO,uBAAP,OAAO,CAAG,cAAc,CAAC,CAAA,KAAI,cAAc,aAAd,cAAc,uBAAd,cAAc,CAAE,IAAI,CAAA,EAAE;QACtD,OAAO,CAAC,cAAc,CAAC,GAAG,kBAAkB,CAAC;KAC9C;IAED;;OAEG;IACH,IAAI,cAAc,aAAd,cAAc,uBAAd,cAAc,CAAE,UAAU,EAAE;QAC9B,OAAO,cAAc,CAAC,UAAU,CAAC,KAAK,kCACjC,cAAc,KACjB,OAAO,IACP,CAAC;KACJ;IAED,OAAO,KAAK,CAAC,KAAK,kCACb,cAAc,KACjB,OAAO,IACP,CAAC;AACL,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"fetch.d.ts","sourceRoot":"","sources":["../../../../../src/lib/core/internals/fetch.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,KAAK,yBAAS,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"fetch.js","sourceRoot":"","sources":["../../../../../src/lib/core/internals/fetch.ts"],"names":[],"mappings":"AAAA,OAAO,MAAM,MAAM,aAAa,CAAC;AAEjC,MAAM,CAAC,MAAM,KAAK,GAAG,MAAM,CAAC"}
|