@tramvai/module-http-client 1.45.0 → 1.46.8
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/lib/index.browser.js +2 -0
- package/lib/index.d.ts +2 -0
- package/lib/index.es.js +2 -0
- package/lib/index.js +13 -0
- package/package.json +11 -11
package/lib/index.browser.js
CHANGED
|
@@ -2,6 +2,7 @@ import { __decorate } from 'tslib';
|
|
|
2
2
|
import { createToken } from '@tinkoff/dippy';
|
|
3
3
|
import { Module, provide, Scope, APP_INFO_TOKEN } from '@tramvai/core';
|
|
4
4
|
import { PAPI_SERVICE, HTTP_CLIENT_FACTORY, API_CLIENT_PASS_HEADERS, HTTP_CLIENT_AGENT, HTTP_CLIENT } from '@tramvai/tokens-http-client';
|
|
5
|
+
export * from '@tramvai/tokens-http-client';
|
|
5
6
|
import { LOGGER_TOKEN, ENV_MANAGER_TOKEN, REQUEST_MANAGER_TOKEN, ENV_USED_TOKEN, CREATE_CACHE_TOKEN } from '@tramvai/tokens-common';
|
|
6
7
|
import isNil from '@tinkoff/utils/is/nil';
|
|
7
8
|
import omit from '@tinkoff/utils/object/omit';
|
|
@@ -10,6 +11,7 @@ import { mergeOptions, createTinkoffRequest, HttpClientAdapter } from '@tramvai/
|
|
|
10
11
|
import { SERVER_MODULE_PAPI_PUBLIC_URL } from '@tramvai/tokens-server';
|
|
11
12
|
import prop from '@tinkoff/utils/object/prop';
|
|
12
13
|
import { ApiService } from '@tramvai/http-client';
|
|
14
|
+
export * from '@tramvai/http-client';
|
|
13
15
|
|
|
14
16
|
const fillHeaders = (deps) => (params) => {
|
|
15
17
|
return params;
|
package/lib/index.d.ts
CHANGED
|
@@ -3,3 +3,5 @@ export { httpClientFactory } from './httpClient/httpClientFactory';
|
|
|
3
3
|
export { PapiService } from './papiClientModule';
|
|
4
4
|
export { fillHeaderIp, fillHeaders } from './utils/fillHeaders';
|
|
5
5
|
export { formatError } from './utils/errors';
|
|
6
|
+
export * from '@tramvai/tokens-http-client';
|
|
7
|
+
export * from '@tramvai/http-client';
|
package/lib/index.es.js
CHANGED
|
@@ -2,6 +2,7 @@ import { __decorate } from 'tslib';
|
|
|
2
2
|
import { createChildContainer, createToken } from '@tinkoff/dippy';
|
|
3
3
|
import { Module, provide, Scope, DI_TOKEN, APP_INFO_TOKEN } from '@tramvai/core';
|
|
4
4
|
import { PAPI_SERVICE, HTTP_CLIENT_FACTORY, API_CLIENT_PASS_HEADERS, HTTP_CLIENT_AGENT, HTTP_CLIENT } from '@tramvai/tokens-http-client';
|
|
5
|
+
export * from '@tramvai/tokens-http-client';
|
|
5
6
|
import { LOGGER_TOKEN, ENV_MANAGER_TOKEN, REQUEST_MANAGER_TOKEN, ENV_USED_TOKEN, CREATE_CACHE_TOKEN } from '@tramvai/tokens-common';
|
|
6
7
|
import isNil from '@tinkoff/utils/is/nil';
|
|
7
8
|
import omit from '@tinkoff/utils/object/omit';
|
|
@@ -14,6 +15,7 @@ import { SERVER_MODULE_PAPI_PUBLIC_ROUTE } from '@tramvai/tokens-server';
|
|
|
14
15
|
import find from '@tinkoff/utils/array/find';
|
|
15
16
|
import { getPapiParameters } from '@tramvai/papi';
|
|
16
17
|
import { REQUEST, RESPONSE } from '@tramvai/module-common';
|
|
18
|
+
export * from '@tramvai/http-client';
|
|
17
19
|
|
|
18
20
|
const fillHeaderIp = ({ requestManager, }) => {
|
|
19
21
|
if (!requestManager) {
|
package/lib/index.js
CHANGED
|
@@ -18,6 +18,7 @@ var tokensServer = require('@tramvai/tokens-server');
|
|
|
18
18
|
var find = require('@tinkoff/utils/array/find');
|
|
19
19
|
var papi = require('@tramvai/papi');
|
|
20
20
|
var moduleCommon = require('@tramvai/module-common');
|
|
21
|
+
var httpClient = require('@tramvai/http-client');
|
|
21
22
|
|
|
22
23
|
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
23
24
|
|
|
@@ -358,3 +359,15 @@ exports.fillHeaderIp = fillHeaderIp;
|
|
|
358
359
|
exports.fillHeaders = fillHeaders;
|
|
359
360
|
exports.formatError = formatError;
|
|
360
361
|
exports.httpClientFactory = httpClientFactory;
|
|
362
|
+
Object.keys(tokensHttpClient).forEach(function (k) {
|
|
363
|
+
if (k !== 'default' && !exports.hasOwnProperty(k)) Object.defineProperty(exports, k, {
|
|
364
|
+
enumerable: true,
|
|
365
|
+
get: function () { return tokensHttpClient[k]; }
|
|
366
|
+
});
|
|
367
|
+
});
|
|
368
|
+
Object.keys(httpClient).forEach(function (k) {
|
|
369
|
+
if (k !== 'default' && !exports.hasOwnProperty(k)) Object.defineProperty(exports, k, {
|
|
370
|
+
enumerable: true,
|
|
371
|
+
get: function () { return httpClient[k]; }
|
|
372
|
+
});
|
|
373
|
+
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tramvai/module-http-client",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.46.8",
|
|
4
4
|
"initialVersion": "0.58.99",
|
|
5
5
|
"description": "",
|
|
6
6
|
"main": "lib/index.js",
|
|
@@ -25,22 +25,22 @@
|
|
|
25
25
|
},
|
|
26
26
|
"dependencies": {
|
|
27
27
|
"@tramvai/http-client": "0.1.23",
|
|
28
|
-
"@tramvai/tinkoff-request-http-client-adapter": "0.8.
|
|
29
|
-
"@tramvai/tokens-http-client": "1.
|
|
30
|
-
"@tramvai/tokens-common": "1.
|
|
31
|
-
"@tramvai/tokens-server": "1.
|
|
28
|
+
"@tramvai/tinkoff-request-http-client-adapter": "0.8.208",
|
|
29
|
+
"@tramvai/tokens-http-client": "1.46.8",
|
|
30
|
+
"@tramvai/tokens-common": "1.46.8",
|
|
31
|
+
"@tramvai/tokens-server": "1.46.8"
|
|
32
32
|
},
|
|
33
33
|
"devDependencies": {
|
|
34
34
|
"@tinkoff/request-core": "^0.8.9"
|
|
35
35
|
},
|
|
36
36
|
"peerDependencies": {
|
|
37
37
|
"@tinkoff/utils": "^2.1.2",
|
|
38
|
-
"@tramvai/core": "1.
|
|
39
|
-
"@tramvai/module-common": "1.
|
|
40
|
-
"@tramvai/papi": "1.
|
|
41
|
-
"@tramvai/test-helpers": "1.
|
|
42
|
-
"@tramvai/test-mocks": "1.
|
|
43
|
-
"@tinkoff/dippy": "0.7.
|
|
38
|
+
"@tramvai/core": "1.46.8",
|
|
39
|
+
"@tramvai/module-common": "1.46.8",
|
|
40
|
+
"@tramvai/papi": "1.46.8",
|
|
41
|
+
"@tramvai/test-helpers": "1.46.8",
|
|
42
|
+
"@tramvai/test-mocks": "1.46.8",
|
|
43
|
+
"@tinkoff/dippy": "0.7.36",
|
|
44
44
|
"node-fetch": "^2.6.1",
|
|
45
45
|
"tslib": "^2.0.3"
|
|
46
46
|
},
|