@shippo/shippo-mcp 0.8.8 → 0.8.24

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 (62) hide show
  1. package/bin/mcp-server.js +58 -42
  2. package/bin/mcp-server.js.map +16 -16
  3. package/esm/lib/config.d.ts +3 -3
  4. package/esm/lib/config.js +3 -3
  5. package/esm/lib/config.js.map +1 -1
  6. package/esm/mcp-server/mcp-server.js +1 -1
  7. package/esm/mcp-server/mcp-server.js.map +1 -1
  8. package/esm/mcp-server/server.js +1 -1
  9. package/esm/mcp-server/server.js.map +1 -1
  10. package/esm/models/address.d.ts +1 -1
  11. package/esm/models/address.d.ts.map +1 -1
  12. package/esm/models/address.js +1 -1
  13. package/esm/models/address.js.map +1 -1
  14. package/esm/models/customsitem.d.ts +5 -5
  15. package/esm/models/customsitem.d.ts.map +1 -1
  16. package/esm/models/customsitem.js +5 -5
  17. package/esm/models/customsitem.js.map +1 -1
  18. package/esm/models/customsitemcreaterequest.d.ts +5 -5
  19. package/esm/models/customsitemcreaterequest.d.ts.map +1 -1
  20. package/esm/models/customsitemcreaterequest.js +5 -5
  21. package/esm/models/customsitemcreaterequest.js.map +1 -1
  22. package/esm/models/defaultparceltemplate.d.ts +19 -2
  23. package/esm/models/defaultparceltemplate.d.ts.map +1 -1
  24. package/esm/models/defaultparceltemplate.js +18 -2
  25. package/esm/models/defaultparceltemplate.js.map +1 -1
  26. package/esm/models/parcel.d.ts +1 -1
  27. package/esm/models/parcel.d.ts.map +1 -1
  28. package/esm/models/parcel.js +1 -1
  29. package/esm/models/parcel.js.map +1 -1
  30. package/esm/models/responsemessage.d.ts +3 -3
  31. package/esm/models/responsemessage.d.ts.map +1 -1
  32. package/esm/models/responsemessage.js +3 -3
  33. package/esm/models/responsemessage.js.map +1 -1
  34. package/esm/models/servicegroup.d.ts +3 -3
  35. package/esm/models/servicegroup.d.ts.map +1 -1
  36. package/esm/models/servicegroup.js +4 -3
  37. package/esm/models/servicegroup.js.map +1 -1
  38. package/esm/models/servicegroupcreaterequest.d.ts +2 -2
  39. package/esm/models/servicegroupcreaterequest.d.ts.map +1 -1
  40. package/esm/models/servicegroupcreaterequest.js +2 -2
  41. package/esm/models/servicegroupcreaterequest.js.map +1 -1
  42. package/esm/models/servicegroupupdaterequest.d.ts +2 -2
  43. package/esm/models/servicegroupupdaterequest.d.ts.map +1 -1
  44. package/esm/models/servicegroupupdaterequest.js +2 -2
  45. package/esm/models/servicegroupupdaterequest.js.map +1 -1
  46. package/esm/models/userparceltemplate.js +2 -2
  47. package/esm/models/userparceltemplate.js.map +1 -1
  48. package/manifest.json +1 -1
  49. package/package.json +1 -1
  50. package/src/lib/config.ts +3 -3
  51. package/src/mcp-server/mcp-server.ts +1 -1
  52. package/src/mcp-server/server.ts +1 -1
  53. package/src/models/address.ts +2 -2
  54. package/src/models/customsitem.ts +10 -10
  55. package/src/models/customsitemcreaterequest.ts +10 -10
  56. package/src/models/defaultparceltemplate.ts +49 -5
  57. package/src/models/parcel.ts +2 -2
  58. package/src/models/responsemessage.ts +6 -6
  59. package/src/models/servicegroup.ts +7 -6
  60. package/src/models/servicegroupcreaterequest.ts +4 -4
  61. package/src/models/servicegroupupdaterequest.ts +4 -4
  62. package/src/models/userparceltemplate.ts +2 -2
package/src/lib/config.ts CHANGED
@@ -67,8 +67,8 @@ export function serverURLFromOptions(options: SDKOptions): URL | null {
67
67
  export const SDK_METADATA = {
68
68
  language: "typescript",
69
69
  openapiDocVersion: "2018-02-08",
70
- sdkVersion: "0.8.8",
71
- genVersion: "2.769.1",
70
+ sdkVersion: "0.8.24",
71
+ genVersion: "2.770.0",
72
72
  userAgent:
73
- "speakeasy-sdk/mcp-typescript 0.8.8 2.769.1 2018-02-08 @shippo/shippo-mcp",
73
+ "speakeasy-sdk/mcp-typescript 0.8.24 2.770.0 2018-02-08 @shippo/shippo-mcp",
74
74
  } 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.8.8",
22
+ currentVersion: "0.8.24",
23
23
  },
24
24
  });
25
25
 
@@ -96,7 +96,7 @@ export function createMCPServer(deps: {
96
96
  }) {
97
97
  const server = new McpServer({
98
98
  name: "ShippoSDK",
99
- version: "0.8.8",
99
+ version: "0.8.24",
100
100
  });
101
101
 
102
102
  const getClient = deps.getSDK || (() =>
@@ -32,7 +32,7 @@ export type Address = {
32
32
  object_owner?: string | undefined;
33
33
  object_updated?: string | undefined;
34
34
  validation_results?: AddressValidationResults | undefined;
35
- test?: boolean | undefined;
35
+ test?: boolean | null | undefined;
36
36
  };
37
37
 
38
38
  export const Address$zodSchema: z.ZodType<Address, z.ZodTypeDef, unknown> = z
@@ -55,7 +55,7 @@ export const Address$zodSchema: z.ZodType<Address, z.ZodTypeDef, unknown> = z
55
55
  street2: z.string().optional(),
56
56
  street3: z.string().optional(),
57
57
  street_no: z.string().optional(),
58
- test: z.boolean().optional(),
58
+ test: z.boolean().nullable().optional(),
59
59
  validation_results: AddressValidationResults$zodSchema.optional(),
60
60
  zip: z.string().optional(),
61
61
  }).describe("Address represents the address as retrieved from the database");
@@ -11,15 +11,15 @@ import { WeightUnitEnum, WeightUnitEnum$zodSchema } from "./weightunitenum.js";
11
11
 
12
12
  export type CustomsItem = {
13
13
  description: string;
14
- eccn_ear99?: string | undefined;
14
+ eccn_ear99?: string | null | undefined;
15
15
  mass_unit: WeightUnitEnum;
16
- metadata?: string | undefined;
16
+ metadata?: string | null | undefined;
17
17
  net_weight: string;
18
18
  origin_country: string;
19
19
  quantity: number;
20
- sku_code?: string | undefined;
21
- hs_code?: string | undefined;
22
- tariff_number?: string | undefined;
20
+ sku_code?: string | null | undefined;
21
+ hs_code?: string | null | undefined;
22
+ tariff_number?: string | null | undefined;
23
23
  value_amount: string;
24
24
  value_currency: string;
25
25
  object_created?: string | undefined;
@@ -36,10 +36,10 @@ export const CustomsItem$zodSchema: z.ZodType<
36
36
  unknown
37
37
  > = z.object({
38
38
  description: z.string(),
39
- eccn_ear99: z.string().optional(),
40
- hs_code: z.string().optional(),
39
+ eccn_ear99: z.string().nullable().optional(),
40
+ hs_code: z.string().nullable().optional(),
41
41
  mass_unit: WeightUnitEnum$zodSchema,
42
- metadata: z.string().optional(),
42
+ metadata: z.string().nullable().optional(),
43
43
  net_weight: z.string(),
44
44
  object_created: z.string().datetime({ offset: true }).optional(),
45
45
  object_id: z.string().optional(),
@@ -48,8 +48,8 @@ export const CustomsItem$zodSchema: z.ZodType<
48
48
  object_updated: z.string().datetime({ offset: true }).optional(),
49
49
  origin_country: z.string(),
50
50
  quantity: z.number().int(),
51
- sku_code: z.string().optional(),
52
- tariff_number: z.string().optional(),
51
+ sku_code: z.string().nullable().optional(),
52
+ tariff_number: z.string().nullable().optional(),
53
53
  test: z.boolean().optional(),
54
54
  value_amount: z.string(),
55
55
  value_currency: z.string(),
@@ -7,15 +7,15 @@ import { WeightUnitEnum, WeightUnitEnum$zodSchema } from "./weightunitenum.js";
7
7
 
8
8
  export type CustomsItemCreateRequest = {
9
9
  description: string;
10
- eccn_ear99?: string | undefined;
10
+ eccn_ear99?: string | null | undefined;
11
11
  mass_unit: WeightUnitEnum;
12
- metadata?: string | undefined;
12
+ metadata?: string | null | undefined;
13
13
  net_weight: string;
14
14
  origin_country: string;
15
15
  quantity: number;
16
- sku_code?: string | undefined;
17
- hs_code?: string | undefined;
18
- tariff_number?: string | undefined;
16
+ sku_code?: string | null | undefined;
17
+ hs_code?: string | null | undefined;
18
+ tariff_number?: string | null | undefined;
19
19
  value_amount: string;
20
20
  value_currency: string;
21
21
  };
@@ -26,15 +26,15 @@ export const CustomsItemCreateRequest$zodSchema: z.ZodType<
26
26
  unknown
27
27
  > = z.object({
28
28
  description: z.string(),
29
- eccn_ear99: z.string().optional(),
30
- hs_code: z.string().optional(),
29
+ eccn_ear99: z.string().nullable().optional(),
30
+ hs_code: z.string().nullable().optional(),
31
31
  mass_unit: WeightUnitEnum$zodSchema,
32
- metadata: z.string().optional(),
32
+ metadata: z.string().nullable().optional(),
33
33
  net_weight: z.string(),
34
34
  origin_country: z.string(),
35
35
  quantity: z.number().int(),
36
- sku_code: z.string().optional(),
37
- tariff_number: z.string().optional(),
36
+ sku_code: z.string().nullable().optional(),
37
+ tariff_number: z.string().nullable().optional(),
38
38
  value_amount: z.string(),
39
39
  value_currency: z.string(),
40
40
  });
@@ -4,16 +4,60 @@
4
4
 
5
5
  import * as z from "zod";
6
6
  import {
7
- UserParcelTemplate,
8
- UserParcelTemplate$zodSchema,
9
- } from "./userparceltemplate.js";
7
+ CarrierParcelTemplate,
8
+ CarrierParcelTemplate$zodSchema,
9
+ } from "./carrierparceltemplate.js";
10
+ import {
11
+ DistanceUnitEnum,
12
+ DistanceUnitEnum$zodSchema,
13
+ } from "./distanceunitenum.js";
14
+ import { WeightUnitEnum, WeightUnitEnum$zodSchema } from "./weightunitenum.js";
15
+
16
+ export type TheFieldsOfAParcelTemplateBeforeSavingItToTheDb = {
17
+ distance_unit?: DistanceUnitEnum | undefined;
18
+ height?: string | undefined;
19
+ length?: string | undefined;
20
+ name?: string | undefined;
21
+ weight?: string | undefined;
22
+ weight_unit?: WeightUnitEnum | undefined;
23
+ width?: string | undefined;
24
+ object_created?: string | undefined;
25
+ object_id?: string | undefined;
26
+ object_owner?: string | undefined;
27
+ object_updated?: string | undefined;
28
+ template?: CarrierParcelTemplate | undefined;
29
+ };
30
+
31
+ export const TheFieldsOfAParcelTemplateBeforeSavingItToTheDb$zodSchema:
32
+ z.ZodType<
33
+ TheFieldsOfAParcelTemplateBeforeSavingItToTheDb,
34
+ z.ZodTypeDef,
35
+ unknown
36
+ > = z.object({
37
+ distance_unit: DistanceUnitEnum$zodSchema.optional(),
38
+ height: z.string().optional(),
39
+ length: z.string().optional(),
40
+ name: z.string().optional(),
41
+ object_created: z.string().optional(),
42
+ object_id: z.string().optional(),
43
+ object_owner: z.string().optional(),
44
+ object_updated: z.string().optional(),
45
+ template: CarrierParcelTemplate$zodSchema.optional(),
46
+ weight: z.string().optional(),
47
+ weight_unit: WeightUnitEnum$zodSchema.optional(),
48
+ width: z.string().optional(),
49
+ });
10
50
 
11
- export type DefaultParcelTemplate = { result?: UserParcelTemplate | undefined };
51
+ export type DefaultParcelTemplate = {
52
+ result?: TheFieldsOfAParcelTemplateBeforeSavingItToTheDb | null | undefined;
53
+ };
12
54
 
13
55
  export const DefaultParcelTemplate$zodSchema: z.ZodType<
14
56
  DefaultParcelTemplate,
15
57
  z.ZodTypeDef,
16
58
  unknown
17
59
  > = z.object({
18
- result: UserParcelTemplate$zodSchema.optional(),
60
+ result: z.lazy(() =>
61
+ TheFieldsOfAParcelTemplateBeforeSavingItToTheDb$zodSchema
62
+ ).nullable().optional(),
19
63
  });
@@ -40,7 +40,7 @@ export type Parcel = {
40
40
  object_state?: ObjectState | undefined;
41
41
  object_updated?: string | undefined;
42
42
  template?: ParcelTemplateEnumSet | null | undefined;
43
- test?: boolean | undefined;
43
+ test?: boolean | null | undefined;
44
44
  };
45
45
 
46
46
  export const Parcel$zodSchema: z.ZodType<Parcel, z.ZodTypeDef, unknown> = z
@@ -57,7 +57,7 @@ export const Parcel$zodSchema: z.ZodType<Parcel, z.ZodTypeDef, unknown> = z
57
57
  object_state: ObjectState$zodSchema.optional(),
58
58
  object_updated: z.string().datetime({ offset: true }).optional(),
59
59
  template: ParcelTemplateEnumSet$zodSchema.nullable().optional(),
60
- test: z.boolean().optional(),
60
+ test: z.boolean().nullable().optional(),
61
61
  weight: z.string(),
62
62
  width: z.string(),
63
63
  });
@@ -11,9 +11,9 @@ import * as z from "zod";
11
11
  * for example a timeout from a carrier. If available, the origin of the message is displayed in `source`.
12
12
  */
13
13
  export type ResponseMessage = {
14
- source?: string | undefined;
15
- code?: string | undefined;
16
- text?: string | undefined;
14
+ source?: string | null | undefined;
15
+ code?: string | null | undefined;
16
+ text?: string | null | undefined;
17
17
  };
18
18
 
19
19
  export const ResponseMessage$zodSchema: z.ZodType<
@@ -21,9 +21,9 @@ export const ResponseMessage$zodSchema: z.ZodType<
21
21
  z.ZodTypeDef,
22
22
  unknown
23
23
  > = z.object({
24
- code: z.string().optional(),
25
- source: z.string().optional(),
26
- text: z.string().optional(),
24
+ code: z.string().nullable().optional(),
25
+ source: z.string().nullable().optional(),
26
+ text: z.string().nullable().optional(),
27
27
  }).describe(
28
28
  "Message returned with supporting information from a request. In some cases this can be an error message, \n"
29
29
  + "for example a timeout from a carrier. If available, the origin of the message is displayed in `source`.",
@@ -16,14 +16,14 @@ export type ServiceGroup = {
16
16
  description: string;
17
17
  flat_rate?: string | undefined;
18
18
  flat_rate_currency?: string | undefined;
19
- free_shipping_threshold_currency?: string | undefined;
20
- free_shipping_threshold_min?: string | undefined;
19
+ free_shipping_threshold_currency?: string | null | undefined;
20
+ free_shipping_threshold_min?: string | null | undefined;
21
21
  name: string;
22
22
  rate_adjustment?: number | undefined;
23
23
  type: ServiceGroupTypeEnum;
24
24
  object_id: string;
25
25
  is_active?: boolean | undefined;
26
- service_levels: Array<ServiceGroupAccountAndServiceLevel>;
26
+ service_levels: Array<ServiceGroupAccountAndServiceLevel> | null;
27
27
  };
28
28
 
29
29
  export const ServiceGroup$zodSchema: z.ZodType<
@@ -34,12 +34,13 @@ export const ServiceGroup$zodSchema: z.ZodType<
34
34
  description: z.string(),
35
35
  flat_rate: z.string().optional(),
36
36
  flat_rate_currency: z.string().optional(),
37
- free_shipping_threshold_currency: z.string().optional(),
38
- free_shipping_threshold_min: z.string().optional(),
37
+ free_shipping_threshold_currency: z.string().nullable().optional(),
38
+ free_shipping_threshold_min: z.string().nullable().optional(),
39
39
  is_active: z.boolean().optional(),
40
40
  name: z.string(),
41
41
  object_id: z.string(),
42
42
  rate_adjustment: z.number().int().optional(),
43
- service_levels: z.array(ServiceGroupAccountAndServiceLevel$zodSchema),
43
+ service_levels: z.array(ServiceGroupAccountAndServiceLevel$zodSchema)
44
+ .nullable(),
44
45
  type: ServiceGroupTypeEnum$zodSchema,
45
46
  });
@@ -16,8 +16,8 @@ export type ServiceGroupCreateRequest = {
16
16
  description: string;
17
17
  flat_rate?: string | undefined;
18
18
  flat_rate_currency?: string | undefined;
19
- free_shipping_threshold_currency?: string | undefined;
20
- free_shipping_threshold_min?: string | undefined;
19
+ free_shipping_threshold_currency?: string | null | undefined;
20
+ free_shipping_threshold_min?: string | null | undefined;
21
21
  name: string;
22
22
  rate_adjustment?: number | undefined;
23
23
  type: ServiceGroupTypeEnum;
@@ -32,8 +32,8 @@ export const ServiceGroupCreateRequest$zodSchema: z.ZodType<
32
32
  description: z.string(),
33
33
  flat_rate: z.string().optional(),
34
34
  flat_rate_currency: z.string().optional(),
35
- free_shipping_threshold_currency: z.string().optional(),
36
- free_shipping_threshold_min: z.string().optional(),
35
+ free_shipping_threshold_currency: z.string().nullable().optional(),
36
+ free_shipping_threshold_min: z.string().nullable().optional(),
37
37
  name: z.string(),
38
38
  rate_adjustment: z.number().int().optional(),
39
39
  service_levels: z.array(ServiceGroupAccountAndServiceLevel$zodSchema),
@@ -16,8 +16,8 @@ export type ServiceGroupUpdateRequest = {
16
16
  description: string;
17
17
  flat_rate?: string | undefined;
18
18
  flat_rate_currency?: string | undefined;
19
- free_shipping_threshold_currency?: string | undefined;
20
- free_shipping_threshold_min?: string | undefined;
19
+ free_shipping_threshold_currency?: string | null | undefined;
20
+ free_shipping_threshold_min?: string | null | undefined;
21
21
  name: string;
22
22
  rate_adjustment?: number | undefined;
23
23
  type: ServiceGroupTypeEnum;
@@ -34,8 +34,8 @@ export const ServiceGroupUpdateRequest$zodSchema: z.ZodType<
34
34
  description: z.string(),
35
35
  flat_rate: z.string().optional(),
36
36
  flat_rate_currency: z.string().optional(),
37
- free_shipping_threshold_currency: z.string().optional(),
38
- free_shipping_threshold_min: z.string().optional(),
37
+ free_shipping_threshold_currency: z.string().nullable().optional(),
38
+ free_shipping_threshold_min: z.string().nullable().optional(),
39
39
  is_active: z.boolean(),
40
40
  name: z.string(),
41
41
  object_id: z.string(),
@@ -37,10 +37,10 @@ export const UserParcelTemplate$zodSchema: z.ZodType<
37
37
  height: z.string().optional(),
38
38
  length: z.string().optional(),
39
39
  name: z.string().optional(),
40
- object_created: z.string().datetime({ offset: true }).optional(),
40
+ object_created: z.string().optional(),
41
41
  object_id: z.string().optional(),
42
42
  object_owner: z.string().optional(),
43
- object_updated: z.string().datetime({ offset: true }).optional(),
43
+ object_updated: z.string().optional(),
44
44
  template: CarrierParcelTemplate$zodSchema.optional(),
45
45
  weight: z.string().optional(),
46
46
  weight_unit: WeightUnitEnum$zodSchema.optional(),