servicem8 0.3.3 → 0.3.8

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.
Files changed (53) hide show
  1. package/.devcontainer/README.md +30 -0
  2. package/bin/mcp-server.js +5 -5
  3. package/bin/mcp-server.js.map +4 -4
  4. package/dist/commonjs/lib/config.d.ts +2 -2
  5. package/dist/commonjs/lib/config.js +2 -2
  6. package/dist/commonjs/mcp-server/mcp-server.js +1 -1
  7. package/dist/commonjs/mcp-server/server.js +1 -1
  8. package/dist/esm/lib/config.d.ts +2 -2
  9. package/dist/esm/lib/config.js +2 -2
  10. package/dist/esm/mcp-server/mcp-server.js +1 -1
  11. package/dist/esm/mcp-server/server.js +1 -1
  12. package/docs/sdks/allocationwindows/README.md +433 -0
  13. package/docs/sdks/assets/README.md +364 -0
  14. package/docs/sdks/assettypefields/README.md +456 -0
  15. package/docs/sdks/assettypes/README.md +448 -0
  16. package/docs/sdks/attachments/README.md +441 -0
  17. package/docs/sdks/badges/README.md +460 -0
  18. package/docs/sdks/bundles/README.md +437 -0
  19. package/docs/sdks/categories/README.md +462 -0
  20. package/docs/sdks/clients/README.md +466 -0
  21. package/docs/sdks/companycontacts/README.md +462 -0
  22. package/docs/sdks/emailtemplates/README.md +437 -0
  23. package/docs/sdks/feedback/README.md +437 -0
  24. package/docs/sdks/formfields/README.md +437 -0
  25. package/docs/sdks/formresponses/README.md +461 -0
  26. package/docs/sdks/forms/README.md +437 -0
  27. package/docs/sdks/jobactivities/README.md +490 -0
  28. package/docs/sdks/joballocations/README.md +492 -0
  29. package/docs/sdks/jobchecklists/README.md +477 -0
  30. package/docs/sdks/jobcontacts/README.md +462 -0
  31. package/docs/sdks/jobmaterialbundles/README.md +441 -0
  32. package/docs/sdks/jobmaterials/README.md +478 -0
  33. package/docs/sdks/jobpayments/README.md +445 -0
  34. package/docs/sdks/jobqueues/README.md +458 -0
  35. package/docs/sdks/jobs/README.md +546 -0
  36. package/docs/sdks/knowledgearticles/README.md +452 -0
  37. package/docs/sdks/locations/README.md +462 -0
  38. package/docs/sdks/materials/README.md +466 -0
  39. package/docs/sdks/notes/README.md +445 -0
  40. package/docs/sdks/securityroles/README.md +437 -0
  41. package/docs/sdks/servicem8/README.md +22 -0
  42. package/docs/sdks/smstemplates/README.md +437 -0
  43. package/docs/sdks/staffmembers/README.md +494 -0
  44. package/docs/sdks/staffmessages/README.md +457 -0
  45. package/docs/sdks/tasks/README.md +490 -0
  46. package/docs/sdks/taxrates/README.md +437 -0
  47. package/docs/sdks/vendors/README.md +278 -0
  48. package/jsr.json +1 -1
  49. package/package.json +1 -1
  50. package/src/lib/config.ts +2 -2
  51. package/src/mcp-server/mcp-server.ts +1 -1
  52. package/src/mcp-server/server.ts +1 -1
  53. package/api_fixed.json +0 -14096
@@ -0,0 +1,278 @@
1
+ # Vendors
2
+ (*vendors*)
3
+
4
+ ## Overview
5
+
6
+ Vendor account information
7
+
8
+ ### Available Operations
9
+
10
+ * [listVendors](#listvendors) - List all Vendors
11
+ * [getVendors](#getvendors) - Retrieve a Vendor
12
+ * [updateVendors](#updatevendors) - Update a Vendor
13
+
14
+ ## listVendors
15
+
16
+ Vendor account information
17
+
18
+
19
+
20
+ #### Filtering
21
+ This endpoint supports result filtering. For more information on how to filter this request, [go here](/docs/filtering).
22
+
23
+
24
+ #### OAuth Scope
25
+ This endpoint requires the following OAuth scope **vendor**.
26
+
27
+
28
+
29
+ ### Example Usage
30
+
31
+ ```typescript
32
+ import { ServiceM8 } from "servicem8";
33
+
34
+ const serviceM8 = new ServiceM8({
35
+ security: {
36
+ oauth2: process.env["SERVICEM8_OAUTH2"] ?? "",
37
+ },
38
+ });
39
+
40
+ async function run() {
41
+ const result = await serviceM8.vendors.listVendors();
42
+
43
+ // Handle the result
44
+ console.log(result);
45
+ }
46
+
47
+ run();
48
+ ```
49
+
50
+ ### Standalone function
51
+
52
+ The standalone function version of this method:
53
+
54
+ ```typescript
55
+ import { ServiceM8Core } from "servicem8/core.js";
56
+ import { vendorsListVendors } from "servicem8/funcs/vendorsListVendors.js";
57
+
58
+ // Use `ServiceM8Core` for best tree-shaking performance.
59
+ // You can create one instance of it to use across an application.
60
+ const serviceM8 = new ServiceM8Core({
61
+ security: {
62
+ oauth2: process.env["SERVICEM8_OAUTH2"] ?? "",
63
+ },
64
+ });
65
+
66
+ async function run() {
67
+ const res = await vendorsListVendors(serviceM8);
68
+
69
+ if (!res.ok) {
70
+ throw res.error;
71
+ }
72
+
73
+ const { value: result } = res;
74
+
75
+ // Handle the result
76
+ console.log(result);
77
+ }
78
+
79
+ run();
80
+ ```
81
+
82
+ ### Parameters
83
+
84
+ | Parameter | Type | Required | Description |
85
+ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
86
+ | `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
87
+ | `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
88
+ | `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
89
+
90
+ ### Response
91
+
92
+ **Promise\<[operations.ListVendorsResponse](../../models/operations/listvendorsresponse.md)\>**
93
+
94
+ ### Errors
95
+
96
+ | Error Type | Status Code | Content Type |
97
+ | ---------------- | ---------------- | ---------------- |
98
+ | errors.ErrorT | 400 | application/json |
99
+ | errors.APIError | 4XX, 5XX | \*/\* |
100
+
101
+ ## getVendors
102
+
103
+ Vendor account information
104
+
105
+
106
+
107
+ #### OAuth Scope
108
+ This endpoint requires the following OAuth scope **vendor**.
109
+
110
+
111
+
112
+ ### Example Usage
113
+
114
+ ```typescript
115
+ import { ServiceM8 } from "servicem8";
116
+
117
+ const serviceM8 = new ServiceM8({
118
+ security: {
119
+ oauth2: process.env["SERVICEM8_OAUTH2"] ?? "",
120
+ },
121
+ });
122
+
123
+ async function run() {
124
+ const result = await serviceM8.vendors.getVendors({
125
+ uuid: "3856b51a-59e7-4442-afe7-adbe7477e097",
126
+ });
127
+
128
+ // Handle the result
129
+ console.log(result);
130
+ }
131
+
132
+ run();
133
+ ```
134
+
135
+ ### Standalone function
136
+
137
+ The standalone function version of this method:
138
+
139
+ ```typescript
140
+ import { ServiceM8Core } from "servicem8/core.js";
141
+ import { vendorsGetVendors } from "servicem8/funcs/vendorsGetVendors.js";
142
+
143
+ // Use `ServiceM8Core` for best tree-shaking performance.
144
+ // You can create one instance of it to use across an application.
145
+ const serviceM8 = new ServiceM8Core({
146
+ security: {
147
+ oauth2: process.env["SERVICEM8_OAUTH2"] ?? "",
148
+ },
149
+ });
150
+
151
+ async function run() {
152
+ const res = await vendorsGetVendors(serviceM8, {
153
+ uuid: "3856b51a-59e7-4442-afe7-adbe7477e097",
154
+ });
155
+
156
+ if (!res.ok) {
157
+ throw res.error;
158
+ }
159
+
160
+ const { value: result } = res;
161
+
162
+ // Handle the result
163
+ console.log(result);
164
+ }
165
+
166
+ run();
167
+ ```
168
+
169
+ ### Parameters
170
+
171
+ | Parameter | Type | Required | Description |
172
+ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
173
+ | `request` | [operations.GetVendorsRequest](../../models/operations/getvendorsrequest.md) | :heavy_check_mark: | The request object to use for the request. |
174
+ | `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
175
+ | `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
176
+ | `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
177
+
178
+ ### Response
179
+
180
+ **Promise\<[operations.GetVendorsResponse](../../models/operations/getvendorsresponse.md)\>**
181
+
182
+ ### Errors
183
+
184
+ | Error Type | Status Code | Content Type |
185
+ | ---------------- | ---------------- | ---------------- |
186
+ | errors.ErrorT | 400 | application/json |
187
+ | errors.APIError | 4XX, 5XX | \*/\* |
188
+
189
+ ## updateVendors
190
+
191
+ Vendor account information
192
+
193
+
194
+
195
+ ### Example Usage
196
+
197
+ ```typescript
198
+ import { ServiceM8 } from "servicem8";
199
+
200
+ const serviceM8 = new ServiceM8({
201
+ security: {
202
+ oauth2: process.env["SERVICEM8_OAUTH2"] ?? "",
203
+ },
204
+ });
205
+
206
+ async function run() {
207
+ const result = await serviceM8.vendors.updateVendors({
208
+ uuid: "c0aa77d3-51eb-4609-a7d4-c4293b2c471e",
209
+ vendor: {
210
+ uuid: "123e4567-f6a5-4b6c-b79f-22b4db05a84b",
211
+ name: "<value>",
212
+ },
213
+ });
214
+
215
+ // Handle the result
216
+ console.log(result);
217
+ }
218
+
219
+ run();
220
+ ```
221
+
222
+ ### Standalone function
223
+
224
+ The standalone function version of this method:
225
+
226
+ ```typescript
227
+ import { ServiceM8Core } from "servicem8/core.js";
228
+ import { vendorsUpdateVendors } from "servicem8/funcs/vendorsUpdateVendors.js";
229
+
230
+ // Use `ServiceM8Core` for best tree-shaking performance.
231
+ // You can create one instance of it to use across an application.
232
+ const serviceM8 = new ServiceM8Core({
233
+ security: {
234
+ oauth2: process.env["SERVICEM8_OAUTH2"] ?? "",
235
+ },
236
+ });
237
+
238
+ async function run() {
239
+ const res = await vendorsUpdateVendors(serviceM8, {
240
+ uuid: "c0aa77d3-51eb-4609-a7d4-c4293b2c471e",
241
+ vendor: {
242
+ uuid: "123e4567-f6a5-4b6c-b79f-22b4db05a84b",
243
+ name: "<value>",
244
+ },
245
+ });
246
+
247
+ if (!res.ok) {
248
+ throw res.error;
249
+ }
250
+
251
+ const { value: result } = res;
252
+
253
+ // Handle the result
254
+ console.log(result);
255
+ }
256
+
257
+ run();
258
+ ```
259
+
260
+ ### Parameters
261
+
262
+ | Parameter | Type | Required | Description |
263
+ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
264
+ | `request` | [operations.UpdateVendorsRequest](../../models/operations/updatevendorsrequest.md) | :heavy_check_mark: | The request object to use for the request. |
265
+ | `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
266
+ | `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
267
+ | `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
268
+
269
+ ### Response
270
+
271
+ **Promise\<[operations.UpdateVendorsResponse](../../models/operations/updatevendorsresponse.md)\>**
272
+
273
+ ### Errors
274
+
275
+ | Error Type | Status Code | Content Type |
276
+ | ---------------- | ---------------- | ---------------- |
277
+ | errors.ErrorT | 400 | application/json |
278
+ | errors.APIError | 4XX, 5XX | \*/\* |
package/jsr.json CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  {
4
4
  "name": "servicem8",
5
- "version": "0.3.3",
5
+ "version": "0.3.8",
6
6
  "exports": {
7
7
  ".": "./src/index.ts",
8
8
  "./models/errors": "./src/models/errors/index.ts",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "servicem8",
3
- "version": "0.3.3",
3
+ "version": "0.3.8",
4
4
  "author": "Speakeasy",
5
5
  "type": "module",
6
6
  "bin": {
package/src/lib/config.ts CHANGED
@@ -61,7 +61,7 @@ export function serverURLFromOptions(options: SDKOptions): URL | null {
61
61
  export const SDK_METADATA = {
62
62
  language: "typescript",
63
63
  openapiDocVersion: "1.0.0",
64
- sdkVersion: "0.3.3",
64
+ sdkVersion: "0.3.8",
65
65
  genVersion: "2.593.4",
66
- userAgent: "speakeasy-sdk/typescript 0.3.3 2.593.4 1.0.0 servicem8",
66
+ userAgent: "speakeasy-sdk/typescript 0.3.8 2.593.4 1.0.0 servicem8",
67
67
  } as const;
@@ -19,7 +19,7 @@ const routes = buildRouteMap({
19
19
  export const app = buildApplication(routes, {
20
20
  name: "mcp",
21
21
  versionInfo: {
22
- currentVersion: "0.3.3",
22
+ currentVersion: "0.3.8",
23
23
  },
24
24
  });
25
25
 
@@ -196,7 +196,7 @@ export function createMCPServer(deps: {
196
196
  }) {
197
197
  const server = new McpServer({
198
198
  name: "ServiceM8",
199
- version: "0.3.3",
199
+ version: "0.3.8",
200
200
  });
201
201
 
202
202
  const client = new ServiceM8Core({