@gewis/sudosos-client 1.29.0 → 1.29.2
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 +110 -0
- package/dist/api.d.ts +46 -32
- package/dist/api.js +37 -16
- package/dist/base.js +1 -1
- package/package.json +1 -1
package/README.md
ADDED
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
# @gewis/sudosos-client
|
|
2
|
+
|
|
3
|
+
Auto-generated TypeScript-Axios client for the SudoSOS API. Published on npm as [`@gewis/sudosos-client`](https://www.npmjs.com/package/@gewis/sudosos-client).
|
|
4
|
+
|
|
5
|
+
This package lives inside the [SudoSOS Backend](https://github.com/GEWIS/sudosos-backend/tree/develop/client) monorepo (`client/`) and is generated from the backend's Swagger/OpenAPI spec.
|
|
6
|
+
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
## Installation
|
|
10
|
+
|
|
11
|
+
```bash
|
|
12
|
+
npm install @gewis/sudosos-client
|
|
13
|
+
# or
|
|
14
|
+
yarn add @gewis/sudosos-client
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
---
|
|
18
|
+
|
|
19
|
+
## Usage
|
|
20
|
+
|
|
21
|
+
### Unauthorized API usage
|
|
22
|
+
|
|
23
|
+
```typescript
|
|
24
|
+
import { BannersApi, Configuration } from '@gewis/sudosos-client';
|
|
25
|
+
|
|
26
|
+
const configuration = new Configuration({
|
|
27
|
+
basePath: 'https://sudosos.gewis.nl/api/v1',
|
|
28
|
+
});
|
|
29
|
+
|
|
30
|
+
const bannersApi = new BannersApi(configuration);
|
|
31
|
+
bannersApi.getAllOpenBanners().then((res) => {
|
|
32
|
+
console.log(res.data);
|
|
33
|
+
});
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
### Authorized API usage
|
|
37
|
+
|
|
38
|
+
All API methods accept a single object parameter (named properties, no positional `undefined` placeholders needed).
|
|
39
|
+
|
|
40
|
+
```typescript
|
|
41
|
+
import { AuthenticateApi, BalanceApi, Configuration } from '@gewis/sudosos-client';
|
|
42
|
+
|
|
43
|
+
const basePath = 'https://sudosos.gewis.nl/api/v1';
|
|
44
|
+
const configuration = new Configuration({ basePath });
|
|
45
|
+
|
|
46
|
+
// Authenticate with an API key
|
|
47
|
+
const { data } = await new AuthenticateApi(configuration).keyAuthentication({
|
|
48
|
+
keyAuthenticationRequest: { key: 'API_KEY', userId: 0 },
|
|
49
|
+
});
|
|
50
|
+
const jwtToken = data.token;
|
|
51
|
+
|
|
52
|
+
// Use the token for authenticated requests
|
|
53
|
+
const authedConfig = new Configuration({
|
|
54
|
+
basePath,
|
|
55
|
+
accessToken: () => jwtToken,
|
|
56
|
+
});
|
|
57
|
+
|
|
58
|
+
const balanceApi = new BalanceApi(authedConfig);
|
|
59
|
+
balanceApi.getBalances().then((res) => {
|
|
60
|
+
console.log(res.data);
|
|
61
|
+
});
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
For a more complete integration example, see [sudosos-frontend-common](https://github.com/GEWIS/sudosos-frontend-common).
|
|
65
|
+
|
|
66
|
+
---
|
|
67
|
+
|
|
68
|
+
## How the client is generated
|
|
69
|
+
|
|
70
|
+
The client is generated from the OpenAPI spec that the backend emits at build time (`out/swagger.json`). The generator is [`openapi-generator-cli`](https://openapi-generator.tech/) using the `typescript-axios` template with `useSingleRequestParameter=true`.
|
|
71
|
+
|
|
72
|
+
### Prerequisites
|
|
73
|
+
|
|
74
|
+
- Node.js 22+
|
|
75
|
+
- Java runtime (required by `openapi-generator-cli`)
|
|
76
|
+
- The backend's Swagger output must exist at `../out/swagger.json` — run `npm run swagger` from the backend root first
|
|
77
|
+
|
|
78
|
+
### Common commands
|
|
79
|
+
|
|
80
|
+
| Command | Description |
|
|
81
|
+
|---|---|
|
|
82
|
+
| `npm run gen` | Generate TypeScript source from `../out/swagger.json` into `src/` |
|
|
83
|
+
| `npm run build` | Compile `src/` to `dist/` |
|
|
84
|
+
| `npm run genbuild` | Run `gen` then `build` (full regeneration) |
|
|
85
|
+
| `npm run clean` | Remove `src/` and `dist/` |
|
|
86
|
+
|
|
87
|
+
### Regenerating after a backend change
|
|
88
|
+
|
|
89
|
+
```bash
|
|
90
|
+
# From the backend root — generate the OpenAPI spec first
|
|
91
|
+
npm run swagger # produces out/swagger.json
|
|
92
|
+
|
|
93
|
+
# Then regenerate the client
|
|
94
|
+
cd client
|
|
95
|
+
npm run genbuild
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
Or use the one-shot helper from the backend root:
|
|
99
|
+
|
|
100
|
+
```bash
|
|
101
|
+
npm run client:gen # runs npm run swagger, then cd client && npm install && npm run genbuild
|
|
102
|
+
```
|
|
103
|
+
|
|
104
|
+
---
|
|
105
|
+
|
|
106
|
+
## Contributing
|
|
107
|
+
|
|
108
|
+
This package is generated — do not edit files under `src/` by hand; they will be overwritten on the next `npm run gen`. To change the client's output, update the backend API and regenerate.
|
|
109
|
+
|
|
110
|
+
Issues and contributions go through the [SudoSOS Backend issue tracker](https://github.com/GEWIS/sudosos-backend/issues).
|
package/dist/api.d.ts
CHANGED
|
@@ -2566,10 +2566,15 @@ export interface FineResponse {
|
|
|
2566
2566
|
/**
|
|
2567
2567
|
*
|
|
2568
2568
|
* @export
|
|
2569
|
-
* @
|
|
2569
|
+
* @enum {string}
|
|
2570
2570
|
*/
|
|
2571
|
-
export
|
|
2572
|
-
|
|
2571
|
+
export declare const GetAllInvoicesCurrentStateParameterInner: {
|
|
2572
|
+
readonly Created: "CREATED";
|
|
2573
|
+
readonly Sent: "SENT";
|
|
2574
|
+
readonly Paid: "PAID";
|
|
2575
|
+
readonly Deleted: "DELETED";
|
|
2576
|
+
};
|
|
2577
|
+
export type GetAllInvoicesCurrentStateParameterInner = typeof GetAllInvoicesCurrentStateParameterInner[keyof typeof GetAllInvoicesCurrentStateParameterInner];
|
|
2573
2578
|
/**
|
|
2574
2579
|
* @type GetAllPayoutRequestsRequestedByIdParameter
|
|
2575
2580
|
* @export
|
|
@@ -6490,6 +6495,22 @@ export interface UserToInactiveAdministrativeCostResponse {
|
|
|
6490
6495
|
*/
|
|
6491
6496
|
'nickname'?: string;
|
|
6492
6497
|
}
|
|
6498
|
+
/**
|
|
6499
|
+
* The type of a user
|
|
6500
|
+
* @export
|
|
6501
|
+
* @enum {string}
|
|
6502
|
+
*/
|
|
6503
|
+
export declare const UserType: {
|
|
6504
|
+
readonly Member: "MEMBER";
|
|
6505
|
+
readonly Organ: "ORGAN";
|
|
6506
|
+
readonly Voucher: "VOUCHER";
|
|
6507
|
+
readonly LocalUser: "LOCAL_USER";
|
|
6508
|
+
readonly LocalAdmin: "LOCAL_ADMIN";
|
|
6509
|
+
readonly Invoice: "INVOICE";
|
|
6510
|
+
readonly PointOfSale: "POINT_OF_SALE";
|
|
6511
|
+
readonly Integration: "INTEGRATION";
|
|
6512
|
+
};
|
|
6513
|
+
export type UserType = typeof UserType[keyof typeof UserType];
|
|
6493
6514
|
/**
|
|
6494
6515
|
*
|
|
6495
6516
|
* @export
|
|
@@ -8111,7 +8132,7 @@ export declare const BalanceApiAxiosParamCreator: (configuration?: Configuration
|
|
|
8111
8132
|
* @param {boolean} [hasFine] Only users with(out) fines
|
|
8112
8133
|
* @param {number} [minFine] Minimum fine
|
|
8113
8134
|
* @param {number} [maxFine] Maximum fine
|
|
8114
|
-
* @param {
|
|
8135
|
+
* @param {Array<UserType>} [userTypes] Filter based on user type.
|
|
8115
8136
|
* @param {string} [orderBy] Column to order balance by - eg: id,amount
|
|
8116
8137
|
* @param {GetAllBalanceOrderDirectionEnum} [orderDirection] Order direction
|
|
8117
8138
|
* @param {boolean} [allowDeleted] Whether to include deleted users
|
|
@@ -8121,7 +8142,7 @@ export declare const BalanceApiAxiosParamCreator: (configuration?: Configuration
|
|
|
8121
8142
|
* @param {*} [options] Override http request option.
|
|
8122
8143
|
* @throws {RequiredError}
|
|
8123
8144
|
*/
|
|
8124
|
-
getAllBalance: (date?: string, minBalance?: number, maxBalance?: number, hasFine?: boolean, minFine?: number, maxFine?: number, userTypes?:
|
|
8145
|
+
getAllBalance: (date?: string, minBalance?: number, maxBalance?: number, hasFine?: boolean, minFine?: number, maxFine?: number, userTypes?: Array<UserType>, orderBy?: string, orderDirection?: GetAllBalanceOrderDirectionEnum, allowDeleted?: boolean, inactive?: boolean, take?: number, skip?: number, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
|
|
8125
8146
|
/**
|
|
8126
8147
|
*
|
|
8127
8148
|
* @summary Retrieves the requested balance
|
|
@@ -8161,7 +8182,7 @@ export declare const BalanceApiFp: (configuration?: Configuration) => {
|
|
|
8161
8182
|
* @param {boolean} [hasFine] Only users with(out) fines
|
|
8162
8183
|
* @param {number} [minFine] Minimum fine
|
|
8163
8184
|
* @param {number} [maxFine] Maximum fine
|
|
8164
|
-
* @param {
|
|
8185
|
+
* @param {Array<UserType>} [userTypes] Filter based on user type.
|
|
8165
8186
|
* @param {string} [orderBy] Column to order balance by - eg: id,amount
|
|
8166
8187
|
* @param {GetAllBalanceOrderDirectionEnum} [orderDirection] Order direction
|
|
8167
8188
|
* @param {boolean} [allowDeleted] Whether to include deleted users
|
|
@@ -8171,7 +8192,7 @@ export declare const BalanceApiFp: (configuration?: Configuration) => {
|
|
|
8171
8192
|
* @param {*} [options] Override http request option.
|
|
8172
8193
|
* @throws {RequiredError}
|
|
8173
8194
|
*/
|
|
8174
|
-
getAllBalance(date?: string, minBalance?: number, maxBalance?: number, hasFine?: boolean, minFine?: number, maxFine?: number, userTypes?:
|
|
8195
|
+
getAllBalance(date?: string, minBalance?: number, maxBalance?: number, hasFine?: boolean, minFine?: number, maxFine?: number, userTypes?: Array<UserType>, orderBy?: string, orderDirection?: GetAllBalanceOrderDirectionEnum, allowDeleted?: boolean, inactive?: boolean, take?: number, skip?: number, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<PaginatedBalanceResponse>>;
|
|
8175
8196
|
/**
|
|
8176
8197
|
*
|
|
8177
8198
|
* @summary Retrieves the requested balance
|
|
@@ -8288,10 +8309,10 @@ export interface BalanceApiGetAllBalanceRequest {
|
|
|
8288
8309
|
readonly maxFine?: number;
|
|
8289
8310
|
/**
|
|
8290
8311
|
* Filter based on user type.
|
|
8291
|
-
* @type {Array<
|
|
8312
|
+
* @type {Array<UserType>}
|
|
8292
8313
|
* @memberof BalanceApiGetAllBalance
|
|
8293
8314
|
*/
|
|
8294
|
-
readonly userTypes?:
|
|
8315
|
+
readonly userTypes?: Array<UserType>;
|
|
8295
8316
|
/**
|
|
8296
8317
|
* Column to order balance by - eg: id,amount
|
|
8297
8318
|
* @type {string}
|
|
@@ -8385,11 +8406,6 @@ export declare class BalanceApi extends BaseAPI {
|
|
|
8385
8406
|
*/
|
|
8386
8407
|
getBalances(options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<BalanceResponse, any, {}>>;
|
|
8387
8408
|
}
|
|
8388
|
-
/**
|
|
8389
|
-
* @export
|
|
8390
|
-
*/
|
|
8391
|
-
export declare const GetAllBalanceUserTypesEnum: {};
|
|
8392
|
-
export type GetAllBalanceUserTypesEnum = typeof GetAllBalanceUserTypesEnum[keyof typeof GetAllBalanceUserTypesEnum];
|
|
8393
8409
|
/**
|
|
8394
8410
|
* @export
|
|
8395
8411
|
*/
|
|
@@ -11156,7 +11172,7 @@ export declare const InvoicesApiAxiosParamCreator: (configuration?: Configuratio
|
|
|
11156
11172
|
* @summary Returns all invoices in the system.
|
|
11157
11173
|
* @param {number} [toId] Filter on Id of the debtor
|
|
11158
11174
|
* @param {number} [invoiceId] Filter on invoice ID
|
|
11159
|
-
* @param {
|
|
11175
|
+
* @param {Array<GetAllInvoicesCurrentStateParameterInner>} [currentState] Filter based on Invoice State.
|
|
11160
11176
|
* @param {boolean} [returnEntries] Boolean if invoice entries should be returned
|
|
11161
11177
|
* @param {string} [fromDate] Start date for selected invoices (inclusive)
|
|
11162
11178
|
* @param {string} [tillDate] End date for selected invoices (exclusive)
|
|
@@ -11166,7 +11182,7 @@ export declare const InvoicesApiAxiosParamCreator: (configuration?: Configuratio
|
|
|
11166
11182
|
* @param {*} [options] Override http request option.
|
|
11167
11183
|
* @throws {RequiredError}
|
|
11168
11184
|
*/
|
|
11169
|
-
getAllInvoices: (toId?: number, invoiceId?: number, currentState?:
|
|
11185
|
+
getAllInvoices: (toId?: number, invoiceId?: number, currentState?: Array<GetAllInvoicesCurrentStateParameterInner>, returnEntries?: boolean, fromDate?: string, tillDate?: string, description?: string, take?: number, skip?: number, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
|
|
11170
11186
|
/**
|
|
11171
11187
|
*
|
|
11172
11188
|
* @summary Get eligible transactions for invoice creation.
|
|
@@ -11263,7 +11279,7 @@ export declare const InvoicesApiFp: (configuration?: Configuration) => {
|
|
|
11263
11279
|
* @summary Returns all invoices in the system.
|
|
11264
11280
|
* @param {number} [toId] Filter on Id of the debtor
|
|
11265
11281
|
* @param {number} [invoiceId] Filter on invoice ID
|
|
11266
|
-
* @param {
|
|
11282
|
+
* @param {Array<GetAllInvoicesCurrentStateParameterInner>} [currentState] Filter based on Invoice State.
|
|
11267
11283
|
* @param {boolean} [returnEntries] Boolean if invoice entries should be returned
|
|
11268
11284
|
* @param {string} [fromDate] Start date for selected invoices (inclusive)
|
|
11269
11285
|
* @param {string} [tillDate] End date for selected invoices (exclusive)
|
|
@@ -11273,7 +11289,7 @@ export declare const InvoicesApiFp: (configuration?: Configuration) => {
|
|
|
11273
11289
|
* @param {*} [options] Override http request option.
|
|
11274
11290
|
* @throws {RequiredError}
|
|
11275
11291
|
*/
|
|
11276
|
-
getAllInvoices(toId?: number, invoiceId?: number, currentState?:
|
|
11292
|
+
getAllInvoices(toId?: number, invoiceId?: number, currentState?: Array<GetAllInvoicesCurrentStateParameterInner>, returnEntries?: boolean, fromDate?: string, tillDate?: string, description?: string, take?: number, skip?: number, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<PaginatedInvoiceResponse>>;
|
|
11277
11293
|
/**
|
|
11278
11294
|
*
|
|
11279
11295
|
* @summary Get eligible transactions for invoice creation.
|
|
@@ -11488,10 +11504,10 @@ export interface InvoicesApiGetAllInvoicesRequest {
|
|
|
11488
11504
|
readonly invoiceId?: number;
|
|
11489
11505
|
/**
|
|
11490
11506
|
* Filter based on Invoice State.
|
|
11491
|
-
* @type {Array<
|
|
11507
|
+
* @type {Array<GetAllInvoicesCurrentStateParameterInner>}
|
|
11492
11508
|
* @memberof InvoicesApiGetAllInvoices
|
|
11493
11509
|
*/
|
|
11494
|
-
readonly currentState?:
|
|
11510
|
+
readonly currentState?: Array<GetAllInvoicesCurrentStateParameterInner>;
|
|
11495
11511
|
/**
|
|
11496
11512
|
* Boolean if invoice entries should be returned
|
|
11497
11513
|
* @type {boolean}
|
|
@@ -11749,11 +11765,6 @@ export declare class InvoicesApi extends BaseAPI {
|
|
|
11749
11765
|
*/
|
|
11750
11766
|
updateInvoice(requestParameters: InvoicesApiUpdateInvoiceRequest, options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<BaseInvoiceResponse, any, {}>>;
|
|
11751
11767
|
}
|
|
11752
|
-
/**
|
|
11753
|
-
* @export
|
|
11754
|
-
*/
|
|
11755
|
-
export declare const GetAllInvoicesCurrentStateEnum: {};
|
|
11756
|
-
export type GetAllInvoicesCurrentStateEnum = typeof GetAllInvoicesCurrentStateEnum[keyof typeof GetAllInvoicesCurrentStateEnum];
|
|
11757
11768
|
/**
|
|
11758
11769
|
* PayoutRequestsApi - axios parameter creator
|
|
11759
11770
|
* @export
|
|
@@ -14308,11 +14319,11 @@ export declare const SyncApiAxiosParamCreator: (configuration?: Configuration) =
|
|
|
14308
14319
|
/**
|
|
14309
14320
|
* Performs a dry-run synchronization of users using the specified services. This endpoint always performs a dry-run and does not apply any actual database changes.
|
|
14310
14321
|
* @summary Get dry-run sync results for users
|
|
14311
|
-
* @param {GetUserSyncResultsServiceEnum} [service] Array of sync services to use (ldap, gewisdb). If not provided, all available services will be used.
|
|
14322
|
+
* @param {Array<GetUserSyncResultsServiceEnum>} [service] Array of sync services to use (ldap, gewisdb). If not provided, all available services will be used.
|
|
14312
14323
|
* @param {*} [options] Override http request option.
|
|
14313
14324
|
* @throws {RequiredError}
|
|
14314
14325
|
*/
|
|
14315
|
-
getUserSyncResults: (service?: GetUserSyncResultsServiceEnum
|
|
14326
|
+
getUserSyncResults: (service?: Array<GetUserSyncResultsServiceEnum>, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
|
|
14316
14327
|
};
|
|
14317
14328
|
/**
|
|
14318
14329
|
* SyncApi - functional programming interface
|
|
@@ -14322,11 +14333,11 @@ export declare const SyncApiFp: (configuration?: Configuration) => {
|
|
|
14322
14333
|
/**
|
|
14323
14334
|
* Performs a dry-run synchronization of users using the specified services. This endpoint always performs a dry-run and does not apply any actual database changes.
|
|
14324
14335
|
* @summary Get dry-run sync results for users
|
|
14325
|
-
* @param {GetUserSyncResultsServiceEnum} [service] Array of sync services to use (ldap, gewisdb). If not provided, all available services will be used.
|
|
14336
|
+
* @param {Array<GetUserSyncResultsServiceEnum>} [service] Array of sync services to use (ldap, gewisdb). If not provided, all available services will be used.
|
|
14326
14337
|
* @param {*} [options] Override http request option.
|
|
14327
14338
|
* @throws {RequiredError}
|
|
14328
14339
|
*/
|
|
14329
|
-
getUserSyncResults(service?: GetUserSyncResultsServiceEnum
|
|
14340
|
+
getUserSyncResults(service?: Array<GetUserSyncResultsServiceEnum>, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<object>>;
|
|
14330
14341
|
};
|
|
14331
14342
|
/**
|
|
14332
14343
|
* SyncApi - factory interface
|
|
@@ -14350,10 +14361,10 @@ export declare const SyncApiFactory: (configuration?: Configuration, basePath?:
|
|
|
14350
14361
|
export interface SyncApiGetUserSyncResultsRequest {
|
|
14351
14362
|
/**
|
|
14352
14363
|
* Array of sync services to use (ldap, gewisdb). If not provided, all available services will be used.
|
|
14353
|
-
* @type {Array<
|
|
14364
|
+
* @type {Array<'LDAP' | 'GEWISDB'>}
|
|
14354
14365
|
* @memberof SyncApiGetUserSyncResults
|
|
14355
14366
|
*/
|
|
14356
|
-
readonly service?: GetUserSyncResultsServiceEnum
|
|
14367
|
+
readonly service?: Array<GetUserSyncResultsServiceEnum>;
|
|
14357
14368
|
}
|
|
14358
14369
|
/**
|
|
14359
14370
|
* SyncApi - object-oriented interface
|
|
@@ -14375,7 +14386,10 @@ export declare class SyncApi extends BaseAPI {
|
|
|
14375
14386
|
/**
|
|
14376
14387
|
* @export
|
|
14377
14388
|
*/
|
|
14378
|
-
export declare const GetUserSyncResultsServiceEnum: {
|
|
14389
|
+
export declare const GetUserSyncResultsServiceEnum: {
|
|
14390
|
+
readonly Ldap: "LDAP";
|
|
14391
|
+
readonly Gewisdb: "GEWISDB";
|
|
14392
|
+
};
|
|
14379
14393
|
export type GetUserSyncResultsServiceEnum = typeof GetUserSyncResultsServiceEnum[keyof typeof GetUserSyncResultsServiceEnum];
|
|
14380
14394
|
/**
|
|
14381
14395
|
* TermsOfServiceApi - axios parameter creator
|
package/dist/api.js
CHANGED
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
* Do not edit the class manually.
|
|
14
14
|
*/
|
|
15
15
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
|
-
exports.PayoutRequestsApiAxiosParamCreator = exports.
|
|
16
|
+
exports.PayoutRequestsApiAxiosParamCreator = exports.InvoicesApi = exports.InvoicesApiFactory = exports.InvoicesApiFp = exports.InvoicesApiAxiosParamCreator = exports.InactiveAdministrativeCostsApi = exports.InactiveAdministrativeCostsApiFactory = exports.InactiveAdministrativeCostsApiFp = exports.InactiveAdministrativeCostsApiAxiosParamCreator = exports.FilesApi = exports.FilesApiFactory = exports.FilesApiFp = exports.FilesApiAxiosParamCreator = exports.EventsApi = exports.EventsApiFactory = exports.EventsApiFp = exports.EventsApiAxiosParamCreator = exports.GetFineReportPdfFileTypeEnum = exports.DebtorsApi = exports.DebtorsApiFactory = exports.DebtorsApiFp = exports.DebtorsApiAxiosParamCreator = exports.ContainersApi = exports.ContainersApiFactory = exports.ContainersApiFp = exports.ContainersApiAxiosParamCreator = exports.BannersApi = exports.BannersApiFactory = exports.BannersApiFp = exports.BannersApiAxiosParamCreator = exports.GetAllBalanceOrderDirectionEnum = exports.BalanceApi = exports.BalanceApiFactory = exports.BalanceApiFp = exports.BalanceApiAxiosParamCreator = exports.AuthenticateApi = exports.AuthenticateApiFactory = exports.AuthenticateApiFp = exports.AuthenticateApiAxiosParamCreator = exports.UserType = exports.UserSettingsResponseLanguageEnum = exports.UpdateInvoiceRequestStateEnum = exports.QRStatusResponseStatusEnum = exports.PayoutRequestStatusRequestStateEnum = exports.PayoutRequestResponseStatusEnum = exports.PatchUserSettingsRequestLanguageEnum = exports.InvoiceStatusResponseStateEnum = exports.GetAllInvoicesCurrentStateParameterInner = exports.FinancialMutationResponseTypeEnum = exports.BasePayoutRequestResponseStatusEnum = void 0;
|
|
17
17
|
exports.TransactionSummariesApiFp = exports.TransactionSummariesApiAxiosParamCreator = exports.TestOperationsOfTheTestControllerApi = exports.TestOperationsOfTheTestControllerApiFactory = exports.TestOperationsOfTheTestControllerApiFp = exports.TestOperationsOfTheTestControllerApiAxiosParamCreator = exports.TermsOfServiceApi = exports.TermsOfServiceApiFactory = exports.TermsOfServiceApiFp = exports.TermsOfServiceApiAxiosParamCreator = exports.GetUserSyncResultsServiceEnum = exports.SyncApi = exports.SyncApiFactory = exports.SyncApiFp = exports.SyncApiAxiosParamCreator = exports.StripeApi = exports.StripeApiFactory = exports.StripeApiFp = exports.StripeApiAxiosParamCreator = exports.ServerSettingsApi = exports.ServerSettingsApiFactory = exports.ServerSettingsApiFp = exports.ServerSettingsApiAxiosParamCreator = exports.SellerPayoutsApi = exports.SellerPayoutsApiFactory = exports.SellerPayoutsApiFp = exports.SellerPayoutsApiAxiosParamCreator = exports.RootApi = exports.RootApiFactory = exports.RootApiFp = exports.RootApiAxiosParamCreator = exports.RbacApi = exports.RbacApiFactory = exports.RbacApiFp = exports.RbacApiAxiosParamCreator = exports.ProductsApi = exports.ProductsApiFactory = exports.ProductsApiFp = exports.ProductsApiAxiosParamCreator = exports.ProductCategoriesApi = exports.ProductCategoriesApiFactory = exports.ProductCategoriesApiFp = exports.ProductCategoriesApiAxiosParamCreator = exports.PointofsaleApi = exports.PointofsaleApiFactory = exports.PointofsaleApiFp = exports.PointofsaleApiAxiosParamCreator = exports.PayoutRequestsApi = exports.PayoutRequestsApiFactory = exports.PayoutRequestsApiFp = void 0;
|
|
18
18
|
exports.WriteoffsApi = exports.WriteoffsApiFactory = exports.WriteoffsApiFp = exports.WriteoffsApiAxiosParamCreator = exports.VouchergroupsApi = exports.VouchergroupsApiFactory = exports.VouchergroupsApiFp = exports.VouchergroupsApiAxiosParamCreator = exports.VatGroupsApi = exports.VatGroupsApiFactory = exports.VatGroupsApiFp = exports.VatGroupsApiAxiosParamCreator = exports.GetUsersSalesReportPdfFileTypeEnum = exports.GetUsersPurchaseReportPdfFileTypeEnum = exports.GetAllUsersTypeEnum = exports.UsersApi = exports.UsersApiFactory = exports.UsersApiFp = exports.UsersApiAxiosParamCreator = exports.UserNotificationPreferencesApi = exports.UserNotificationPreferencesApiFactory = exports.UserNotificationPreferencesApiFp = exports.UserNotificationPreferencesApiAxiosParamCreator = exports.TransfersApi = exports.TransfersApiFactory = exports.TransfersApiFp = exports.TransfersApiAxiosParamCreator = exports.TransactionsApi = exports.TransactionsApiFactory = exports.TransactionsApiFp = exports.TransactionsApiAxiosParamCreator = exports.TransactionSummariesApi = exports.TransactionSummariesApiFactory = void 0;
|
|
19
19
|
const axios_1 = require("axios");
|
|
@@ -32,6 +32,17 @@ exports.FinancialMutationResponseTypeEnum = {
|
|
|
32
32
|
Transfer: 'transfer',
|
|
33
33
|
Transaction: 'transaction'
|
|
34
34
|
};
|
|
35
|
+
/**
|
|
36
|
+
*
|
|
37
|
+
* @export
|
|
38
|
+
* @enum {string}
|
|
39
|
+
*/
|
|
40
|
+
exports.GetAllInvoicesCurrentStateParameterInner = {
|
|
41
|
+
Created: 'CREATED',
|
|
42
|
+
Sent: 'SENT',
|
|
43
|
+
Paid: 'PAID',
|
|
44
|
+
Deleted: 'DELETED'
|
|
45
|
+
};
|
|
35
46
|
exports.InvoiceStatusResponseStateEnum = {
|
|
36
47
|
Created: 'CREATED',
|
|
37
48
|
Sent: 'SENT',
|
|
@@ -72,6 +83,21 @@ exports.UserSettingsResponseLanguageEnum = {
|
|
|
72
83
|
EnUs: 'en-US',
|
|
73
84
|
PlPl: 'pl-PL'
|
|
74
85
|
};
|
|
86
|
+
/**
|
|
87
|
+
* The type of a user
|
|
88
|
+
* @export
|
|
89
|
+
* @enum {string}
|
|
90
|
+
*/
|
|
91
|
+
exports.UserType = {
|
|
92
|
+
Member: 'MEMBER',
|
|
93
|
+
Organ: 'ORGAN',
|
|
94
|
+
Voucher: 'VOUCHER',
|
|
95
|
+
LocalUser: 'LOCAL_USER',
|
|
96
|
+
LocalAdmin: 'LOCAL_ADMIN',
|
|
97
|
+
Invoice: 'INVOICE',
|
|
98
|
+
PointOfSale: 'POINT_OF_SALE',
|
|
99
|
+
Integration: 'INTEGRATION'
|
|
100
|
+
};
|
|
75
101
|
/**
|
|
76
102
|
* AuthenticateApi - axios parameter creator
|
|
77
103
|
* @export
|
|
@@ -1703,7 +1729,7 @@ const BalanceApiAxiosParamCreator = function (configuration) {
|
|
|
1703
1729
|
* @param {boolean} [hasFine] Only users with(out) fines
|
|
1704
1730
|
* @param {number} [minFine] Minimum fine
|
|
1705
1731
|
* @param {number} [maxFine] Maximum fine
|
|
1706
|
-
* @param {
|
|
1732
|
+
* @param {Array<UserType>} [userTypes] Filter based on user type.
|
|
1707
1733
|
* @param {string} [orderBy] Column to order balance by - eg: id,amount
|
|
1708
1734
|
* @param {GetAllBalanceOrderDirectionEnum} [orderDirection] Order direction
|
|
1709
1735
|
* @param {boolean} [allowDeleted] Whether to include deleted users
|
|
@@ -1867,7 +1893,7 @@ const BalanceApiFp = function (configuration) {
|
|
|
1867
1893
|
* @param {boolean} [hasFine] Only users with(out) fines
|
|
1868
1894
|
* @param {number} [minFine] Minimum fine
|
|
1869
1895
|
* @param {number} [maxFine] Maximum fine
|
|
1870
|
-
* @param {
|
|
1896
|
+
* @param {Array<UserType>} [userTypes] Filter based on user type.
|
|
1871
1897
|
* @param {string} [orderBy] Column to order balance by - eg: id,amount
|
|
1872
1898
|
* @param {GetAllBalanceOrderDirectionEnum} [orderDirection] Order direction
|
|
1873
1899
|
* @param {boolean} [allowDeleted] Whether to include deleted users
|
|
@@ -2012,10 +2038,6 @@ class BalanceApi extends base_1.BaseAPI {
|
|
|
2012
2038
|
}
|
|
2013
2039
|
}
|
|
2014
2040
|
exports.BalanceApi = BalanceApi;
|
|
2015
|
-
/**
|
|
2016
|
-
* @export
|
|
2017
|
-
*/
|
|
2018
|
-
exports.GetAllBalanceUserTypesEnum = {};
|
|
2019
2041
|
/**
|
|
2020
2042
|
* @export
|
|
2021
2043
|
*/
|
|
@@ -5804,7 +5826,7 @@ const InvoicesApiAxiosParamCreator = function (configuration) {
|
|
|
5804
5826
|
* @summary Returns all invoices in the system.
|
|
5805
5827
|
* @param {number} [toId] Filter on Id of the debtor
|
|
5806
5828
|
* @param {number} [invoiceId] Filter on invoice ID
|
|
5807
|
-
* @param {
|
|
5829
|
+
* @param {Array<GetAllInvoicesCurrentStateParameterInner>} [currentState] Filter based on Invoice State.
|
|
5808
5830
|
* @param {boolean} [returnEntries] Boolean if invoice entries should be returned
|
|
5809
5831
|
* @param {string} [fromDate] Start date for selected invoices (inclusive)
|
|
5810
5832
|
* @param {string} [tillDate] End date for selected invoices (exclusive)
|
|
@@ -6167,7 +6189,7 @@ const InvoicesApiFp = function (configuration) {
|
|
|
6167
6189
|
* @summary Returns all invoices in the system.
|
|
6168
6190
|
* @param {number} [toId] Filter on Id of the debtor
|
|
6169
6191
|
* @param {number} [invoiceId] Filter on invoice ID
|
|
6170
|
-
* @param {
|
|
6192
|
+
* @param {Array<GetAllInvoicesCurrentStateParameterInner>} [currentState] Filter based on Invoice State.
|
|
6171
6193
|
* @param {boolean} [returnEntries] Boolean if invoice entries should be returned
|
|
6172
6194
|
* @param {string} [fromDate] Start date for selected invoices (inclusive)
|
|
6173
6195
|
* @param {string} [tillDate] End date for selected invoices (exclusive)
|
|
@@ -6530,10 +6552,6 @@ class InvoicesApi extends base_1.BaseAPI {
|
|
|
6530
6552
|
}
|
|
6531
6553
|
}
|
|
6532
6554
|
exports.InvoicesApi = InvoicesApi;
|
|
6533
|
-
/**
|
|
6534
|
-
* @export
|
|
6535
|
-
*/
|
|
6536
|
-
exports.GetAllInvoicesCurrentStateEnum = {};
|
|
6537
6555
|
/**
|
|
6538
6556
|
* PayoutRequestsApi - axios parameter creator
|
|
6539
6557
|
* @export
|
|
@@ -10075,7 +10093,7 @@ const SyncApiAxiosParamCreator = function (configuration) {
|
|
|
10075
10093
|
/**
|
|
10076
10094
|
* Performs a dry-run synchronization of users using the specified services. This endpoint always performs a dry-run and does not apply any actual database changes.
|
|
10077
10095
|
* @summary Get dry-run sync results for users
|
|
10078
|
-
* @param {GetUserSyncResultsServiceEnum} [service] Array of sync services to use (ldap, gewisdb). If not provided, all available services will be used.
|
|
10096
|
+
* @param {Array<GetUserSyncResultsServiceEnum>} [service] Array of sync services to use (ldap, gewisdb). If not provided, all available services will be used.
|
|
10079
10097
|
* @param {*} [options] Override http request option.
|
|
10080
10098
|
* @throws {RequiredError}
|
|
10081
10099
|
*/
|
|
@@ -10117,7 +10135,7 @@ const SyncApiFp = function (configuration) {
|
|
|
10117
10135
|
/**
|
|
10118
10136
|
* Performs a dry-run synchronization of users using the specified services. This endpoint always performs a dry-run and does not apply any actual database changes.
|
|
10119
10137
|
* @summary Get dry-run sync results for users
|
|
10120
|
-
* @param {GetUserSyncResultsServiceEnum} [service] Array of sync services to use (ldap, gewisdb). If not provided, all available services will be used.
|
|
10138
|
+
* @param {Array<GetUserSyncResultsServiceEnum>} [service] Array of sync services to use (ldap, gewisdb). If not provided, all available services will be used.
|
|
10121
10139
|
* @param {*} [options] Override http request option.
|
|
10122
10140
|
* @throws {RequiredError}
|
|
10123
10141
|
*/
|
|
@@ -10173,7 +10191,10 @@ exports.SyncApi = SyncApi;
|
|
|
10173
10191
|
/**
|
|
10174
10192
|
* @export
|
|
10175
10193
|
*/
|
|
10176
|
-
exports.GetUserSyncResultsServiceEnum = {
|
|
10194
|
+
exports.GetUserSyncResultsServiceEnum = {
|
|
10195
|
+
Ldap: 'LDAP',
|
|
10196
|
+
Gewisdb: 'GEWISDB'
|
|
10197
|
+
};
|
|
10177
10198
|
/**
|
|
10178
10199
|
* TermsOfServiceApi - axios parameter creator
|
|
10179
10200
|
* @export
|
package/dist/base.js
CHANGED
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
16
16
|
exports.operationServerMap = exports.RequiredError = exports.BaseAPI = exports.COLLECTION_FORMATS = exports.BASE_PATH = void 0;
|
|
17
17
|
const axios_1 = require("axios");
|
|
18
|
-
exports.BASE_PATH = "http://
|
|
18
|
+
exports.BASE_PATH = "http://localhost:3000/api/v1".replace(/\/+$/, "");
|
|
19
19
|
/**
|
|
20
20
|
*
|
|
21
21
|
* @export
|