@randock/nameshift-api-client 0.0.498 → 0.0.499
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/.openapi-generator/FILES +7 -0
- package/README.md +3 -3
- package/dist/apis/AccountsApi.d.ts +15 -1
- package/dist/apis/AccountsApi.js +66 -0
- package/dist/apis/AdminApi.d.ts +27 -15
- package/dist/apis/AdminApi.js +78 -22
- package/dist/models/AccountBankAccountDto.d.ts +21 -0
- package/dist/models/AccountBankAccountDto.js +17 -1
- package/dist/models/AccountPayoutDto.d.ts +13 -0
- package/dist/models/AccountPayoutDto.js +9 -0
- package/dist/models/BankAccountFormatCountryDto.d.ts +7 -1
- package/dist/models/BankAccountFormatCountryDto.js +4 -0
- package/dist/models/BankAccountFormatDto.d.ts +14 -0
- package/dist/models/BankAccountFormatDto.js +10 -0
- package/dist/models/BankAccountTransferMethod.d.ts +25 -0
- package/dist/models/BankAccountTransferMethod.js +51 -0
- package/dist/models/InvoiceDto.d.ts +13 -0
- package/dist/models/InvoiceDto.js +9 -0
- package/dist/models/InvoicePayoutDto.d.ts +71 -0
- package/dist/models/InvoicePayoutDto.js +78 -0
- package/dist/models/InvoiceSellerAccountDto.d.ts +13 -0
- package/dist/models/InvoiceSellerAccountDto.js +9 -0
- package/dist/models/PaySellerInvoicesInput.d.ts +32 -0
- package/dist/models/PaySellerInvoicesInput.js +51 -0
- package/dist/models/PayoutFrequency.d.ts +28 -0
- package/dist/models/PayoutFrequency.js +54 -0
- package/dist/models/SellerInvoiceDto.d.ts +13 -0
- package/dist/models/SellerInvoiceDto.js +9 -0
- package/dist/models/SellerPayoutPreviewDto.d.ts +60 -0
- package/dist/models/SellerPayoutPreviewDto.js +73 -0
- package/dist/models/SellerPayoutStatus.d.ts +26 -0
- package/dist/models/SellerPayoutStatus.js +52 -0
- package/dist/models/SetPayoutFrequencyInput.d.ts +39 -0
- package/dist/models/SetPayoutFrequencyInput.js +54 -0
- package/dist/models/index.d.ts +7 -0
- package/dist/models/index.js +7 -0
- package/package.json +1 -1
- package/src/apis/AccountsApi.ts +64 -0
- package/src/apis/AdminApi.ts +82 -31
- package/src/models/AccountBankAccountDto.ts +34 -0
- package/src/models/AccountPayoutDto.ts +26 -0
- package/src/models/BankAccountFormatCountryDto.ts +10 -1
- package/src/models/BankAccountFormatDto.ts +34 -0
- package/src/models/BankAccountTransferMethod.ts +53 -0
- package/src/models/InvoiceDto.ts +25 -0
- package/src/models/InvoicePayoutDto.ts +144 -0
- package/src/models/InvoiceSellerAccountDto.ts +26 -0
- package/src/models/PaySellerInvoicesInput.ts +66 -0
- package/src/models/PayoutFrequency.ts +56 -0
- package/src/models/SellerInvoiceDto.ts +25 -0
- package/src/models/SellerPayoutPreviewDto.ts +119 -0
- package/src/models/SellerPayoutStatus.ts +54 -0
- package/src/models/SetPayoutFrequencyInput.ts +84 -0
- package/src/models/index.ts +7 -0
|
@@ -0,0 +1,144 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Nameshift
|
|
5
|
+
* Nameshift domain marketplace and management API. ## Authentication - **Bearer JWT** — Seller and buyer sessions obtained via login endpoints. - **API key** — Pass the `apikey` header for programmatic seller access. ## Audiences - **(public)** tags — Unauthenticated or buyer-facing endpoints. - **Accounts / Domains / Leads / Buyers** — Seller or buyer resources. - **Partner** — Partner integrations.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
import type { MoneyDto } from './MoneyDto';
|
|
17
|
+
import {
|
|
18
|
+
MoneyDtoFromJSON,
|
|
19
|
+
MoneyDtoFromJSONTyped,
|
|
20
|
+
MoneyDtoToJSON,
|
|
21
|
+
MoneyDtoToJSONTyped,
|
|
22
|
+
} from './MoneyDto';
|
|
23
|
+
import type { SellerPayoutStatus } from './SellerPayoutStatus';
|
|
24
|
+
import {
|
|
25
|
+
SellerPayoutStatusFromJSON,
|
|
26
|
+
SellerPayoutStatusFromJSONTyped,
|
|
27
|
+
SellerPayoutStatusToJSON,
|
|
28
|
+
SellerPayoutStatusToJSONTyped,
|
|
29
|
+
} from './SellerPayoutStatus';
|
|
30
|
+
import type { BankAccountTransferMethod } from './BankAccountTransferMethod';
|
|
31
|
+
import {
|
|
32
|
+
BankAccountTransferMethodFromJSON,
|
|
33
|
+
BankAccountTransferMethodFromJSONTyped,
|
|
34
|
+
BankAccountTransferMethodToJSON,
|
|
35
|
+
BankAccountTransferMethodToJSONTyped,
|
|
36
|
+
} from './BankAccountTransferMethod';
|
|
37
|
+
|
|
38
|
+
/**
|
|
39
|
+
*
|
|
40
|
+
* @export
|
|
41
|
+
* @interface InvoicePayoutDto
|
|
42
|
+
*/
|
|
43
|
+
export interface InvoicePayoutDto {
|
|
44
|
+
/**
|
|
45
|
+
* The payout. Invoices paid out in one transfer share it.
|
|
46
|
+
* @type {string}
|
|
47
|
+
* @memberof InvoicePayoutDto
|
|
48
|
+
*/
|
|
49
|
+
id: string;
|
|
50
|
+
/**
|
|
51
|
+
* pending while the transfer is being made, paid once it is, failed when the payout provider refused it: the invoice then awaits another payout.
|
|
52
|
+
* @type {SellerPayoutStatus}
|
|
53
|
+
* @memberof InvoicePayoutDto
|
|
54
|
+
*/
|
|
55
|
+
status: SellerPayoutStatus;
|
|
56
|
+
/**
|
|
57
|
+
* What the payout is for: this invoice and the others paid out with it.
|
|
58
|
+
* @type {MoneyDto}
|
|
59
|
+
* @memberof InvoicePayoutDto
|
|
60
|
+
*/
|
|
61
|
+
amount: MoneyDto;
|
|
62
|
+
/**
|
|
63
|
+
* How the payout reaches the bank account: LOCAL over the country's own clearing system, or SWIFT, an international transfer with a fee.
|
|
64
|
+
* @type {BankAccountTransferMethod}
|
|
65
|
+
* @memberof InvoicePayoutDto
|
|
66
|
+
*/
|
|
67
|
+
transferMethod: BankAccountTransferMethod;
|
|
68
|
+
/**
|
|
69
|
+
* The transfer fee that was taken out of what the seller receives, once for the whole payout. Null when there was none.
|
|
70
|
+
* @type {MoneyDto}
|
|
71
|
+
* @memberof InvoicePayoutDto
|
|
72
|
+
*/
|
|
73
|
+
fee: MoneyDto | null;
|
|
74
|
+
/**
|
|
75
|
+
* What the payout provider says arrives on the bank account, in its currency. Null when it did not say.
|
|
76
|
+
* @type {MoneyDto}
|
|
77
|
+
* @memberof InvoicePayoutDto
|
|
78
|
+
*/
|
|
79
|
+
receivedAmount: MoneyDto | null;
|
|
80
|
+
/**
|
|
81
|
+
* When the transfer was made.
|
|
82
|
+
* @type {Date}
|
|
83
|
+
* @memberof InvoicePayoutDto
|
|
84
|
+
*/
|
|
85
|
+
paidAt: Date | null;
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
|
|
89
|
+
|
|
90
|
+
/**
|
|
91
|
+
* Check if a given object implements the InvoicePayoutDto interface.
|
|
92
|
+
*/
|
|
93
|
+
export function instanceOfInvoicePayoutDto(value: object): value is InvoicePayoutDto {
|
|
94
|
+
if (!('id' in value) || value['id'] === undefined) return false;
|
|
95
|
+
if (!('status' in value) || value['status'] === undefined) return false;
|
|
96
|
+
if (!('amount' in value) || value['amount'] === undefined) return false;
|
|
97
|
+
if (!('transferMethod' in value) || value['transferMethod'] === undefined) return false;
|
|
98
|
+
if (!('fee' in value) || value['fee'] === undefined) return false;
|
|
99
|
+
if (!('receivedAmount' in value) || value['receivedAmount'] === undefined) return false;
|
|
100
|
+
if (!('paidAt' in value) || value['paidAt'] === undefined) return false;
|
|
101
|
+
return true;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
export function InvoicePayoutDtoFromJSON(json: any): InvoicePayoutDto {
|
|
105
|
+
return InvoicePayoutDtoFromJSONTyped(json, false);
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
export function InvoicePayoutDtoFromJSONTyped(json: any, ignoreDiscriminator: boolean): InvoicePayoutDto {
|
|
109
|
+
if (json == null) {
|
|
110
|
+
return json;
|
|
111
|
+
}
|
|
112
|
+
return {
|
|
113
|
+
|
|
114
|
+
'id': json['id'],
|
|
115
|
+
'status': SellerPayoutStatusFromJSON(json['status']),
|
|
116
|
+
'amount': MoneyDtoFromJSON(json['amount']),
|
|
117
|
+
'transferMethod': BankAccountTransferMethodFromJSON(json['transferMethod']),
|
|
118
|
+
'fee': MoneyDtoFromJSON(json['fee']),
|
|
119
|
+
'receivedAmount': MoneyDtoFromJSON(json['receivedAmount']),
|
|
120
|
+
'paidAt': (json['paidAt'] == null ? null : new Date(json['paidAt'])),
|
|
121
|
+
};
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
export function InvoicePayoutDtoToJSON(json: any): InvoicePayoutDto {
|
|
125
|
+
return InvoicePayoutDtoToJSONTyped(json, false);
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
export function InvoicePayoutDtoToJSONTyped(value?: InvoicePayoutDto | null, ignoreDiscriminator: boolean = false): any {
|
|
129
|
+
if (value == null) {
|
|
130
|
+
return value;
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
return {
|
|
134
|
+
|
|
135
|
+
'id': value['id'],
|
|
136
|
+
'status': SellerPayoutStatusToJSON(value['status']),
|
|
137
|
+
'amount': MoneyDtoToJSON(value['amount']),
|
|
138
|
+
'transferMethod': BankAccountTransferMethodToJSON(value['transferMethod']),
|
|
139
|
+
'fee': MoneyDtoToJSON(value['fee']),
|
|
140
|
+
'receivedAmount': MoneyDtoToJSON(value['receivedAmount']),
|
|
141
|
+
'paidAt': (value['paidAt'] == null ? null : (value['paidAt'] as any).toISOString()),
|
|
142
|
+
};
|
|
143
|
+
}
|
|
144
|
+
|
|
@@ -13,6 +13,14 @@
|
|
|
13
13
|
*/
|
|
14
14
|
|
|
15
15
|
import { mapValues } from '../runtime';
|
|
16
|
+
import type { PayoutFrequency } from './PayoutFrequency';
|
|
17
|
+
import {
|
|
18
|
+
PayoutFrequencyFromJSON,
|
|
19
|
+
PayoutFrequencyFromJSONTyped,
|
|
20
|
+
PayoutFrequencyToJSON,
|
|
21
|
+
PayoutFrequencyToJSONTyped,
|
|
22
|
+
} from './PayoutFrequency';
|
|
23
|
+
|
|
16
24
|
/**
|
|
17
25
|
*
|
|
18
26
|
* @export
|
|
@@ -49,6 +57,18 @@ export interface InvoiceSellerAccountDto {
|
|
|
49
57
|
* @memberof InvoiceSellerAccountDto
|
|
50
58
|
*/
|
|
51
59
|
payoutProvider: InvoiceSellerAccountDtoPayoutProviderEnum;
|
|
60
|
+
/**
|
|
61
|
+
* How often the seller wants to be paid out: their invoices are due accordingly.
|
|
62
|
+
* @type {PayoutFrequency}
|
|
63
|
+
* @memberof InvoiceSellerAccountDto
|
|
64
|
+
*/
|
|
65
|
+
payoutFrequency: PayoutFrequency;
|
|
66
|
+
/**
|
|
67
|
+
* Whether the invoices of this seller are paid out without an admin once they are due.
|
|
68
|
+
* @type {boolean}
|
|
69
|
+
* @memberof InvoiceSellerAccountDto
|
|
70
|
+
*/
|
|
71
|
+
automaticPayouts: boolean;
|
|
52
72
|
}
|
|
53
73
|
|
|
54
74
|
|
|
@@ -71,6 +91,8 @@ export function instanceOfInvoiceSellerAccountDto(value: object): value is Invoi
|
|
|
71
91
|
if (!('name' in value) || value['name'] === undefined) return false;
|
|
72
92
|
if (!('isBusiness' in value) || value['isBusiness'] === undefined) return false;
|
|
73
93
|
if (!('payoutProvider' in value) || value['payoutProvider'] === undefined) return false;
|
|
94
|
+
if (!('payoutFrequency' in value) || value['payoutFrequency'] === undefined) return false;
|
|
95
|
+
if (!('automaticPayouts' in value) || value['automaticPayouts'] === undefined) return false;
|
|
74
96
|
return true;
|
|
75
97
|
}
|
|
76
98
|
|
|
@@ -89,6 +111,8 @@ export function InvoiceSellerAccountDtoFromJSONTyped(json: any, ignoreDiscrimina
|
|
|
89
111
|
'name': json['name'],
|
|
90
112
|
'isBusiness': json['isBusiness'],
|
|
91
113
|
'payoutProvider': json['payoutProvider'],
|
|
114
|
+
'payoutFrequency': PayoutFrequencyFromJSON(json['payoutFrequency']),
|
|
115
|
+
'automaticPayouts': json['automaticPayouts'],
|
|
92
116
|
};
|
|
93
117
|
}
|
|
94
118
|
|
|
@@ -108,6 +132,8 @@ export function InvoiceSellerAccountDtoToJSONTyped(value?: InvoiceSellerAccountD
|
|
|
108
132
|
'name': value['name'],
|
|
109
133
|
'isBusiness': value['isBusiness'],
|
|
110
134
|
'payoutProvider': value['payoutProvider'],
|
|
135
|
+
'payoutFrequency': PayoutFrequencyToJSON(value['payoutFrequency']),
|
|
136
|
+
'automaticPayouts': value['automaticPayouts'],
|
|
111
137
|
};
|
|
112
138
|
}
|
|
113
139
|
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Nameshift
|
|
5
|
+
* Nameshift domain marketplace and management API. ## Authentication - **Bearer JWT** — Seller and buyer sessions obtained via login endpoints. - **API key** — Pass the `apikey` header for programmatic seller access. ## Audiences - **(public)** tags — Unauthenticated or buyer-facing endpoints. - **Accounts / Domains / Leads / Buyers** — Seller or buyer resources. - **Partner** — Partner integrations.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
/**
|
|
17
|
+
*
|
|
18
|
+
* @export
|
|
19
|
+
* @interface PaySellerInvoicesInput
|
|
20
|
+
*/
|
|
21
|
+
export interface PaySellerInvoicesInput {
|
|
22
|
+
/**
|
|
23
|
+
* The seller invoices to pay out together: all of one seller, awaiting their payout and, for a bank transfer, in one currency.
|
|
24
|
+
* @type {Array<string>}
|
|
25
|
+
* @memberof PaySellerInvoicesInput
|
|
26
|
+
*/
|
|
27
|
+
invoiceIds: Array<string>;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
* Check if a given object implements the PaySellerInvoicesInput interface.
|
|
32
|
+
*/
|
|
33
|
+
export function instanceOfPaySellerInvoicesInput(value: object): value is PaySellerInvoicesInput {
|
|
34
|
+
if (!('invoiceIds' in value) || value['invoiceIds'] === undefined) return false;
|
|
35
|
+
return true;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
export function PaySellerInvoicesInputFromJSON(json: any): PaySellerInvoicesInput {
|
|
39
|
+
return PaySellerInvoicesInputFromJSONTyped(json, false);
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
export function PaySellerInvoicesInputFromJSONTyped(json: any, ignoreDiscriminator: boolean): PaySellerInvoicesInput {
|
|
43
|
+
if (json == null) {
|
|
44
|
+
return json;
|
|
45
|
+
}
|
|
46
|
+
return {
|
|
47
|
+
|
|
48
|
+
'invoiceIds': json['invoiceIds'],
|
|
49
|
+
};
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
export function PaySellerInvoicesInputToJSON(json: any): PaySellerInvoicesInput {
|
|
53
|
+
return PaySellerInvoicesInputToJSONTyped(json, false);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
export function PaySellerInvoicesInputToJSONTyped(value?: PaySellerInvoicesInput | null, ignoreDiscriminator: boolean = false): any {
|
|
57
|
+
if (value == null) {
|
|
58
|
+
return value;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
return {
|
|
62
|
+
|
|
63
|
+
'invoiceIds': value['invoiceIds'],
|
|
64
|
+
};
|
|
65
|
+
}
|
|
66
|
+
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Nameshift
|
|
5
|
+
* Nameshift domain marketplace and management API. ## Authentication - **Bearer JWT** — Seller and buyer sessions obtained via login endpoints. - **API key** — Pass the `apikey` header for programmatic seller access. ## Audiences - **(public)** tags — Unauthenticated or buyer-facing endpoints. - **Accounts / Domains / Leads / Buyers** — Seller or buyer resources. - **Partner** — Partner integrations.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* How often the seller is paid out when they are paid out automatically: each invoice as soon as it can be (immediate), or what came in during a week, two weeks, month or quarter when the next one starts. An admin pays out the others, whatever this says.
|
|
18
|
+
* @export
|
|
19
|
+
*/
|
|
20
|
+
export const PayoutFrequency = {
|
|
21
|
+
IMMEDIATE: 'immediate',
|
|
22
|
+
WEEKLY: 'weekly',
|
|
23
|
+
BIWEEKLY: 'biweekly',
|
|
24
|
+
MONTHLY: 'monthly',
|
|
25
|
+
QUARTERLY: 'quarterly'
|
|
26
|
+
} as const;
|
|
27
|
+
export type PayoutFrequency = typeof PayoutFrequency[keyof typeof PayoutFrequency];
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
export function instanceOfPayoutFrequency(value: any): boolean {
|
|
31
|
+
for (const key in PayoutFrequency) {
|
|
32
|
+
if (Object.prototype.hasOwnProperty.call(PayoutFrequency, key)) {
|
|
33
|
+
if (PayoutFrequency[key as keyof typeof PayoutFrequency] === value) {
|
|
34
|
+
return true;
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
return false;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
export function PayoutFrequencyFromJSON(json: any): PayoutFrequency {
|
|
42
|
+
return PayoutFrequencyFromJSONTyped(json, false);
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
export function PayoutFrequencyFromJSONTyped(json: any, ignoreDiscriminator: boolean): PayoutFrequency {
|
|
46
|
+
return json as PayoutFrequency;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export function PayoutFrequencyToJSON(value?: PayoutFrequency | null): any {
|
|
50
|
+
return value as any;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
export function PayoutFrequencyToJSONTyped(value: any, ignoreDiscriminator: boolean): PayoutFrequency {
|
|
54
|
+
return value as PayoutFrequency;
|
|
55
|
+
}
|
|
56
|
+
|
|
@@ -27,6 +27,13 @@ import {
|
|
|
27
27
|
SellerInvoiceSellerAccountDtoToJSON,
|
|
28
28
|
SellerInvoiceSellerAccountDtoToJSONTyped,
|
|
29
29
|
} from './SellerInvoiceSellerAccountDto';
|
|
30
|
+
import type { InvoicePayoutDto } from './InvoicePayoutDto';
|
|
31
|
+
import {
|
|
32
|
+
InvoicePayoutDtoFromJSON,
|
|
33
|
+
InvoicePayoutDtoFromJSONTyped,
|
|
34
|
+
InvoicePayoutDtoToJSON,
|
|
35
|
+
InvoicePayoutDtoToJSONTyped,
|
|
36
|
+
} from './InvoicePayoutDto';
|
|
30
37
|
import type { MoneyDto } from './MoneyDto';
|
|
31
38
|
import {
|
|
32
39
|
MoneyDtoFromJSON,
|
|
@@ -107,6 +114,18 @@ export interface SellerInvoiceDto {
|
|
|
107
114
|
* @memberof SellerInvoiceDto
|
|
108
115
|
*/
|
|
109
116
|
isAffiliateCommission: boolean;
|
|
117
|
+
/**
|
|
118
|
+
* For an invoice awaiting its payout: when it is due, by the payout frequency of the account. A payout that costs the account nothing is due right away, unless it wants those to wait too, and so is every invoice of an account that is not paid out automatically. Null when it awaits no payout.
|
|
119
|
+
* @type {Date}
|
|
120
|
+
* @memberof SellerInvoiceDto
|
|
121
|
+
*/
|
|
122
|
+
payoutDueAt: Date | null;
|
|
123
|
+
/**
|
|
124
|
+
* The bank transfer the invoice is or was last paid out with, which tells the transfer fee taken out of it. Null when it was in none.
|
|
125
|
+
* @type {InvoicePayoutDto}
|
|
126
|
+
* @memberof SellerInvoiceDto
|
|
127
|
+
*/
|
|
128
|
+
payout: InvoicePayoutDto | null;
|
|
110
129
|
}
|
|
111
130
|
|
|
112
131
|
|
|
@@ -146,6 +165,8 @@ export function instanceOfSellerInvoiceDto(value: object): value is SellerInvoic
|
|
|
146
165
|
if (!('parent' in value) || value['parent'] === undefined) return false;
|
|
147
166
|
if (!('hasChildren' in value) || value['hasChildren'] === undefined) return false;
|
|
148
167
|
if (!('isAffiliateCommission' in value) || value['isAffiliateCommission'] === undefined) return false;
|
|
168
|
+
if (!('payoutDueAt' in value) || value['payoutDueAt'] === undefined) return false;
|
|
169
|
+
if (!('payout' in value) || value['payout'] === undefined) return false;
|
|
149
170
|
return true;
|
|
150
171
|
}
|
|
151
172
|
|
|
@@ -170,6 +191,8 @@ export function SellerInvoiceDtoFromJSONTyped(json: any, ignoreDiscriminator: bo
|
|
|
170
191
|
'parent': json['parent'],
|
|
171
192
|
'hasChildren': json['hasChildren'],
|
|
172
193
|
'isAffiliateCommission': json['isAffiliateCommission'],
|
|
194
|
+
'payoutDueAt': (json['payoutDueAt'] == null ? null : new Date(json['payoutDueAt'])),
|
|
195
|
+
'payout': InvoicePayoutDtoFromJSON(json['payout']),
|
|
173
196
|
};
|
|
174
197
|
}
|
|
175
198
|
|
|
@@ -195,6 +218,8 @@ export function SellerInvoiceDtoToJSONTyped(value?: SellerInvoiceDto | null, ign
|
|
|
195
218
|
'parent': value['parent'],
|
|
196
219
|
'hasChildren': value['hasChildren'],
|
|
197
220
|
'isAffiliateCommission': value['isAffiliateCommission'],
|
|
221
|
+
'payoutDueAt': (value['payoutDueAt'] == null ? null : (value['payoutDueAt'] as any).toISOString()),
|
|
222
|
+
'payout': InvoicePayoutDtoToJSON(value['payout']),
|
|
198
223
|
};
|
|
199
224
|
}
|
|
200
225
|
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Nameshift
|
|
5
|
+
* Nameshift domain marketplace and management API. ## Authentication - **Bearer JWT** — Seller and buyer sessions obtained via login endpoints. - **API key** — Pass the `apikey` header for programmatic seller access. ## Audiences - **(public)** tags — Unauthenticated or buyer-facing endpoints. - **Accounts / Domains / Leads / Buyers** — Seller or buyer resources. - **Partner** — Partner integrations.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
import type { AccountBankAccountDto } from './AccountBankAccountDto';
|
|
17
|
+
import {
|
|
18
|
+
AccountBankAccountDtoFromJSON,
|
|
19
|
+
AccountBankAccountDtoFromJSONTyped,
|
|
20
|
+
AccountBankAccountDtoToJSON,
|
|
21
|
+
AccountBankAccountDtoToJSONTyped,
|
|
22
|
+
} from './AccountBankAccountDto';
|
|
23
|
+
import type { MoneyDto } from './MoneyDto';
|
|
24
|
+
import {
|
|
25
|
+
MoneyDtoFromJSON,
|
|
26
|
+
MoneyDtoFromJSONTyped,
|
|
27
|
+
MoneyDtoToJSON,
|
|
28
|
+
MoneyDtoToJSONTyped,
|
|
29
|
+
} from './MoneyDto';
|
|
30
|
+
|
|
31
|
+
/**
|
|
32
|
+
*
|
|
33
|
+
* @export
|
|
34
|
+
* @interface SellerPayoutPreviewDto
|
|
35
|
+
*/
|
|
36
|
+
export interface SellerPayoutPreviewDto {
|
|
37
|
+
/**
|
|
38
|
+
* How the seller is paid out: to their bank account in one transfer, or through Stripe, each invoice apart.
|
|
39
|
+
* @type {string}
|
|
40
|
+
* @memberof SellerPayoutPreviewDto
|
|
41
|
+
*/
|
|
42
|
+
provider: SellerPayoutPreviewDtoProviderEnum;
|
|
43
|
+
/**
|
|
44
|
+
* What the invoices come to together, in their currency. Null through Stripe.
|
|
45
|
+
* @type {MoneyDto}
|
|
46
|
+
* @memberof SellerPayoutPreviewDto
|
|
47
|
+
*/
|
|
48
|
+
amount: MoneyDto | null;
|
|
49
|
+
/**
|
|
50
|
+
* The bank account the transfer goes to, with how it is paid out to. When its currency is not that of the invoices, the payout provider converts the amount. Null through Stripe.
|
|
51
|
+
* @type {AccountBankAccountDto}
|
|
52
|
+
* @memberof SellerPayoutPreviewDto
|
|
53
|
+
*/
|
|
54
|
+
bankAccount: AccountBankAccountDto | null;
|
|
55
|
+
/**
|
|
56
|
+
* The transfer fee taken out of what the seller receives, as an indication in the currency of the invoices: the configured SWIFT fee at today's rate. Null when the transfer costs the seller nothing, or no fee is configured.
|
|
57
|
+
* @type {MoneyDto}
|
|
58
|
+
* @memberof SellerPayoutPreviewDto
|
|
59
|
+
*/
|
|
60
|
+
fee: MoneyDto | null;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
|
|
64
|
+
/**
|
|
65
|
+
* @export
|
|
66
|
+
*/
|
|
67
|
+
export const SellerPayoutPreviewDtoProviderEnum = {
|
|
68
|
+
STRIPE: 'stripe',
|
|
69
|
+
BANK_ACCOUNT: 'bank_account'
|
|
70
|
+
} as const;
|
|
71
|
+
export type SellerPayoutPreviewDtoProviderEnum = typeof SellerPayoutPreviewDtoProviderEnum[keyof typeof SellerPayoutPreviewDtoProviderEnum];
|
|
72
|
+
|
|
73
|
+
|
|
74
|
+
/**
|
|
75
|
+
* Check if a given object implements the SellerPayoutPreviewDto interface.
|
|
76
|
+
*/
|
|
77
|
+
export function instanceOfSellerPayoutPreviewDto(value: object): value is SellerPayoutPreviewDto {
|
|
78
|
+
if (!('provider' in value) || value['provider'] === undefined) return false;
|
|
79
|
+
if (!('amount' in value) || value['amount'] === undefined) return false;
|
|
80
|
+
if (!('bankAccount' in value) || value['bankAccount'] === undefined) return false;
|
|
81
|
+
if (!('fee' in value) || value['fee'] === undefined) return false;
|
|
82
|
+
return true;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
export function SellerPayoutPreviewDtoFromJSON(json: any): SellerPayoutPreviewDto {
|
|
86
|
+
return SellerPayoutPreviewDtoFromJSONTyped(json, false);
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
export function SellerPayoutPreviewDtoFromJSONTyped(json: any, ignoreDiscriminator: boolean): SellerPayoutPreviewDto {
|
|
90
|
+
if (json == null) {
|
|
91
|
+
return json;
|
|
92
|
+
}
|
|
93
|
+
return {
|
|
94
|
+
|
|
95
|
+
'provider': json['provider'],
|
|
96
|
+
'amount': MoneyDtoFromJSON(json['amount']),
|
|
97
|
+
'bankAccount': AccountBankAccountDtoFromJSON(json['bankAccount']),
|
|
98
|
+
'fee': MoneyDtoFromJSON(json['fee']),
|
|
99
|
+
};
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
export function SellerPayoutPreviewDtoToJSON(json: any): SellerPayoutPreviewDto {
|
|
103
|
+
return SellerPayoutPreviewDtoToJSONTyped(json, false);
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
export function SellerPayoutPreviewDtoToJSONTyped(value?: SellerPayoutPreviewDto | null, ignoreDiscriminator: boolean = false): any {
|
|
107
|
+
if (value == null) {
|
|
108
|
+
return value;
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
return {
|
|
112
|
+
|
|
113
|
+
'provider': value['provider'],
|
|
114
|
+
'amount': MoneyDtoToJSON(value['amount']),
|
|
115
|
+
'bankAccount': AccountBankAccountDtoToJSON(value['bankAccount']),
|
|
116
|
+
'fee': MoneyDtoToJSON(value['fee']),
|
|
117
|
+
};
|
|
118
|
+
}
|
|
119
|
+
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Nameshift
|
|
5
|
+
* Nameshift domain marketplace and management API. ## Authentication - **Bearer JWT** — Seller and buyer sessions obtained via login endpoints. - **API key** — Pass the `apikey` header for programmatic seller access. ## Audiences - **(public)** tags — Unauthenticated or buyer-facing endpoints. - **Accounts / Domains / Leads / Buyers** — Seller or buyer resources. - **Partner** — Partner integrations.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
/**
|
|
17
|
+
* pending while the transfer is being made, paid once it is, failed when the payout provider refused it: the invoice then awaits another payout.
|
|
18
|
+
* @export
|
|
19
|
+
*/
|
|
20
|
+
export const SellerPayoutStatus = {
|
|
21
|
+
PENDING: 'pending',
|
|
22
|
+
PAID: 'paid',
|
|
23
|
+
FAILED: 'failed'
|
|
24
|
+
} as const;
|
|
25
|
+
export type SellerPayoutStatus = typeof SellerPayoutStatus[keyof typeof SellerPayoutStatus];
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
export function instanceOfSellerPayoutStatus(value: any): boolean {
|
|
29
|
+
for (const key in SellerPayoutStatus) {
|
|
30
|
+
if (Object.prototype.hasOwnProperty.call(SellerPayoutStatus, key)) {
|
|
31
|
+
if (SellerPayoutStatus[key as keyof typeof SellerPayoutStatus] === value) {
|
|
32
|
+
return true;
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
return false;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
export function SellerPayoutStatusFromJSON(json: any): SellerPayoutStatus {
|
|
40
|
+
return SellerPayoutStatusFromJSONTyped(json, false);
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
export function SellerPayoutStatusFromJSONTyped(json: any, ignoreDiscriminator: boolean): SellerPayoutStatus {
|
|
44
|
+
return json as SellerPayoutStatus;
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
export function SellerPayoutStatusToJSON(value?: SellerPayoutStatus | null): any {
|
|
48
|
+
return value as any;
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
export function SellerPayoutStatusToJSONTyped(value: any, ignoreDiscriminator: boolean): SellerPayoutStatus {
|
|
52
|
+
return value as SellerPayoutStatus;
|
|
53
|
+
}
|
|
54
|
+
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* Nameshift
|
|
5
|
+
* Nameshift domain marketplace and management API. ## Authentication - **Bearer JWT** — Seller and buyer sessions obtained via login endpoints. - **API key** — Pass the `apikey` header for programmatic seller access. ## Audiences - **(public)** tags — Unauthenticated or buyer-facing endpoints. - **Accounts / Domains / Leads / Buyers** — Seller or buyer resources. - **Partner** — Partner integrations.
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
|
|
15
|
+
import { mapValues } from '../runtime';
|
|
16
|
+
import type { PayoutFrequency } from './PayoutFrequency';
|
|
17
|
+
import {
|
|
18
|
+
PayoutFrequencyFromJSON,
|
|
19
|
+
PayoutFrequencyFromJSONTyped,
|
|
20
|
+
PayoutFrequencyToJSON,
|
|
21
|
+
PayoutFrequencyToJSONTyped,
|
|
22
|
+
} from './PayoutFrequency';
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
*
|
|
26
|
+
* @export
|
|
27
|
+
* @interface SetPayoutFrequencyInput
|
|
28
|
+
*/
|
|
29
|
+
export interface SetPayoutFrequencyInput {
|
|
30
|
+
/**
|
|
31
|
+
* How often to be paid out: each invoice as soon as it can be (immediate), or what came in during a week, two weeks, month or quarter when the next one starts.
|
|
32
|
+
* @type {PayoutFrequency}
|
|
33
|
+
* @memberof SetPayoutFrequencyInput
|
|
34
|
+
*/
|
|
35
|
+
frequency: PayoutFrequency;
|
|
36
|
+
/**
|
|
37
|
+
* Whether payouts that cost the seller nothing (a local transfer to their bank account) wait for the frequency too. When false, those are made as soon as they can be, and only payouts with a transfer fee wait, to go out together. Left as it is when not given.
|
|
38
|
+
* @type {boolean}
|
|
39
|
+
* @memberof SetPayoutFrequencyInput
|
|
40
|
+
*/
|
|
41
|
+
batchFreePayouts?: boolean;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
/**
|
|
47
|
+
* Check if a given object implements the SetPayoutFrequencyInput interface.
|
|
48
|
+
*/
|
|
49
|
+
export function instanceOfSetPayoutFrequencyInput(value: object): value is SetPayoutFrequencyInput {
|
|
50
|
+
if (!('frequency' in value) || value['frequency'] === undefined) return false;
|
|
51
|
+
return true;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
export function SetPayoutFrequencyInputFromJSON(json: any): SetPayoutFrequencyInput {
|
|
55
|
+
return SetPayoutFrequencyInputFromJSONTyped(json, false);
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
export function SetPayoutFrequencyInputFromJSONTyped(json: any, ignoreDiscriminator: boolean): SetPayoutFrequencyInput {
|
|
59
|
+
if (json == null) {
|
|
60
|
+
return json;
|
|
61
|
+
}
|
|
62
|
+
return {
|
|
63
|
+
|
|
64
|
+
'frequency': PayoutFrequencyFromJSON(json['frequency']),
|
|
65
|
+
'batchFreePayouts': json['batchFreePayouts'] == null ? undefined : json['batchFreePayouts'],
|
|
66
|
+
};
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
export function SetPayoutFrequencyInputToJSON(json: any): SetPayoutFrequencyInput {
|
|
70
|
+
return SetPayoutFrequencyInputToJSONTyped(json, false);
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
export function SetPayoutFrequencyInputToJSONTyped(value?: SetPayoutFrequencyInput | null, ignoreDiscriminator: boolean = false): any {
|
|
74
|
+
if (value == null) {
|
|
75
|
+
return value;
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
return {
|
|
79
|
+
|
|
80
|
+
'frequency': PayoutFrequencyToJSON(value['frequency']),
|
|
81
|
+
'batchFreePayouts': value['batchFreePayouts'],
|
|
82
|
+
};
|
|
83
|
+
}
|
|
84
|
+
|
package/src/models/index.ts
CHANGED
|
@@ -105,6 +105,7 @@ export * from './BankAccountFormatFieldDto';
|
|
|
105
105
|
export * from './BankAccountFormatFieldOptionDto';
|
|
106
106
|
export * from './BankAccountFormatFieldType';
|
|
107
107
|
export * from './BankAccountFormatsDto';
|
|
108
|
+
export * from './BankAccountTransferMethod';
|
|
108
109
|
export * from './BatchDeleteBuyerLeadsInput';
|
|
109
110
|
export * from './BatchImportPreviewDto';
|
|
110
111
|
export * from './BatchReadBuyerLeadMessageInput';
|
|
@@ -305,6 +306,7 @@ export * from './InvoiceDto';
|
|
|
305
306
|
export * from './InvoiceDtoTransaction';
|
|
306
307
|
export * from './InvoiceItemDto';
|
|
307
308
|
export * from './InvoiceItemTaxDto';
|
|
309
|
+
export * from './InvoicePayoutDto';
|
|
308
310
|
export * from './InvoiceSellerAccountDto';
|
|
309
311
|
export * from './InvoiceTransactionDto';
|
|
310
312
|
export * from './JobDto';
|
|
@@ -425,7 +427,9 @@ export * from './ParsedDomainDto';
|
|
|
425
427
|
export * from './PartnerAuctionDto';
|
|
426
428
|
export * from './PartnerDomainFindDto';
|
|
427
429
|
export * from './PayAccountPaymentInput';
|
|
430
|
+
export * from './PaySellerInvoicesInput';
|
|
428
431
|
export * from './PaymentMethodsStatsDto';
|
|
432
|
+
export * from './PayoutFrequency';
|
|
429
433
|
export * from './PopularCategoryDto';
|
|
430
434
|
export * from './PreviewDomainEditInput';
|
|
431
435
|
export * from './PrivateAccountGetMeResponse';
|
|
@@ -483,6 +487,8 @@ export * from './SellerInvoiceDomainDto';
|
|
|
483
487
|
export * from './SellerInvoiceDto';
|
|
484
488
|
export * from './SellerInvoiceSellerAccountDto';
|
|
485
489
|
export * from './SellerLeadDetails';
|
|
490
|
+
export * from './SellerPayoutPreviewDto';
|
|
491
|
+
export * from './SellerPayoutStatus';
|
|
486
492
|
export * from './SellerPendingPayoutsByCurrencyStatsItemDto';
|
|
487
493
|
export * from './SellerRemainingAndTotalLeaseToOwnByCurrencyStatsItemDto';
|
|
488
494
|
export * from './SellerSalesByTldStatsItemDto';
|
|
@@ -502,6 +508,7 @@ export * from './SeoMetricsDto';
|
|
|
502
508
|
export * from './SetAccountMarketplaceInput';
|
|
503
509
|
export * from './SetDomainTransferConfirmationInput';
|
|
504
510
|
export * from './SetNewPasswordInput';
|
|
511
|
+
export * from './SetPayoutFrequencyInput';
|
|
505
512
|
export * from './SetPayoutProviderInput';
|
|
506
513
|
export * from './SimulateCommissionInput';
|
|
507
514
|
export * from './StartAuctionInput';
|