MethodFi / method-node

Node.js library for the Method API
MIT License
4 stars 4 forks source link

Expose custom httpsAgent for Axios #40

Closed na-wu closed 1 year ago

na-wu commented 1 year ago

Customers should be able to pass in a custom httpsAgent under httpsAgent

import { Method, Environments } from 'method-node';
import HttpsProxyAgent from 'https-proxy-agent';

const customAgent = new HttpsProxyAgent('url');

const method = new Method({
  apiKey: '<API_KEY>',
  env: Environments.dev,
  httpsAgent: customAgent,
});