diff --git a/packages/openapi-to-graphql/README.md b/packages/openapi-to-graphql/README.md index 5e0c3922..2354f368 100644 --- a/packages/openapi-to-graphql/README.md +++ b/packages/openapi-to-graphql/README.md @@ -176,7 +176,7 @@ Resolver options: - `qs` (type: `object`, default: `{}`): Query parameters to be sent in every request to the API. Parameters defined in the OpenAPI Specification and set by these query parameters will be ignored by OpenAPI-to-GraphQL. -- `requestOptions` (type: `object`, default: `{}`): Additional [options](https://github.com/request/request#requestoptions-callback), provided by the [`Request` module](https://github.com/request/request), that can be used to configure the HTTP calls that powers the generated GraphQL resolvers. A common use case for this option is to set up a web proxy with the `proxy` field. Parameters defined in the OpenAPI Specification and set by this option will be ignored by OpenAPI-to-GraphQL. Additionally, the `headers` field has the feature of being used as a function. If used as a function, the following parameters will be exposed per-request: the operation's `method`, the operation's `path`, the API `title`, and `resolverParams` (the [GraphQL resolver's parameters](https://graphql.org/learn/execution/#root-fields-resolvers)). The function should return the desired headers. +- `requestOptions` (type: `object` | `function`, default: `{}`): Additional [options](https://github.com/request/request#requestoptions-callback), provided by the [`Request` module](https://github.com/request/request), that can be used to configure the HTTP calls that powers the generated GraphQL resolvers. A common use case for this option is to set up a web proxy with the `proxy` field. Parameters defined in the OpenAPI Specification and set by this option will be ignored by OpenAPI-to-GraphQL. Additionally, the `headers` field has the feature of being used as a function. If used as a function, the following parameters will be exposed per-request: the operation's `method`, the operation's `path`, the API `title`, and `resolverParams` (the [GraphQL resolver's parameters](https://graphql.org/learn/execution/#root-fields-resolvers)). The function should return the desired headers. If `requestOptions` is used as a function, the following parameters will be exposed per-request: the operation's `method`, the operation's `path`, the API `title`, and `resolverParams` (the [GraphQL resolver's parameters](https://graphql.org/learn/execution/#root-fields-resolvers)). It should return object of type [options](https://github.com/request/request#requestoptions-callback). If `requestOptions` is used as a function `url` and `method` can also be set. - `baseUrl` (type: `string`): Used to manually specify the base URL which all paths will be built on. Normally, OpenAPI-to-GraphQL will select a base URL from the [server object](https://github.com/OAI/OpenAPI-Specification/blob/master/versions/3.0.2.md#serverObject) defined in the OAS. However, if the server object contains multiple URLs, OpenAPI-to-GraphQL will randomly select one. The purpose of this option is to provide greater control over the base URL in these situations, especially when the OAS cannot be modified. This option may also prove to be useful in testing and development. diff --git a/packages/openapi-to-graphql/lib/index.js.map b/packages/openapi-to-graphql/lib/index.js.map index 5a4bfc07..15b650f6 100644 --- a/packages/openapi-to-graphql/lib/index.js.map +++ b/packages/openapi-to-graphql/lib/index.js.map @@ -1 +1 @@ -{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";AAAA,iDAAiD;AACjD,kCAAkC;AAClC,+CAA+C;AAC/C,gEAAgE;;;AAuChE,6CAIwB;AAGxB,qCAKgB;AAEhB,WAAW;AACX,qDAA0D;AAC1D,yDAI2B;AAC3B,gDAA+C;AAC/C,iDAA8C;AAC9C,2CAA0C;AAC1C,iDAAoD;AACpD,iCAAyB;AAEzB,mCAAoE;AAEpE,MAAM,cAAc,GAAG,eAAK,CAAC,aAAa,CAAC,CAAA;AAQ3C,MAAM,eAAe,GAAmC;IACtD,MAAM,EAAE;QACN,QAAQ,EAAE,EAAE;QACZ,MAAM,EAAE,CAAC;QACT,WAAW,EAAE,CAAC;QACd,cAAc,EAAE,CAAC;QACjB,kBAAkB,EAAE,CAAC;QACrB,iBAAiB,EAAE,CAAC;QACpB,mBAAmB,EAAE,CAAC;QACtB,uBAAuB,EAAE,CAAC;KAC3B;IAED,0BAA0B;IAC1B,MAAM,EAAE,KAAK;IAEb,iBAAiB;IACjB,qBAAqB,EAAE,KAAK;IAC5B,kBAAkB,EAAE,KAAK;IACzB,gBAAgB,EAAE,KAAK;IACvB,SAAS,EAAE,EAAE;IACb,0BAA0B,EAAE,EAAE;IAC9B,qBAAqB,EAAE,KAAK;IAC5B,WAAW,EAAE,KAAK;IAClB,gBAAgB,EAAE,KAAK;IACvB,aAAa,EAAE,KAAK;IACpB,gCAAgC,EAAE,KAAK;IAEvC,mBAAmB;IACnB,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EAAE,IAAI,CAAC,CAAA;IAE5D,oCAAoC;IACpC,6BAA6B,CAAC,OAAO,CAAC,2BAA2B,EAAE,IAAI,CAAC,CAAA;AAC1E,CAAC;AAED,6CAAmD;AAA1C,uGAAA,QAAQ,OAAA;AAAE,wGAAA,SAAS,OAAA;AAC5B,2CAAsD;AAA7C,+GAAA,oBAAoB,OAAA"} \ No newline at end of file diff --git a/packages/openapi-to-graphql/lib/resolver_builder.d.ts b/packages/openapi-to-graphql/lib/resolver_builder.d.ts index 7135e709..aede332a 100644 --- a/packages/openapi-to-graphql/lib/resolver_builder.d.ts +++ b/packages/openapi-to-graphql/lib/resolver_builder.d.ts @@ -7,7 +7,7 @@ import { ConnectOptions } from './types/options'; import { Operation } from './types/operation'; import { SubscriptionContext } from './types/graphql'; import { PreprocessingData } from './types/preprocessing_data'; -import { RequestOptions } from './types/options'; +import { RequestOptions, RequestOptionsFunction } from './types/options'; import { GraphQLFieldResolver } from 'graphql'; import { IncomingHttpHeaders } from 'http'; export declare const OPENAPI_TO_GRAPHQL = "_openAPIToGraphQL"; @@ -20,7 +20,7 @@ declare type GetResolverParams = { responseName?: string; data: PreprocessingData; baseUrl?: string; - requestOptions?: Partial>; + requestOptions?: Partial> | RequestOptionsFunction; }; declare type GetSubscribeParams = { operation: Operation; diff --git a/packages/openapi-to-graphql/lib/resolver_builder.js b/packages/openapi-to-graphql/lib/resolver_builder.js index c19b24a9..93e21a75 100644 --- a/packages/openapi-to-graphql/lib/resolver_builder.js +++ b/packages/openapi-to-graphql/lib/resolver_builder.js @@ -283,7 +283,7 @@ function getResolver({ operation, argsFromLink = {}, payloadName, data, baseUrl, resolveData.usedParams = Object.assign(resolveData.usedParams, args); // Build URL (i.e., fill in path parameters): const { path, qs, headers } = extractRequestDataFromArgs(operation.path, operation.parameters, args, data); - const url = baseUrl + path; + let url = baseUrl + path; /** * The Content-Type and Accept property should not be changed because the * object type has already been created and unlike these properties, it @@ -303,17 +303,33 @@ function getResolver({ operation, argsFromLink = {}, payloadName, data, baseUrl, : 'application/json'; let options; if (requestOptions) { - options = Object.assign(Object.assign({}, requestOptions), { method: operation.method, url // Must be after the requestOptions spread as url is a mandatory field so undefined may be used + let requestOptionsVal = requestOptions; + let method = operation.method; + if (typeof requestOptions === 'function') { + requestOptionsVal = requestOptions(method, path, title, { + source, + args, + context, + info + }); + if (requestOptionsVal.url && requestOptionsVal.url.toString().trim().length > 0) { + url = requestOptionsVal.url.toString().trim(); + } + if (requestOptionsVal.method && requestOptionsVal.method.length > 0) { + method = Oas3Tools.methodToHttpMethod(requestOptionsVal.method); + } + } + options = Object.assign(Object.assign({}, requestOptionsVal), { method: method, url // Must be after the requestOptions spread as url is a mandatory field so undefined may be used }); options.headers = {}; // Handle requestOptions.header later if applicable options.qs = {}; // Handle requestOptions.qs later if applicable - if (requestOptions.headers) { + if (requestOptionsVal.headers) { // requestOptions.headers may be either an object or a function - if (typeof requestOptions.headers === 'object') { - Object.assign(options.headers, headers, requestOptions.headers); + if (typeof requestOptionsVal.headers === 'object') { + Object.assign(options.headers, headers, requestOptionsVal.headers); } - else if (typeof requestOptions.headers === 'function') { - const headers = requestOptions.headers(method, path, title, { + else if (typeof requestOptionsVal.headers === 'function') { + const headers = requestOptionsVal.headers(method, path, title, { source, args, context, @@ -327,8 +343,8 @@ function getResolver({ operation, argsFromLink = {}, payloadName, data, baseUrl, else { options.headers = headers; } - if (requestOptions.qs) { - Object.assign(options.qs, qs, requestOptions.qs); + if (requestOptionsVal.qs) { + Object.assign(options.qs, qs, requestOptionsVal.qs); } else { options.qs = qs; diff --git a/packages/openapi-to-graphql/lib/resolver_builder.js.map b/packages/openapi-to-graphql/lib/resolver_builder.js.map index 76411bac..ee657bc7 100644 --- a/packages/openapi-to-graphql/lib/resolver_builder.js.map +++ b/packages/openapi-to-graphql/lib/resolver_builder.js.map @@ -1 +1 @@ -{"version":3,"file":"resolver_builder.js","sourceRoot":"","sources":["../src/resolver_builder.ts"],"names":[],"mappings":";AAAA,iDAAi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,IAAI,IAAI,CAAC,aAAa,CAAC,IAAI,CAAA;oBAC7D,MAAK;gBAEP;oBACE,OAAO,CACL,oCAAoC,KAAK,CAAC,EAAE,WAAW;wBACrD,cAAc,KAAK,CAAC,IAAI,mBAAmB,IAAI,WAAW;wBAC1D,WAAW,CACd,CAAA;aACJ;SACF;KACF;IAED,OAAO,EAAE,IAAI,EAAE,EAAE,EAAE,OAAO,EAAE,CAAA;AAC9B,CAAC;AA3DD,gEA2DC"} \ No newline at end of file +{"version":3,"file":"resolver_builder.js","sourceRoot":"","sources":["../src/resolver_builder.ts"],"names":[],"mappings":";AAAA,iDAAiD;AACjD,kCAAkC;AAClC,+CAA+C;AAC/C,gEAAgE;;;AAYhE,uCAAsC;AAGtC,WAAW;AACX,2CAA0C;AAC1C,2CAA0C;AAC1C,0CAAyC;AACzC,iCAA6B;AAC7B,qCAA4D;AAC5D,qDAA4C;AAC5C,iEAA8C;AAG9C,MAAM,MAAM,GAAG,IAAI,8BAAM,EAAE,CAAA;AAE3B,MAAM,cAAc,GAAG,aAAK,CAAC,aAAa,CAAC,CAAA;AAC3C,MAAM,OAAO,GAAG,aAAK,CAAC,MAAM,CAAC,CAAA;AAC7B,MAAM,SAAS,GAAG,aAAK,CAAC,QAAQ,CAAC,CAAA;AAEjC,6CAA6C;AAC7C,MAAM,kBAAkB,GAAG,CAAC,SAAS,EAAE,QAAQ,EAAE,OAAO,EAAE,MAAM,CAAC,CAAA;AAEpD,QAAA,kBAAkB,GAAG,mBAAmB,CAAA;AAmErD;;;;GAIG;AACH,SAAgB,YAAY,CAA2B,EACrD,SAAS,EACT,WAAW,EACX,IAAI,EACJ,OAAO,EACP,cAAc,EAC+B;IAK7C,iCAAiC;IACjC,IAAI,OAAO,OAAO,KAAK,WAAW,EAAE;QAClC,OAAO,GAAG,SAAS,CAAC,UAAU,CAAC,SAAS,CAAC,CAAA;KAC1C;IAED,0CAA0C;IAC1C,MAAM,eAAe,GAAG,IAAI,CAAC,OAAO,CAAC,2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C1D,WAAW,CACd,CAAA;aACJ;SACF;KACF;IAED,OAAO,EAAE,IAAI,EAAE,EAAE,EAAE,OAAO,EAAE,CAAA;AAC9B,CAAC;AA3DD,gEA2DC"} \ No newline at end of file diff --git a/packages/openapi-to-graphql/lib/types/options.d.ts b/packages/openapi-to-graphql/lib/types/options.d.ts index 898c1d53..12cc86fc 100644 --- a/packages/openapi-to-graphql/lib/types/options.d.ts +++ b/packages/openapi-to-graphql/lib/types/options.d.ts @@ -43,6 +43,12 @@ export declare type RequestHeadersFunction = (method: context: TContext; info: GraphQLResolveInfo; }) => Headers; +export declare type RequestOptionsFunction = (method: string, path: string, title: string, resolverParams?: { + source: TSource; + args: TArgs; + context: TContext; + info: GraphQLResolveInfo; +}) => Partial; /** * We rely on the Request library in order to make resolver API calls. * @@ -175,7 +181,7 @@ export declare type InternalOptions = { * * Based on: https://github.com/request/request#requestoptions-callback */ - requestOptions?: Partial>; + requestOptions?: Partial> | RequestOptionsFunction; /** * Allows to override or add options to the PubSub connect object used to make * publish/subscribe to the API backend. diff --git a/packages/openapi-to-graphql/src/index.ts b/packages/openapi-to-graphql/src/index.ts index 514f5b9b..48a1e7ce 100644 --- a/packages/openapi-to-graphql/src/index.ts +++ b/packages/openapi-to-graphql/src/index.ts @@ -36,6 +36,7 @@ import { InternalOptions, Report, ConnectOptions, + RequestOptionsFunction, RequestOptions } from './types/options' import { Oas3 } from './types/oas3' @@ -640,7 +641,9 @@ function getFieldForOperation( operation: Operation, baseUrl: string, data: PreprocessingData, - requestOptions: Partial>, + requestOptions: + | Partial> + | RequestOptionsFunction, connectOptions: ConnectOptions ): GraphQLFieldConfig { // Create GraphQL Type for response: diff --git a/packages/openapi-to-graphql/src/resolver_builder.ts b/packages/openapi-to-graphql/src/resolver_builder.ts index 2c4a88e5..44cbd355 100644 --- a/packages/openapi-to-graphql/src/resolver_builder.ts +++ b/packages/openapi-to-graphql/src/resolver_builder.ts @@ -14,7 +14,7 @@ import { Operation } from './types/operation' import { SubscriptionContext } from './types/graphql' import { PreprocessingData } from './types/preprocessing_data' import * as NodeRequest from 'request' -import { RequestOptions } from './types/options' +import { RequestOptions, RequestOptionsFunction } from './types/options' // Imports: import * as Oas3Tools from './oas_3_tools' @@ -57,7 +57,9 @@ type GetResolverParams = { responseName?: string data: PreprocessingData baseUrl?: string - requestOptions?: Partial> + requestOptions?: + | Partial> + | RequestOptionsFunction } type GetSubscribeParams = { @@ -487,7 +489,7 @@ export function getResolver({ args, data ) - const url = baseUrl + path + let url = baseUrl + path /** * The Content-Type and Accept property should not be changed because the @@ -510,21 +512,41 @@ export function getResolver({ let options: NodeRequest.OptionsWithUrl if (requestOptions) { + let requestOptionsVal: any = requestOptions + let method = operation.method + if (typeof requestOptions === 'function') { + requestOptionsVal = requestOptions(method, path, title, { + source, + args, + context, + info + }) + + if ( + requestOptionsVal.url && + requestOptionsVal.url.toString().trim().length > 0 + ) { + url = requestOptionsVal.url.toString().trim() + } + if (requestOptionsVal.method && requestOptionsVal.method.length > 0) { + method = Oas3Tools.methodToHttpMethod(requestOptionsVal.method) + } + } options = { - ...requestOptions, - method: operation.method, + ...requestOptionsVal, + method: method, url // Must be after the requestOptions spread as url is a mandatory field so undefined may be used } options.headers = {} // Handle requestOptions.header later if applicable options.qs = {} // Handle requestOptions.qs later if applicable - if (requestOptions.headers) { + if (requestOptionsVal.headers) { // requestOptions.headers may be either an object or a function - if (typeof requestOptions.headers === 'object') { - Object.assign(options.headers, headers, requestOptions.headers) - } else if (typeof requestOptions.headers === 'function') { - const headers = requestOptions.headers(method, path, title, { + if (typeof requestOptionsVal.headers === 'object') { + Object.assign(options.headers, headers, requestOptionsVal.headers) + } else if (typeof requestOptionsVal.headers === 'function') { + const headers = requestOptionsVal.headers(method, path, title, { source, args, context, @@ -539,8 +561,8 @@ export function getResolver({ options.headers = headers } - if (requestOptions.qs) { - Object.assign(options.qs, qs, requestOptions.qs) + if (requestOptionsVal.qs) { + Object.assign(options.qs, qs, requestOptionsVal.qs) } else { options.qs = qs } diff --git a/packages/openapi-to-graphql/src/types/options.ts b/packages/openapi-to-graphql/src/types/options.ts index 5c416063..f3a33ad5 100644 --- a/packages/openapi-to-graphql/src/types/options.ts +++ b/packages/openapi-to-graphql/src/types/options.ts @@ -60,6 +60,18 @@ export type RequestHeadersFunction = ( } ) => Headers +export type RequestOptionsFunction = ( + method: string, + path: string, + title: string, + resolverParams?: { + source: TSource + args: TArgs + context: TContext + info: GraphQLResolveInfo + } +) => Partial + /** * We rely on the Request library in order to make resolver API calls. * @@ -219,7 +231,9 @@ export type InternalOptions = { * * Based on: https://github.com/request/request#requestoptions-callback */ - requestOptions?: Partial> + requestOptions?: + | Partial> + | RequestOptionsFunction /** * Allows to override or add options to the PubSub connect object used to make