cimpress-fulfiller-identity
Advanced tools
Comparing version 0.2.1 to 0.2.2
@@ -44,2 +44,3 @@ 'use strict'; | ||
} | ||
this.timeout = options.timeout ? options.timeout : 3000; | ||
this.baseUrl = options.url ? options.url : "https://fulfilleridentity.trdlnk.cimpress.io"; | ||
@@ -199,6 +200,4 @@ this.xrayPRoxy = new XRayProxy(this.authorizer, awsXRay); | ||
value: function makeRequest(authorization, method, url, body) { | ||
var timeout = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : 3000; | ||
var params = { | ||
timeout: timeout, | ||
timeout: this.timeout, | ||
method: method, | ||
@@ -205,0 +204,0 @@ url: url, |
{ | ||
"name": "cimpress-fulfiller-identity", | ||
"version": "0.2.1", | ||
"version": "0.2.2", | ||
"description": "Thin client library for Cimpress' Fulfiller Identity service", | ||
@@ -5,0 +5,0 @@ "main": "./lib/index.js", |
@@ -27,2 +27,3 @@ # Cimpress Fulfiller Identity client | ||
url: 'string', // Base url of the service, by default it will be fulfilleridentity.trdlnk.cimpress.io | ||
timeout: 3000, // Default timeout to use for retrieving fulfillers | ||
retries: 3, // By default there are 3 retries | ||
@@ -29,0 +30,0 @@ retryDelayInMs: 1000 //Default: 1000 |
@@ -30,2 +30,3 @@ const axios = require('axios'); | ||
} | ||
this.timeout = options.timeout ? options.timeout : 3000; | ||
this.baseUrl = options.url ? options.url : "https://fulfilleridentity.trdlnk.cimpress.io"; | ||
@@ -166,5 +167,5 @@ this.xrayPRoxy = new XRayProxy(this.authorizer, awsXRay); | ||
makeRequest(authorization, method, url, body, timeout = 3000) { | ||
makeRequest(authorization, method, url, body) { | ||
let params = { | ||
timeout, | ||
timeout: this.timeout, | ||
method, | ||
@@ -171,0 +172,0 @@ url, |
57068
1125
136