@entur-partner/bff 1.1.0 → 1.2.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.
@@ -11,7 +11,6 @@ var proxy__default = /*#__PURE__*/_interopDefaultLegacy(proxy);
11
11
  var requireOAuth = function requireOAuth(req) {
12
12
  return /(^undefined$)|(^Bearer .+$)/gim.test(req.headers.authorization || '');
13
13
  };
14
-
15
14
  var proxyConfig = function proxyConfig(methods, proxyReqPathResolver) {
16
15
  var httpMethods = Array.isArray(methods) ? methods : [methods];
17
16
  return {
@@ -25,12 +24,10 @@ var proxyConfig = function proxyConfig(methods, proxyReqPathResolver) {
25
24
  limit: (process.env.UPLOAD_LIMIT_MB || 200) + "mb"
26
25
  };
27
26
  };
28
-
29
27
  var stripTrailingSlash = function stripTrailingSlash(url) {
30
28
  return url.endsWith('/') ? url.substring(0, url.length - 1) : url;
31
- }; // forwards a call of a specific url / set of methods to a remote server
32
-
33
-
29
+ };
30
+ // forwards a call of a specific url / set of methods to a remote server
34
31
  var forwardingProxy = function forwardingProxy(apiUrl) {
35
32
  return function (method, forwardPath) {
36
33
  return proxy__default["default"](apiUrl, proxyConfig(method, function () {
@@ -1 +1 @@
1
- {"version":3,"file":"bff.cjs.development.js","sources":["../src/forwardingproxy.ts"],"sourcesContent":["import proxy, { ProxyOptions } from 'express-http-proxy';\nimport { Request } from 'express';\n\nconst requireOAuth = (req: Request) =>\n /(^undefined$)|(^Bearer .+$)/gim.test(req.headers.authorization || '');\n\nexport const proxyConfig = (\n methods: string[],\n proxyReqPathResolver: Required<ProxyOptions>['proxyReqPathResolver']\n): Parameters<typeof proxy>[1] => {\n const httpMethods = Array.isArray(methods) ? methods : [methods];\n\n return {\n filter: (req: Request) =>\n httpMethods.includes(req.method) && requireOAuth(req),\n proxyReqPathResolver,\n proxyReqBodyDecorator: (bodyContent, _srcReq) => bodyContent,\n limit: `${process.env.UPLOAD_LIMIT_MB || 200}mb`,\n };\n};\n\nconst stripTrailingSlash = (url: string) =>\n url.endsWith('/') ? url.substring(0, url.length - 1) : url;\n\n// forwards a call of a specific url / set of methods to a remote server\nexport const forwardingProxy =\n (apiUrl: string) =>\n (method: string[], forwardPath: (...reqs: Request[]) => string) =>\n proxy(\n apiUrl,\n proxyConfig(\n method,\n (...params) =>\n stripTrailingSlash(new URL(apiUrl).pathname) + forwardPath(...params)\n )\n );\n"],"names":["requireOAuth","req","test","headers","authorization","proxyConfig","methods","proxyReqPathResolver","httpMethods","Array","isArray","filter","includes","method","proxyReqBodyDecorator","bodyContent","_srcReq","limit","process","env","UPLOAD_LIMIT_MB","stripTrailingSlash","url","endsWith","substring","length","forwardingProxy","apiUrl","forwardPath","proxy","URL","pathname"],"mappings":";;;;;;;;;;AAGA,IAAMA,YAAY,GAAG,SAAfA,YAAe,CAACC,GAAD,EAAA;AAAA,EACnB,OAAA,gCAAA,CAAiCC,IAAjC,CAAsCD,GAAG,CAACE,OAAJ,CAAYC,aAAZ,IAA6B,EAAnE,CADmB,CAAA;AAAA,CAArB,CAAA;;AAGO,IAAMC,WAAW,GAAG,SAAdA,WAAc,CACzBC,OADyB,EAEzBC,oBAFyB,EAGM;AAC/B,EAAA,IAAMC,WAAW,GAAGC,KAAK,CAACC,OAAN,CAAcJ,OAAd,CAAA,GAAyBA,OAAzB,GAAmC,CAACA,OAAD,CAAvD,CAAA;AAEA,EAAO,OAAA;AACLK,IAAAA,MAAM,EAAE,SAAA,MAAA,CAACV,GAAD,EAAA;AAAA,MACNO,OAAAA,WAAW,CAACI,QAAZ,CAAqBX,GAAG,CAACY,MAAzB,CAAoCb,IAAAA,YAAY,CAACC,GAAD,CAD1C,CAAA;AAAA,KADH;AAGLM,IAAAA,oBAAoB,EAApBA,oBAHK;AAILO,IAAAA,qBAAqB,EAAE,SAACC,qBAAAA,CAAAA,WAAD,EAAcC,OAAd,EAAA;AAAA,MAAA,OAA0BD,WAA1B,CAAA;AAAA,KAJlB;AAKLE,IAAAA,KAAK,GAAKC,OAAO,CAACC,GAAR,CAAYC,eAAZ,IAA+B,GAApC,IAAA,IAAA;AALA,GAAP,CAAA;AAOD,EAbM;;AAeP,IAAMC,kBAAkB,GAAG,SAArBA,kBAAqB,CAACC,GAAD,EAAA;AAAA,EAAA,OACzBA,GAAG,CAACC,QAAJ,CAAa,GAAb,CAAA,GAAoBD,GAAG,CAACE,SAAJ,CAAc,CAAd,EAAiBF,GAAG,CAACG,MAAJ,GAAa,CAA9B,CAApB,GAAuDH,GAD9B,CAAA;AAAA,CAA3B;;;IAIaI,eAAe,GAC1B,SADWA,eACX,CAACC,MAAD,EAAA;AAAA,EACA,OAAA,UAACd,MAAD,EAAmBe,WAAnB,EAAA;AAAA,IAAA,OACEC,yBAAK,CACHF,MADG,EAEHtB,WAAW,CACTQ,MADS,EAET,YAAA;AAAA,MAAA,OACEQ,kBAAkB,CAAC,IAAIS,GAAJ,CAAQH,MAAR,CAAgBI,CAAAA,QAAjB,CAAlB,GAA+CH,WAAW,CAAA,KAAX,CADjD,KAAA,CAAA,EAAA,SAAA,CAAA,CAAA;AAAA,KAFS,CAFR,CADP,CAAA;AAAA,GADA,CAAA;AAAA;;;;;"}
1
+ {"version":3,"file":"bff.cjs.development.js","sources":["../src/forwardingproxy.ts"],"sourcesContent":["import proxy, { ProxyOptions } from 'express-http-proxy';\nimport { Request } from 'express';\n\nconst requireOAuth = (req: Request) =>\n /(^undefined$)|(^Bearer .+$)/gim.test(req.headers.authorization || '');\n\nexport const proxyConfig = (\n methods: string[],\n proxyReqPathResolver: Required<ProxyOptions>['proxyReqPathResolver']\n): Parameters<typeof proxy>[1] => {\n const httpMethods = Array.isArray(methods) ? methods : [methods];\n\n return {\n filter: (req: Request) =>\n httpMethods.includes(req.method) && requireOAuth(req),\n proxyReqPathResolver,\n proxyReqBodyDecorator: (bodyContent, _srcReq) => bodyContent,\n limit: `${process.env.UPLOAD_LIMIT_MB || 200}mb`,\n };\n};\n\nconst stripTrailingSlash = (url: string) =>\n url.endsWith('/') ? url.substring(0, url.length - 1) : url;\n\n// forwards a call of a specific url / set of methods to a remote server\nexport const forwardingProxy =\n (apiUrl: string) =>\n (method: string[], forwardPath: (...reqs: Request[]) => string) =>\n proxy(\n apiUrl,\n proxyConfig(\n method,\n (...params) =>\n stripTrailingSlash(new URL(apiUrl).pathname) + forwardPath(...params)\n )\n );\n"],"names":["requireOAuth","req","test","headers","authorization","proxyConfig","methods","proxyReqPathResolver","httpMethods","Array","isArray","filter","includes","method","proxyReqBodyDecorator","bodyContent","_srcReq","limit","process","env","UPLOAD_LIMIT_MB","stripTrailingSlash","url","endsWith","substring","length","forwardingProxy","apiUrl","forwardPath","proxy","URL","pathname","apply","arguments"],"mappings":";;;;;;;;;;AAGA,IAAMA,YAAY,GAAG,SAAfA,YAAYA,CAAIC,GAAY,EAAA;EAAA,OAChC,gCAAgC,CAACC,IAAI,CAACD,GAAG,CAACE,OAAO,CAACC,aAAa,IAAI,EAAE,CAAC,CAAA;AAAA,CAAA,CAAA;AAEjE,IAAMC,WAAW,GAAG,SAAdA,WAAWA,CACtBC,OAAiB,EACjBC,oBAAoE,EACrC;AAC/B,EAAA,IAAMC,WAAW,GAAGC,KAAK,CAACC,OAAO,CAACJ,OAAO,CAAC,GAAGA,OAAO,GAAG,CAACA,OAAO,CAAC,CAAA;EAEhE,OAAO;IACLK,MAAM,EAAE,SAAAA,MAAAA,CAACV,GAAY,EAAA;AAAA,MAAA,OACnBO,WAAW,CAACI,QAAQ,CAACX,GAAG,CAACY,MAAM,CAAC,IAAIb,YAAY,CAACC,GAAG,CAAC,CAAA;AAAA,KAAA;AACvDM,IAAAA,oBAAoB,EAApBA,oBAAoB;AACpBO,IAAAA,qBAAqB,EAAE,SAAAA,qBAACC,CAAAA,WAAW,EAAEC,OAAO,EAAA;AAAA,MAAA,OAAKD,WAAW,CAAA;AAAA,KAAA;AAC5DE,IAAAA,KAAK,GAAKC,OAAO,CAACC,GAAG,CAACC,eAAe,IAAI,GAAG,IAAA,IAAA;GAC7C,CAAA;AACH,EAAC;AAED,IAAMC,kBAAkB,GAAG,SAArBA,kBAAkBA,CAAIC,GAAW,EAAA;EAAA,OACrCA,GAAG,CAACC,QAAQ,CAAC,GAAG,CAAC,GAAGD,GAAG,CAACE,SAAS,CAAC,CAAC,EAAEF,GAAG,CAACG,MAAM,GAAG,CAAC,CAAC,GAAGH,GAAG,CAAA;AAAA,CAAA,CAAA;AAE5D;IACaI,eAAe,GAC1B,SADWA,eAAeA,CACzBC,MAAc,EAAA;EAAA,OACf,UAACd,MAAgB,EAAEe,WAA2C,EAAA;AAAA,IAAA,OAC5DC,yBAAK,CACHF,MAAM,EACNtB,WAAW,CACTQ,MAAM,EACN,YAAA;AAAA,MAAA,OACEQ,kBAAkB,CAAC,IAAIS,GAAG,CAACH,MAAM,CAAC,CAACI,QAAQ,CAAC,GAAGH,WAAW,CAAAI,KAAA,CAAA,KAAA,CAAA,EAAAC,SAAU,CAAC,CAAA;AAAA,KAAA,CACxE,CACF,CAAA;AAAA,GAAA,CAAA;AAAA;;;;;"}
@@ -1 +1 @@
1
- {"version":3,"file":"bff.cjs.production.min.js","sources":["../src/forwardingproxy.ts"],"sourcesContent":["import proxy, { ProxyOptions } from 'express-http-proxy';\nimport { Request } from 'express';\n\nconst requireOAuth = (req: Request) =>\n /(^undefined$)|(^Bearer .+$)/gim.test(req.headers.authorization || '');\n\nexport const proxyConfig = (\n methods: string[],\n proxyReqPathResolver: Required<ProxyOptions>['proxyReqPathResolver']\n): Parameters<typeof proxy>[1] => {\n const httpMethods = Array.isArray(methods) ? methods : [methods];\n\n return {\n filter: (req: Request) =>\n httpMethods.includes(req.method) && requireOAuth(req),\n proxyReqPathResolver,\n proxyReqBodyDecorator: (bodyContent, _srcReq) => bodyContent,\n limit: `${process.env.UPLOAD_LIMIT_MB || 200}mb`,\n };\n};\n\nconst stripTrailingSlash = (url: string) =>\n url.endsWith('/') ? url.substring(0, url.length - 1) : url;\n\n// forwards a call of a specific url / set of methods to a remote server\nexport const forwardingProxy =\n (apiUrl: string) =>\n (method: string[], forwardPath: (...reqs: Request[]) => string) =>\n proxy(\n apiUrl,\n proxyConfig(\n method,\n (...params) =>\n stripTrailingSlash(new URL(apiUrl).pathname) + forwardPath(...params)\n )\n );\n"],"names":["proxyConfig","methods","proxyReqPathResolver","httpMethods","Array","isArray","filter","req","includes","method","test","headers","authorization","requireOAuth","proxyReqBodyDecorator","bodyContent","_srcReq","limit","process","env","UPLOAD_LIMIT_MB","stripTrailingSlash","url","endsWith","substring","length","apiUrl","forwardPath","proxy","URL","pathname","apply","arguments"],"mappings":"mLAMaA,EAAc,SACzBC,EACAC,GAEA,IAAMC,EAAcC,MAAMC,QAAQJ,GAAWA,EAAU,CAACA,GAEjD,MAAA,CACLK,OAAQ,SAACC,GACPJ,OAAAA,EAAYK,SAASD,EAAIE,SAXV,SAACF,GACpB,MAAA,iCAAiCG,KAAKH,EAAII,QAAQC,eAAiB,IAU3BC,CAAaN,IACnDL,qBAAAA,EACAY,sBAAuB,SAACC,EAAaC,GAAd,OAA0BD,GACjDE,OAAUC,QAAQC,IAAIC,iBAAmB,KAApC,OAIHC,EAAqB,SAACC,GAAD,OACzBA,EAAIC,SAAS,KAAOD,EAAIE,UAAU,EAAGF,EAAIG,OAAS,GAAKH,2BAIvD,SAACI,GACD,OAAA,SAACjB,EAAkBkB,GAAnB,OACEC,UACEF,EACA1B,EACES,GACA,WAAA,OACEY,EAAmB,IAAIQ,IAAIH,GAAQI,UAAYH,EAAWI,WAD5D,EAAAC"}
1
+ {"version":3,"file":"bff.cjs.production.min.js","sources":["../src/forwardingproxy.ts"],"sourcesContent":["import proxy, { ProxyOptions } from 'express-http-proxy';\nimport { Request } from 'express';\n\nconst requireOAuth = (req: Request) =>\n /(^undefined$)|(^Bearer .+$)/gim.test(req.headers.authorization || '');\n\nexport const proxyConfig = (\n methods: string[],\n proxyReqPathResolver: Required<ProxyOptions>['proxyReqPathResolver']\n): Parameters<typeof proxy>[1] => {\n const httpMethods = Array.isArray(methods) ? methods : [methods];\n\n return {\n filter: (req: Request) =>\n httpMethods.includes(req.method) && requireOAuth(req),\n proxyReqPathResolver,\n proxyReqBodyDecorator: (bodyContent, _srcReq) => bodyContent,\n limit: `${process.env.UPLOAD_LIMIT_MB || 200}mb`,\n };\n};\n\nconst stripTrailingSlash = (url: string) =>\n url.endsWith('/') ? url.substring(0, url.length - 1) : url;\n\n// forwards a call of a specific url / set of methods to a remote server\nexport const forwardingProxy =\n (apiUrl: string) =>\n (method: string[], forwardPath: (...reqs: Request[]) => string) =>\n proxy(\n apiUrl,\n proxyConfig(\n method,\n (...params) =>\n stripTrailingSlash(new URL(apiUrl).pathname) + forwardPath(...params)\n )\n );\n"],"names":["proxyConfig","methods","proxyReqPathResolver","httpMethods","Array","isArray","filter","req","includes","method","test","headers","authorization","requireOAuth","proxyReqBodyDecorator","bodyContent","_srcReq","limit","process","env","UPLOAD_LIMIT_MB","stripTrailingSlash","url","endsWith","substring","length","apiUrl","forwardPath","proxy","URL","pathname","apply","arguments"],"mappings":"mLAMaA,EAAc,SACzBC,EACAC,GAEA,IAAMC,EAAcC,MAAMC,QAAQJ,GAAWA,EAAU,CAACA,GAExD,MAAO,CACLK,OAAQ,SAACC,GAAY,OACnBJ,EAAYK,SAASD,EAAIE,SAXV,SAACF,GAAY,MAChC,iCAAiCG,KAAKH,EAAII,QAAQC,eAAiB,IAU3BC,CAAaN,IACnDL,qBAAAA,EACAY,sBAAuB,SAACC,EAAaC,GAAO,OAAKD,GACjDE,OAAUC,QAAQC,IAAIC,iBAAmB,KAAG,OAI1CC,EAAqB,SAACC,GAAW,OACrCA,EAAIC,SAAS,KAAOD,EAAIE,UAAU,EAAGF,EAAIG,OAAS,GAAKH,2BAIvD,SAACI,GAAc,OACf,SAACjB,EAAkBkB,GAA2C,OAC5DC,UACEF,EACA1B,EACES,GACA,WAAA,OACEY,EAAmB,IAAIQ,IAAIH,GAAQI,UAAYH,EAAWI,WAAA,EAAAC"}
package/dist/bff.esm.js CHANGED
@@ -3,7 +3,6 @@ import proxy from 'express-http-proxy';
3
3
  var requireOAuth = function requireOAuth(req) {
4
4
  return /(^undefined$)|(^Bearer .+$)/gim.test(req.headers.authorization || '');
5
5
  };
6
-
7
6
  var proxyConfig = function proxyConfig(methods, proxyReqPathResolver) {
8
7
  var httpMethods = Array.isArray(methods) ? methods : [methods];
9
8
  return {
@@ -17,12 +16,10 @@ var proxyConfig = function proxyConfig(methods, proxyReqPathResolver) {
17
16
  limit: (process.env.UPLOAD_LIMIT_MB || 200) + "mb"
18
17
  };
19
18
  };
20
-
21
19
  var stripTrailingSlash = function stripTrailingSlash(url) {
22
20
  return url.endsWith('/') ? url.substring(0, url.length - 1) : url;
23
- }; // forwards a call of a specific url / set of methods to a remote server
24
-
25
-
21
+ };
22
+ // forwards a call of a specific url / set of methods to a remote server
26
23
  var forwardingProxy = function forwardingProxy(apiUrl) {
27
24
  return function (method, forwardPath) {
28
25
  return proxy(apiUrl, proxyConfig(method, function () {
@@ -1 +1 @@
1
- {"version":3,"file":"bff.esm.js","sources":["../src/forwardingproxy.ts"],"sourcesContent":["import proxy, { ProxyOptions } from 'express-http-proxy';\nimport { Request } from 'express';\n\nconst requireOAuth = (req: Request) =>\n /(^undefined$)|(^Bearer .+$)/gim.test(req.headers.authorization || '');\n\nexport const proxyConfig = (\n methods: string[],\n proxyReqPathResolver: Required<ProxyOptions>['proxyReqPathResolver']\n): Parameters<typeof proxy>[1] => {\n const httpMethods = Array.isArray(methods) ? methods : [methods];\n\n return {\n filter: (req: Request) =>\n httpMethods.includes(req.method) && requireOAuth(req),\n proxyReqPathResolver,\n proxyReqBodyDecorator: (bodyContent, _srcReq) => bodyContent,\n limit: `${process.env.UPLOAD_LIMIT_MB || 200}mb`,\n };\n};\n\nconst stripTrailingSlash = (url: string) =>\n url.endsWith('/') ? url.substring(0, url.length - 1) : url;\n\n// forwards a call of a specific url / set of methods to a remote server\nexport const forwardingProxy =\n (apiUrl: string) =>\n (method: string[], forwardPath: (...reqs: Request[]) => string) =>\n proxy(\n apiUrl,\n proxyConfig(\n method,\n (...params) =>\n stripTrailingSlash(new URL(apiUrl).pathname) + forwardPath(...params)\n )\n );\n"],"names":["requireOAuth","req","test","headers","authorization","proxyConfig","methods","proxyReqPathResolver","httpMethods","Array","isArray","filter","includes","method","proxyReqBodyDecorator","bodyContent","_srcReq","limit","process","env","UPLOAD_LIMIT_MB","stripTrailingSlash","url","endsWith","substring","length","forwardingProxy","apiUrl","forwardPath","proxy","URL","pathname"],"mappings":";;AAGA,IAAMA,YAAY,GAAG,SAAfA,YAAe,CAACC,GAAD,EAAA;AAAA,EACnB,OAAA,gCAAA,CAAiCC,IAAjC,CAAsCD,GAAG,CAACE,OAAJ,CAAYC,aAAZ,IAA6B,EAAnE,CADmB,CAAA;AAAA,CAArB,CAAA;;AAGO,IAAMC,WAAW,GAAG,SAAdA,WAAc,CACzBC,OADyB,EAEzBC,oBAFyB,EAGM;AAC/B,EAAA,IAAMC,WAAW,GAAGC,KAAK,CAACC,OAAN,CAAcJ,OAAd,CAAA,GAAyBA,OAAzB,GAAmC,CAACA,OAAD,CAAvD,CAAA;AAEA,EAAO,OAAA;AACLK,IAAAA,MAAM,EAAE,SAAA,MAAA,CAACV,GAAD,EAAA;AAAA,MACNO,OAAAA,WAAW,CAACI,QAAZ,CAAqBX,GAAG,CAACY,MAAzB,CAAoCb,IAAAA,YAAY,CAACC,GAAD,CAD1C,CAAA;AAAA,KADH;AAGLM,IAAAA,oBAAoB,EAApBA,oBAHK;AAILO,IAAAA,qBAAqB,EAAE,SAACC,qBAAAA,CAAAA,WAAD,EAAcC,OAAd,EAAA;AAAA,MAAA,OAA0BD,WAA1B,CAAA;AAAA,KAJlB;AAKLE,IAAAA,KAAK,GAAKC,OAAO,CAACC,GAAR,CAAYC,eAAZ,IAA+B,GAApC,IAAA,IAAA;AALA,GAAP,CAAA;AAOD,EAbM;;AAeP,IAAMC,kBAAkB,GAAG,SAArBA,kBAAqB,CAACC,GAAD,EAAA;AAAA,EAAA,OACzBA,GAAG,CAACC,QAAJ,CAAa,GAAb,CAAA,GAAoBD,GAAG,CAACE,SAAJ,CAAc,CAAd,EAAiBF,GAAG,CAACG,MAAJ,GAAa,CAA9B,CAApB,GAAuDH,GAD9B,CAAA;AAAA,CAA3B;;;IAIaI,eAAe,GAC1B,SADWA,eACX,CAACC,MAAD,EAAA;AAAA,EACA,OAAA,UAACd,MAAD,EAAmBe,WAAnB,EAAA;AAAA,IAAA,OACEC,KAAK,CACHF,MADG,EAEHtB,WAAW,CACTQ,MADS,EAET,YAAA;AAAA,MAAA,OACEQ,kBAAkB,CAAC,IAAIS,GAAJ,CAAQH,MAAR,CAAgBI,CAAAA,QAAjB,CAAlB,GAA+CH,WAAW,CAAA,KAAX,CADjD,KAAA,CAAA,EAAA,SAAA,CAAA,CAAA;AAAA,KAFS,CAFR,CADP,CAAA;AAAA,GADA,CAAA;AAAA;;;;"}
1
+ {"version":3,"file":"bff.esm.js","sources":["../src/forwardingproxy.ts"],"sourcesContent":["import proxy, { ProxyOptions } from 'express-http-proxy';\nimport { Request } from 'express';\n\nconst requireOAuth = (req: Request) =>\n /(^undefined$)|(^Bearer .+$)/gim.test(req.headers.authorization || '');\n\nexport const proxyConfig = (\n methods: string[],\n proxyReqPathResolver: Required<ProxyOptions>['proxyReqPathResolver']\n): Parameters<typeof proxy>[1] => {\n const httpMethods = Array.isArray(methods) ? methods : [methods];\n\n return {\n filter: (req: Request) =>\n httpMethods.includes(req.method) && requireOAuth(req),\n proxyReqPathResolver,\n proxyReqBodyDecorator: (bodyContent, _srcReq) => bodyContent,\n limit: `${process.env.UPLOAD_LIMIT_MB || 200}mb`,\n };\n};\n\nconst stripTrailingSlash = (url: string) =>\n url.endsWith('/') ? url.substring(0, url.length - 1) : url;\n\n// forwards a call of a specific url / set of methods to a remote server\nexport const forwardingProxy =\n (apiUrl: string) =>\n (method: string[], forwardPath: (...reqs: Request[]) => string) =>\n proxy(\n apiUrl,\n proxyConfig(\n method,\n (...params) =>\n stripTrailingSlash(new URL(apiUrl).pathname) + forwardPath(...params)\n )\n );\n"],"names":["requireOAuth","req","test","headers","authorization","proxyConfig","methods","proxyReqPathResolver","httpMethods","Array","isArray","filter","includes","method","proxyReqBodyDecorator","bodyContent","_srcReq","limit","process","env","UPLOAD_LIMIT_MB","stripTrailingSlash","url","endsWith","substring","length","forwardingProxy","apiUrl","forwardPath","proxy","URL","pathname","apply","arguments"],"mappings":";;AAGA,IAAMA,YAAY,GAAG,SAAfA,YAAYA,CAAIC,GAAY,EAAA;EAAA,OAChC,gCAAgC,CAACC,IAAI,CAACD,GAAG,CAACE,OAAO,CAACC,aAAa,IAAI,EAAE,CAAC,CAAA;AAAA,CAAA,CAAA;AAEjE,IAAMC,WAAW,GAAG,SAAdA,WAAWA,CACtBC,OAAiB,EACjBC,oBAAoE,EACrC;AAC/B,EAAA,IAAMC,WAAW,GAAGC,KAAK,CAACC,OAAO,CAACJ,OAAO,CAAC,GAAGA,OAAO,GAAG,CAACA,OAAO,CAAC,CAAA;EAEhE,OAAO;IACLK,MAAM,EAAE,SAAAA,MAAAA,CAACV,GAAY,EAAA;AAAA,MAAA,OACnBO,WAAW,CAACI,QAAQ,CAACX,GAAG,CAACY,MAAM,CAAC,IAAIb,YAAY,CAACC,GAAG,CAAC,CAAA;AAAA,KAAA;AACvDM,IAAAA,oBAAoB,EAApBA,oBAAoB;AACpBO,IAAAA,qBAAqB,EAAE,SAAAA,qBAACC,CAAAA,WAAW,EAAEC,OAAO,EAAA;AAAA,MAAA,OAAKD,WAAW,CAAA;AAAA,KAAA;AAC5DE,IAAAA,KAAK,GAAKC,OAAO,CAACC,GAAG,CAACC,eAAe,IAAI,GAAG,IAAA,IAAA;GAC7C,CAAA;AACH,EAAC;AAED,IAAMC,kBAAkB,GAAG,SAArBA,kBAAkBA,CAAIC,GAAW,EAAA;EAAA,OACrCA,GAAG,CAACC,QAAQ,CAAC,GAAG,CAAC,GAAGD,GAAG,CAACE,SAAS,CAAC,CAAC,EAAEF,GAAG,CAACG,MAAM,GAAG,CAAC,CAAC,GAAGH,GAAG,CAAA;AAAA,CAAA,CAAA;AAE5D;IACaI,eAAe,GAC1B,SADWA,eAAeA,CACzBC,MAAc,EAAA;EAAA,OACf,UAACd,MAAgB,EAAEe,WAA2C,EAAA;AAAA,IAAA,OAC5DC,KAAK,CACHF,MAAM,EACNtB,WAAW,CACTQ,MAAM,EACN,YAAA;AAAA,MAAA,OACEQ,kBAAkB,CAAC,IAAIS,GAAG,CAACH,MAAM,CAAC,CAACI,QAAQ,CAAC,GAAGH,WAAW,CAAAI,KAAA,CAAA,KAAA,CAAA,EAAAC,SAAU,CAAC,CAAA;AAAA,KAAA,CACxE,CACF,CAAA;AAAA,GAAA,CAAA;AAAA;;;;"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@entur-partner/bff",
3
- "version": "1.1.0",
3
+ "version": "1.2.1",
4
4
  "license": "EUPL-1.2",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/bff.esm.js",
@@ -23,10 +23,10 @@
23
23
  "lint": "dts lint"
24
24
  },
25
25
  "dependencies": {
26
- "express-http-proxy": "1.6.3"
26
+ "express-http-proxy": "^1.6.3"
27
27
  },
28
28
  "devDependencies": {
29
- "@types/express-http-proxy": "1.6.3"
29
+ "@types/express-http-proxy": "1.6.6"
30
30
  },
31
31
  "jest": {
32
32
  "collectCoverageFrom": [
@@ -38,5 +38,5 @@
38
38
  "reportFile": "jest-sonar-report.xml",
39
39
  "indent": 4
40
40
  },
41
- "gitHead": "1b60c3d704fdb4d30d0a24d5eb68c4334d065ae0"
41
+ "gitHead": "c691310480d1a3416eb5d2d2a3a7ceaba47ffda1"
42
42
  }