conductor-node 7.1.3 → 7.3.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/dist/package.json +2 -2
- package/dist/src/Client.d.ts +21 -2
- package/dist/src/Client.js +23 -0
- package/dist/src/environment.d.ts +1 -1
- package/dist/src/graphql/__generated__/operationTypes.d.ts +50 -30
- package/dist/src/graphql/__generated__/operationTypes.js +15 -1
- package/dist/src/integrations/qbd/QbdIntegration.d.ts +14 -0
- package/dist/src/integrations/qbd/QbdIntegration.js +14 -0
- package/dist/src/integrations/qbd/qbdTypes.d.ts +173 -32
- package/dist/src/utils/testing.d.ts +2 -2
- package/dist/src/utils/testing.js +3 -3
- package/package.json +2 -2
package/dist/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "conductor-node",
|
|
3
|
-
"version": "7.
|
|
3
|
+
"version": "7.3.0",
|
|
4
4
|
"description": "Easily integrate with the entire QuickBooks Desktop API with fully-typed async TypeScript",
|
|
5
5
|
"author": "Danny Nemer <hi@DannyNemer.com>",
|
|
6
6
|
"license": "MIT",
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
"postpack": "rm -rf dist",
|
|
18
18
|
"clean": "rm -rf dist package conductor-node-*.tgz tsconfig.tsbuildinfo",
|
|
19
19
|
"gen:graphql-types": "yarn graphql-codegen --config ./src/graphql/codegenConfig.ts",
|
|
20
|
-
"
|
|
20
|
+
"status": "yarn ts-node ./bin/logConnectionStatuses.ts"
|
|
21
21
|
},
|
|
22
22
|
"engines": {
|
|
23
23
|
"node": ">=16"
|
package/dist/src/Client.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { Environment } from "./environment";
|
|
2
|
-
import type { GraphqlCreateIntegrationConnectionInput, GraphqlCreateIntegrationConnectionMutation, GraphqlGetIntegrationConnectionQuery, GraphqlGetIntegrationConnectionQueryVariables, GraphqlGetIntegrationConnectionsQuery, GraphqlIntegrationRequestInput, GraphqlIntegrationRequestQuery, GraphqlIsIntegrationConnectionActiveQuery, GraphqlIsIntegrationConnectionActiveQueryVariables } from "./graphql/__generated__/operationTypes";
|
|
2
|
+
import type { GraphqlCreateIntegrationConnectionInput, GraphqlCreateIntegrationConnectionMutation, GraphqlGetConnectionStatusQuery, GraphqlGetConnectionStatusQueryVariables, GraphqlGetIntegrationConnectionQuery, GraphqlGetIntegrationConnectionQueryVariables, GraphqlGetIntegrationConnectionsQuery, GraphqlIntegrationRequestInput, GraphqlIntegrationRequestQuery, GraphqlIsIntegrationConnectionActiveQuery, GraphqlIsIntegrationConnectionActiveQueryVariables } from "./graphql/__generated__/operationTypes";
|
|
3
3
|
import QbdIntegration from "./integrations/qbd/QbdIntegration";
|
|
4
4
|
export interface ClientOptions {
|
|
5
5
|
/** Log each request and response. */
|
|
@@ -33,7 +33,26 @@ export default class Client {
|
|
|
33
33
|
integrationKey: "quickbooks-desktop";
|
|
34
34
|
}): Promise<GraphqlCreateIntegrationConnectionMutation["createIntegrationConnection"]>;
|
|
35
35
|
isIntegrationConnectionActive(integrationConnectionId: GraphqlIsIntegrationConnectionActiveQueryVariables["integrationConnectionId"], secondsSinceLastActive?: GraphqlIsIntegrationConnectionActiveQueryVariables["secondsSinceLastActive"]): Promise<GraphqlIsIntegrationConnectionActiveQuery["integrationConnection"]["isActive"]>;
|
|
36
|
+
/**
|
|
37
|
+
* Check whether we can successfully connect to the end-user's QBD instance.
|
|
38
|
+
*
|
|
39
|
+
* Unlike `lastHeartbeatAt`, which only checks if QBWC is running (i.e., is
|
|
40
|
+
* the user's computer on), this check fails if the user's computer is on but
|
|
41
|
+
* QBD is not running, the wrong company file is open, or there is a modal
|
|
42
|
+
* dialog open in QBD.
|
|
43
|
+
*
|
|
44
|
+
* @param integrationConnectionId The ID of the integration connection.
|
|
45
|
+
* @returns result Object with the following properties:
|
|
46
|
+
* @returns result.isConnected Whether we can connect to QBD.
|
|
47
|
+
* @returns result.devErrorMessage If `isConnected=false`, this will be the
|
|
48
|
+
* corresponding error message for the developer; e.g., "The end-user's
|
|
49
|
+
* computer is likely off".
|
|
50
|
+
* @returns result.endUserErrorMessage If `isConnected=false`, this will be
|
|
51
|
+
* the corresponding error message for the end-user; e.g., "Please ensure your
|
|
52
|
+
* computer is on and QuickBooks Desktop is open".
|
|
53
|
+
*/
|
|
54
|
+
getConnectionStatus(integrationConnectionId: GraphqlGetConnectionStatusQueryVariables["integrationConnectionId"]): Promise<GraphqlGetConnectionStatusQuery["integrationConnection"]["connectionStatus"]>;
|
|
36
55
|
integrationRequest(input: GraphqlIntegrationRequestInput): Promise<GraphqlIntegrationRequestQuery["integrationRequest"]>;
|
|
37
|
-
graphqlOperationWrapper
|
|
56
|
+
private graphqlOperationWrapper;
|
|
38
57
|
private checkForUpdates;
|
|
39
58
|
}
|
package/dist/src/Client.js
CHANGED
|
@@ -73,6 +73,29 @@ class Client {
|
|
|
73
73
|
})
|
|
74
74
|
.then((result) => result.integrationConnection.isActive);
|
|
75
75
|
}
|
|
76
|
+
/**
|
|
77
|
+
* Check whether we can successfully connect to the end-user's QBD instance.
|
|
78
|
+
*
|
|
79
|
+
* Unlike `lastHeartbeatAt`, which only checks if QBWC is running (i.e., is
|
|
80
|
+
* the user's computer on), this check fails if the user's computer is on but
|
|
81
|
+
* QBD is not running, the wrong company file is open, or there is a modal
|
|
82
|
+
* dialog open in QBD.
|
|
83
|
+
*
|
|
84
|
+
* @param integrationConnectionId The ID of the integration connection.
|
|
85
|
+
* @returns result Object with the following properties:
|
|
86
|
+
* @returns result.isConnected Whether we can connect to QBD.
|
|
87
|
+
* @returns result.devErrorMessage If `isConnected=false`, this will be the
|
|
88
|
+
* corresponding error message for the developer; e.g., "The end-user's
|
|
89
|
+
* computer is likely off".
|
|
90
|
+
* @returns result.endUserErrorMessage If `isConnected=false`, this will be
|
|
91
|
+
* the corresponding error message for the end-user; e.g., "Please ensure your
|
|
92
|
+
* computer is on and QuickBooks Desktop is open".
|
|
93
|
+
*/
|
|
94
|
+
async getConnectionStatus(integrationConnectionId) {
|
|
95
|
+
return this.graphqlOperations
|
|
96
|
+
.getConnectionStatus({ integrationConnectionId })
|
|
97
|
+
.then((result) => result.integrationConnection.connectionStatus);
|
|
98
|
+
}
|
|
76
99
|
// TODO: Hide this method from the dev-user while still allowing the
|
|
77
100
|
// integration clients to access it.
|
|
78
101
|
async integrationRequest(input) {
|
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import { GraphQLClient } from "graphql-request";
|
|
2
2
|
import * as Dom from "graphql-request/dist/types.dom";
|
|
3
|
-
export
|
|
4
|
-
export
|
|
5
|
-
export
|
|
3
|
+
export type Maybe<T> = T | null;
|
|
4
|
+
export type InputMaybe<T> = Maybe<T>;
|
|
5
|
+
export type Exact<T extends {
|
|
6
6
|
[key: string]: unknown;
|
|
7
7
|
}> = {
|
|
8
8
|
[K in keyof T]: T[K];
|
|
9
9
|
};
|
|
10
|
-
export
|
|
10
|
+
export type MakeOptional<T, K extends keyof T> = Omit<T, K> & {
|
|
11
11
|
[SubKey in K]?: Maybe<T[SubKey]>;
|
|
12
12
|
};
|
|
13
|
-
export
|
|
13
|
+
export type MakeMaybe<T, K extends keyof T> = Omit<T, K> & {
|
|
14
14
|
[SubKey in K]: Maybe<T[SubKey]>;
|
|
15
15
|
};
|
|
16
16
|
/** All built-in and custom scalars, mapped to their actual values */
|
|
17
|
-
export
|
|
17
|
+
export type Scalars = {
|
|
18
18
|
ID: string;
|
|
19
19
|
String: string;
|
|
20
20
|
Boolean: boolean;
|
|
@@ -23,22 +23,28 @@ export declare type Scalars = {
|
|
|
23
23
|
DateTime: Date;
|
|
24
24
|
JSONObject: object;
|
|
25
25
|
};
|
|
26
|
-
export
|
|
26
|
+
export type GraphqlConnectionStatusResult = {
|
|
27
|
+
devErrorMessage: Maybe<Scalars["String"]>;
|
|
28
|
+
endUserErrorMessage: Maybe<Scalars["String"]>;
|
|
29
|
+
isConnected: Scalars["Boolean"];
|
|
30
|
+
};
|
|
31
|
+
export type GraphqlCreateIntegrationConnectionInput = {
|
|
27
32
|
endUserEmail: Scalars["String"];
|
|
28
33
|
endUserName: Scalars["String"];
|
|
29
34
|
integrationKey: Scalars["String"];
|
|
30
35
|
};
|
|
31
|
-
export
|
|
36
|
+
export type GraphqlCreateIntegrationConnectionResult = {
|
|
32
37
|
integrationConnection: GraphqlIntegrationConnection;
|
|
33
38
|
qbwcPassword: Scalars["String"];
|
|
34
39
|
qwcFileDownloadUrl: Scalars["String"];
|
|
35
40
|
};
|
|
36
|
-
export
|
|
41
|
+
export type GraphqlIntegration = {
|
|
37
42
|
id: Scalars["ID"];
|
|
38
43
|
key: Scalars["String"];
|
|
39
44
|
name: Scalars["String"];
|
|
40
45
|
};
|
|
41
|
-
export
|
|
46
|
+
export type GraphqlIntegrationConnection = {
|
|
47
|
+
connectionStatus: GraphqlConnectionStatusResult;
|
|
42
48
|
devUserId: Scalars["ID"];
|
|
43
49
|
endUserEmail: Scalars["String"];
|
|
44
50
|
endUserName: Scalars["String"];
|
|
@@ -49,41 +55,41 @@ export declare type GraphqlIntegrationConnection = {
|
|
|
49
55
|
lastHeartbeatAt: Maybe<Scalars["DateTime"]>;
|
|
50
56
|
qbwcPassword: Scalars["String"];
|
|
51
57
|
};
|
|
52
|
-
export
|
|
58
|
+
export type GraphqlIntegrationConnectionIsActiveArgs = {
|
|
53
59
|
secondsSinceLastActive: Scalars["Int"];
|
|
54
60
|
};
|
|
55
|
-
export
|
|
61
|
+
export type GraphqlIntegrationRequestInput = {
|
|
56
62
|
integrationConnectionId: Scalars["ID"];
|
|
57
63
|
requestObject: Scalars["JSONObject"];
|
|
58
64
|
};
|
|
59
|
-
export
|
|
65
|
+
export type GraphqlMutation = {
|
|
60
66
|
createIntegrationConnection: GraphqlCreateIntegrationConnectionResult;
|
|
61
67
|
};
|
|
62
|
-
export
|
|
68
|
+
export type GraphqlMutationCreateIntegrationConnectionArgs = {
|
|
63
69
|
input: GraphqlCreateIntegrationConnectionInput;
|
|
64
70
|
};
|
|
65
|
-
export
|
|
71
|
+
export type GraphqlQuery = {
|
|
66
72
|
integrationConnection: GraphqlIntegrationConnection;
|
|
67
73
|
integrationConnections: Array<GraphqlIntegrationConnection>;
|
|
68
74
|
integrationRequest: Scalars["JSONObject"];
|
|
69
75
|
};
|
|
70
|
-
export
|
|
76
|
+
export type GraphqlQueryIntegrationConnectionArgs = {
|
|
71
77
|
id: Scalars["ID"];
|
|
72
78
|
};
|
|
73
|
-
export
|
|
79
|
+
export type GraphqlQueryIntegrationRequestArgs = {
|
|
74
80
|
input: GraphqlIntegrationRequestInput;
|
|
75
81
|
};
|
|
76
|
-
export
|
|
82
|
+
export type GraphqlIntegrationConnectionFragment = {
|
|
77
83
|
id: string;
|
|
78
84
|
integrationKey: string;
|
|
79
85
|
endUserEmail: string;
|
|
80
86
|
endUserName: string;
|
|
81
87
|
lastHeartbeatAt: Date | null;
|
|
82
88
|
};
|
|
83
|
-
export
|
|
89
|
+
export type GraphqlGetIntegrationConnectionQueryVariables = Exact<{
|
|
84
90
|
integrationConnectionId: Scalars["ID"];
|
|
85
91
|
}>;
|
|
86
|
-
export
|
|
92
|
+
export type GraphqlGetIntegrationConnectionQuery = {
|
|
87
93
|
integrationConnection: {
|
|
88
94
|
id: string;
|
|
89
95
|
integrationKey: string;
|
|
@@ -92,10 +98,10 @@ export declare type GraphqlGetIntegrationConnectionQuery = {
|
|
|
92
98
|
lastHeartbeatAt: Date | null;
|
|
93
99
|
};
|
|
94
100
|
};
|
|
95
|
-
export
|
|
101
|
+
export type GraphqlGetIntegrationConnectionsQueryVariables = Exact<{
|
|
96
102
|
[key: string]: never;
|
|
97
103
|
}>;
|
|
98
|
-
export
|
|
104
|
+
export type GraphqlGetIntegrationConnectionsQuery = {
|
|
99
105
|
integrationConnections: Array<{
|
|
100
106
|
id: string;
|
|
101
107
|
integrationKey: string;
|
|
@@ -104,10 +110,10 @@ export declare type GraphqlGetIntegrationConnectionsQuery = {
|
|
|
104
110
|
lastHeartbeatAt: Date | null;
|
|
105
111
|
}>;
|
|
106
112
|
};
|
|
107
|
-
export
|
|
113
|
+
export type GraphqlCreateIntegrationConnectionMutationVariables = Exact<{
|
|
108
114
|
input: GraphqlCreateIntegrationConnectionInput;
|
|
109
115
|
}>;
|
|
110
|
-
export
|
|
116
|
+
export type GraphqlCreateIntegrationConnectionMutation = {
|
|
111
117
|
createIntegrationConnection: {
|
|
112
118
|
qbwcPassword: string;
|
|
113
119
|
qwcFileDownloadUrl: string;
|
|
@@ -120,19 +126,31 @@ export declare type GraphqlCreateIntegrationConnectionMutation = {
|
|
|
120
126
|
};
|
|
121
127
|
};
|
|
122
128
|
};
|
|
123
|
-
export
|
|
129
|
+
export type GraphqlIsIntegrationConnectionActiveQueryVariables = Exact<{
|
|
124
130
|
integrationConnectionId: Scalars["ID"];
|
|
125
131
|
secondsSinceLastActive: Scalars["Int"];
|
|
126
132
|
}>;
|
|
127
|
-
export
|
|
133
|
+
export type GraphqlIsIntegrationConnectionActiveQuery = {
|
|
128
134
|
integrationConnection: {
|
|
129
135
|
isActive: boolean;
|
|
130
136
|
};
|
|
131
137
|
};
|
|
132
|
-
export
|
|
138
|
+
export type GraphqlGetConnectionStatusQueryVariables = Exact<{
|
|
139
|
+
integrationConnectionId: Scalars["ID"];
|
|
140
|
+
}>;
|
|
141
|
+
export type GraphqlGetConnectionStatusQuery = {
|
|
142
|
+
integrationConnection: {
|
|
143
|
+
connectionStatus: {
|
|
144
|
+
isConnected: boolean;
|
|
145
|
+
devErrorMessage: string | null;
|
|
146
|
+
endUserErrorMessage: string | null;
|
|
147
|
+
};
|
|
148
|
+
};
|
|
149
|
+
};
|
|
150
|
+
export type GraphqlIntegrationRequestQueryVariables = Exact<{
|
|
133
151
|
input: GraphqlIntegrationRequestInput;
|
|
134
152
|
}>;
|
|
135
|
-
export
|
|
153
|
+
export type GraphqlIntegrationRequestQuery = {
|
|
136
154
|
integrationRequest: object;
|
|
137
155
|
};
|
|
138
156
|
export declare const IntegrationConnectionFragmentDoc = "\n fragment IntegrationConnection on IntegrationConnection {\n id\n integrationKey\n endUserEmail\n endUserName\n lastHeartbeatAt\n}\n ";
|
|
@@ -140,13 +158,15 @@ export declare const GetIntegrationConnectionDocument: string;
|
|
|
140
158
|
export declare const GetIntegrationConnectionsDocument: string;
|
|
141
159
|
export declare const CreateIntegrationConnectionDocument: string;
|
|
142
160
|
export declare const IsIntegrationConnectionActiveDocument = "\n query isIntegrationConnectionActive($integrationConnectionId: ID!, $secondsSinceLastActive: Int!) {\n integrationConnection(id: $integrationConnectionId) {\n isActive(secondsSinceLastActive: $secondsSinceLastActive)\n }\n}\n ";
|
|
161
|
+
export declare const GetConnectionStatusDocument = "\n query getConnectionStatus($integrationConnectionId: ID!) {\n integrationConnection(id: $integrationConnectionId) {\n connectionStatus {\n isConnected\n devErrorMessage\n endUserErrorMessage\n }\n }\n}\n ";
|
|
143
162
|
export declare const IntegrationRequestDocument = "\n query integrationRequest($input: IntegrationRequestInput!) {\n integrationRequest(input: $input)\n}\n ";
|
|
144
|
-
export
|
|
163
|
+
export type SdkFunctionWrapper = <T>(action: (requestHeaders?: Record<string, string>) => Promise<T>, operationName: string, operationType?: string) => Promise<T>;
|
|
145
164
|
export declare function getSdk(client: GraphQLClient, withWrapper?: SdkFunctionWrapper): {
|
|
146
165
|
getIntegrationConnection(variables: GraphqlGetIntegrationConnectionQueryVariables, requestHeaders?: (Record<string, string> | Dom.Headers | string[][]) | undefined): Promise<GraphqlGetIntegrationConnectionQuery>;
|
|
147
166
|
getIntegrationConnections(variables?: GraphqlGetIntegrationConnectionsQueryVariables, requestHeaders?: (Record<string, string> | Dom.Headers | string[][]) | undefined): Promise<GraphqlGetIntegrationConnectionsQuery>;
|
|
148
167
|
createIntegrationConnection(variables: GraphqlCreateIntegrationConnectionMutationVariables, requestHeaders?: (Record<string, string> | Dom.Headers | string[][]) | undefined): Promise<GraphqlCreateIntegrationConnectionMutation>;
|
|
149
168
|
isIntegrationConnectionActive(variables: GraphqlIsIntegrationConnectionActiveQueryVariables, requestHeaders?: (Record<string, string> | Dom.Headers | string[][]) | undefined): Promise<GraphqlIsIntegrationConnectionActiveQuery>;
|
|
169
|
+
getConnectionStatus(variables: GraphqlGetConnectionStatusQueryVariables, requestHeaders?: (Record<string, string> | Dom.Headers | string[][]) | undefined): Promise<GraphqlGetConnectionStatusQuery>;
|
|
150
170
|
integrationRequest(variables: GraphqlIntegrationRequestQueryVariables, requestHeaders?: (Record<string, string> | Dom.Headers | string[][]) | undefined): Promise<GraphqlIntegrationRequestQuery>;
|
|
151
171
|
};
|
|
152
|
-
export
|
|
172
|
+
export type Sdk = ReturnType<typeof getSdk>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.getSdk = exports.IntegrationRequestDocument = exports.IsIntegrationConnectionActiveDocument = exports.CreateIntegrationConnectionDocument = exports.GetIntegrationConnectionsDocument = exports.GetIntegrationConnectionDocument = exports.IntegrationConnectionFragmentDoc = void 0;
|
|
3
|
+
exports.getSdk = exports.IntegrationRequestDocument = exports.GetConnectionStatusDocument = exports.IsIntegrationConnectionActiveDocument = exports.CreateIntegrationConnectionDocument = exports.GetIntegrationConnectionsDocument = exports.GetIntegrationConnectionDocument = exports.IntegrationConnectionFragmentDoc = void 0;
|
|
4
4
|
exports.IntegrationConnectionFragmentDoc = `
|
|
5
5
|
fragment IntegrationConnection on IntegrationConnection {
|
|
6
6
|
id
|
|
@@ -42,6 +42,17 @@ exports.IsIntegrationConnectionActiveDocument = `
|
|
|
42
42
|
}
|
|
43
43
|
}
|
|
44
44
|
`;
|
|
45
|
+
exports.GetConnectionStatusDocument = `
|
|
46
|
+
query getConnectionStatus($integrationConnectionId: ID!) {
|
|
47
|
+
integrationConnection(id: $integrationConnectionId) {
|
|
48
|
+
connectionStatus {
|
|
49
|
+
isConnected
|
|
50
|
+
devErrorMessage
|
|
51
|
+
endUserErrorMessage
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
`;
|
|
45
56
|
exports.IntegrationRequestDocument = `
|
|
46
57
|
query integrationRequest($input: IntegrationRequestInput!) {
|
|
47
58
|
integrationRequest(input: $input)
|
|
@@ -62,6 +73,9 @@ function getSdk(client, withWrapper = defaultWrapper) {
|
|
|
62
73
|
isIntegrationConnectionActive(variables, requestHeaders) {
|
|
63
74
|
return withWrapper((wrappedRequestHeaders) => client.request(exports.IsIntegrationConnectionActiveDocument, variables, { ...requestHeaders, ...wrappedRequestHeaders }), "isIntegrationConnectionActive", "query");
|
|
64
75
|
},
|
|
76
|
+
getConnectionStatus(variables, requestHeaders) {
|
|
77
|
+
return withWrapper((wrappedRequestHeaders) => client.request(exports.GetConnectionStatusDocument, variables, { ...requestHeaders, ...wrappedRequestHeaders }), "getConnectionStatus", "query");
|
|
78
|
+
},
|
|
65
79
|
integrationRequest(variables, requestHeaders) {
|
|
66
80
|
return withWrapper((wrappedRequestHeaders) => client.request(exports.IntegrationRequestDocument, variables, { ...requestHeaders, ...wrappedRequestHeaders }), "integrationRequest", "query");
|
|
67
81
|
},
|
|
@@ -352,6 +352,20 @@ export default class QbdIntegration extends BaseIntegration {
|
|
|
352
352
|
*/
|
|
353
353
|
query: (integrationConnectionId: string, params: QbdTypes.ClassQueryRq) => Promise<NonNullable<QbdTypes.ClassQueryRs["ClassRet"]>>;
|
|
354
354
|
};
|
|
355
|
+
company: {
|
|
356
|
+
/**
|
|
357
|
+
* Returns detailed information about a QuickBooks company file, such as the
|
|
358
|
+
* company’s address and legal name, certain preferences that are set, and
|
|
359
|
+
* any services that the company is subscribed to, such as payroll,
|
|
360
|
+
* QuickBooks Merchant Services, and so forth.
|
|
361
|
+
*
|
|
362
|
+
* Company information cannot be added or modified through the SDK, only
|
|
363
|
+
* through the QuickBooks user interface
|
|
364
|
+
*
|
|
365
|
+
* https://developer.intuit.com/app/developer/qbdesktop/docs/api-reference/qbdesktop/CompanyQuery
|
|
366
|
+
*/
|
|
367
|
+
query: (integrationConnectionId: string, params: QbdTypes.CompanyQueryRq) => Promise<NonNullable<QbdTypes.CompanyQueryRs["CompanyRet"]>>;
|
|
368
|
+
};
|
|
355
369
|
customer: {
|
|
356
370
|
/**
|
|
357
371
|
* The customer list includes information about the QuickBooks user’s
|
|
@@ -356,6 +356,20 @@ class QbdIntegration extends BaseIntegration_1.default {
|
|
|
356
356
|
*/
|
|
357
357
|
query: async (integrationConnectionId, params) => this.sendRequestBase(integrationConnectionId, { ClassQueryRq: params }, "ClassQueryRs", "ClassRet"),
|
|
358
358
|
};
|
|
359
|
+
company = {
|
|
360
|
+
/**
|
|
361
|
+
* Returns detailed information about a QuickBooks company file, such as the
|
|
362
|
+
* company’s address and legal name, certain preferences that are set, and
|
|
363
|
+
* any services that the company is subscribed to, such as payroll,
|
|
364
|
+
* QuickBooks Merchant Services, and so forth.
|
|
365
|
+
*
|
|
366
|
+
* Company information cannot be added or modified through the SDK, only
|
|
367
|
+
* through the QuickBooks user interface
|
|
368
|
+
*
|
|
369
|
+
* https://developer.intuit.com/app/developer/qbdesktop/docs/api-reference/qbdesktop/CompanyQuery
|
|
370
|
+
*/
|
|
371
|
+
query: async (integrationConnectionId, params) => this.sendRequestBase(integrationConnectionId, { CompanyQueryRq: params }, "CompanyQueryRs", "CompanyRet"),
|
|
372
|
+
};
|
|
359
373
|
customer = {
|
|
360
374
|
/**
|
|
361
375
|
* The customer list includes information about the QuickBooks user’s
|
|
@@ -47,6 +47,12 @@ export interface AccountAddRs {
|
|
|
47
47
|
AccountRet?: AccountRet;
|
|
48
48
|
ErrorRecovery?: ErrorRecovery;
|
|
49
49
|
}
|
|
50
|
+
export interface AccountantCopy {
|
|
51
|
+
/** Indicates whether an accountant copy has been made for this company file, with a value of true meaning a copy has been made and a value of false meaning there is no accountant copy. */
|
|
52
|
+
AccountantCopyExists: boolean;
|
|
53
|
+
/** The dividing date indicates the fiscal period within which the accountant is working. This date is key because as long as the accountant copy exists, no transactions can be modified or created within that period. You can add new accounts, but you cannot add new subaccounts to existing accounts, and you cannot edit, merge, or make an existing account inactive. Finally, you cannot delete or merge list items. */
|
|
54
|
+
DividingDate?: string;
|
|
55
|
+
}
|
|
50
56
|
export interface AccountFilter {
|
|
51
57
|
/** One or more `ListID` values. Along with `FullName`, `ListID` is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a `ListID`.
|
|
52
58
|
|
|
@@ -225,10 +231,10 @@ export interface AccountRet {
|
|
|
225
231
|
/** A list of `IDataExtRet` objects, each of which represents a field that has been added to QuickBooks as a data extension. */
|
|
226
232
|
DataExtRet?: DataExtRet | DataExtRet[];
|
|
227
233
|
}
|
|
228
|
-
export
|
|
229
|
-
export
|
|
234
|
+
export type AccountType = "AccountsPayable" | "AccountsReceivable" | "Bank" | "CostOfGoodsSold" | "CreditCard" | "Equity" | "Expense" | "FixedAsset" | "Income" | "LongTermLiability" | "NonPosting" | "OtherAsset" | "OtherCurrentAsset" | "OtherCurrentLiability" | "OtherExpense" | "OtherIncome";
|
|
235
|
+
export type AccrualPeriod = "BeginningOfYear" | "EveryHourOnPaycheck" | "EveryPaycheck";
|
|
230
236
|
/** @default: ActiveOnly */
|
|
231
|
-
export
|
|
237
|
+
export type ActiveStatus = "ActiveOnly" | "All" | "InactiveOnly";
|
|
232
238
|
export interface AdditionalContactRef {
|
|
233
239
|
/** The name of the contact. */
|
|
234
240
|
ContactName: string;
|
|
@@ -369,7 +375,7 @@ export interface BarCode {
|
|
|
369
375
|
/** Allows for barcode to be overridden for an item. */
|
|
370
376
|
AllowOverride?: boolean;
|
|
371
377
|
}
|
|
372
|
-
export
|
|
378
|
+
export type BillableStatus = "Billable" | "HasBeenBilled" | "NotBillable";
|
|
373
379
|
export interface BillAdd {
|
|
374
380
|
/** A vendor is any person or company from whom a small business owner buys goods and services. (Banks and tax agencies usually are included on the vendor list.) A company’s vendor list contains information such as account balance and contact information about each vendor. A `VendorRef` aggregate refers to one of the vendors on the list. In a request, if a `VendorRef` aggregate includes both `FullName` and `ListID`, `FullName` will be ignored. */
|
|
375
381
|
VendorRef: VendorRef;
|
|
@@ -775,6 +781,8 @@ export interface BillRet {
|
|
|
775
781
|
|
|
776
782
|
Note (especially relevant to `CheckAdd` requests): When `RefNumber` is left blank in an SDK transaction add request (that is, or ), the `RefNumber` will be left blank in QuickBooks. This behavior is new as of QBFC3. It used to select the next sequential reference number since the last one used by QuickBooks, as though no `RefNumber` had been provided. This is especially relevant to `CheckAdd` requests because with the current behavior, you will not know the number until the check is printed. */
|
|
777
783
|
RefNumber?: string;
|
|
784
|
+
/** If `IsPending` is set to true, the bill has not been completed or in draft version. */
|
|
785
|
+
IsPending?: boolean;
|
|
778
786
|
/** Refers to the payment terms associated with this entity. (This will be an item on the `DateDrivenTerms` or `StandardTerms` list.) If a `TermsRef` aggregate includes both `FullName` and `ListID`, `FullName` will be ignored. */
|
|
779
787
|
TermsRef?: TermsRef;
|
|
780
788
|
/** Appears in the A/P register and in reports that include this bill. */
|
|
@@ -832,7 +840,7 @@ export interface CashBackInfoRet {
|
|
|
832
840
|
/** A monetary amount. */
|
|
833
841
|
Amount?: string;
|
|
834
842
|
}
|
|
835
|
-
export
|
|
843
|
+
export type CashFlowClassification = "Financing" | "Investing" | "None" | "NotApplicable" | "Operating";
|
|
836
844
|
export interface CheckAdd {
|
|
837
845
|
/** The Account list is the company file’s list of accounts. An `AccountRef` aggregate refers to one of these accounts. (If an `AccountRef` aggregate includes both `FullName` and `ListID`, `FullName` will be ignored.)Special cases to note:In a Check message, `AccountRef` refers to the account from which the funds are being drawn for this check, for example, Checking or Savings.In an `ExpenseLineAdd` message, you must include `AccountRef` if the “Require accounts” check box is selected in the QuickBooks Accounting preferences. (It is selected by default.) In a `CreditCardCredit` message, `AccountRef` refers to the bank account or credit card account to which the credit is applied.In a `CreditCardCharge` message, `AccountRef` refers to the bank or credit card company to whom money is owed. How do you increase and decrease amounts in bank accounts?The following requests increase the balance in a bank account:Deposit Add `ReceivePaymentAdd` Journal Entry Add Sales `ReceiptAdd` The following requests decrease the balance in a bank account:`CheckAdd` Bill `PaymentCheckAdd` `JournalEntryAdd` */
|
|
838
846
|
AccountRef: AccountRef;
|
|
@@ -989,6 +997,8 @@ export interface CheckRet {
|
|
|
989
997
|
Address?: Address;
|
|
990
998
|
/** The address expressed as an address block of `Addr1` through `Addr5`, depending on the number of lines in the original request that created the address. */
|
|
991
999
|
AddressBlock?: AddressBlock;
|
|
1000
|
+
/** If `IsPending` is set to true, the check has not been completed or in draft version. */
|
|
1001
|
+
IsPending?: boolean;
|
|
992
1002
|
/** If `IsToBePrinted` is set to true, this transaction is on a list of forms to be printed later. The user can then choose to print all these forms at once. Notice that setting this field to true does not actually perform the printing. Only the QuickBooks user can do that from within QuickBooks. This cannot be done from the SDK. Setting this field to false does not prevent the QuickBooks user from printing the transaction later. It simply results in the transaction NOT being placed in the list of transactions to be printed. */
|
|
993
1003
|
IsToBePrinted?: boolean;
|
|
994
1004
|
/** For future use with international versions of QuickBooks. */
|
|
@@ -1105,6 +1115,93 @@ export interface ClassRet {
|
|
|
1105
1115
|
/** The number of ancestors. For example, The customer job with `Name` = carpets and `FullName` = Jones:Building2:carpets would have a sublevel of 2. */
|
|
1106
1116
|
Sublevel: number;
|
|
1107
1117
|
}
|
|
1118
|
+
export interface CompanyAddressBlockForCustomer {
|
|
1119
|
+
/** The first line of an address. */
|
|
1120
|
+
Addr1?: string;
|
|
1121
|
+
/** The second line of an address (if a second line is needed). */
|
|
1122
|
+
Addr2?: string;
|
|
1123
|
+
/** The third line of an address (if a third line is needed). */
|
|
1124
|
+
Addr3?: string;
|
|
1125
|
+
/** The fourth line of an address (if a fourth line is needed). */
|
|
1126
|
+
Addr4?: string;
|
|
1127
|
+
/** The fifth line of an address (if a fifth line is needed). */
|
|
1128
|
+
Addr5?: string;
|
|
1129
|
+
}
|
|
1130
|
+
export interface CompanyAddressForCustomer {
|
|
1131
|
+
/** The first line of an address. */
|
|
1132
|
+
Addr1?: string;
|
|
1133
|
+
/** The second line of an address (if a second line is needed). */
|
|
1134
|
+
Addr2?: string;
|
|
1135
|
+
/** The third line of an address (if a third line is needed). */
|
|
1136
|
+
Addr3?: string;
|
|
1137
|
+
/** The fourth line of an address (if a fourth line is needed). */
|
|
1138
|
+
Addr4?: string;
|
|
1139
|
+
/** The fifth line of an address (if a fifth line is needed). */
|
|
1140
|
+
Addr5?: string;
|
|
1141
|
+
/** The city name in an address. */
|
|
1142
|
+
City?: string;
|
|
1143
|
+
/** The state name in an address. */
|
|
1144
|
+
State?: string;
|
|
1145
|
+
/** The postal code in an address. */
|
|
1146
|
+
PostalCode?: string;
|
|
1147
|
+
/** The country name in an address, or, in returned Host information (`HostRet` or `HostInfo`), the country for which this edition of QuickBooks was designed. (Possible values are US, CA, UK, and AU.) */
|
|
1148
|
+
Country?: string;
|
|
1149
|
+
/** In a `BillAddress` or `ShipAddress` aggregate, the `Note` field value is written at the bottom of the address in the form in which it appears, such as the invoice form. */
|
|
1150
|
+
Note?: string;
|
|
1151
|
+
}
|
|
1152
|
+
export interface CompanyQueryRq {
|
|
1153
|
+
/** You use this if you want to limit the data that will be returned in the response. In this list, you specify the name of each top-level element or aggregate that you want to be returned in the response to the request. You cannot specify fields within an aggregate, for example, you cannot specify a `City` within an `Address`: you must specify `Address` and will get the entire address. The names specified in the list are not parsed, so you must be especially careful to supply valid names, properly cased. No error is returned in the status code if you specify an invalid name. Notice that if you want to return custom data or private data extensions, you must specify the `DataExtRet` element and you must supply the `OwnerID` set to either a value of 0 (custom data) or the GUID for the private data. */
|
|
1154
|
+
IncludeRetElement?: string[] | string;
|
|
1155
|
+
/** Zero or more `OwnerID` values. `OwnerID` refers to the owner of a data extension:If `OwnerID` is 0, this is a public data extension, also known as a custom field. Custom fields appear in the QuickBooks UI.If `OwnerID` is a GUID, for example `{6B063959-81B0-4622-85D6-F548C8CCB517}`, this field is a private data extension defined by an integrated application. Private data extensions do not appear in the QuickBooks UI. Note that `OwnerID` values are not case-sensitive, meaning that if you enter an `OwnerID` value with lower-case letters, the value will be saved and returned with upper-case letters. When you share a private data extension with another application, the other application must know both the `OwnerID` and the `DataExtName`, as these together form a data extension’s unique name. */
|
|
1156
|
+
OwnerID?: string[] | string;
|
|
1157
|
+
}
|
|
1158
|
+
export interface CompanyQueryRs {
|
|
1159
|
+
CompanyRet: CompanyRet[];
|
|
1160
|
+
}
|
|
1161
|
+
export interface CompanyRet {
|
|
1162
|
+
/** Indicates whether this company file is a QuickBooks “sample file.” */
|
|
1163
|
+
IsSampleCompany: boolean;
|
|
1164
|
+
/** The name of the QuickBooks user’s business, as specified in QuickBooks. `CompanyName` and `Address` are used on invoices, checks, and other forms. (`LegalCompanyName` and `LegalAddress`, on the other hand, are used on a company’s tax forms and pay stubs.) */
|
|
1165
|
+
CompanyName?: string;
|
|
1166
|
+
/** `LegalCompanyName` and `LegalAddress` are used on a company’s tax forms and pay stubs. (`CompanyName` and `Address`, on the other hand, are used on invoices, checks, and other forms.) */
|
|
1167
|
+
LegalCompanyName?: string;
|
|
1168
|
+
/** If an address request fails, some combination of address fields might be too long. In a Check, `BillPaymentCheck`, or `SalesTaxPaymentCheck` message, `Address` is the address that will print on the check. */
|
|
1169
|
+
Address?: Address;
|
|
1170
|
+
/** The address expressed as an address block of `Addr1` through `Addr5`, depending on the number of lines in the original request that created the address. */
|
|
1171
|
+
AddressBlock?: AddressBlock;
|
|
1172
|
+
/** `LegalAddress` and `LegalCompanyName` are used on a company’s tax forms and pay stubs. (Address and `CompanyName`, on the other hand, are used on invoices, checks, and other forms.) If an address request fails, some combination of address fields might be too long. */
|
|
1173
|
+
LegalAddress?: LegalAddress;
|
|
1174
|
+
/** The address where a QuickBooks company receives mail from its customers. If an address request fails, some combination of address fields might be too long. */
|
|
1175
|
+
CompanyAddressForCustomer?: CompanyAddressForCustomer;
|
|
1176
|
+
/** The company address for customers expressed as an address block of `Addr1` through `Addr5`. */
|
|
1177
|
+
CompanyAddressBlockForCustomer?: CompanyAddressBlockForCustomer;
|
|
1178
|
+
/** The telephone number. */
|
|
1179
|
+
Phone?: string;
|
|
1180
|
+
/** Fax number. */
|
|
1181
|
+
Fax?: string;
|
|
1182
|
+
/** E-mail address. */
|
|
1183
|
+
Email?: string;
|
|
1184
|
+
/** The company’s public Web address. */
|
|
1185
|
+
CompanyWebSite?: string;
|
|
1186
|
+
/** The first month in the 12-month period over which a company tracks its finances. The QuickBooks user sets this value. In QuickBooks, `FirstMonthFiscalYear` determines the default date range for some reports and graphs. */
|
|
1187
|
+
FirstMonthFiscalYear?: FirstMonthFiscalYear;
|
|
1188
|
+
/** In QuickBooks, `FirstMonthIncomeTaxYear` determines the default date range for income tax summary and detail reports. The QuickBooks user sets this value. */
|
|
1189
|
+
FirstMonthIncomeTaxYear?: FirstMonthIncomeTaxYear;
|
|
1190
|
+
/** The QuickBooks user selects a company type from a list when creating a company file. */
|
|
1191
|
+
CompanyType?: string;
|
|
1192
|
+
/** Employer Identification Number. */
|
|
1193
|
+
EIN?: string;
|
|
1194
|
+
/** Social security number. */
|
|
1195
|
+
SSN?: string;
|
|
1196
|
+
/** The tax form that the QuickBooks user expects to file for this company’s taxes. If a `TaxForm` value is assigned (that is, if it is not `OtherOrNone`), the QuickBooks user can associate each account with a tax form line. (An account’s tax form line information will show up in the response from an account query.) */
|
|
1197
|
+
TaxForm?: TaxForm;
|
|
1198
|
+
/** Information returned from a company query about the Intuit services that the company is currently subscribed to, for example, Intuit Payroll, QBMS, and so forth */
|
|
1199
|
+
SubscribedServices?: SubscribedServices;
|
|
1200
|
+
/** Aggregate containing information about accountant copy. An Accountant’s Copy is a version of your company file your accountant can use to make changes while the original company file continues to be used for most normal operations. The key part of the accountant copy “protocol” is the dividing date which defines the fiscal period within which the accountant will be working. Dividing date is key because there are enforced restrictions against certain types of operations on data that fall within the fiscal period the accountant is working on.continue to work. The restrictions are listed below: Transactions: You can work only on transactions dated after the dividing date. Accounts: You can add a new account, but you cannot add a new subaccount to an existing account. Existing accounts: You cannot edit, merge, or make an existing account inactive. New accounts: You can edit an account or make any account inactive that you created while your accountant has the Accountant’s Copy. Lists (other than Chart of Accounts): You can edit, sort, and make list items inactive. You cannot delete or merge list items. Reconciling:You can reconcile your accounts while your accountant has an Accountant’s Copy. All reconciliations that include transactions in the current period (after the dividing date) are saved and will not be undone.To prevent conflicts with your accountant’s changes, reconciliations that include transactions dated on or before the dividing date will be undone when you import your accountant’s changes. If your accountant has reconciled or undone a reconciliation for any period, any reconciliations you did will be undone when you import your accountant’s changes. */
|
|
1201
|
+
AccountantCopy?: AccountantCopy;
|
|
1202
|
+
/** A list of `IDataExtRet` objects, each of which represents a field that has been added to QuickBooks as a data extension. */
|
|
1203
|
+
DataExtRet?: DataExtRet | DataExtRet[];
|
|
1204
|
+
}
|
|
1108
1205
|
export interface Contacts {
|
|
1109
1206
|
/** A formal reference, such as Mr. or Dr., that precedes a name. */
|
|
1110
1207
|
Salutation?: string;
|
|
@@ -1586,8 +1683,8 @@ export interface DataExtRet {
|
|
|
1586
1683
|
/** The data in this field. The maximum length of `DataExtValue` will depend on the `DataExtType` of this data extension. For example, if `DataExtType` is `STR255TYPE`, the maximum length of `DataExtValue` is 255 characters. If `DataExtType` is `STR1024TYPE`, the maximum size of `DataExtValue` is `1KB`. */
|
|
1587
1684
|
DataExtValue: string;
|
|
1588
1685
|
}
|
|
1589
|
-
export
|
|
1590
|
-
export
|
|
1686
|
+
export type DataExtType = "AMTTYPE" | "DATETIMETYPE" | "INTTYPE" | "PERCENTTYPE" | "PRICETYPE" | "QUANTYPE" | "STR255TYPE" | "STR1024TYPE";
|
|
1687
|
+
export type DateMacro = "All" | "LastCalendarQuarter" | "LastCalendarQuarterToDate" | "LastCalendarYear" | "LastCalendarYearToDate" | "LastFiscalQuarter" | "LastFiscalQuarterToDate" | "LastFiscalYear" | "LastFiscalYearToDate" | "LastMonth" | "LastMonthToDate" | "LastWeek" | "LastWeekToDate" | "NextCalendarQuarter" | "NextCalendarYear" | "NextFiscalQuarter" | "NextFiscalYear" | "NextFourWeeks" | "NextMonth" | "NextWeek" | "ThisCalendarQuarter" | "ThisCalendarQuarterToDate" | "ThisCalendarYear" | "ThisCalendarYearToDate" | "ThisFiscalQuarter" | "ThisFiscalQuarterToDate" | "ThisFiscalYear" | "ThisFiscalYearToDate" | "ThisMonth" | "ThisMonthToDate" | "ThisWeek" | "ThisWeekToDate" | "Today" | "Yesterday";
|
|
1591
1688
|
export interface DepositAdd {
|
|
1592
1689
|
/** The date of the transaction. In some cases, if you leave `TxnDate` out of an -Add message, QuickBooks will prefill `TxnDate` with the date of the last-saved transaction of the same type. */
|
|
1593
1690
|
TxnDate?: string;
|
|
@@ -1787,7 +1884,7 @@ export interface DepositToAccountRef {
|
|
|
1787
1884
|
/** `FullName` (along with `ListID`) is a way to identify a list object. The `FullName` is the name prefixed by the names of each ancestor, for example `Jones:Kitchen:Cabinets`. `FullName` values are not case-sensitive. */
|
|
1788
1885
|
FullName?: string;
|
|
1789
1886
|
}
|
|
1790
|
-
export
|
|
1887
|
+
export type Disabled = "No" | "Yes";
|
|
1791
1888
|
export interface DiscountAccountRef {
|
|
1792
1889
|
/** Along with `FullName`, `ListID` is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a `ListID`. A `ListID` is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same `ListID`, and a customer could not have the same `ListID` as an employee (because Customer and Employee are both name lists). But a customer could have the same `ListID` as a non-inventory item. */
|
|
1793
1890
|
ListID?: string;
|
|
@@ -2198,7 +2295,7 @@ export interface EmployeeRet {
|
|
|
2198
2295
|
DataExtRet?: DataExtRet | DataExtRet[];
|
|
2199
2296
|
}
|
|
2200
2297
|
/** @default: Regular */
|
|
2201
|
-
export
|
|
2298
|
+
export type EmployeeType = "Officer" | "Owner" | "Regular" | "Statutory";
|
|
2202
2299
|
export interface EntityFilter {
|
|
2203
2300
|
/** One or more `ListID` values. Along with `FullName`, `ListID` is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a `ListID`.
|
|
2204
2301
|
|
|
@@ -2239,8 +2336,8 @@ export interface ErrorRecovery {
|
|
|
2239
2336
|
/** Allows for the attachment of a user defined GUID value. */
|
|
2240
2337
|
ExternalGUID?: string;
|
|
2241
2338
|
}
|
|
2242
|
-
export
|
|
2243
|
-
export
|
|
2339
|
+
export type Ethnicity = "AmericianIndian" | "Asian" | "Black" | "Hawaiian" | "Hispanic" | "TwoOrMoreRaces" | "White";
|
|
2340
|
+
export type Exempt = "Exempt" | "NonExempt";
|
|
2244
2341
|
export interface ExpenseAccountRef {
|
|
2245
2342
|
/** Along with `FullName`, `ListID` is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a `ListID`. A `ListID` is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same `ListID`, and a customer could not have the same `ListID` as an employee (because Customer and Employee are both name lists). But a customer could have the same `ListID` as a non-inventory item. */
|
|
2246
2343
|
ListID?: string;
|
|
@@ -2399,7 +2496,9 @@ export interface ExpenseLineRet {
|
|
|
2399
2496
|
/** A list of `IDataExtRet` objects, each of which represents a field that has been added to QuickBooks as a data extension. */
|
|
2400
2497
|
DataExtRet?: DataExtRet | DataExtRet[];
|
|
2401
2498
|
}
|
|
2402
|
-
export
|
|
2499
|
+
export type FirstMonthFiscalYear = "April" | "August" | "December" | "February" | "January" | "July" | "June" | "March" | "May" | "November" | "October" | "September";
|
|
2500
|
+
export type FirstMonthIncomeTaxYear = "April" | "August" | "December" | "February" | "January" | "July" | "June" | "March" | "May" | "November" | "October" | "September";
|
|
2501
|
+
export type Gender = "Female" | "Male";
|
|
2403
2502
|
export interface IncomeAccountRef {
|
|
2404
2503
|
/** Along with `FullName`, `ListID` is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a `ListID`. A `ListID` is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same `ListID`, and a customer could not have the same `ListID` as an employee (because Customer and Employee are both name lists). But a customer could have the same `ListID` as a non-inventory item. */
|
|
2405
2504
|
ListID?: string;
|
|
@@ -2493,6 +2592,8 @@ export interface ItemLineAdd {
|
|
|
2493
2592
|
SerialNumber?: string;
|
|
2494
2593
|
/** The lot number of the asset. */
|
|
2495
2594
|
LotNumber?: string;
|
|
2595
|
+
/** The expiration date of the inventory serial/lot number. Expiration `Date` is supported from QB Desktop 2023 (USA & Canada) and SDK 16.0. */
|
|
2596
|
+
ExpirationDateForSerialLotNumber: string;
|
|
2496
2597
|
/** A descriptive text field. */
|
|
2497
2598
|
Desc?: string;
|
|
2498
2599
|
/** `QuantityFor` transactions: If an item line add on a transaction request specifies `Quantity` and `Amount` but not `Rate`, QuickBooks will use `Quantity` and `Amount` to calculate `Rate`. Likewise, if a request specifies `Quantity` and `Rate` but not `Amount`, QuickBooks will calculate the `Amount`. If a transaction add request includes a reference to an `ItemDiscount` item, do not include a `Quantity` element as well, or you will get an error. For Item requests: `Quantity` indicates how many of this item there are. */
|
|
@@ -2547,6 +2648,8 @@ export interface ItemLineMod {
|
|
|
2547
2648
|
SerialNumber?: string;
|
|
2548
2649
|
/** The lot number of the asset. */
|
|
2549
2650
|
LotNumber?: string;
|
|
2651
|
+
/** The expiration date of the inventory serial/lot number. Expiration `Date` is supported from QB Desktop 2023 (USA & Canada) and SDK 16.0. */
|
|
2652
|
+
ExpirationDateForSerialLotNumber?: string;
|
|
2550
2653
|
/** A descriptive text field. */
|
|
2551
2654
|
Desc?: string;
|
|
2552
2655
|
/** `QuantityFor` transactions: If an item line add on a transaction request specifies `Quantity` and `Amount` but not `Rate`, QuickBooks will use `Quantity` and `Amount` to calculate `Rate`. Likewise, if a request specifies `Quantity` and `Rate` but not `Amount`, QuickBooks will calculate the `Amount`. If a transaction add request includes a reference to an `ItemDiscount` item, do not include a `Quantity` element as well, or you will get an error. For Item requests: `Quantity` indicates how many of this item there are. */
|
|
@@ -2601,6 +2704,8 @@ export interface ItemLineRet {
|
|
|
2601
2704
|
SerialNumber?: string;
|
|
2602
2705
|
/** The lot number of the asset. */
|
|
2603
2706
|
LotNumber?: string;
|
|
2707
|
+
/** The expiration date of the inventory serial/lot number. Expiration `Date` is supported from QB Desktop 2023 (USA & Canada) and SDK 16.0. */
|
|
2708
|
+
ExpirationDateForSerialLotNumber: string;
|
|
2604
2709
|
/** A descriptive text field. */
|
|
2605
2710
|
Desc?: string;
|
|
2606
2711
|
/** `QuantityFor` transactions: If an item line add on a transaction request specifies `Quantity` and `Amount` but not `Rate`, QuickBooks will use `Quantity` and `Amount` to calculate `Rate`. Likewise, if a request specifies `Quantity` and `Rate` but not `Amount`, QuickBooks will calculate the `Amount`. If a transaction add request includes a reference to an `ItemDiscount` item, do not include a `Quantity` element as well, or you will get an error. For Item requests: `Quantity` indicates how many of this item there are. */
|
|
@@ -2788,7 +2893,7 @@ export interface ItemServiceRet {
|
|
|
2788
2893
|
DataExtRet?: DataExtRet | DataExtRet[];
|
|
2789
2894
|
}
|
|
2790
2895
|
/** @default: None */
|
|
2791
|
-
export
|
|
2896
|
+
export type JobStatus = "Awarded" | "Closed" | "InProgress" | "None" | "NotAwarded" | "Pending";
|
|
2792
2897
|
export interface JobTypeRef {
|
|
2793
2898
|
/** Along with `FullName`, `ListID` is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a `ListID`. A `ListID` is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same `ListID`, and a customer could not have the same `ListID` as an employee (because Customer and Employee are both name lists). But a customer could have the same `ListID` as a non-inventory item. */
|
|
2794
2899
|
ListID?: string;
|
|
@@ -2978,8 +3083,30 @@ export interface JournalLineMod {
|
|
|
2978
3083
|
/** The billing status of this item line or expense line. */
|
|
2979
3084
|
BillableStatus?: BillableStatus;
|
|
2980
3085
|
}
|
|
2981
|
-
export
|
|
2982
|
-
export
|
|
3086
|
+
export type JournalLineType = "Credit" | "Debit";
|
|
3087
|
+
export type KeyEmployee = "No" | "Yes";
|
|
3088
|
+
export interface LegalAddress {
|
|
3089
|
+
/** The first line of an address. */
|
|
3090
|
+
Addr1?: string;
|
|
3091
|
+
/** The second line of an address (if a second line is needed). */
|
|
3092
|
+
Addr2?: string;
|
|
3093
|
+
/** The third line of an address (if a third line is needed). */
|
|
3094
|
+
Addr3?: string;
|
|
3095
|
+
/** The fourth line of an address (if a fourth line is needed). */
|
|
3096
|
+
Addr4?: string;
|
|
3097
|
+
/** The fifth line of an address (if a fifth line is needed). */
|
|
3098
|
+
Addr5?: string;
|
|
3099
|
+
/** The city name in an address. */
|
|
3100
|
+
City?: string;
|
|
3101
|
+
/** The state name in an address. */
|
|
3102
|
+
State?: string;
|
|
3103
|
+
/** The postal code in an address. */
|
|
3104
|
+
PostalCode?: string;
|
|
3105
|
+
/** The country name in an address, or, in returned Host information (`HostRet` or `HostInfo`), the country for which this edition of QuickBooks was designed. (Possible values are US, CA, UK, and AU.) */
|
|
3106
|
+
Country?: string;
|
|
3107
|
+
/** In a `BillAddress` or `ShipAddress` aggregate, the `Note` field value is written at the bottom of the address in the form in which it appears, such as the invoice form. */
|
|
3108
|
+
Note?: string;
|
|
3109
|
+
}
|
|
2983
3110
|
export interface LinkedTxn {
|
|
2984
3111
|
/** QuickBooks generates a unique `TxnID` for each transaction that is added to QuickBooks. A `TxnID` returned from a request can be used to refer to the transaction in subsequent requests.
|
|
2985
3112
|
|
|
@@ -3010,9 +3137,9 @@ export interface LinkToTxn {
|
|
|
3010
3137
|
If you need to add a new transaction line in a transaction Mod request, you can do so by setting the `TxnLineID` to -1. */
|
|
3011
3138
|
TxnLineID: string;
|
|
3012
3139
|
}
|
|
3013
|
-
export
|
|
3014
|
-
export
|
|
3015
|
-
export
|
|
3140
|
+
export type LinkType = "AMTTYPE" | "QUANTYPE";
|
|
3141
|
+
export type MatchCriterion = "Contains" | "EndsWith" | "StartsWith";
|
|
3142
|
+
export type MilitaryStatus = "Active" | "Reserve";
|
|
3016
3143
|
export interface ModifiedDateRangeFilter {
|
|
3017
3144
|
/** Selects objects modified on or after this date. See the note below regarding QBFC usage.
|
|
3018
3145
|
|
|
@@ -3043,8 +3170,8 @@ export interface NameRangeFilter {
|
|
|
3043
3170
|
/** The final name or item in the search range. If `ToName` is omitted, the range will end with last name on the list. */
|
|
3044
3171
|
ToName?: string;
|
|
3045
3172
|
}
|
|
3046
|
-
export
|
|
3047
|
-
export
|
|
3173
|
+
export type OnFile = "No" | "Yes";
|
|
3174
|
+
export type Operator = "Equal" | "GreaterThan" | "GreaterThanEqual" | "LessThan" | "LessThanEqual";
|
|
3048
3175
|
export interface OverrideClassRef {
|
|
3049
3176
|
/** Along with `FullName`, `ListID` is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a `ListID`. A `ListID` is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same `ListID`, and a customer could not have the same `ListID` as an employee (because Customer and Employee are both name lists). But a customer could have the same `ListID` as a non-inventory item. */
|
|
3050
3177
|
ListID?: string;
|
|
@@ -3064,14 +3191,14 @@ export interface OverrideUOMSetRef {
|
|
|
3064
3191
|
FullName?: string;
|
|
3065
3192
|
}
|
|
3066
3193
|
/** @default: All */
|
|
3067
|
-
export
|
|
3194
|
+
export type PaidStatus = "All" | "NotPaidOnly" | "PaidOnly";
|
|
3068
3195
|
export interface ParentRef {
|
|
3069
3196
|
/** Along with `FullName`, `ListID` is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a `ListID`. A `ListID` is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same `ListID`, and a customer could not have the same `ListID` as an employee (because Customer and Employee are both name lists). But a customer could have the same `ListID` as a non-inventory item. */
|
|
3070
3197
|
ListID?: string;
|
|
3071
3198
|
/** `FullName` (along with `ListID`) is a way to identify a list object. The `FullName` is the name prefixed by the names of each ancestor, for example `Jones:Kitchen:Cabinets`. `FullName` values are not case-sensitive. */
|
|
3072
3199
|
FullName?: string;
|
|
3073
3200
|
}
|
|
3074
|
-
export
|
|
3201
|
+
export type PartOrFullTime = "FullTime" | "PartTime";
|
|
3075
3202
|
export interface PayeeEntityRef {
|
|
3076
3203
|
/** Along with `FullName`, `ListID` is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a `ListID`. A `ListID` is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same `ListID`, and a customer could not have the same `ListID` as an employee (because Customer and Employee are both name lists). But a customer could have the same `ListID` as a non-inventory item. */
|
|
3077
3204
|
ListID?: string;
|
|
@@ -3084,7 +3211,7 @@ export interface PaymentMethodRef {
|
|
|
3084
3211
|
/** `FullName` (along with `ListID`) is a way to identify a list object. The `FullName` is the name prefixed by the names of each ancestor, for example `Jones:Kitchen:Cabinets`. `FullName` values are not case-sensitive. */
|
|
3085
3212
|
FullName?: string;
|
|
3086
3213
|
}
|
|
3087
|
-
export
|
|
3214
|
+
export type PayPeriod = "Biweekly" | "Daily" | "Monthly" | "Quarterly" | "Semimonthly" | "Weekly" | "Yearly";
|
|
3088
3215
|
export interface PayrollItemWageRef {
|
|
3089
3216
|
/** Along with `FullName`, `ListID` is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a `ListID`. A `ListID` is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same `ListID`, and a customer could not have the same `ListID` as an employee (because Customer and Employee are both name lists). But a customer could have the same `ListID` as a non-inventory item. */
|
|
3090
3217
|
ListID?: string;
|
|
@@ -3092,7 +3219,7 @@ export interface PayrollItemWageRef {
|
|
|
3092
3219
|
FullName?: string;
|
|
3093
3220
|
}
|
|
3094
3221
|
/** @default: None */
|
|
3095
|
-
export
|
|
3222
|
+
export type PreferredDeliveryMethod = "Email" | "Fax" | "None";
|
|
3096
3223
|
export interface PreferredPaymentMethodRef {
|
|
3097
3224
|
/** Along with `FullName`, `ListID` is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a `ListID`. A `ListID` is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same `ListID`, and a customer could not have the same `ListID` as an employee (because Customer and Employee are both name lists). But a customer could have the same `ListID` as a non-inventory item. */
|
|
3098
3225
|
ListID?: string;
|
|
@@ -3147,9 +3274,9 @@ export interface RefNumberRangeFilter {
|
|
|
3147
3274
|
/** The final `RefNumber` in the search range. If `ToRefNumber` is omitted, the range will end with last number on the list. */
|
|
3148
3275
|
ToRefNumber?: string;
|
|
3149
3276
|
}
|
|
3150
|
-
export
|
|
3277
|
+
export type Relation = "Brother" | "Daughter" | "Father" | "Friend" | "Mother" | "Other" | "Partner" | "Sister" | "Son" | "Spouse";
|
|
3151
3278
|
/** @default: Quarterly */
|
|
3152
|
-
export
|
|
3279
|
+
export type ReportingPeriod = "Monthly" | "Quarterly";
|
|
3153
3280
|
export interface SalesAndPurchase {
|
|
3154
3281
|
/** Appears in the `Description` column of a sales form when the QuickBooks user sells this item. For a fixed asset, describes the sale of the asset (for accounting purposes). */
|
|
3155
3282
|
SalesDesc?: string;
|
|
@@ -3225,7 +3352,7 @@ export interface SalesTaxCodeRef {
|
|
|
3225
3352
|
FullName?: string;
|
|
3226
3353
|
}
|
|
3227
3354
|
/** @default: Canada */
|
|
3228
|
-
export
|
|
3355
|
+
export type SalesTaxCountry = "Australia" | "Canada" | "UK" | "US";
|
|
3229
3356
|
export interface SalesTaxReturnRef {
|
|
3230
3357
|
/** Along with `FullName`, `ListID` is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a `ListID`. A `ListID` is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same `ListID`, and a customer could not have the same `ListID` as an employee (because Customer and Employee are both name lists). But a customer could have the same `ListID` as a non-inventory item. */
|
|
3231
3358
|
ListID?: string;
|
|
@@ -3240,6 +3367,15 @@ export interface SecondaryContact {
|
|
|
3240
3367
|
/** Relationship of emergency contact information to the employee. */
|
|
3241
3368
|
Relation?: Relation;
|
|
3242
3369
|
}
|
|
3370
|
+
export interface Service {
|
|
3371
|
+
/** The case-insensitive name of a list object, not including the names of its ancestors. `Name` must be unique, unless it is the `Name` of a “hierarchical” list object. List objects in different hierarchies can have duplicate names because their `FullNames` will still be unique. For example, two objects could both have the `Name` kitchen, but they could have unique `FullNames`, such as Job12:kitchen and Baker:kitchen. For built-in currencies, `Name` is the internationally accepted currency name and is not editable. */
|
|
3372
|
+
Name: string;
|
|
3373
|
+
/** Indicates the provider of the subscribed service, for example, Intuit. */
|
|
3374
|
+
Domain: string;
|
|
3375
|
+
/** The status of the Intuit services that the company is or has been subscribed to, for example, Intuit Payroll, QBMS. */
|
|
3376
|
+
ServiceStatus: ServiceStatus;
|
|
3377
|
+
}
|
|
3378
|
+
export type ServiceStatus = "Active" | "Expired" | "Never" | "Pending" | "Suspended" | "Terminated" | "Trial";
|
|
3243
3379
|
export interface SetCredit {
|
|
3244
3380
|
/** The ID of the credit memo that you are applying to this invoice or bill. */
|
|
3245
3381
|
CreditTxnID: string;
|
|
@@ -3324,13 +3460,18 @@ export interface SickHours {
|
|
|
3324
3460
|
/** When used in the `SickHours` or `VacationHours` aggregates, refers to the date on which sick leave or vacation hours in the current year began to accrue. */
|
|
3325
3461
|
AccrualStartDate?: string;
|
|
3326
3462
|
}
|
|
3327
|
-
export
|
|
3463
|
+
export type SpecialAccountType = "AccountsPayable" | "AccountsReceivable" | "CondenseItemAdjustmentExpenses" | "CostOfGoodsSold" | "DirectDepositLiabilities" | "Estimates" | "ExchangeGainLoss" | "InventoryAssets" | "ItemReceiptAccount" | "OpeningBalanceEquity" | "PayrollExpenses" | "PayrollLiabilities" | "PettyCash" | "PurchaseOrders" | "ReconciliationDifferences" | "RetainedEarnings" | "SalesOrders" | "SalesTaxPayable" | "UncategorizedExpenses" | "UncategorizedIncome" | "UndepositedFunds";
|
|
3464
|
+
export interface SubscribedServices {
|
|
3465
|
+
/** The list of the Intuit services that the company is or has been subscribed to, for example, Intuit Payroll, QBMS. */
|
|
3466
|
+
Service?: Service | Service[];
|
|
3467
|
+
}
|
|
3328
3468
|
export interface SupervisorRef {
|
|
3329
3469
|
/** Along with `FullName`, `ListID` is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a `ListID`. A `ListID` is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same `ListID`, and a customer could not have the same `ListID` as an employee (because Customer and Employee are both name lists). But a customer could have the same `ListID` as a non-inventory item. */
|
|
3330
3470
|
ListID?: string;
|
|
3331
3471
|
/** `FullName` (along with `ListID`) is a way to identify a list object. The `FullName` is the name prefixed by the names of each ancestor, for example `Jones:Kitchen:Cabinets`. `FullName` values are not case-sensitive. */
|
|
3332
3472
|
FullName?: string;
|
|
3333
3473
|
}
|
|
3474
|
+
export type TaxForm = "Form990" | "Form990PF" | "Form990T" | "Form1040" | "Form1065" | "Form1120" | "Form1120S" | "OtherOrNone";
|
|
3334
3475
|
export interface TaxLineInfoRet {
|
|
3335
3476
|
/** An internal representation of the tax line associated with this account. */
|
|
3336
3477
|
TaxLineID: number;
|
|
@@ -3502,16 +3643,16 @@ export interface TxnDateRangeFilter {
|
|
|
3502
3643
|
The list given when you click `IQBENDateMacroType` shows the complete list of valid version 3.0 values. */
|
|
3503
3644
|
DateMacro?: DateMacro;
|
|
3504
3645
|
}
|
|
3505
|
-
export
|
|
3646
|
+
export type TxnType = "ARRefundCreditCard" | "Bill" | "BillPaymentCheck" | "BillPaymentCreditCard" | "BuildAssembly" | "Charge" | "Check" | "CreditCardCharge" | "CreditCardCredit" | "CreditMemo" | "Deposit" | "Estimate" | "InventoryAdjustment" | "Invoice" | "ItemReceipt" | "JournalEntry" | "LiabilityAdjustment" | "Paycheck" | "PayrollLiabilityCheck" | "PurchaseOrder" | "ReceivePayment" | "SalesOrder" | "SalesReceipt" | "SalesTaxPaymentCheck" | "Transfer" | "VendorCredit" | "YTDAdjustment";
|
|
3506
3647
|
export interface UnitOfMeasureSetRef {
|
|
3507
3648
|
/** Along with `FullName`, `ListID` is a way to identify a list object. When a list object is added to QuickBooks through the SDK or through the QuickBooks user interface, the server assigns it a `ListID`. A `ListID` is not unique across lists, but it is unique across each particular type of list. For example, two customers could not have the same `ListID`, and a customer could not have the same `ListID` as an employee (because Customer and Employee are both name lists). But a customer could have the same `ListID` as a non-inventory item. */
|
|
3508
3649
|
ListID?: string;
|
|
3509
3650
|
/** `FullName` (along with `ListID`) is a way to identify a list object. The `FullName` is the name prefixed by the names of each ancestor, for example `Jones:Kitchen:Cabinets`. `FullName` values are not case-sensitive. */
|
|
3510
3651
|
FullName?: string;
|
|
3511
3652
|
}
|
|
3512
|
-
export
|
|
3513
|
-
export
|
|
3514
|
-
export
|
|
3653
|
+
export type USCitizen = "No" | "Yes";
|
|
3654
|
+
export type UseTimeDataToCreatePaychecks = "DoNotUseTimeData" | "NotSet" | "UseTimeData";
|
|
3655
|
+
export type USVeteran = "No" | "Yes";
|
|
3515
3656
|
export interface VacationHours {
|
|
3516
3657
|
/** The total number of hours currently available for the employee to use. If this value is empty, it will default to 0. */
|
|
3517
3658
|
HoursAvailable?: string;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const
|
|
2
|
-
export declare const
|
|
1
|
+
export declare const CONDUCTOR_TEST_API_KEY = "063d95bc-a6f7-4b4b-841d-8007648a3112";
|
|
2
|
+
export declare const CONDUCTOR_TEST_QBD_CONNECTION_ID = "49ee2e46-ec5a-40a0-8c37-43913994b2a9";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.
|
|
4
|
-
exports.
|
|
5
|
-
exports.
|
|
3
|
+
exports.CONDUCTOR_TEST_QBD_CONNECTION_ID = exports.CONDUCTOR_TEST_API_KEY = void 0;
|
|
4
|
+
exports.CONDUCTOR_TEST_API_KEY = "063d95bc-a6f7-4b4b-841d-8007648a3112";
|
|
5
|
+
exports.CONDUCTOR_TEST_QBD_CONNECTION_ID = "49ee2e46-ec5a-40a0-8c37-43913994b2a9";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "conductor-node",
|
|
3
|
-
"version": "7.
|
|
3
|
+
"version": "7.3.0",
|
|
4
4
|
"description": "Easily integrate with the entire QuickBooks Desktop API with fully-typed async TypeScript",
|
|
5
5
|
"author": "Danny Nemer <hi@DannyNemer.com>",
|
|
6
6
|
"license": "MIT",
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
"postpack": "rm -rf dist",
|
|
18
18
|
"clean": "rm -rf dist package conductor-node-*.tgz tsconfig.tsbuildinfo",
|
|
19
19
|
"gen:graphql-types": "yarn graphql-codegen --config ./src/graphql/codegenConfig.ts",
|
|
20
|
-
"
|
|
20
|
+
"status": "yarn ts-node ./bin/logConnectionStatuses.ts"
|
|
21
21
|
},
|
|
22
22
|
"engines": {
|
|
23
23
|
"node": ">=16"
|