Skip to content

Commit

Permalink
Merge pull request #503 from XeroAPI/csrf
Browse files Browse the repository at this point in the history
refactors use of params and check for csrf
  • Loading branch information
RettBehrens authored Mar 15, 2021
2 parents a1b4008 + 7041360 commit 8de095c
Show file tree
Hide file tree
Showing 18 changed files with 18,887 additions and 14,048 deletions.
32,899 changes: 18,869 additions & 14,030 deletions docs/v4/accounting/index.html

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/v4/assets/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -1314,7 +1314,7 @@ <h1>Xero Assets API</h1>
<h2 id="welcome-to-apidoc">API and SDK Documentation</h2>
<div class="app-desc">Version: 1.0.0</div>
<!--
<div class="app-desc">Version: 2.9.4</div>
<div class="app-desc">Version: 2.10.0</div>
<hr>
<div id="app-description" class="app-desc">
The Assets API exposes fixed asset related functions of the Xero Accounting application and can be used for a variety of purposes such as creating assets, retrieving asset valuations etc.
Expand Down
2 changes: 1 addition & 1 deletion docs/v4/bankfeeds/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -1188,7 +1188,7 @@ <h1>Xero Bank Feeds API</h1>
<h2 id="welcome-to-apidoc">API and SDK Documentation</h2>
<div class="app-desc">Version: 1.0.0</div>
<!--
<div class="app-desc">Version: 2.9.4</div>
<div class="app-desc">Version: 2.10.0</div>
<hr>
<div id="app-description" class="app-desc">
The Bank Feeds API is a closed API that is only available to financial institutions that have an established financial services partnership with Xero. If you're an existing financial services partner that wants access, contact your local Partner Manager. If you're a financial institution who wants to provide bank feeds to your business customers, contact us to become a financial services partner.
Expand Down
2 changes: 1 addition & 1 deletion docs/v4/files/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -1107,7 +1107,7 @@ <h1>Xero Files API</h1>
<h2 id="welcome-to-apidoc">API and SDK Documentation</h2>
<div class="app-desc">Version: 1.0.0</div>
<!--
<div class="app-desc">Version: 2.9.4</div>
<div class="app-desc">Version: 2.10.0</div>
<hr>
<div id="app-description" class="app-desc">
These endpoints are specific to Xero Files API
Expand Down
2 changes: 1 addition & 1 deletion docs/v4/payroll-au/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -3225,7 +3225,7 @@ <h1>Xero Payroll AU API</h1>
<h2 id="welcome-to-apidoc">API and SDK Documentation</h2>
<div class="app-desc">Version: 1.0.0</div>
<!--
<div class="app-desc">Version: 2.9.4</div>
<div class="app-desc">Version: 2.10.0</div>
<hr>
<div id="app-description" class="app-desc">
This is the Xero Payroll API for orgs in Australia region.
Expand Down
2 changes: 1 addition & 1 deletion docs/v4/payroll-uk/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -3621,7 +3621,7 @@ <h1>Xero Payroll UK</h1>
<h2 id="welcome-to-apidoc">API and SDK Documentation</h2>
<div class="app-desc">Version: 1.0.0</div>
<!--
<div class="app-desc">Version: 2.9.4</div>
<div class="app-desc">Version: 2.10.0</div>
<hr>
<div id="app-description" class="app-desc">
This is the Xero Payroll API for orgs in the UK region.
Expand Down
2 changes: 1 addition & 1 deletion docs/v4/projects/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -1412,7 +1412,7 @@ <h1>Xero Projects API</h1>
<h2 id="welcome-to-apidoc">API and SDK Documentation</h2>
<div class="app-desc">Version: 1.0.0</div>
<!--
<div class="app-desc">Version: 2.9.4</div>
<div class="app-desc">Version: 2.10.0</div>
<hr>
<div id="app-description" class="app-desc">
This is the Xero Projects API
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "xero-node",
"version": "4.10.2",
"version": "4.10.3",
"description": "Xero NodeJS OAuth 2.0 client for xero-node",
"main": "dist/index.js",
"types": "dist/index.d.ts",
Expand Down
2 changes: 1 addition & 1 deletion src/XeroClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ export class XeroClient {

public async apiCallback(callbackUrl: string): Promise<TokenSet> {
const params = this.openIdClient.callbackParams(callbackUrl);
const check = { ...params };
const check = { state: this.config.state };
if (this.config.scopes.includes('openid')) {
this._tokenSet = await this.openIdClient.callback(this.config.redirectUris[0], params, check);
} else {
Expand Down
2 changes: 1 addition & 1 deletion src/gen/api/accountingApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ export enum AccountingApiApiKeys {

export class AccountingApi {
protected _basePath = defaultBasePath;
protected defaultHeaders : any = {'user-agent': 'xero-node-4.10.2'};
protected defaultHeaders : any = {'user-agent': 'xero-node-4.10.3'};
protected _useQuerystring : boolean = false;
protected binaryHeaders : any = {};

Expand Down
2 changes: 1 addition & 1 deletion src/gen/api/assetApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ export enum AssetApiApiKeys {

export class AssetApi {
protected _basePath = defaultBasePath;
protected defaultHeaders : any = {'user-agent': 'xero-node-4.10.2'};
protected defaultHeaders : any = {'user-agent': 'xero-node-4.10.3'};
protected _useQuerystring : boolean = false;
protected binaryHeaders : any = {};

Expand Down
2 changes: 1 addition & 1 deletion src/gen/api/bankfeedsApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ export enum BankFeedsApiApiKeys {

export class BankFeedsApi {
protected _basePath = defaultBasePath;
protected defaultHeaders : any = {'user-agent': 'xero-node-4.10.2'};
protected defaultHeaders : any = {'user-agent': 'xero-node-4.10.3'};
protected _useQuerystring : boolean = false;
protected binaryHeaders : any = {};

Expand Down
2 changes: 1 addition & 1 deletion src/gen/api/filesApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ export enum FilesApiApiKeys {

export class FilesApi {
protected _basePath = defaultBasePath;
protected defaultHeaders : any = {'user-agent': 'xero-node-4.10.2'};
protected defaultHeaders : any = {'user-agent': 'xero-node-4.10.3'};
protected _useQuerystring : boolean = false;
protected binaryHeaders : any = {};

Expand Down
2 changes: 1 addition & 1 deletion src/gen/api/payrollAUApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ export enum PayrollAuApiApiKeys {

export class PayrollAuApi {
protected _basePath = defaultBasePath;
protected defaultHeaders : any = {'user-agent': 'xero-node-4.10.2'};
protected defaultHeaders : any = {'user-agent': 'xero-node-4.10.3'};
protected _useQuerystring : boolean = false;
protected binaryHeaders : any = {};

Expand Down
2 changes: 1 addition & 1 deletion src/gen/api/payrollNZApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ export enum PayrollNzApiApiKeys {

export class PayrollNzApi {
protected _basePath = defaultBasePath;
protected defaultHeaders : any = {'user-agent': 'xero-node-4.10.2'};
protected defaultHeaders : any = {'user-agent': 'xero-node-4.10.3'};
protected _useQuerystring : boolean = false;
protected binaryHeaders : any = {};

Expand Down
2 changes: 1 addition & 1 deletion src/gen/api/payrollUKApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ export enum PayrollUkApiApiKeys {

export class PayrollUkApi {
protected _basePath = defaultBasePath;
protected defaultHeaders : any = {'user-agent': 'xero-node-4.10.2'};
protected defaultHeaders : any = {'user-agent': 'xero-node-4.10.3'};
protected _useQuerystring : boolean = false;
protected binaryHeaders : any = {};

Expand Down
2 changes: 1 addition & 1 deletion src/gen/api/projectApi.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ export enum ProjectApiApiKeys {

export class ProjectApi {
protected _basePath = defaultBasePath;
protected defaultHeaders : any = {'user-agent': 'xero-node-4.10.2'};
protected defaultHeaders : any = {'user-agent': 'xero-node-4.10.3'};
protected _useQuerystring : boolean = false;
protected binaryHeaders : any = {};

Expand Down

0 comments on commit 8de095c

Please sign in to comment.