smartling-api-sdk-nodejs 1.4.0 → 1.4.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.
|
@@ -2,5 +2,5 @@ projectKey=smartling-api-sdk-nodejs
|
|
|
2
2
|
serverUrl=https://sonar-next.connectors.stg.smartling.net
|
|
3
3
|
serverVersion=8.6.1.40680
|
|
4
4
|
dashboardUrl=https://sonar-next.connectors.stg.smartling.net/dashboard?id=smartling-api-sdk-nodejs
|
|
5
|
-
ceTaskId=
|
|
6
|
-
ceTaskUrl=https://sonar-next.connectors.stg.smartling.net/api/ce/task?id=
|
|
5
|
+
ceTaskId=AYaeDUlIgRVcM-XZbdjJ
|
|
6
|
+
ceTaskUrl=https://sonar-next.connectors.stg.smartling.net/api/ce/task?id=AYaeDUlIgRVcM-XZbdjJ
|
package/api/builder/index.ts
CHANGED
|
@@ -79,6 +79,7 @@ export class SmartlingApiClientBuilder {
|
|
|
79
79
|
|
|
80
80
|
this.authApiClient.setClientLibId(this.clientLibId);
|
|
81
81
|
this.authApiClient.setClientLibVersion(this.clientLibVersion);
|
|
82
|
+
this.authApiClient.setOptions(this.httpClientOptions);
|
|
82
83
|
}
|
|
83
84
|
|
|
84
85
|
const instance = new constructor(this.baseSmartlingApiUrl, this.authApiClient, this.logger);
|
|
@@ -48,6 +48,7 @@ class SmartlingApiClientBuilder {
|
|
|
48
48
|
this.authApiClient = new index_1.SmartlingAuthApi(this.baseSmartlingApiUrl, this.userId, this.userSecret, this.logger);
|
|
49
49
|
this.authApiClient.setClientLibId(this.clientLibId);
|
|
50
50
|
this.authApiClient.setClientLibVersion(this.clientLibVersion);
|
|
51
|
+
this.authApiClient.setOptions(this.httpClientOptions);
|
|
51
52
|
}
|
|
52
53
|
const instance = new constructor(this.baseSmartlingApiUrl, this.authApiClient, this.logger);
|
|
53
54
|
instance.setClientLibId(this.clientLibId);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../api/builder/index.ts"],"names":[],"mappings":";;;AAAA,yCAAiD;AAKjD,MAAM,WAAW,GAAG,OAAO,CAAC,oBAAoB,CAAC,CAAC;AAElD,MAAa,yBAAyB;IAAtC;QACc,kBAAa,GAAqB,IAAI,CAAC;QACvC,WAAM,GAAW,IAAI,CAAC;QACtB,eAAU,GAAW,IAAI,CAAC;QAE1B,sBAAiB,GAA4B,EAAE,CAAC;QAChD,gBAAW,GAAW,WAAW,CAAC,IAAI,CAAC;QACvC,qBAAgB,GAAW,WAAW,CAAC,OAAO,CAAC;QAC/C,WAAM,GAAW;YAEvB,KAAK,EAAE,GAAG,EAAE,GAAE,CAAC;YAEf,IAAI,EAAE,GAAG,EAAE,GAAE,CAAC;YAEd,KAAK,EAAE,GAAG,EAAE,GAAE,CAAC;SAClB,CAAC;
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../api/builder/index.ts"],"names":[],"mappings":";;;AAAA,yCAAiD;AAKjD,MAAM,WAAW,GAAG,OAAO,CAAC,oBAAoB,CAAC,CAAC;AAElD,MAAa,yBAAyB;IAAtC;QACc,kBAAa,GAAqB,IAAI,CAAC;QACvC,WAAM,GAAW,IAAI,CAAC;QACtB,eAAU,GAAW,IAAI,CAAC;QAE1B,sBAAiB,GAA4B,EAAE,CAAC;QAChD,gBAAW,GAAW,WAAW,CAAC,IAAI,CAAC;QACvC,qBAAgB,GAAW,WAAW,CAAC,OAAO,CAAC;QAC/C,WAAM,GAAW;YAEvB,KAAK,EAAE,GAAG,EAAE,GAAE,CAAC;YAEf,IAAI,EAAE,GAAG,EAAE,GAAE,CAAC;YAEd,KAAK,EAAE,GAAG,EAAE,GAAE,CAAC;SAClB,CAAC;IAsEN,CAAC;IApEU,SAAS,CAAC,MAAc;QAC3B,IAAI,CAAC,MAAM,GAAG,MAAM,CAAC;QAErB,OAAO,IAAI,CAAC;IAChB,CAAC;IAEM,sBAAsB,CAAC,mBAA2B;QACrD,IAAI,CA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C,aAAa,EAAE,IAAI,CAAC,MAAM,CAAC,CAAC;QAE5F,QAAQ,CAAC,cAAc,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC;QAC1C,QAAQ,CAAC,mBAAmB,CAAC,IAAI,CAAC,gBAAgB,CAAC,CAAC;QACpD,QAAQ,CAAC,UAAU,CAAC,IAAI,CAAC,iBAAiB,CAAC,CAAC;QAE5C,OAAO,QAAQ,CAAC;IACpB,CAAC;CACJ;AArFD,8DAqFC"}
|
package/built/package.json
CHANGED
package/package.json
CHANGED
package/test/builder.spec.ts
CHANGED
|
@@ -229,6 +229,17 @@ describe("SmartlingApiClientBuilder class tests.", () => {
|
|
|
229
229
|
);
|
|
230
230
|
});
|
|
231
231
|
|
|
232
|
+
it("should provide http client options to auth client", () => {
|
|
233
|
+
const httpClientOptions = { test: "value" };
|
|
234
|
+
const apiClient = new SmartlingApiClientBuilder()
|
|
235
|
+
.authWithUserIdAndUserSecret("test_user_id", "test_user_secret")
|
|
236
|
+
.setBaseSmartlingApiUrl("test_base_url")
|
|
237
|
+
.setHttpClientConfiguration(httpClientOptions)
|
|
238
|
+
.build(SmartlingJobsApi);
|
|
239
|
+
|
|
240
|
+
assert.equal(apiClient["options"], httpClientOptions);
|
|
241
|
+
});
|
|
242
|
+
|
|
232
243
|
it("Instantiates files api client", () => {
|
|
233
244
|
assertApiClient(
|
|
234
245
|
SmartlingFilesApi,
|