@foxiko/client
Advanced tools
Comparing version 1.0.29 to 1.0.30
@@ -26,3 +26,3 @@ const {COMMUNICATION} = require("../Networking"); | ||
async getPDFByBody(body, size = "A4") { | ||
const data = await this.client.request(await this.client.getAccessToken(['identity_security'])) | ||
const data = await this.client.request() | ||
.url(COMMUNICATION.PDF.CREATE_PDF) | ||
@@ -29,0 +29,0 @@ .params({ |
@@ -33,25 +33,24 @@ const {FoxikoCloud} = require("./cloud/FoxikoCloud"); | ||
initializeIdentity() { | ||
this.#client.scopes.push(['identity']); | ||
this.identity = new FoxikoIdentity(this.#client); | ||
this.#client.scopes.push(['identity']); | ||
return this; | ||
} | ||
initializeCommunication() { | ||
this.#client.scopes.push('communication'); | ||
this.communication = new FoxikoCommunication(this.#client); | ||
this.#client.scopes.push('communication'); | ||
return this; | ||
} | ||
initializeCloud() { | ||
this.#client.scopes.push('cloud'); | ||
this.cloud = new FoxikoCloud(this.#client); | ||
this.#client.scopes.push('cloud'); | ||
return this; | ||
} | ||
initializeFinance(accountId) { | ||
this.#client.scopes.push('finance'); | ||
this.finance = new FoxikoFinance(accountId, this.#client); | ||
this.#client.scopes.push('finance'); | ||
console.log(this.#client); | ||
return this; | ||
} | ||
initializePay() { | ||
this.#client.scopes.push('pay'); | ||
this.pay = new FoxikoPay(this.#client); | ||
this.#client.scopes.push('pay'); | ||
return this; | ||
@@ -58,0 +57,0 @@ } |
{ | ||
"name": "@foxiko/client", | ||
"version": "1.0.29", | ||
"version": "1.0.30", | ||
"description": "", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
const {IdentityServer} = require("../identity/IdentityServer"); | ||
const {AUTHORIZATION, IDENTITY} = require("../Networking"); | ||
const {OAuthClient} = require("@foxiko/oauth"); | ||
const oAuthClient = new OAuthClient({ | ||
clientId: "a147be12-58a6-4c72-a2ee-41559c69c82e", | ||
clientSecret: "ef760ebb-b9df-4f32-9217-c6ce35ff1238", | ||
tokenUrl: "http://localhost/v1/token" | ||
// tokenUrl: AUTHORIZATION.TOKEN | ||
}); | ||
oAuthClient.getAccessToken(["cloud", "finance"]).then(a => console.log(a)); | ||
const {FoxikoAPI} = require("../FoxikoAPI"); | ||
const foxikoAPI = new FoxikoAPI({ | ||
}).initializeCommunication().initializeFinance("fin"); | ||
foxikoAPI.client().getStandardHeaders() | ||
.then(a => console.log(a)).catch(e => console.error(e)); |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
131866
2170