@enfuce/nextgen-sdk 0.0.7 → 0.0.9
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.
- package/README.md +209 -27
- package/dist/authorisation-control/api.d.ts +0 -56
- package/dist/authorisation-control/api.js +1 -115
- package/dist/authorisation-control/index.d.ts +0 -1
- package/dist/authorisation-control/index.js +0 -1
- package/dist/card/api.js +12 -12
- package/dist/card/client.d.ts +2 -2
- package/dist/cardholder/api.js +5 -5
- package/dist/cardholder/client.d.ts +2 -2
- package/dist/cards/client.d.ts +2 -2
- package/dist/esm/authorisation-control/api.d.ts +0 -56
- package/dist/esm/authorisation-control/api.js +0 -110
- package/dist/esm/authorisation-control/index.d.ts +0 -1
- package/dist/esm/authorisation-control/index.js +0 -1
- package/dist/esm/card/api.js +12 -12
- package/dist/esm/card/client.d.ts +2 -2
- package/dist/esm/cardholder/api.js +5 -5
- package/dist/esm/cardholder/client.d.ts +2 -2
- package/dist/esm/cards/client.d.ts +2 -2
- package/dist/esm/exchange-rate/client.d.ts +2 -2
- package/dist/esm/issuer-events/api.d.ts +0 -120
- package/dist/esm/issuer-events/api.js +0 -241
- package/dist/esm/issuer-events/index.d.ts +0 -1
- package/dist/esm/issuer-events/index.js +0 -1
- package/dist/esm/oauth/axios.d.ts +3 -3
- package/dist/esm/oauth/axios.js +1 -1
- package/dist/esm/oauth/clientCredentials.d.ts +31 -3
- package/dist/esm/oauth/clientCredentials.js +59 -4
- package/dist/esm/oauth/index.d.ts +2 -2
- package/dist/esm/oauth/index.js +2 -2
- package/dist/esm/oauth/tokenManager.d.ts +2 -2
- package/dist/esm/oauth/tokenManager.js +2 -2
- package/dist/esm/pin/api.d.ts +52 -0
- package/dist/esm/pin/api.js +80 -3
- package/dist/esm/pin/client.d.ts +2 -2
- package/dist/esm/threeds/client.d.ts +2 -2
- package/dist/esm/threeds-oob/api.d.ts +0 -56
- package/dist/esm/threeds-oob/api.js +0 -112
- package/dist/esm/threeds-oob/index.d.ts +0 -1
- package/dist/esm/threeds-oob/index.js +0 -1
- package/dist/esm/wallet/api.js +12 -12
- package/dist/esm/wallet/client.d.ts +2 -2
- package/dist/exchange-rate/client.d.ts +2 -2
- package/dist/issuer-events/api.d.ts +0 -120
- package/dist/issuer-events/api.js +1 -246
- package/dist/issuer-events/index.d.ts +0 -1
- package/dist/issuer-events/index.js +0 -1
- package/dist/oauth/axios.d.ts +3 -3
- package/dist/oauth/axios.js +1 -1
- package/dist/oauth/clientCredentials.d.ts +31 -3
- package/dist/oauth/clientCredentials.js +60 -3
- package/dist/oauth/index.d.ts +2 -2
- package/dist/oauth/index.js +4 -2
- package/dist/oauth/tokenManager.d.ts +2 -2
- package/dist/oauth/tokenManager.js +4 -4
- package/dist/pin/api.d.ts +52 -0
- package/dist/pin/api.js +80 -3
- package/dist/pin/client.d.ts +2 -2
- package/dist/threeds/client.d.ts +2 -2
- package/dist/threeds-oob/api.d.ts +0 -56
- package/dist/threeds-oob/api.js +1 -117
- package/dist/threeds-oob/index.d.ts +0 -1
- package/dist/threeds-oob/index.js +0 -1
- package/dist/wallet/api.js +12 -12
- package/dist/wallet/client.d.ts +2 -2
- package/package.json +1 -1
- package/src/authorisation-control/api.ts +0 -102
- package/src/authorisation-control/index.ts +0 -2
- package/src/card/api.ts +12 -12
- package/src/card/client.ts +3 -3
- package/src/cardholder/api.ts +5 -5
- package/src/cardholder/client.ts +3 -3
- package/src/cards/client.ts +3 -3
- package/src/exchange-rate/client.ts +3 -3
- package/src/issuer-events/api.ts +0 -237
- package/src/issuer-events/index.ts +0 -2
- package/src/oauth/axios.ts +3 -3
- package/src/oauth/clientCredentials.ts +87 -4
- package/src/oauth/index.ts +9 -2
- package/src/oauth/tokenManager.ts +2 -2
- package/src/pin/api.ts +99 -3
- package/src/pin/client.ts +3 -3
- package/src/threeds/client.ts +3 -3
- package/src/threeds-oob/api.ts +0 -105
- package/src/threeds-oob/index.ts +0 -2
- package/src/wallet/api.ts +12 -12
- package/src/wallet/client.ts +3 -3
- package/test/clientCredentials.test.ts +20 -0
- package/test/oauth.test.ts +12 -12
- package/dist/authorisation-control/client.d.ts +0 -47
- package/dist/authorisation-control/client.js +0 -80
- package/dist/esm/authorisation-control/client.d.ts +0 -47
- package/dist/esm/authorisation-control/client.js +0 -75
- package/dist/esm/issuer-events/client.d.ts +0 -47
- package/dist/esm/issuer-events/client.js +0 -75
- package/dist/esm/threeds-oob/client.d.ts +0 -47
- package/dist/esm/threeds-oob/client.js +0 -75
- package/dist/issuer-events/client.d.ts +0 -47
- package/dist/issuer-events/client.js +0 -80
- package/dist/threeds-oob/client.d.ts +0 -47
- package/dist/threeds-oob/client.js +0 -80
- package/src/authorisation-control/client.ts +0 -86
- package/src/issuer-events/client.ts +0 -86
- package/src/threeds-oob/client.ts +0 -86
- package/test/authorisation-control.test.ts +0 -71
- package/test/issuer-events.test.ts +0 -55
- package/test/threeds-oob.test.ts +0 -90
|
@@ -1,80 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.AuthorisationControlClientBuilder = exports.AuthorisationControlClient = void 0;
|
|
4
|
-
/*
|
|
5
|
-
* Enfuce nextgen SDK — fluent module client.
|
|
6
|
-
*
|
|
7
|
-
* GENERATED by scripts/generate.sh from a custom template (generator-templates/typescript). One per
|
|
8
|
-
* API module: wires an OAuth-enabled axios instance (bearer token on every request + reactive 401
|
|
9
|
-
* retry) to the module's Configuration and exposes each API. Nothing is shared across modules.
|
|
10
|
-
*/
|
|
11
|
-
const axios_1 = require("axios");
|
|
12
|
-
const oauth_1 = require("../oauth");
|
|
13
|
-
const configuration_1 = require("./configuration");
|
|
14
|
-
const api_1 = require("./api");
|
|
15
|
-
/**
|
|
16
|
-
* Fluent entry point for this module. Build one with {@link AuthorisationControlClient.builder}:
|
|
17
|
-
*
|
|
18
|
-
* ```ts
|
|
19
|
-
* const client = AuthorisationControlClient.builder()
|
|
20
|
-
* .baseUrl('https://api.example.com/...')
|
|
21
|
-
* .oauth(tokens)
|
|
22
|
-
* .build();
|
|
23
|
-
* ```
|
|
24
|
-
*/
|
|
25
|
-
class AuthorisationControlClient {
|
|
26
|
-
constructor(
|
|
27
|
-
/** The axios instance — OAuth interceptors and any customizations already applied. */
|
|
28
|
-
http,
|
|
29
|
-
/** The module configuration — base path applied. */
|
|
30
|
-
configuration) {
|
|
31
|
-
this.http = http;
|
|
32
|
-
this.configuration = configuration;
|
|
33
|
-
}
|
|
34
|
-
/** Build any API in this module bound to this client (for APIs without a named getter). */
|
|
35
|
-
api(factory) {
|
|
36
|
-
return factory(this.configuration, this.http);
|
|
37
|
-
}
|
|
38
|
-
/** {@link AuthorisationRequestAPIApi} bound to this client. */
|
|
39
|
-
authorisationRequestAPIApi() {
|
|
40
|
-
return new api_1.AuthorisationRequestAPIApi(this.configuration, undefined, this.http);
|
|
41
|
-
}
|
|
42
|
-
static builder() {
|
|
43
|
-
return new AuthorisationControlClientBuilder();
|
|
44
|
-
}
|
|
45
|
-
}
|
|
46
|
-
exports.AuthorisationControlClient = AuthorisationControlClient;
|
|
47
|
-
/** Builds a {@link AuthorisationControlClient}: base URL + optional OAuth + transport customization. */
|
|
48
|
-
class AuthorisationControlClientBuilder {
|
|
49
|
-
constructor() {
|
|
50
|
-
this._customizers = [];
|
|
51
|
-
}
|
|
52
|
-
/** The module's host, e.g. `https://api.<tenant>.../issuer`. */
|
|
53
|
-
baseUrl(baseUrl) {
|
|
54
|
-
this._baseUrl = baseUrl;
|
|
55
|
-
return this;
|
|
56
|
-
}
|
|
57
|
-
/** Install OAuth: a fresh bearer token on every request + reactive 401 retry. */
|
|
58
|
-
oauth(tokens) {
|
|
59
|
-
this._tokens = tokens;
|
|
60
|
-
return this;
|
|
61
|
-
}
|
|
62
|
-
/**
|
|
63
|
-
* Customize the underlying axios instance — set a timeout (`http.defaults.timeout = ...`), a proxy,
|
|
64
|
-
* default headers, extra interceptors, etc. Runs after OAuth is installed. Composable: multiple
|
|
65
|
-
* calls run in order.
|
|
66
|
-
*/
|
|
67
|
-
configure(customizer) {
|
|
68
|
-
this._customizers.push(customizer);
|
|
69
|
-
return this;
|
|
70
|
-
}
|
|
71
|
-
build() {
|
|
72
|
-
const http = this._tokens ? (0, oauth_1.createOAuthAxios)(this._tokens) : axios_1.default.create();
|
|
73
|
-
for (const customizer of this._customizers) {
|
|
74
|
-
customizer(http);
|
|
75
|
-
}
|
|
76
|
-
const configuration = new configuration_1.Configuration({ basePath: this._baseUrl });
|
|
77
|
-
return new AuthorisationControlClient(http, configuration);
|
|
78
|
-
}
|
|
79
|
-
}
|
|
80
|
-
exports.AuthorisationControlClientBuilder = AuthorisationControlClientBuilder;
|
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
import { type AxiosInstance } from 'axios';
|
|
2
|
-
import { type TokenManager } from '../oauth';
|
|
3
|
-
import { Configuration } from './configuration';
|
|
4
|
-
import { AuthorisationRequestAPIApi } from './api';
|
|
5
|
-
/**
|
|
6
|
-
* Fluent entry point for this module. Build one with {@link AuthorisationControlClient.builder}:
|
|
7
|
-
*
|
|
8
|
-
* ```ts
|
|
9
|
-
* const client = AuthorisationControlClient.builder()
|
|
10
|
-
* .baseUrl('https://api.example.com/...')
|
|
11
|
-
* .oauth(tokens)
|
|
12
|
-
* .build();
|
|
13
|
-
* ```
|
|
14
|
-
*/
|
|
15
|
-
export declare class AuthorisationControlClient {
|
|
16
|
-
/** The axios instance — OAuth interceptors and any customizations already applied. */
|
|
17
|
-
readonly http: AxiosInstance;
|
|
18
|
-
/** The module configuration — base path applied. */
|
|
19
|
-
readonly configuration: Configuration;
|
|
20
|
-
constructor(
|
|
21
|
-
/** The axios instance — OAuth interceptors and any customizations already applied. */
|
|
22
|
-
http: AxiosInstance,
|
|
23
|
-
/** The module configuration — base path applied. */
|
|
24
|
-
configuration: Configuration);
|
|
25
|
-
/** Build any API in this module bound to this client (for APIs without a named getter). */
|
|
26
|
-
api<T>(factory: (configuration: Configuration, http: AxiosInstance) => T): T;
|
|
27
|
-
/** {@link AuthorisationRequestAPIApi} bound to this client. */
|
|
28
|
-
authorisationRequestAPIApi(): AuthorisationRequestAPIApi;
|
|
29
|
-
static builder(): AuthorisationControlClientBuilder;
|
|
30
|
-
}
|
|
31
|
-
/** Builds a {@link AuthorisationControlClient}: base URL + optional OAuth + transport customization. */
|
|
32
|
-
export declare class AuthorisationControlClientBuilder {
|
|
33
|
-
private _baseUrl?;
|
|
34
|
-
private _tokens?;
|
|
35
|
-
private _customizers;
|
|
36
|
-
/** The module's host, e.g. `https://api.<tenant>.../issuer`. */
|
|
37
|
-
baseUrl(baseUrl: string): this;
|
|
38
|
-
/** Install OAuth: a fresh bearer token on every request + reactive 401 retry. */
|
|
39
|
-
oauth(tokens: TokenManager): this;
|
|
40
|
-
/**
|
|
41
|
-
* Customize the underlying axios instance — set a timeout (`http.defaults.timeout = ...`), a proxy,
|
|
42
|
-
* default headers, extra interceptors, etc. Runs after OAuth is installed. Composable: multiple
|
|
43
|
-
* calls run in order.
|
|
44
|
-
*/
|
|
45
|
-
configure(customizer: (http: AxiosInstance) => void): this;
|
|
46
|
-
build(): AuthorisationControlClient;
|
|
47
|
-
}
|
|
@@ -1,75 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Enfuce nextgen SDK — fluent module client.
|
|
3
|
-
*
|
|
4
|
-
* GENERATED by scripts/generate.sh from a custom template (generator-templates/typescript). One per
|
|
5
|
-
* API module: wires an OAuth-enabled axios instance (bearer token on every request + reactive 401
|
|
6
|
-
* retry) to the module's Configuration and exposes each API. Nothing is shared across modules.
|
|
7
|
-
*/
|
|
8
|
-
import globalAxios from 'axios';
|
|
9
|
-
import { createOAuthAxios } from '../oauth';
|
|
10
|
-
import { Configuration } from './configuration';
|
|
11
|
-
import { AuthorisationRequestAPIApi, } from './api';
|
|
12
|
-
/**
|
|
13
|
-
* Fluent entry point for this module. Build one with {@link AuthorisationControlClient.builder}:
|
|
14
|
-
*
|
|
15
|
-
* ```ts
|
|
16
|
-
* const client = AuthorisationControlClient.builder()
|
|
17
|
-
* .baseUrl('https://api.example.com/...')
|
|
18
|
-
* .oauth(tokens)
|
|
19
|
-
* .build();
|
|
20
|
-
* ```
|
|
21
|
-
*/
|
|
22
|
-
export class AuthorisationControlClient {
|
|
23
|
-
constructor(
|
|
24
|
-
/** The axios instance — OAuth interceptors and any customizations already applied. */
|
|
25
|
-
http,
|
|
26
|
-
/** The module configuration — base path applied. */
|
|
27
|
-
configuration) {
|
|
28
|
-
this.http = http;
|
|
29
|
-
this.configuration = configuration;
|
|
30
|
-
}
|
|
31
|
-
/** Build any API in this module bound to this client (for APIs without a named getter). */
|
|
32
|
-
api(factory) {
|
|
33
|
-
return factory(this.configuration, this.http);
|
|
34
|
-
}
|
|
35
|
-
/** {@link AuthorisationRequestAPIApi} bound to this client. */
|
|
36
|
-
authorisationRequestAPIApi() {
|
|
37
|
-
return new AuthorisationRequestAPIApi(this.configuration, undefined, this.http);
|
|
38
|
-
}
|
|
39
|
-
static builder() {
|
|
40
|
-
return new AuthorisationControlClientBuilder();
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
/** Builds a {@link AuthorisationControlClient}: base URL + optional OAuth + transport customization. */
|
|
44
|
-
export class AuthorisationControlClientBuilder {
|
|
45
|
-
constructor() {
|
|
46
|
-
this._customizers = [];
|
|
47
|
-
}
|
|
48
|
-
/** The module's host, e.g. `https://api.<tenant>.../issuer`. */
|
|
49
|
-
baseUrl(baseUrl) {
|
|
50
|
-
this._baseUrl = baseUrl;
|
|
51
|
-
return this;
|
|
52
|
-
}
|
|
53
|
-
/** Install OAuth: a fresh bearer token on every request + reactive 401 retry. */
|
|
54
|
-
oauth(tokens) {
|
|
55
|
-
this._tokens = tokens;
|
|
56
|
-
return this;
|
|
57
|
-
}
|
|
58
|
-
/**
|
|
59
|
-
* Customize the underlying axios instance — set a timeout (`http.defaults.timeout = ...`), a proxy,
|
|
60
|
-
* default headers, extra interceptors, etc. Runs after OAuth is installed. Composable: multiple
|
|
61
|
-
* calls run in order.
|
|
62
|
-
*/
|
|
63
|
-
configure(customizer) {
|
|
64
|
-
this._customizers.push(customizer);
|
|
65
|
-
return this;
|
|
66
|
-
}
|
|
67
|
-
build() {
|
|
68
|
-
const http = this._tokens ? createOAuthAxios(this._tokens) : globalAxios.create();
|
|
69
|
-
for (const customizer of this._customizers) {
|
|
70
|
-
customizer(http);
|
|
71
|
-
}
|
|
72
|
-
const configuration = new Configuration({ basePath: this._baseUrl });
|
|
73
|
-
return new AuthorisationControlClient(http, configuration);
|
|
74
|
-
}
|
|
75
|
-
}
|
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
import { type AxiosInstance } from 'axios';
|
|
2
|
-
import { type TokenManager } from '../oauth';
|
|
3
|
-
import { Configuration } from './configuration';
|
|
4
|
-
import { IssuerEventWebhooksApi } from './api';
|
|
5
|
-
/**
|
|
6
|
-
* Fluent entry point for this module. Build one with {@link IssuerEventsClient.builder}:
|
|
7
|
-
*
|
|
8
|
-
* ```ts
|
|
9
|
-
* const client = IssuerEventsClient.builder()
|
|
10
|
-
* .baseUrl('https://api.example.com/...')
|
|
11
|
-
* .oauth(tokens)
|
|
12
|
-
* .build();
|
|
13
|
-
* ```
|
|
14
|
-
*/
|
|
15
|
-
export declare class IssuerEventsClient {
|
|
16
|
-
/** The axios instance — OAuth interceptors and any customizations already applied. */
|
|
17
|
-
readonly http: AxiosInstance;
|
|
18
|
-
/** The module configuration — base path applied. */
|
|
19
|
-
readonly configuration: Configuration;
|
|
20
|
-
constructor(
|
|
21
|
-
/** The axios instance — OAuth interceptors and any customizations already applied. */
|
|
22
|
-
http: AxiosInstance,
|
|
23
|
-
/** The module configuration — base path applied. */
|
|
24
|
-
configuration: Configuration);
|
|
25
|
-
/** Build any API in this module bound to this client (for APIs without a named getter). */
|
|
26
|
-
api<T>(factory: (configuration: Configuration, http: AxiosInstance) => T): T;
|
|
27
|
-
/** {@link IssuerEventWebhooksApi} bound to this client. */
|
|
28
|
-
issuerEventWebhooksApi(): IssuerEventWebhooksApi;
|
|
29
|
-
static builder(): IssuerEventsClientBuilder;
|
|
30
|
-
}
|
|
31
|
-
/** Builds a {@link IssuerEventsClient}: base URL + optional OAuth + transport customization. */
|
|
32
|
-
export declare class IssuerEventsClientBuilder {
|
|
33
|
-
private _baseUrl?;
|
|
34
|
-
private _tokens?;
|
|
35
|
-
private _customizers;
|
|
36
|
-
/** The module's host, e.g. `https://api.<tenant>.../issuer`. */
|
|
37
|
-
baseUrl(baseUrl: string): this;
|
|
38
|
-
/** Install OAuth: a fresh bearer token on every request + reactive 401 retry. */
|
|
39
|
-
oauth(tokens: TokenManager): this;
|
|
40
|
-
/**
|
|
41
|
-
* Customize the underlying axios instance — set a timeout (`http.defaults.timeout = ...`), a proxy,
|
|
42
|
-
* default headers, extra interceptors, etc. Runs after OAuth is installed. Composable: multiple
|
|
43
|
-
* calls run in order.
|
|
44
|
-
*/
|
|
45
|
-
configure(customizer: (http: AxiosInstance) => void): this;
|
|
46
|
-
build(): IssuerEventsClient;
|
|
47
|
-
}
|
|
@@ -1,75 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Enfuce nextgen SDK — fluent module client.
|
|
3
|
-
*
|
|
4
|
-
* GENERATED by scripts/generate.sh from a custom template (generator-templates/typescript). One per
|
|
5
|
-
* API module: wires an OAuth-enabled axios instance (bearer token on every request + reactive 401
|
|
6
|
-
* retry) to the module's Configuration and exposes each API. Nothing is shared across modules.
|
|
7
|
-
*/
|
|
8
|
-
import globalAxios from 'axios';
|
|
9
|
-
import { createOAuthAxios } from '../oauth';
|
|
10
|
-
import { Configuration } from './configuration';
|
|
11
|
-
import { IssuerEventWebhooksApi, } from './api';
|
|
12
|
-
/**
|
|
13
|
-
* Fluent entry point for this module. Build one with {@link IssuerEventsClient.builder}:
|
|
14
|
-
*
|
|
15
|
-
* ```ts
|
|
16
|
-
* const client = IssuerEventsClient.builder()
|
|
17
|
-
* .baseUrl('https://api.example.com/...')
|
|
18
|
-
* .oauth(tokens)
|
|
19
|
-
* .build();
|
|
20
|
-
* ```
|
|
21
|
-
*/
|
|
22
|
-
export class IssuerEventsClient {
|
|
23
|
-
constructor(
|
|
24
|
-
/** The axios instance — OAuth interceptors and any customizations already applied. */
|
|
25
|
-
http,
|
|
26
|
-
/** The module configuration — base path applied. */
|
|
27
|
-
configuration) {
|
|
28
|
-
this.http = http;
|
|
29
|
-
this.configuration = configuration;
|
|
30
|
-
}
|
|
31
|
-
/** Build any API in this module bound to this client (for APIs without a named getter). */
|
|
32
|
-
api(factory) {
|
|
33
|
-
return factory(this.configuration, this.http);
|
|
34
|
-
}
|
|
35
|
-
/** {@link IssuerEventWebhooksApi} bound to this client. */
|
|
36
|
-
issuerEventWebhooksApi() {
|
|
37
|
-
return new IssuerEventWebhooksApi(this.configuration, undefined, this.http);
|
|
38
|
-
}
|
|
39
|
-
static builder() {
|
|
40
|
-
return new IssuerEventsClientBuilder();
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
/** Builds a {@link IssuerEventsClient}: base URL + optional OAuth + transport customization. */
|
|
44
|
-
export class IssuerEventsClientBuilder {
|
|
45
|
-
constructor() {
|
|
46
|
-
this._customizers = [];
|
|
47
|
-
}
|
|
48
|
-
/** The module's host, e.g. `https://api.<tenant>.../issuer`. */
|
|
49
|
-
baseUrl(baseUrl) {
|
|
50
|
-
this._baseUrl = baseUrl;
|
|
51
|
-
return this;
|
|
52
|
-
}
|
|
53
|
-
/** Install OAuth: a fresh bearer token on every request + reactive 401 retry. */
|
|
54
|
-
oauth(tokens) {
|
|
55
|
-
this._tokens = tokens;
|
|
56
|
-
return this;
|
|
57
|
-
}
|
|
58
|
-
/**
|
|
59
|
-
* Customize the underlying axios instance — set a timeout (`http.defaults.timeout = ...`), a proxy,
|
|
60
|
-
* default headers, extra interceptors, etc. Runs after OAuth is installed. Composable: multiple
|
|
61
|
-
* calls run in order.
|
|
62
|
-
*/
|
|
63
|
-
configure(customizer) {
|
|
64
|
-
this._customizers.push(customizer);
|
|
65
|
-
return this;
|
|
66
|
-
}
|
|
67
|
-
build() {
|
|
68
|
-
const http = this._tokens ? createOAuthAxios(this._tokens) : globalAxios.create();
|
|
69
|
-
for (const customizer of this._customizers) {
|
|
70
|
-
customizer(http);
|
|
71
|
-
}
|
|
72
|
-
const configuration = new Configuration({ basePath: this._baseUrl });
|
|
73
|
-
return new IssuerEventsClient(http, configuration);
|
|
74
|
-
}
|
|
75
|
-
}
|
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
import { type AxiosInstance } from 'axios';
|
|
2
|
-
import { type TokenManager } from '../oauth';
|
|
3
|
-
import { Configuration } from './configuration';
|
|
4
|
-
import { OOBAuthenticationChallengeWebhookNotificationApi } from './api';
|
|
5
|
-
/**
|
|
6
|
-
* Fluent entry point for this module. Build one with {@link ThreedsOobClient.builder}:
|
|
7
|
-
*
|
|
8
|
-
* ```ts
|
|
9
|
-
* const client = ThreedsOobClient.builder()
|
|
10
|
-
* .baseUrl('https://api.example.com/...')
|
|
11
|
-
* .oauth(tokens)
|
|
12
|
-
* .build();
|
|
13
|
-
* ```
|
|
14
|
-
*/
|
|
15
|
-
export declare class ThreedsOobClient {
|
|
16
|
-
/** The axios instance — OAuth interceptors and any customizations already applied. */
|
|
17
|
-
readonly http: AxiosInstance;
|
|
18
|
-
/** The module configuration — base path applied. */
|
|
19
|
-
readonly configuration: Configuration;
|
|
20
|
-
constructor(
|
|
21
|
-
/** The axios instance — OAuth interceptors and any customizations already applied. */
|
|
22
|
-
http: AxiosInstance,
|
|
23
|
-
/** The module configuration — base path applied. */
|
|
24
|
-
configuration: Configuration);
|
|
25
|
-
/** Build any API in this module bound to this client (for APIs without a named getter). */
|
|
26
|
-
api<T>(factory: (configuration: Configuration, http: AxiosInstance) => T): T;
|
|
27
|
-
/** {@link OOBAuthenticationChallengeWebhookNotificationApi} bound to this client. */
|
|
28
|
-
oOBAuthenticationChallengeWebhookNotificationApi(): OOBAuthenticationChallengeWebhookNotificationApi;
|
|
29
|
-
static builder(): ThreedsOobClientBuilder;
|
|
30
|
-
}
|
|
31
|
-
/** Builds a {@link ThreedsOobClient}: base URL + optional OAuth + transport customization. */
|
|
32
|
-
export declare class ThreedsOobClientBuilder {
|
|
33
|
-
private _baseUrl?;
|
|
34
|
-
private _tokens?;
|
|
35
|
-
private _customizers;
|
|
36
|
-
/** The module's host, e.g. `https://api.<tenant>.../issuer`. */
|
|
37
|
-
baseUrl(baseUrl: string): this;
|
|
38
|
-
/** Install OAuth: a fresh bearer token on every request + reactive 401 retry. */
|
|
39
|
-
oauth(tokens: TokenManager): this;
|
|
40
|
-
/**
|
|
41
|
-
* Customize the underlying axios instance — set a timeout (`http.defaults.timeout = ...`), a proxy,
|
|
42
|
-
* default headers, extra interceptors, etc. Runs after OAuth is installed. Composable: multiple
|
|
43
|
-
* calls run in order.
|
|
44
|
-
*/
|
|
45
|
-
configure(customizer: (http: AxiosInstance) => void): this;
|
|
46
|
-
build(): ThreedsOobClient;
|
|
47
|
-
}
|
|
@@ -1,75 +0,0 @@
|
|
|
1
|
-
/*
|
|
2
|
-
* Enfuce nextgen SDK — fluent module client.
|
|
3
|
-
*
|
|
4
|
-
* GENERATED by scripts/generate.sh from a custom template (generator-templates/typescript). One per
|
|
5
|
-
* API module: wires an OAuth-enabled axios instance (bearer token on every request + reactive 401
|
|
6
|
-
* retry) to the module's Configuration and exposes each API. Nothing is shared across modules.
|
|
7
|
-
*/
|
|
8
|
-
import globalAxios from 'axios';
|
|
9
|
-
import { createOAuthAxios } from '../oauth';
|
|
10
|
-
import { Configuration } from './configuration';
|
|
11
|
-
import { OOBAuthenticationChallengeWebhookNotificationApi, } from './api';
|
|
12
|
-
/**
|
|
13
|
-
* Fluent entry point for this module. Build one with {@link ThreedsOobClient.builder}:
|
|
14
|
-
*
|
|
15
|
-
* ```ts
|
|
16
|
-
* const client = ThreedsOobClient.builder()
|
|
17
|
-
* .baseUrl('https://api.example.com/...')
|
|
18
|
-
* .oauth(tokens)
|
|
19
|
-
* .build();
|
|
20
|
-
* ```
|
|
21
|
-
*/
|
|
22
|
-
export class ThreedsOobClient {
|
|
23
|
-
constructor(
|
|
24
|
-
/** The axios instance — OAuth interceptors and any customizations already applied. */
|
|
25
|
-
http,
|
|
26
|
-
/** The module configuration — base path applied. */
|
|
27
|
-
configuration) {
|
|
28
|
-
this.http = http;
|
|
29
|
-
this.configuration = configuration;
|
|
30
|
-
}
|
|
31
|
-
/** Build any API in this module bound to this client (for APIs without a named getter). */
|
|
32
|
-
api(factory) {
|
|
33
|
-
return factory(this.configuration, this.http);
|
|
34
|
-
}
|
|
35
|
-
/** {@link OOBAuthenticationChallengeWebhookNotificationApi} bound to this client. */
|
|
36
|
-
oOBAuthenticationChallengeWebhookNotificationApi() {
|
|
37
|
-
return new OOBAuthenticationChallengeWebhookNotificationApi(this.configuration, undefined, this.http);
|
|
38
|
-
}
|
|
39
|
-
static builder() {
|
|
40
|
-
return new ThreedsOobClientBuilder();
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
/** Builds a {@link ThreedsOobClient}: base URL + optional OAuth + transport customization. */
|
|
44
|
-
export class ThreedsOobClientBuilder {
|
|
45
|
-
constructor() {
|
|
46
|
-
this._customizers = [];
|
|
47
|
-
}
|
|
48
|
-
/** The module's host, e.g. `https://api.<tenant>.../issuer`. */
|
|
49
|
-
baseUrl(baseUrl) {
|
|
50
|
-
this._baseUrl = baseUrl;
|
|
51
|
-
return this;
|
|
52
|
-
}
|
|
53
|
-
/** Install OAuth: a fresh bearer token on every request + reactive 401 retry. */
|
|
54
|
-
oauth(tokens) {
|
|
55
|
-
this._tokens = tokens;
|
|
56
|
-
return this;
|
|
57
|
-
}
|
|
58
|
-
/**
|
|
59
|
-
* Customize the underlying axios instance — set a timeout (`http.defaults.timeout = ...`), a proxy,
|
|
60
|
-
* default headers, extra interceptors, etc. Runs after OAuth is installed. Composable: multiple
|
|
61
|
-
* calls run in order.
|
|
62
|
-
*/
|
|
63
|
-
configure(customizer) {
|
|
64
|
-
this._customizers.push(customizer);
|
|
65
|
-
return this;
|
|
66
|
-
}
|
|
67
|
-
build() {
|
|
68
|
-
const http = this._tokens ? createOAuthAxios(this._tokens) : globalAxios.create();
|
|
69
|
-
for (const customizer of this._customizers) {
|
|
70
|
-
customizer(http);
|
|
71
|
-
}
|
|
72
|
-
const configuration = new Configuration({ basePath: this._baseUrl });
|
|
73
|
-
return new ThreedsOobClient(http, configuration);
|
|
74
|
-
}
|
|
75
|
-
}
|
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
import { type AxiosInstance } from 'axios';
|
|
2
|
-
import { type TokenManager } from '../oauth';
|
|
3
|
-
import { Configuration } from './configuration';
|
|
4
|
-
import { IssuerEventWebhooksApi } from './api';
|
|
5
|
-
/**
|
|
6
|
-
* Fluent entry point for this module. Build one with {@link IssuerEventsClient.builder}:
|
|
7
|
-
*
|
|
8
|
-
* ```ts
|
|
9
|
-
* const client = IssuerEventsClient.builder()
|
|
10
|
-
* .baseUrl('https://api.example.com/...')
|
|
11
|
-
* .oauth(tokens)
|
|
12
|
-
* .build();
|
|
13
|
-
* ```
|
|
14
|
-
*/
|
|
15
|
-
export declare class IssuerEventsClient {
|
|
16
|
-
/** The axios instance — OAuth interceptors and any customizations already applied. */
|
|
17
|
-
readonly http: AxiosInstance;
|
|
18
|
-
/** The module configuration — base path applied. */
|
|
19
|
-
readonly configuration: Configuration;
|
|
20
|
-
constructor(
|
|
21
|
-
/** The axios instance — OAuth interceptors and any customizations already applied. */
|
|
22
|
-
http: AxiosInstance,
|
|
23
|
-
/** The module configuration — base path applied. */
|
|
24
|
-
configuration: Configuration);
|
|
25
|
-
/** Build any API in this module bound to this client (for APIs without a named getter). */
|
|
26
|
-
api<T>(factory: (configuration: Configuration, http: AxiosInstance) => T): T;
|
|
27
|
-
/** {@link IssuerEventWebhooksApi} bound to this client. */
|
|
28
|
-
issuerEventWebhooksApi(): IssuerEventWebhooksApi;
|
|
29
|
-
static builder(): IssuerEventsClientBuilder;
|
|
30
|
-
}
|
|
31
|
-
/** Builds a {@link IssuerEventsClient}: base URL + optional OAuth + transport customization. */
|
|
32
|
-
export declare class IssuerEventsClientBuilder {
|
|
33
|
-
private _baseUrl?;
|
|
34
|
-
private _tokens?;
|
|
35
|
-
private _customizers;
|
|
36
|
-
/** The module's host, e.g. `https://api.<tenant>.../issuer`. */
|
|
37
|
-
baseUrl(baseUrl: string): this;
|
|
38
|
-
/** Install OAuth: a fresh bearer token on every request + reactive 401 retry. */
|
|
39
|
-
oauth(tokens: TokenManager): this;
|
|
40
|
-
/**
|
|
41
|
-
* Customize the underlying axios instance — set a timeout (`http.defaults.timeout = ...`), a proxy,
|
|
42
|
-
* default headers, extra interceptors, etc. Runs after OAuth is installed. Composable: multiple
|
|
43
|
-
* calls run in order.
|
|
44
|
-
*/
|
|
45
|
-
configure(customizer: (http: AxiosInstance) => void): this;
|
|
46
|
-
build(): IssuerEventsClient;
|
|
47
|
-
}
|
|
@@ -1,80 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.IssuerEventsClientBuilder = exports.IssuerEventsClient = void 0;
|
|
4
|
-
/*
|
|
5
|
-
* Enfuce nextgen SDK — fluent module client.
|
|
6
|
-
*
|
|
7
|
-
* GENERATED by scripts/generate.sh from a custom template (generator-templates/typescript). One per
|
|
8
|
-
* API module: wires an OAuth-enabled axios instance (bearer token on every request + reactive 401
|
|
9
|
-
* retry) to the module's Configuration and exposes each API. Nothing is shared across modules.
|
|
10
|
-
*/
|
|
11
|
-
const axios_1 = require("axios");
|
|
12
|
-
const oauth_1 = require("../oauth");
|
|
13
|
-
const configuration_1 = require("./configuration");
|
|
14
|
-
const api_1 = require("./api");
|
|
15
|
-
/**
|
|
16
|
-
* Fluent entry point for this module. Build one with {@link IssuerEventsClient.builder}:
|
|
17
|
-
*
|
|
18
|
-
* ```ts
|
|
19
|
-
* const client = IssuerEventsClient.builder()
|
|
20
|
-
* .baseUrl('https://api.example.com/...')
|
|
21
|
-
* .oauth(tokens)
|
|
22
|
-
* .build();
|
|
23
|
-
* ```
|
|
24
|
-
*/
|
|
25
|
-
class IssuerEventsClient {
|
|
26
|
-
constructor(
|
|
27
|
-
/** The axios instance — OAuth interceptors and any customizations already applied. */
|
|
28
|
-
http,
|
|
29
|
-
/** The module configuration — base path applied. */
|
|
30
|
-
configuration) {
|
|
31
|
-
this.http = http;
|
|
32
|
-
this.configuration = configuration;
|
|
33
|
-
}
|
|
34
|
-
/** Build any API in this module bound to this client (for APIs without a named getter). */
|
|
35
|
-
api(factory) {
|
|
36
|
-
return factory(this.configuration, this.http);
|
|
37
|
-
}
|
|
38
|
-
/** {@link IssuerEventWebhooksApi} bound to this client. */
|
|
39
|
-
issuerEventWebhooksApi() {
|
|
40
|
-
return new api_1.IssuerEventWebhooksApi(this.configuration, undefined, this.http);
|
|
41
|
-
}
|
|
42
|
-
static builder() {
|
|
43
|
-
return new IssuerEventsClientBuilder();
|
|
44
|
-
}
|
|
45
|
-
}
|
|
46
|
-
exports.IssuerEventsClient = IssuerEventsClient;
|
|
47
|
-
/** Builds a {@link IssuerEventsClient}: base URL + optional OAuth + transport customization. */
|
|
48
|
-
class IssuerEventsClientBuilder {
|
|
49
|
-
constructor() {
|
|
50
|
-
this._customizers = [];
|
|
51
|
-
}
|
|
52
|
-
/** The module's host, e.g. `https://api.<tenant>.../issuer`. */
|
|
53
|
-
baseUrl(baseUrl) {
|
|
54
|
-
this._baseUrl = baseUrl;
|
|
55
|
-
return this;
|
|
56
|
-
}
|
|
57
|
-
/** Install OAuth: a fresh bearer token on every request + reactive 401 retry. */
|
|
58
|
-
oauth(tokens) {
|
|
59
|
-
this._tokens = tokens;
|
|
60
|
-
return this;
|
|
61
|
-
}
|
|
62
|
-
/**
|
|
63
|
-
* Customize the underlying axios instance — set a timeout (`http.defaults.timeout = ...`), a proxy,
|
|
64
|
-
* default headers, extra interceptors, etc. Runs after OAuth is installed. Composable: multiple
|
|
65
|
-
* calls run in order.
|
|
66
|
-
*/
|
|
67
|
-
configure(customizer) {
|
|
68
|
-
this._customizers.push(customizer);
|
|
69
|
-
return this;
|
|
70
|
-
}
|
|
71
|
-
build() {
|
|
72
|
-
const http = this._tokens ? (0, oauth_1.createOAuthAxios)(this._tokens) : axios_1.default.create();
|
|
73
|
-
for (const customizer of this._customizers) {
|
|
74
|
-
customizer(http);
|
|
75
|
-
}
|
|
76
|
-
const configuration = new configuration_1.Configuration({ basePath: this._baseUrl });
|
|
77
|
-
return new IssuerEventsClient(http, configuration);
|
|
78
|
-
}
|
|
79
|
-
}
|
|
80
|
-
exports.IssuerEventsClientBuilder = IssuerEventsClientBuilder;
|
|
@@ -1,47 +0,0 @@
|
|
|
1
|
-
import { type AxiosInstance } from 'axios';
|
|
2
|
-
import { type TokenManager } from '../oauth';
|
|
3
|
-
import { Configuration } from './configuration';
|
|
4
|
-
import { OOBAuthenticationChallengeWebhookNotificationApi } from './api';
|
|
5
|
-
/**
|
|
6
|
-
* Fluent entry point for this module. Build one with {@link ThreedsOobClient.builder}:
|
|
7
|
-
*
|
|
8
|
-
* ```ts
|
|
9
|
-
* const client = ThreedsOobClient.builder()
|
|
10
|
-
* .baseUrl('https://api.example.com/...')
|
|
11
|
-
* .oauth(tokens)
|
|
12
|
-
* .build();
|
|
13
|
-
* ```
|
|
14
|
-
*/
|
|
15
|
-
export declare class ThreedsOobClient {
|
|
16
|
-
/** The axios instance — OAuth interceptors and any customizations already applied. */
|
|
17
|
-
readonly http: AxiosInstance;
|
|
18
|
-
/** The module configuration — base path applied. */
|
|
19
|
-
readonly configuration: Configuration;
|
|
20
|
-
constructor(
|
|
21
|
-
/** The axios instance — OAuth interceptors and any customizations already applied. */
|
|
22
|
-
http: AxiosInstance,
|
|
23
|
-
/** The module configuration — base path applied. */
|
|
24
|
-
configuration: Configuration);
|
|
25
|
-
/** Build any API in this module bound to this client (for APIs without a named getter). */
|
|
26
|
-
api<T>(factory: (configuration: Configuration, http: AxiosInstance) => T): T;
|
|
27
|
-
/** {@link OOBAuthenticationChallengeWebhookNotificationApi} bound to this client. */
|
|
28
|
-
oOBAuthenticationChallengeWebhookNotificationApi(): OOBAuthenticationChallengeWebhookNotificationApi;
|
|
29
|
-
static builder(): ThreedsOobClientBuilder;
|
|
30
|
-
}
|
|
31
|
-
/** Builds a {@link ThreedsOobClient}: base URL + optional OAuth + transport customization. */
|
|
32
|
-
export declare class ThreedsOobClientBuilder {
|
|
33
|
-
private _baseUrl?;
|
|
34
|
-
private _tokens?;
|
|
35
|
-
private _customizers;
|
|
36
|
-
/** The module's host, e.g. `https://api.<tenant>.../issuer`. */
|
|
37
|
-
baseUrl(baseUrl: string): this;
|
|
38
|
-
/** Install OAuth: a fresh bearer token on every request + reactive 401 retry. */
|
|
39
|
-
oauth(tokens: TokenManager): this;
|
|
40
|
-
/**
|
|
41
|
-
* Customize the underlying axios instance — set a timeout (`http.defaults.timeout = ...`), a proxy,
|
|
42
|
-
* default headers, extra interceptors, etc. Runs after OAuth is installed. Composable: multiple
|
|
43
|
-
* calls run in order.
|
|
44
|
-
*/
|
|
45
|
-
configure(customizer: (http: AxiosInstance) => void): this;
|
|
46
|
-
build(): ThreedsOobClient;
|
|
47
|
-
}
|