conductor-node 12.6.0 → 12.8.0
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/CHANGELOG.md +16 -0
- package/package.json +1 -1
- package/resources/qbd/index.d.ts +2 -0
- package/resources/qbd/index.d.ts.map +1 -1
- package/resources/qbd/index.js +6 -2
- package/resources/qbd/index.js.map +1 -1
- package/resources/qbd/index.mjs +2 -0
- package/resources/qbd/index.mjs.map +1 -1
- package/resources/qbd/other-names.d.ts +690 -0
- package/resources/qbd/other-names.d.ts.map +1 -0
- package/resources/qbd/other-names.js +88 -0
- package/resources/qbd/other-names.js.map +1 -0
- package/resources/qbd/other-names.mjs +84 -0
- package/resources/qbd/other-names.mjs.map +1 -0
- package/resources/qbd/payment-methods.d.ts +235 -0
- package/resources/qbd/payment-methods.d.ts.map +1 -0
- package/resources/qbd/payment-methods.js +69 -0
- package/resources/qbd/payment-methods.js.map +1 -0
- package/resources/qbd/payment-methods.mjs +65 -0
- package/resources/qbd/payment-methods.mjs.map +1 -0
- package/resources/qbd/qbd.d.ts +8 -0
- package/resources/qbd/qbd.d.ts.map +1 -1
- package/resources/qbd/qbd.js +8 -0
- package/resources/qbd/qbd.js.map +1 -1
- package/resources/qbd/qbd.mjs +8 -0
- package/resources/qbd/qbd.mjs.map +1 -1
- package/src/resources/qbd/index.ts +17 -0
- package/src/resources/qbd/other-names.ts +855 -0
- package/src/resources/qbd/payment-methods.ts +335 -0
- package/src/resources/qbd/qbd.ts +42 -0
- package/src/version.ts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
|
@@ -0,0 +1,335 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
import { APIResource } from '../../resource';
|
|
4
|
+
import * as Core from '../../core';
|
|
5
|
+
|
|
6
|
+
export class PaymentMethods extends APIResource {
|
|
7
|
+
/**
|
|
8
|
+
* Creates a new payment method.
|
|
9
|
+
*
|
|
10
|
+
* @example
|
|
11
|
+
* ```ts
|
|
12
|
+
* const paymentMethod =
|
|
13
|
+
* await client.qbd.paymentMethods.create({
|
|
14
|
+
* name: 'Cash',
|
|
15
|
+
* paymentMethodType: 'cash',
|
|
16
|
+
* conductorEndUserId: 'end_usr_1234567abcdefg',
|
|
17
|
+
* });
|
|
18
|
+
* ```
|
|
19
|
+
*/
|
|
20
|
+
create(params: PaymentMethodCreateParams, options?: Core.RequestOptions): Core.APIPromise<PaymentMethod> {
|
|
21
|
+
const { conductorEndUserId, ...body } = params;
|
|
22
|
+
return this._client.post('/quickbooks-desktop/payment-methods', {
|
|
23
|
+
body,
|
|
24
|
+
...options,
|
|
25
|
+
headers: { 'Conductor-End-User-Id': conductorEndUserId, ...options?.headers },
|
|
26
|
+
});
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
/**
|
|
30
|
+
* Retrieves a payment method by ID.
|
|
31
|
+
*
|
|
32
|
+
* @example
|
|
33
|
+
* ```ts
|
|
34
|
+
* const paymentMethod =
|
|
35
|
+
* await client.qbd.paymentMethods.retrieve(
|
|
36
|
+
* '80000001-1234567890',
|
|
37
|
+
* { conductorEndUserId: 'end_usr_1234567abcdefg' },
|
|
38
|
+
* );
|
|
39
|
+
* ```
|
|
40
|
+
*/
|
|
41
|
+
retrieve(
|
|
42
|
+
id: string,
|
|
43
|
+
params: PaymentMethodRetrieveParams,
|
|
44
|
+
options?: Core.RequestOptions,
|
|
45
|
+
): Core.APIPromise<PaymentMethod> {
|
|
46
|
+
const { conductorEndUserId } = params;
|
|
47
|
+
return this._client.get(`/quickbooks-desktop/payment-methods/${id}`, {
|
|
48
|
+
...options,
|
|
49
|
+
headers: { 'Conductor-End-User-Id': conductorEndUserId, ...options?.headers },
|
|
50
|
+
});
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
/**
|
|
54
|
+
* Returns a list of payment methods. NOTE: QuickBooks Desktop does not support
|
|
55
|
+
* pagination for payment methods; hence, there is no `cursor` parameter. Users
|
|
56
|
+
* typically have few payment methods.
|
|
57
|
+
*
|
|
58
|
+
* @example
|
|
59
|
+
* ```ts
|
|
60
|
+
* const paymentMethods = await client.qbd.paymentMethods.list(
|
|
61
|
+
* { conductorEndUserId: 'end_usr_1234567abcdefg' },
|
|
62
|
+
* );
|
|
63
|
+
* ```
|
|
64
|
+
*/
|
|
65
|
+
list(
|
|
66
|
+
params: PaymentMethodListParams,
|
|
67
|
+
options?: Core.RequestOptions,
|
|
68
|
+
): Core.APIPromise<PaymentMethodListResponse> {
|
|
69
|
+
const { conductorEndUserId, ...query } = params;
|
|
70
|
+
return this._client.get('/quickbooks-desktop/payment-methods', {
|
|
71
|
+
query,
|
|
72
|
+
...options,
|
|
73
|
+
headers: { 'Conductor-End-User-Id': conductorEndUserId, ...options?.headers },
|
|
74
|
+
});
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
export interface PaymentMethod {
|
|
79
|
+
/**
|
|
80
|
+
* The unique identifier assigned by QuickBooks to this payment method. This ID is
|
|
81
|
+
* unique across all payment methods but not across different QuickBooks object
|
|
82
|
+
* types.
|
|
83
|
+
*/
|
|
84
|
+
id: string;
|
|
85
|
+
|
|
86
|
+
/**
|
|
87
|
+
* The date and time when this payment method was created, in ISO 8601 format
|
|
88
|
+
* (YYYY-MM-DDThh:mm:ss±hh:mm). The time zone is the same as the user's time zone
|
|
89
|
+
* in QuickBooks.
|
|
90
|
+
*/
|
|
91
|
+
createdAt: string;
|
|
92
|
+
|
|
93
|
+
/**
|
|
94
|
+
* Indicates whether this payment method is active. Inactive objects are typically
|
|
95
|
+
* hidden from views and reports in QuickBooks. Defaults to `true`.
|
|
96
|
+
*/
|
|
97
|
+
isActive: boolean;
|
|
98
|
+
|
|
99
|
+
/**
|
|
100
|
+
* The case-insensitive unique name of this payment method, unique across all
|
|
101
|
+
* payment methods.
|
|
102
|
+
*
|
|
103
|
+
* **NOTE**: Payment methods do not have a `fullName` field because they are not
|
|
104
|
+
* hierarchical objects, which is why `name` is unique for them but not for objects
|
|
105
|
+
* that have parents.
|
|
106
|
+
*/
|
|
107
|
+
name: string;
|
|
108
|
+
|
|
109
|
+
/**
|
|
110
|
+
* The type of object. This value is always `"qbd_payment_method"`.
|
|
111
|
+
*/
|
|
112
|
+
objectType: 'qbd_payment_method';
|
|
113
|
+
|
|
114
|
+
/**
|
|
115
|
+
* This payment method's type.
|
|
116
|
+
*/
|
|
117
|
+
paymentMethodType:
|
|
118
|
+
| 'american_express'
|
|
119
|
+
| 'cash'
|
|
120
|
+
| 'check'
|
|
121
|
+
| 'debit_card'
|
|
122
|
+
| 'discover'
|
|
123
|
+
| 'e_check'
|
|
124
|
+
| 'gift_card'
|
|
125
|
+
| 'master_card'
|
|
126
|
+
| 'other'
|
|
127
|
+
| 'other_credit_card'
|
|
128
|
+
| 'visa';
|
|
129
|
+
|
|
130
|
+
/**
|
|
131
|
+
* The current QuickBooks-assigned revision number of this payment method object,
|
|
132
|
+
* which changes each time the object is modified. When updating this object, you
|
|
133
|
+
* must provide the most recent `revisionNumber` to ensure you're working with the
|
|
134
|
+
* latest data; otherwise, the update will return an error.
|
|
135
|
+
*/
|
|
136
|
+
revisionNumber: string;
|
|
137
|
+
|
|
138
|
+
/**
|
|
139
|
+
* The date and time when this payment method was last updated, in ISO 8601 format
|
|
140
|
+
* (YYYY-MM-DDThh:mm:ss±hh:mm). The time zone is the same as the user's time zone
|
|
141
|
+
* in QuickBooks.
|
|
142
|
+
*/
|
|
143
|
+
updatedAt: string;
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
export interface PaymentMethodListResponse {
|
|
147
|
+
/**
|
|
148
|
+
* The array of payment methods.
|
|
149
|
+
*/
|
|
150
|
+
data: Array<PaymentMethod>;
|
|
151
|
+
|
|
152
|
+
/**
|
|
153
|
+
* The type of object. This value is always `"list"`.
|
|
154
|
+
*/
|
|
155
|
+
objectType: 'list';
|
|
156
|
+
|
|
157
|
+
/**
|
|
158
|
+
* The endpoint URL where this list can be accessed.
|
|
159
|
+
*/
|
|
160
|
+
url: string;
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
export interface PaymentMethodCreateParams {
|
|
164
|
+
/**
|
|
165
|
+
* Body param: The case-insensitive unique name of this payment method, unique
|
|
166
|
+
* across all payment methods.
|
|
167
|
+
*
|
|
168
|
+
* **NOTE**: Payment methods do not have a `fullName` field because they are not
|
|
169
|
+
* hierarchical objects, which is why `name` is unique for them but not for objects
|
|
170
|
+
* that have parents.
|
|
171
|
+
*
|
|
172
|
+
* Maximum length: 31 characters.
|
|
173
|
+
*/
|
|
174
|
+
name: string;
|
|
175
|
+
|
|
176
|
+
/**
|
|
177
|
+
* Body param: This payment method's type.
|
|
178
|
+
*/
|
|
179
|
+
paymentMethodType:
|
|
180
|
+
| 'american_express'
|
|
181
|
+
| 'cash'
|
|
182
|
+
| 'check'
|
|
183
|
+
| 'debit_card'
|
|
184
|
+
| 'discover'
|
|
185
|
+
| 'e_check'
|
|
186
|
+
| 'gift_card'
|
|
187
|
+
| 'master_card'
|
|
188
|
+
| 'other'
|
|
189
|
+
| 'other_credit_card'
|
|
190
|
+
| 'visa';
|
|
191
|
+
|
|
192
|
+
/**
|
|
193
|
+
* Header param: The ID of the EndUser to receive this request (e.g.,
|
|
194
|
+
* `"Conductor-End-User-Id: {{END_USER_ID}}"`).
|
|
195
|
+
*/
|
|
196
|
+
conductorEndUserId: string;
|
|
197
|
+
|
|
198
|
+
/**
|
|
199
|
+
* Body param: Indicates whether this payment method is active. Inactive objects
|
|
200
|
+
* are typically hidden from views and reports in QuickBooks. Defaults to `true`.
|
|
201
|
+
*/
|
|
202
|
+
isActive?: boolean;
|
|
203
|
+
}
|
|
204
|
+
|
|
205
|
+
export interface PaymentMethodRetrieveParams {
|
|
206
|
+
/**
|
|
207
|
+
* The ID of the EndUser to receive this request (e.g.,
|
|
208
|
+
* `"Conductor-End-User-Id: {{END_USER_ID}}"`).
|
|
209
|
+
*/
|
|
210
|
+
conductorEndUserId: string;
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
export interface PaymentMethodListParams {
|
|
214
|
+
/**
|
|
215
|
+
* Header param: The ID of the EndUser to receive this request (e.g.,
|
|
216
|
+
* `"Conductor-End-User-Id: {{END_USER_ID}}"`).
|
|
217
|
+
*/
|
|
218
|
+
conductorEndUserId: string;
|
|
219
|
+
|
|
220
|
+
/**
|
|
221
|
+
* Query param: Filter for specific payment methods by their QuickBooks-assigned
|
|
222
|
+
* unique identifier(s).
|
|
223
|
+
*
|
|
224
|
+
* **IMPORTANT**: If you include this parameter, QuickBooks will ignore all other
|
|
225
|
+
* query parameters for this request.
|
|
226
|
+
*
|
|
227
|
+
* **NOTE**: If any of the values you specify in this parameter are not found, the
|
|
228
|
+
* request will return an error.
|
|
229
|
+
*/
|
|
230
|
+
ids?: Array<string>;
|
|
231
|
+
|
|
232
|
+
/**
|
|
233
|
+
* Query param: The maximum number of objects to return.
|
|
234
|
+
*
|
|
235
|
+
* **IMPORTANT**: QuickBooks Desktop does not support cursor-based pagination for
|
|
236
|
+
* payment methods. This parameter will limit the response size, but you cannot
|
|
237
|
+
* fetch subsequent results using a cursor. For pagination, use the name-range
|
|
238
|
+
* parameters instead (e.g., `nameFrom=A&nameTo=B`).
|
|
239
|
+
*
|
|
240
|
+
* When this parameter is omitted, the endpoint returns all payment methods without
|
|
241
|
+
* limit, unlike paginated endpoints which default to 150 records. This is
|
|
242
|
+
* acceptable because payment methods typically have low record counts.
|
|
243
|
+
*/
|
|
244
|
+
limit?: number;
|
|
245
|
+
|
|
246
|
+
/**
|
|
247
|
+
* Query param: Filter for payment methods whose `name` contains this substring,
|
|
248
|
+
* case-insensitive. NOTE: If you use this parameter, you cannot also use
|
|
249
|
+
* `nameStartsWith` or `nameEndsWith`.
|
|
250
|
+
*/
|
|
251
|
+
nameContains?: string;
|
|
252
|
+
|
|
253
|
+
/**
|
|
254
|
+
* Query param: Filter for payment methods whose `name` ends with this substring,
|
|
255
|
+
* case-insensitive. NOTE: If you use this parameter, you cannot also use
|
|
256
|
+
* `nameContains` or `nameStartsWith`.
|
|
257
|
+
*/
|
|
258
|
+
nameEndsWith?: string;
|
|
259
|
+
|
|
260
|
+
/**
|
|
261
|
+
* Query param: Filter for payment methods whose `name` is alphabetically greater
|
|
262
|
+
* than or equal to this value.
|
|
263
|
+
*/
|
|
264
|
+
nameFrom?: string;
|
|
265
|
+
|
|
266
|
+
/**
|
|
267
|
+
* Query param: Filter for specific payment methods by their name(s),
|
|
268
|
+
* case-insensitive. Like `id`, `name` is a unique identifier for a payment method.
|
|
269
|
+
*
|
|
270
|
+
* **IMPORTANT**: If you include this parameter, QuickBooks will ignore all other
|
|
271
|
+
* query parameters for this request.
|
|
272
|
+
*
|
|
273
|
+
* **NOTE**: If any of the values you specify in this parameter are not found, the
|
|
274
|
+
* request will return an error.
|
|
275
|
+
*/
|
|
276
|
+
names?: Array<string>;
|
|
277
|
+
|
|
278
|
+
/**
|
|
279
|
+
* Query param: Filter for payment methods whose `name` starts with this substring,
|
|
280
|
+
* case-insensitive. NOTE: If you use this parameter, you cannot also use
|
|
281
|
+
* `nameContains` or `nameEndsWith`.
|
|
282
|
+
*/
|
|
283
|
+
nameStartsWith?: string;
|
|
284
|
+
|
|
285
|
+
/**
|
|
286
|
+
* Query param: Filter for payment methods whose `name` is alphabetically less than
|
|
287
|
+
* or equal to this value.
|
|
288
|
+
*/
|
|
289
|
+
nameTo?: string;
|
|
290
|
+
|
|
291
|
+
/**
|
|
292
|
+
* Query param: Filter for payment methods of this type.
|
|
293
|
+
*/
|
|
294
|
+
paymentMethodType?:
|
|
295
|
+
| 'american_express'
|
|
296
|
+
| 'cash'
|
|
297
|
+
| 'check'
|
|
298
|
+
| 'debit_card'
|
|
299
|
+
| 'discover'
|
|
300
|
+
| 'e_check'
|
|
301
|
+
| 'gift_card'
|
|
302
|
+
| 'master_card'
|
|
303
|
+
| 'other'
|
|
304
|
+
| 'other_credit_card'
|
|
305
|
+
| 'visa';
|
|
306
|
+
|
|
307
|
+
/**
|
|
308
|
+
* Query param: Filter for payment methods that are active, inactive, or both.
|
|
309
|
+
*/
|
|
310
|
+
status?: 'active' | 'all' | 'inactive';
|
|
311
|
+
|
|
312
|
+
/**
|
|
313
|
+
* Query param: Filter for payment methods updated on or after this date and time,
|
|
314
|
+
* in ISO 8601 format (YYYY-MM-DDTHH:mm:ss). If you only provide a date
|
|
315
|
+
* (YYYY-MM-DD), the time is assumed to be 00:00:00 of that day.
|
|
316
|
+
*/
|
|
317
|
+
updatedAfter?: string;
|
|
318
|
+
|
|
319
|
+
/**
|
|
320
|
+
* Query param: Filter for payment methods updated on or before this date and time,
|
|
321
|
+
* in ISO 8601 format (YYYY-MM-DDTHH:mm:ss). If you only provide a date
|
|
322
|
+
* (YYYY-MM-DD), the time is assumed to be 23:59:59 of that day.
|
|
323
|
+
*/
|
|
324
|
+
updatedBefore?: string;
|
|
325
|
+
}
|
|
326
|
+
|
|
327
|
+
export declare namespace PaymentMethods {
|
|
328
|
+
export {
|
|
329
|
+
type PaymentMethod as PaymentMethod,
|
|
330
|
+
type PaymentMethodListResponse as PaymentMethodListResponse,
|
|
331
|
+
type PaymentMethodCreateParams as PaymentMethodCreateParams,
|
|
332
|
+
type PaymentMethodRetrieveParams as PaymentMethodRetrieveParams,
|
|
333
|
+
type PaymentMethodListParams as PaymentMethodListParams,
|
|
334
|
+
};
|
|
335
|
+
}
|
package/src/resources/qbd/qbd.ts
CHANGED
|
@@ -271,6 +271,25 @@ import {
|
|
|
271
271
|
NonInventoryItems,
|
|
272
272
|
NonInventoryItemsCursorPage,
|
|
273
273
|
} from './non-inventory-items';
|
|
274
|
+
import * as OtherNamesAPI from './other-names';
|
|
275
|
+
import {
|
|
276
|
+
OtherName,
|
|
277
|
+
OtherNameCreateParams,
|
|
278
|
+
OtherNameListParams,
|
|
279
|
+
OtherNameListResponse,
|
|
280
|
+
OtherNameRetrieveParams,
|
|
281
|
+
OtherNameUpdateParams,
|
|
282
|
+
OtherNames,
|
|
283
|
+
} from './other-names';
|
|
284
|
+
import * as PaymentMethodsAPI from './payment-methods';
|
|
285
|
+
import {
|
|
286
|
+
PaymentMethod,
|
|
287
|
+
PaymentMethodCreateParams,
|
|
288
|
+
PaymentMethodListParams,
|
|
289
|
+
PaymentMethodListResponse,
|
|
290
|
+
PaymentMethodRetrieveParams,
|
|
291
|
+
PaymentMethods,
|
|
292
|
+
} from './payment-methods';
|
|
274
293
|
import * as PayrollWageItemsAPI from './payroll-wage-items';
|
|
275
294
|
import {
|
|
276
295
|
PayrollWageItem,
|
|
@@ -490,6 +509,8 @@ export class Qbd extends APIResource {
|
|
|
490
509
|
nonInventoryItems: NonInventoryItemsAPI.NonInventoryItems = new NonInventoryItemsAPI.NonInventoryItems(
|
|
491
510
|
this._client,
|
|
492
511
|
);
|
|
512
|
+
otherNames: OtherNamesAPI.OtherNames = new OtherNamesAPI.OtherNames(this._client);
|
|
513
|
+
paymentMethods: PaymentMethodsAPI.PaymentMethods = new PaymentMethodsAPI.PaymentMethods(this._client);
|
|
493
514
|
payrollWageItems: PayrollWageItemsAPI.PayrollWageItems = new PayrollWageItemsAPI.PayrollWageItems(
|
|
494
515
|
this._client,
|
|
495
516
|
);
|
|
@@ -605,6 +626,8 @@ Qbd.JournalEntries = JournalEntries;
|
|
|
605
626
|
Qbd.JournalEntriesCursorPage = JournalEntriesCursorPage;
|
|
606
627
|
Qbd.NonInventoryItems = NonInventoryItems;
|
|
607
628
|
Qbd.NonInventoryItemsCursorPage = NonInventoryItemsCursorPage;
|
|
629
|
+
Qbd.OtherNames = OtherNames;
|
|
630
|
+
Qbd.PaymentMethods = PaymentMethods;
|
|
608
631
|
Qbd.PayrollWageItems = PayrollWageItems;
|
|
609
632
|
Qbd.PayrollWageItemsCursorPage = PayrollWageItemsCursorPage;
|
|
610
633
|
Qbd.PriceLevels = PriceLevels;
|
|
@@ -915,6 +938,25 @@ export declare namespace Qbd {
|
|
|
915
938
|
type NonInventoryItemListParams as NonInventoryItemListParams,
|
|
916
939
|
};
|
|
917
940
|
|
|
941
|
+
export {
|
|
942
|
+
OtherNames as OtherNames,
|
|
943
|
+
type OtherName as OtherName,
|
|
944
|
+
type OtherNameListResponse as OtherNameListResponse,
|
|
945
|
+
type OtherNameCreateParams as OtherNameCreateParams,
|
|
946
|
+
type OtherNameRetrieveParams as OtherNameRetrieveParams,
|
|
947
|
+
type OtherNameUpdateParams as OtherNameUpdateParams,
|
|
948
|
+
type OtherNameListParams as OtherNameListParams,
|
|
949
|
+
};
|
|
950
|
+
|
|
951
|
+
export {
|
|
952
|
+
PaymentMethods as PaymentMethods,
|
|
953
|
+
type PaymentMethod as PaymentMethod,
|
|
954
|
+
type PaymentMethodListResponse as PaymentMethodListResponse,
|
|
955
|
+
type PaymentMethodCreateParams as PaymentMethodCreateParams,
|
|
956
|
+
type PaymentMethodRetrieveParams as PaymentMethodRetrieveParams,
|
|
957
|
+
type PaymentMethodListParams as PaymentMethodListParams,
|
|
958
|
+
};
|
|
959
|
+
|
|
918
960
|
export {
|
|
919
961
|
PayrollWageItems as PayrollWageItems,
|
|
920
962
|
type PayrollWageItem as PayrollWageItem,
|
package/src/version.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const VERSION = '12.
|
|
1
|
+
export const VERSION = '12.8.0'; // x-release-please-version
|
package/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "12.
|
|
1
|
+
export declare const VERSION = "12.8.0";
|
|
2
2
|
//# sourceMappingURL=version.d.ts.map
|
package/version.js
CHANGED
package/version.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export const VERSION = '12.
|
|
1
|
+
export const VERSION = '12.8.0'; // x-release-please-version
|
|
2
2
|
//# sourceMappingURL=version.mjs.map
|