@apideck/unify 0.43.11 → 0.44.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +8 -1
- package/funcs/accountingAttachmentsList.d.ts.map +1 -1
- package/funcs/accountingAttachmentsList.js +4 -2
- package/funcs/accountingAttachmentsList.js.map +1 -1
- package/funcs/accountingCategoriesList.js +1 -0
- package/funcs/accountingCategoriesList.js.map +1 -1
- package/funcs/accountingCompaniesList.d.ts.map +1 -1
- package/funcs/accountingCompaniesList.js +4 -2
- package/funcs/accountingCompaniesList.js.map +1 -1
- package/funcs/accountingDepartmentsList.js +1 -0
- package/funcs/accountingDepartmentsList.js.map +1 -1
- package/funcs/accountingEmployeesList.js +1 -0
- package/funcs/accountingEmployeesList.js.map +1 -1
- package/funcs/accountingExpenseCategoriesList.js +1 -0
- package/funcs/accountingExpenseCategoriesList.js.map +1 -1
- package/funcs/accountingExpenseReportsList.js +1 -0
- package/funcs/accountingExpenseReportsList.js.map +1 -1
- package/funcs/accountingExpensesList.js +1 -0
- package/funcs/accountingExpensesList.js.map +1 -1
- package/funcs/accountingLocationsList.js +1 -0
- package/funcs/accountingLocationsList.js.map +1 -1
- package/funcs/accountingQuotesList.js +1 -0
- package/funcs/accountingQuotesList.js.map +1 -1
- package/funcs/accountingSubsidiariesList.d.ts.map +1 -1
- package/funcs/accountingSubsidiariesList.js +4 -2
- package/funcs/accountingSubsidiariesList.js.map +1 -1
- package/funcs/crmListsGet.d.ts +18 -0
- package/funcs/crmListsGet.d.ts.map +1 -0
- package/funcs/crmListsGet.js +146 -0
- package/funcs/crmListsGet.js.map +1 -0
- package/funcs/crmListsList.d.ts +21 -0
- package/funcs/crmListsList.d.ts.map +1 -0
- package/funcs/crmListsList.js +168 -0
- package/funcs/crmListsList.js.map +1 -0
- package/jsr.json +1 -1
- package/lib/config.d.ts +4 -4
- package/lib/config.js +4 -4
- package/lib/config.js.map +1 -1
- package/lib/http.d.ts +1 -1
- package/lib/http.d.ts.map +1 -1
- package/lib/http.js +1 -1
- package/lib/http.js.map +1 -1
- package/lib/security.d.ts +5 -4
- package/lib/security.d.ts.map +1 -1
- package/lib/security.js +6 -7
- package/lib/security.js.map +1 -1
- package/models/components/billsfilter.d.ts +10 -0
- package/models/components/billsfilter.d.ts.map +1 -1
- package/models/components/billsfilter.js +4 -0
- package/models/components/billsfilter.js.map +1 -1
- package/models/components/connection.d.ts +33 -9
- package/models/components/connection.d.ts.map +1 -1
- package/models/components/connection.js +32 -3
- package/models/components/connection.js.map +1 -1
- package/models/components/connector.d.ts +5 -0
- package/models/components/connector.d.ts.map +1 -1
- package/models/components/connector.js +2 -0
- package/models/components/connector.js.map +1 -1
- package/models/components/connectoroverview.d.ts +188 -0
- package/models/components/connectoroverview.d.ts.map +1 -0
- package/models/components/connectoroverview.js +148 -0
- package/models/components/connectoroverview.js.map +1 -0
- package/models/components/consumerconnection.d.ts +16 -3
- package/models/components/consumerconnection.d.ts.map +1 -1
- package/models/components/consumerconnection.js +14 -2
- package/models/components/consumerconnection.js.map +1 -1
- package/models/components/expensereport.d.ts +9 -0
- package/models/components/expensereport.d.ts.map +1 -1
- package/models/components/expensereport.js +2 -0
- package/models/components/expensereport.js.map +1 -1
- package/models/components/getlistresponse.d.ts +45 -0
- package/models/components/getlistresponse.d.ts.map +1 -0
- package/models/components/getlistresponse.js +66 -0
- package/models/components/getlistresponse.js.map +1 -0
- package/models/components/getlistsresponse.d.ts +50 -0
- package/models/components/getlistsresponse.d.ts.map +1 -0
- package/models/components/getlistsresponse.js +68 -0
- package/models/components/getlistsresponse.js.map +1 -0
- package/models/components/index.d.ts +4 -0
- package/models/components/index.d.ts.map +1 -1
- package/models/components/index.js +4 -0
- package/models/components/index.js.map +1 -1
- package/models/components/list.d.ts +114 -0
- package/models/components/list.d.ts.map +1 -0
- package/models/components/list.js +110 -0
- package/models/components/list.js.map +1 -0
- package/models/components/webhookeventlogsfilter.d.ts +35 -0
- package/models/components/webhookeventlogsfilter.d.ts.map +1 -1
- package/models/components/webhookeventlogsfilter.js +13 -0
- package/models/components/webhookeventlogsfilter.js.map +1 -1
- package/models/components/webhookeventtype.d.ts +3 -0
- package/models/components/webhookeventtype.d.ts.map +1 -1
- package/models/components/webhookeventtype.js +3 -0
- package/models/components/webhookeventtype.js.map +1 -1
- package/models/operations/accountingattachmentsall.d.ts +9 -0
- package/models/operations/accountingattachmentsall.d.ts.map +1 -1
- package/models/operations/accountingattachmentsall.js +2 -0
- package/models/operations/accountingattachmentsall.js.map +1 -1
- package/models/operations/accountingcategoriesall.d.ts +9 -0
- package/models/operations/accountingcategoriesall.d.ts.map +1 -1
- package/models/operations/accountingcategoriesall.js +5 -0
- package/models/operations/accountingcategoriesall.js.map +1 -1
- package/models/operations/accountingcompaniesall.d.ts +9 -0
- package/models/operations/accountingcompaniesall.d.ts.map +1 -1
- package/models/operations/accountingcompaniesall.js +5 -0
- package/models/operations/accountingcompaniesall.js.map +1 -1
- package/models/operations/accountingdepartmentsall.d.ts +9 -0
- package/models/operations/accountingdepartmentsall.d.ts.map +1 -1
- package/models/operations/accountingdepartmentsall.js +5 -0
- package/models/operations/accountingdepartmentsall.js.map +1 -1
- package/models/operations/accountingemployeesall.d.ts +9 -0
- package/models/operations/accountingemployeesall.d.ts.map +1 -1
- package/models/operations/accountingemployeesall.js +5 -0
- package/models/operations/accountingemployeesall.js.map +1 -1
- package/models/operations/accountingexpensecategoriesall.d.ts +9 -0
- package/models/operations/accountingexpensecategoriesall.d.ts.map +1 -1
- package/models/operations/accountingexpensecategoriesall.js +5 -0
- package/models/operations/accountingexpensecategoriesall.js.map +1 -1
- package/models/operations/accountingexpensereportsall.d.ts +9 -0
- package/models/operations/accountingexpensereportsall.d.ts.map +1 -1
- package/models/operations/accountingexpensereportsall.js +5 -0
- package/models/operations/accountingexpensereportsall.js.map +1 -1
- package/models/operations/accountingexpensesall.d.ts +9 -0
- package/models/operations/accountingexpensesall.d.ts.map +1 -1
- package/models/operations/accountingexpensesall.js +5 -0
- package/models/operations/accountingexpensesall.js.map +1 -1
- package/models/operations/accountinglocationsall.d.ts +9 -0
- package/models/operations/accountinglocationsall.d.ts.map +1 -1
- package/models/operations/accountinglocationsall.js +5 -0
- package/models/operations/accountinglocationsall.js.map +1 -1
- package/models/operations/accountingquotesall.d.ts +9 -0
- package/models/operations/accountingquotesall.d.ts.map +1 -1
- package/models/operations/accountingquotesall.js +5 -0
- package/models/operations/accountingquotesall.js.map +1 -1
- package/models/operations/accountingsubsidiariesall.d.ts +9 -0
- package/models/operations/accountingsubsidiariesall.d.ts.map +1 -1
- package/models/operations/accountingsubsidiariesall.js +5 -0
- package/models/operations/accountingsubsidiariesall.js.map +1 -1
- package/models/operations/crmlistsall.d.ts +81 -0
- package/models/operations/crmlistsall.d.ts.map +1 -0
- package/models/operations/crmlistsall.js +80 -0
- package/models/operations/crmlistsall.js.map +1 -0
- package/models/operations/crmlistsone.d.ts +67 -0
- package/models/operations/crmlistsone.d.ts.map +1 -0
- package/models/operations/crmlistsone.js +74 -0
- package/models/operations/crmlistsone.js.map +1 -0
- package/models/operations/index.d.ts +2 -0
- package/models/operations/index.d.ts.map +1 -1
- package/models/operations/index.js +2 -0
- package/models/operations/index.js.map +1 -1
- package/package.json +1 -1
- package/sdk/crm.d.ts +3 -0
- package/sdk/crm.d.ts.map +1 -1
- package/sdk/crm.js +4 -0
- package/sdk/crm.js.map +1 -1
- package/sdk/lists.d.ts +22 -0
- package/sdk/lists.d.ts.map +1 -0
- package/sdk/lists.js +33 -0
- package/sdk/lists.js.map +1 -0
- package/src/__tests__/companies.test.ts +3 -0
- package/src/__tests__/connections.test.ts +48 -32
- package/src/__tests__/connectionsettings.test.ts +18 -12
- package/src/__tests__/consumers.test.ts +48 -32
- package/src/__tests__/employees.test.ts +3 -0
- package/src/__tests__/expensecategories.test.ts +3 -0
- package/src/__tests__/expensereports.test.ts +6 -0
- package/src/__tests__/quotes.test.ts +3 -0
- package/src/funcs/accountingAttachmentsList.ts +17 -7
- package/src/funcs/accountingCategoriesList.ts +1 -0
- package/src/funcs/accountingCompaniesList.ts +17 -7
- package/src/funcs/accountingDepartmentsList.ts +1 -0
- package/src/funcs/accountingEmployeesList.ts +1 -0
- package/src/funcs/accountingExpenseCategoriesList.ts +1 -0
- package/src/funcs/accountingExpenseReportsList.ts +1 -0
- package/src/funcs/accountingExpensesList.ts +1 -0
- package/src/funcs/accountingLocationsList.ts +1 -0
- package/src/funcs/accountingQuotesList.ts +1 -0
- package/src/funcs/accountingSubsidiariesList.ts +17 -7
- package/src/funcs/crmListsGet.ts +228 -0
- package/src/funcs/crmListsList.ts +303 -0
- package/src/lib/config.ts +4 -4
- package/src/lib/http.ts +3 -1
- package/src/lib/security.ts +10 -5
- package/src/models/components/billsfilter.ts +18 -0
- package/src/models/components/connection.ts +85 -6
- package/src/models/components/connector.ts +9 -0
- package/src/models/components/connectoroverview.ts +346 -0
- package/src/models/components/consumerconnection.ts +44 -3
- package/src/models/components/expensereport.ts +11 -0
- package/src/models/components/getlistresponse.ts +78 -0
- package/src/models/components/getlistsresponse.ts +84 -0
- package/src/models/components/index.ts +4 -0
- package/src/models/components/list.ts +181 -0
- package/src/models/components/webhookeventlogsfilter.ts +48 -0
- package/src/models/components/webhookeventtype.ts +3 -0
- package/src/models/operations/accountingattachmentsall.ts +7 -0
- package/src/models/operations/accountingcategoriesall.ts +10 -0
- package/src/models/operations/accountingcompaniesall.ts +10 -0
- package/src/models/operations/accountingdepartmentsall.ts +10 -0
- package/src/models/operations/accountingemployeesall.ts +10 -0
- package/src/models/operations/accountingexpensecategoriesall.ts +10 -0
- package/src/models/operations/accountingexpensereportsall.ts +10 -0
- package/src/models/operations/accountingexpensesall.ts +10 -0
- package/src/models/operations/accountinglocationsall.ts +10 -0
- package/src/models/operations/accountingquotesall.ts +10 -0
- package/src/models/operations/accountingsubsidiariesall.ts +10 -0
- package/src/models/operations/crmlistsall.ts +138 -0
- package/src/models/operations/crmlistsone.ts +122 -0
- package/src/models/operations/index.ts +2 -0
- package/src/sdk/crm.ts +6 -0
- package/src/sdk/lists.ts +46 -0
|
@@ -54,6 +54,10 @@ export type AccountingExpensesAllRequest = {
|
|
|
54
54
|
* Apply filters
|
|
55
55
|
*/
|
|
56
56
|
filter?: components.ExpensesFilter | undefined;
|
|
57
|
+
/**
|
|
58
|
+
* Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads
|
|
59
|
+
*/
|
|
60
|
+
passThrough?: { [k: string]: any } | undefined;
|
|
57
61
|
};
|
|
58
62
|
|
|
59
63
|
export type AccountingExpensesAllResponse = {
|
|
@@ -78,6 +82,7 @@ export type AccountingExpensesAllRequest$Outbound = {
|
|
|
78
82
|
cursor?: string | null | undefined;
|
|
79
83
|
limit: number;
|
|
80
84
|
filter?: components.ExpensesFilter$Outbound | undefined;
|
|
85
|
+
pass_through?: { [k: string]: any } | undefined;
|
|
81
86
|
};
|
|
82
87
|
|
|
83
88
|
/** @internal */
|
|
@@ -94,6 +99,11 @@ export const AccountingExpensesAllRequest$outboundSchema: z.ZodType<
|
|
|
94
99
|
cursor: z.nullable(z.string()).optional(),
|
|
95
100
|
limit: z.number().int().default(20),
|
|
96
101
|
filter: components.ExpensesFilter$outboundSchema.optional(),
|
|
102
|
+
passThrough: z.record(z.any()).optional(),
|
|
103
|
+
}).transform((v) => {
|
|
104
|
+
return remap$(v, {
|
|
105
|
+
passThrough: "pass_through",
|
|
106
|
+
});
|
|
97
107
|
});
|
|
98
108
|
|
|
99
109
|
export function accountingExpensesAllRequestToJSON(
|
|
@@ -58,6 +58,10 @@ export type AccountingLocationsAllRequest = {
|
|
|
58
58
|
* Apply filters
|
|
59
59
|
*/
|
|
60
60
|
filter?: components.AccountingLocationsFilter | undefined;
|
|
61
|
+
/**
|
|
62
|
+
* Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads
|
|
63
|
+
*/
|
|
64
|
+
passThrough?: { [k: string]: any } | undefined;
|
|
61
65
|
};
|
|
62
66
|
|
|
63
67
|
export type AccountingLocationsAllResponse = {
|
|
@@ -85,6 +89,7 @@ export type AccountingLocationsAllRequest$Outbound = {
|
|
|
85
89
|
limit: number;
|
|
86
90
|
fields?: string | null | undefined;
|
|
87
91
|
filter?: components.AccountingLocationsFilter$Outbound | undefined;
|
|
92
|
+
pass_through?: { [k: string]: any } | undefined;
|
|
88
93
|
};
|
|
89
94
|
|
|
90
95
|
/** @internal */
|
|
@@ -102,6 +107,11 @@ export const AccountingLocationsAllRequest$outboundSchema: z.ZodType<
|
|
|
102
107
|
limit: z.number().int().default(20),
|
|
103
108
|
fields: z.nullable(z.string()).optional(),
|
|
104
109
|
filter: components.AccountingLocationsFilter$outboundSchema.optional(),
|
|
110
|
+
passThrough: z.record(z.any()).optional(),
|
|
111
|
+
}).transform((v) => {
|
|
112
|
+
return remap$(v, {
|
|
113
|
+
passThrough: "pass_through",
|
|
114
|
+
});
|
|
105
115
|
});
|
|
106
116
|
|
|
107
117
|
export function accountingLocationsAllRequestToJSON(
|
|
@@ -54,6 +54,10 @@ export type AccountingQuotesAllRequest = {
|
|
|
54
54
|
* Apply filters
|
|
55
55
|
*/
|
|
56
56
|
filter?: components.QuotesFilter | undefined;
|
|
57
|
+
/**
|
|
58
|
+
* Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads
|
|
59
|
+
*/
|
|
60
|
+
passThrough?: { [k: string]: any } | undefined;
|
|
57
61
|
};
|
|
58
62
|
|
|
59
63
|
export type AccountingQuotesAllResponse = {
|
|
@@ -78,6 +82,7 @@ export type AccountingQuotesAllRequest$Outbound = {
|
|
|
78
82
|
cursor?: string | null | undefined;
|
|
79
83
|
limit: number;
|
|
80
84
|
filter?: components.QuotesFilter$Outbound | undefined;
|
|
85
|
+
pass_through?: { [k: string]: any } | undefined;
|
|
81
86
|
};
|
|
82
87
|
|
|
83
88
|
/** @internal */
|
|
@@ -94,6 +99,11 @@ export const AccountingQuotesAllRequest$outboundSchema: z.ZodType<
|
|
|
94
99
|
cursor: z.nullable(z.string()).optional(),
|
|
95
100
|
limit: z.number().int().default(20),
|
|
96
101
|
filter: components.QuotesFilter$outboundSchema.optional(),
|
|
102
|
+
passThrough: z.record(z.any()).optional(),
|
|
103
|
+
}).transform((v) => {
|
|
104
|
+
return remap$(v, {
|
|
105
|
+
passThrough: "pass_through",
|
|
106
|
+
});
|
|
97
107
|
});
|
|
98
108
|
|
|
99
109
|
export function accountingQuotesAllRequestToJSON(
|
|
@@ -54,6 +54,10 @@ export type AccountingSubsidiariesAllRequest = {
|
|
|
54
54
|
* The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. <br /><br />Example: `fields=name,email,addresses.city`<br /><br />In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded.
|
|
55
55
|
*/
|
|
56
56
|
fields?: string | null | undefined;
|
|
57
|
+
/**
|
|
58
|
+
* Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads
|
|
59
|
+
*/
|
|
60
|
+
passThrough?: { [k: string]: any } | undefined;
|
|
57
61
|
};
|
|
58
62
|
|
|
59
63
|
export type AccountingSubsidiariesAllResponse = {
|
|
@@ -78,6 +82,7 @@ export type AccountingSubsidiariesAllRequest$Outbound = {
|
|
|
78
82
|
cursor?: string | null | undefined;
|
|
79
83
|
limit: number;
|
|
80
84
|
fields?: string | null | undefined;
|
|
85
|
+
pass_through?: { [k: string]: any } | undefined;
|
|
81
86
|
};
|
|
82
87
|
|
|
83
88
|
/** @internal */
|
|
@@ -94,6 +99,11 @@ export const AccountingSubsidiariesAllRequest$outboundSchema: z.ZodType<
|
|
|
94
99
|
cursor: z.nullable(z.string()).optional(),
|
|
95
100
|
limit: z.number().int().default(20),
|
|
96
101
|
fields: z.nullable(z.string()).optional(),
|
|
102
|
+
passThrough: z.record(z.any()).optional(),
|
|
103
|
+
}).transform((v) => {
|
|
104
|
+
return remap$(v, {
|
|
105
|
+
passThrough: "pass_through",
|
|
106
|
+
});
|
|
97
107
|
});
|
|
98
108
|
|
|
99
109
|
export function accountingSubsidiariesAllRequestToJSON(
|
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
|
+
import { safeParse } from "../../lib/schemas.js";
|
|
8
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
9
|
+
import * as types from "../../types/primitives.js";
|
|
10
|
+
import * as components from "../components/index.js";
|
|
11
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
12
|
+
|
|
13
|
+
export type CrmListsAllGlobals = {
|
|
14
|
+
/**
|
|
15
|
+
* ID of the consumer which you want to get or push data from
|
|
16
|
+
*/
|
|
17
|
+
consumerId?: string | undefined;
|
|
18
|
+
/**
|
|
19
|
+
* The ID of your Unify application
|
|
20
|
+
*/
|
|
21
|
+
appId?: string | undefined;
|
|
22
|
+
};
|
|
23
|
+
|
|
24
|
+
export type CrmListsAllRequest = {
|
|
25
|
+
/**
|
|
26
|
+
* Include raw response. Mostly used for debugging purposes
|
|
27
|
+
*/
|
|
28
|
+
raw?: boolean | undefined;
|
|
29
|
+
/**
|
|
30
|
+
* ID of the consumer which you want to get or push data from
|
|
31
|
+
*/
|
|
32
|
+
consumerId?: string | undefined;
|
|
33
|
+
/**
|
|
34
|
+
* The ID of your Unify application
|
|
35
|
+
*/
|
|
36
|
+
appId?: string | undefined;
|
|
37
|
+
/**
|
|
38
|
+
* Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API.
|
|
39
|
+
*/
|
|
40
|
+
serviceId?: string | undefined;
|
|
41
|
+
/**
|
|
42
|
+
* Cursor to start from. You can find cursors for next/previous pages in the meta.cursors property of the response.
|
|
43
|
+
*/
|
|
44
|
+
cursor?: string | null | undefined;
|
|
45
|
+
/**
|
|
46
|
+
* Number of results to return. Minimum 1, Maximum 200, Default 20
|
|
47
|
+
*/
|
|
48
|
+
limit?: number | undefined;
|
|
49
|
+
/**
|
|
50
|
+
* Optional unmapped key/values that will be passed through to downstream as query parameters. Ie: ?pass_through[search]=leads becomes ?search=leads
|
|
51
|
+
*/
|
|
52
|
+
passThrough?: { [k: string]: any } | undefined;
|
|
53
|
+
/**
|
|
54
|
+
* The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. <br /><br />Example: `fields=name,email,addresses.city`<br /><br />In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded.
|
|
55
|
+
*/
|
|
56
|
+
fields?: string | null | undefined;
|
|
57
|
+
};
|
|
58
|
+
|
|
59
|
+
export type CrmListsAllResponse = {
|
|
60
|
+
httpMeta: components.HTTPMetadata;
|
|
61
|
+
/**
|
|
62
|
+
* Lists
|
|
63
|
+
*/
|
|
64
|
+
getListsResponse?: components.GetListsResponse | undefined;
|
|
65
|
+
/**
|
|
66
|
+
* Unexpected error
|
|
67
|
+
*/
|
|
68
|
+
unexpectedErrorResponse?: components.UnexpectedErrorResponse | undefined;
|
|
69
|
+
};
|
|
70
|
+
|
|
71
|
+
/** @internal */
|
|
72
|
+
export type CrmListsAllRequest$Outbound = {
|
|
73
|
+
raw: boolean;
|
|
74
|
+
consumerId?: string | undefined;
|
|
75
|
+
appId?: string | undefined;
|
|
76
|
+
serviceId?: string | undefined;
|
|
77
|
+
cursor?: string | null | undefined;
|
|
78
|
+
limit: number;
|
|
79
|
+
pass_through?: { [k: string]: any } | undefined;
|
|
80
|
+
fields?: string | null | undefined;
|
|
81
|
+
};
|
|
82
|
+
|
|
83
|
+
/** @internal */
|
|
84
|
+
export const CrmListsAllRequest$outboundSchema: z.ZodType<
|
|
85
|
+
CrmListsAllRequest$Outbound,
|
|
86
|
+
z.ZodTypeDef,
|
|
87
|
+
CrmListsAllRequest
|
|
88
|
+
> = z.object({
|
|
89
|
+
raw: z.boolean().default(false),
|
|
90
|
+
consumerId: z.string().optional(),
|
|
91
|
+
appId: z.string().optional(),
|
|
92
|
+
serviceId: z.string().optional(),
|
|
93
|
+
cursor: z.nullable(z.string()).optional(),
|
|
94
|
+
limit: z.number().int().default(20),
|
|
95
|
+
passThrough: z.record(z.any()).optional(),
|
|
96
|
+
fields: z.nullable(z.string()).optional(),
|
|
97
|
+
}).transform((v) => {
|
|
98
|
+
return remap$(v, {
|
|
99
|
+
passThrough: "pass_through",
|
|
100
|
+
});
|
|
101
|
+
});
|
|
102
|
+
|
|
103
|
+
export function crmListsAllRequestToJSON(
|
|
104
|
+
crmListsAllRequest: CrmListsAllRequest,
|
|
105
|
+
): string {
|
|
106
|
+
return JSON.stringify(
|
|
107
|
+
CrmListsAllRequest$outboundSchema.parse(crmListsAllRequest),
|
|
108
|
+
);
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
/** @internal */
|
|
112
|
+
export const CrmListsAllResponse$inboundSchema: z.ZodType<
|
|
113
|
+
CrmListsAllResponse,
|
|
114
|
+
z.ZodTypeDef,
|
|
115
|
+
unknown
|
|
116
|
+
> = z.object({
|
|
117
|
+
HttpMeta: components.HTTPMetadata$inboundSchema,
|
|
118
|
+
GetListsResponse: types.optional(components.GetListsResponse$inboundSchema),
|
|
119
|
+
UnexpectedErrorResponse: types.optional(
|
|
120
|
+
components.UnexpectedErrorResponse$inboundSchema,
|
|
121
|
+
),
|
|
122
|
+
}).transform((v) => {
|
|
123
|
+
return remap$(v, {
|
|
124
|
+
"HttpMeta": "httpMeta",
|
|
125
|
+
"GetListsResponse": "getListsResponse",
|
|
126
|
+
"UnexpectedErrorResponse": "unexpectedErrorResponse",
|
|
127
|
+
});
|
|
128
|
+
});
|
|
129
|
+
|
|
130
|
+
export function crmListsAllResponseFromJSON(
|
|
131
|
+
jsonString: string,
|
|
132
|
+
): SafeParseResult<CrmListsAllResponse, SDKValidationError> {
|
|
133
|
+
return safeParse(
|
|
134
|
+
jsonString,
|
|
135
|
+
(x) => CrmListsAllResponse$inboundSchema.parse(JSON.parse(x)),
|
|
136
|
+
`Failed to parse 'CrmListsAllResponse' from JSON`,
|
|
137
|
+
);
|
|
138
|
+
}
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod/v3";
|
|
6
|
+
import { remap as remap$ } from "../../lib/primitives.js";
|
|
7
|
+
import { safeParse } from "../../lib/schemas.js";
|
|
8
|
+
import { Result as SafeParseResult } from "../../types/fp.js";
|
|
9
|
+
import * as types from "../../types/primitives.js";
|
|
10
|
+
import * as components from "../components/index.js";
|
|
11
|
+
import { SDKValidationError } from "../errors/sdkvalidationerror.js";
|
|
12
|
+
|
|
13
|
+
export type CrmListsOneGlobals = {
|
|
14
|
+
/**
|
|
15
|
+
* ID of the consumer which you want to get or push data from
|
|
16
|
+
*/
|
|
17
|
+
consumerId?: string | undefined;
|
|
18
|
+
/**
|
|
19
|
+
* The ID of your Unify application
|
|
20
|
+
*/
|
|
21
|
+
appId?: string | undefined;
|
|
22
|
+
};
|
|
23
|
+
|
|
24
|
+
export type CrmListsOneRequest = {
|
|
25
|
+
/**
|
|
26
|
+
* ID of the record you are acting upon.
|
|
27
|
+
*/
|
|
28
|
+
id: string;
|
|
29
|
+
/**
|
|
30
|
+
* ID of the consumer which you want to get or push data from
|
|
31
|
+
*/
|
|
32
|
+
consumerId?: string | undefined;
|
|
33
|
+
/**
|
|
34
|
+
* The ID of your Unify application
|
|
35
|
+
*/
|
|
36
|
+
appId?: string | undefined;
|
|
37
|
+
/**
|
|
38
|
+
* Provide the service id you want to call (e.g., pipedrive). Only needed when a consumer has activated multiple integrations for a Unified API.
|
|
39
|
+
*/
|
|
40
|
+
serviceId?: string | undefined;
|
|
41
|
+
/**
|
|
42
|
+
* Include raw response. Mostly used for debugging purposes
|
|
43
|
+
*/
|
|
44
|
+
raw?: boolean | undefined;
|
|
45
|
+
/**
|
|
46
|
+
* The 'fields' parameter allows API users to specify the fields they want to include in the API response. If this parameter is not present, the API will return all available fields. If this parameter is present, only the fields specified in the comma-separated string will be included in the response. Nested properties can also be requested by using a dot notation. <br /><br />Example: `fields=name,email,addresses.city`<br /><br />In the example above, the response will only include the fields "name", "email" and "addresses.city". If any other fields are available, they will be excluded.
|
|
47
|
+
*/
|
|
48
|
+
fields?: string | null | undefined;
|
|
49
|
+
};
|
|
50
|
+
|
|
51
|
+
export type CrmListsOneResponse = {
|
|
52
|
+
httpMeta: components.HTTPMetadata;
|
|
53
|
+
/**
|
|
54
|
+
* List
|
|
55
|
+
*/
|
|
56
|
+
getListResponse?: components.GetListResponse | undefined;
|
|
57
|
+
/**
|
|
58
|
+
* Unexpected error
|
|
59
|
+
*/
|
|
60
|
+
unexpectedErrorResponse?: components.UnexpectedErrorResponse | undefined;
|
|
61
|
+
};
|
|
62
|
+
|
|
63
|
+
/** @internal */
|
|
64
|
+
export type CrmListsOneRequest$Outbound = {
|
|
65
|
+
id: string;
|
|
66
|
+
consumerId?: string | undefined;
|
|
67
|
+
appId?: string | undefined;
|
|
68
|
+
serviceId?: string | undefined;
|
|
69
|
+
raw: boolean;
|
|
70
|
+
fields?: string | null | undefined;
|
|
71
|
+
};
|
|
72
|
+
|
|
73
|
+
/** @internal */
|
|
74
|
+
export const CrmListsOneRequest$outboundSchema: z.ZodType<
|
|
75
|
+
CrmListsOneRequest$Outbound,
|
|
76
|
+
z.ZodTypeDef,
|
|
77
|
+
CrmListsOneRequest
|
|
78
|
+
> = z.object({
|
|
79
|
+
id: z.string(),
|
|
80
|
+
consumerId: z.string().optional(),
|
|
81
|
+
appId: z.string().optional(),
|
|
82
|
+
serviceId: z.string().optional(),
|
|
83
|
+
raw: z.boolean().default(false),
|
|
84
|
+
fields: z.nullable(z.string()).optional(),
|
|
85
|
+
});
|
|
86
|
+
|
|
87
|
+
export function crmListsOneRequestToJSON(
|
|
88
|
+
crmListsOneRequest: CrmListsOneRequest,
|
|
89
|
+
): string {
|
|
90
|
+
return JSON.stringify(
|
|
91
|
+
CrmListsOneRequest$outboundSchema.parse(crmListsOneRequest),
|
|
92
|
+
);
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
/** @internal */
|
|
96
|
+
export const CrmListsOneResponse$inboundSchema: z.ZodType<
|
|
97
|
+
CrmListsOneResponse,
|
|
98
|
+
z.ZodTypeDef,
|
|
99
|
+
unknown
|
|
100
|
+
> = z.object({
|
|
101
|
+
HttpMeta: components.HTTPMetadata$inboundSchema,
|
|
102
|
+
GetListResponse: types.optional(components.GetListResponse$inboundSchema),
|
|
103
|
+
UnexpectedErrorResponse: types.optional(
|
|
104
|
+
components.UnexpectedErrorResponse$inboundSchema,
|
|
105
|
+
),
|
|
106
|
+
}).transform((v) => {
|
|
107
|
+
return remap$(v, {
|
|
108
|
+
"HttpMeta": "httpMeta",
|
|
109
|
+
"GetListResponse": "getListResponse",
|
|
110
|
+
"UnexpectedErrorResponse": "unexpectedErrorResponse",
|
|
111
|
+
});
|
|
112
|
+
});
|
|
113
|
+
|
|
114
|
+
export function crmListsOneResponseFromJSON(
|
|
115
|
+
jsonString: string,
|
|
116
|
+
): SafeParseResult<CrmListsOneResponse, SDKValidationError> {
|
|
117
|
+
return safeParse(
|
|
118
|
+
jsonString,
|
|
119
|
+
(x) => CrmListsOneResponse$inboundSchema.parse(JSON.parse(x)),
|
|
120
|
+
`Failed to parse 'CrmListsOneResponse' from JSON`,
|
|
121
|
+
);
|
|
122
|
+
}
|
|
@@ -200,6 +200,8 @@ export * from "./crmleadsall.js";
|
|
|
200
200
|
export * from "./crmleadsdelete.js";
|
|
201
201
|
export * from "./crmleadsone.js";
|
|
202
202
|
export * from "./crmleadsupdate.js";
|
|
203
|
+
export * from "./crmlistsall.js";
|
|
204
|
+
export * from "./crmlistsone.js";
|
|
203
205
|
export * from "./crmnotesadd.js";
|
|
204
206
|
export * from "./crmnotesall.js";
|
|
205
207
|
export * from "./crmnotesdelete.js";
|
package/src/sdk/crm.ts
CHANGED
|
@@ -9,6 +9,7 @@ import { Contacts } from "./contacts.js";
|
|
|
9
9
|
import { CustomObjects } from "./customobjects.js";
|
|
10
10
|
import { CustomObjectSchemas } from "./customobjectschemas.js";
|
|
11
11
|
import { Leads } from "./leads.js";
|
|
12
|
+
import { Lists } from "./lists.js";
|
|
12
13
|
import { Notes } from "./notes.js";
|
|
13
14
|
import { Opportunities } from "./opportunities.js";
|
|
14
15
|
import { Pipelines } from "./pipelines.js";
|
|
@@ -40,6 +41,11 @@ export class Crm extends ClientSDK {
|
|
|
40
41
|
return (this._pipelines ??= new Pipelines(this._options));
|
|
41
42
|
}
|
|
42
43
|
|
|
44
|
+
private _lists?: Lists;
|
|
45
|
+
get lists(): Lists {
|
|
46
|
+
return (this._lists ??= new Lists(this._options));
|
|
47
|
+
}
|
|
48
|
+
|
|
43
49
|
private _notes?: Notes;
|
|
44
50
|
get notes(): Notes {
|
|
45
51
|
return (this._notes ??= new Notes(this._options));
|
package/src/sdk/lists.ts
ADDED
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import { crmListsGet } from "../funcs/crmListsGet.js";
|
|
6
|
+
import { crmListsList } from "../funcs/crmListsList.js";
|
|
7
|
+
import { ClientSDK, RequestOptions } from "../lib/sdks.js";
|
|
8
|
+
import * as operations from "../models/operations/index.js";
|
|
9
|
+
import { unwrapAsync } from "../types/fp.js";
|
|
10
|
+
import { PageIterator, unwrapResultIterator } from "../types/operations.js";
|
|
11
|
+
|
|
12
|
+
export class Lists extends ClientSDK {
|
|
13
|
+
/**
|
|
14
|
+
* List lists
|
|
15
|
+
*
|
|
16
|
+
* @remarks
|
|
17
|
+
* List lists
|
|
18
|
+
*/
|
|
19
|
+
async list(
|
|
20
|
+
request: operations.CrmListsAllRequest,
|
|
21
|
+
options?: RequestOptions,
|
|
22
|
+
): Promise<PageIterator<operations.CrmListsAllResponse, { cursor: string }>> {
|
|
23
|
+
return unwrapResultIterator(crmListsList(
|
|
24
|
+
this,
|
|
25
|
+
request,
|
|
26
|
+
options,
|
|
27
|
+
));
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
* Get list
|
|
32
|
+
*
|
|
33
|
+
* @remarks
|
|
34
|
+
* Get list
|
|
35
|
+
*/
|
|
36
|
+
async get(
|
|
37
|
+
request: operations.CrmListsOneRequest,
|
|
38
|
+
options?: RequestOptions,
|
|
39
|
+
): Promise<operations.CrmListsOneResponse> {
|
|
40
|
+
return unwrapAsync(crmListsGet(
|
|
41
|
+
this,
|
|
42
|
+
request,
|
|
43
|
+
options,
|
|
44
|
+
));
|
|
45
|
+
}
|
|
46
|
+
}
|