@shipengine/connect-carrier-api 4.0.0 → 4.1.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.
Files changed (221) hide show
  1. package/README.md +10 -18
  2. package/lib/app/build-app-deployment.js +3 -3
  3. package/lib/app/build-app-deployment.js.map +1 -1
  4. package/lib/app/carrier-app-definition.d.ts +1 -0
  5. package/lib/app/metadata/auth-identifier.js +3 -0
  6. package/lib/app/metadata/auth-identifier.js.map +1 -1
  7. package/lib/app/metadata/auth-specification.js +12 -0
  8. package/lib/app/metadata/auth-specification.js.map +1 -1
  9. package/lib/app/metadata/monoauth.js +68 -0
  10. package/lib/app/metadata/monoauth.js.map +1 -1
  11. package/lib/app/native-rating-data-validator.js +3 -4
  12. package/lib/app/native-rating-data-validator.js.map +1 -1
  13. package/lib/carrier-app.d.ts +7 -0
  14. package/lib/carrier-app.js +15 -0
  15. package/lib/carrier-app.js.map +1 -0
  16. package/lib/index.d.ts +1 -0
  17. package/lib/index.js +1 -0
  18. package/lib/index.js.map +1 -1
  19. package/lib/models/addresses/address-base.js +30 -0
  20. package/lib/models/addresses/address-base.js.map +1 -1
  21. package/lib/models/addresses/pudo-location.js +4 -0
  22. package/lib/models/addresses/pudo-location.js.map +1 -1
  23. package/lib/models/addresses/service-point-address.js +2 -0
  24. package/lib/models/addresses/service-point-address.js.map +1 -1
  25. package/lib/models/addresses/ship-from.js +2 -0
  26. package/lib/models/addresses/ship-from.js.map +1 -1
  27. package/lib/models/addresses/ship-to.js +2 -0
  28. package/lib/models/addresses/ship-to.js.map +1 -1
  29. package/lib/models/advanced-options.js +16 -0
  30. package/lib/models/advanced-options.js.map +1 -1
  31. package/lib/models/authorization.js +4 -0
  32. package/lib/models/authorization.js.map +1 -1
  33. package/lib/models/bill-to.js +4 -0
  34. package/lib/models/bill-to.js.map +1 -1
  35. package/lib/models/billing/billing-line-item.js +12 -0
  36. package/lib/models/billing/billing-line-item.js.map +1 -1
  37. package/lib/models/collect-on-delivery.js +4 -0
  38. package/lib/models/collect-on-delivery.js.map +1 -1
  39. package/lib/models/currency.js +4 -0
  40. package/lib/models/currency.js.map +1 -1
  41. package/lib/models/customs/customs-charges.js +10 -0
  42. package/lib/models/customs/customs-charges.js.map +1 -1
  43. package/lib/models/customs/customs-item.js +22 -0
  44. package/lib/models/customs/customs-item.js.map +1 -1
  45. package/lib/models/customs/customs.js +20 -0
  46. package/lib/models/customs/customs.js.map +1 -1
  47. package/lib/models/documents/document.js +6 -0
  48. package/lib/models/documents/document.js.map +1 -1
  49. package/lib/models/errors/detailed-error.js +5 -0
  50. package/lib/models/errors/detailed-error.js.map +1 -1
  51. package/lib/models/fulfillment-plans/fulfillment-plan-details.js +6 -0
  52. package/lib/models/fulfillment-plans/fulfillment-plan-details.js.map +1 -1
  53. package/lib/models/fulfillment-plans/fulfillment-plan-items.js +8 -0
  54. package/lib/models/fulfillment-plans/fulfillment-plan-items.js.map +1 -1
  55. package/lib/models/fulfillment-plans/raw-external-source.js +2 -0
  56. package/lib/models/fulfillment-plans/raw-external-source.js.map +1 -1
  57. package/lib/models/identifier.js +2 -0
  58. package/lib/models/identifier.js.map +1 -1
  59. package/lib/models/importer-records/importer-of-record.js +22 -0
  60. package/lib/models/importer-records/importer-of-record.js.map +1 -1
  61. package/lib/models/labels/form-download.js +2 -0
  62. package/lib/models/labels/form-download.js.map +1 -1
  63. package/lib/models/labels/label-download.js +2 -0
  64. package/lib/models/labels/label-download.js.map +1 -1
  65. package/lib/models/labels/label-message.js +3 -0
  66. package/lib/models/labels/label-message.js.map +1 -1
  67. package/lib/models/labels/label-package.js +6 -0
  68. package/lib/models/labels/label-package.js.map +1 -1
  69. package/lib/models/labels/return-label-details.js +2 -0
  70. package/lib/models/labels/return-label-details.js.map +1 -1
  71. package/lib/models/labels/void-request.js +4 -0
  72. package/lib/models/labels/void-request.js.map +1 -1
  73. package/lib/models/labels/void-response.js +8 -0
  74. package/lib/models/labels/void-response.js.map +1 -1
  75. package/lib/models/manifests/label.js +4 -0
  76. package/lib/models/manifests/label.js.map +1 -1
  77. package/lib/models/manifests/manifest-request-shipment.js +1 -0
  78. package/lib/models/manifests/manifest-request-shipment.js.map +1 -1
  79. package/lib/models/manifests/manifest.js +9 -0
  80. package/lib/models/manifests/manifest.js.map +1 -1
  81. package/lib/models/package.js +14 -0
  82. package/lib/models/package.js.map +1 -1
  83. package/lib/models/pickup/cancellation-details.js +6 -0
  84. package/lib/models/pickup/cancellation-details.js.map +1 -1
  85. package/lib/models/pickup/pickup-confirmation.js +6 -0
  86. package/lib/models/pickup/pickup-confirmation.js.map +1 -1
  87. package/lib/models/pickup/pickup-contact-details.js +10 -0
  88. package/lib/models/pickup/pickup-contact-details.js.map +1 -1
  89. package/lib/models/pickup/pickup-location-details.js +6 -0
  90. package/lib/models/pickup/pickup-location-details.js.map +1 -1
  91. package/lib/models/pickup/pickup-package.js +14 -0
  92. package/lib/models/pickup/pickup-package.js.map +1 -1
  93. package/lib/models/pickup/pickup-shipment-details.js +4 -0
  94. package/lib/models/pickup/pickup-shipment-details.js.map +1 -1
  95. package/lib/models/pickup/pickup-window.js +8 -0
  96. package/lib/models/pickup/pickup-window.js.map +1 -1
  97. package/lib/models/pickup/shipment-identifier.js +4 -0
  98. package/lib/models/pickup/shipment-identifier.js.map +1 -1
  99. package/lib/models/pickup/shipped-package.js +20 -0
  100. package/lib/models/pickup/shipped-package.js.map +1 -1
  101. package/lib/models/pickup/shipped-shipment.d.ts +0 -2
  102. package/lib/models/pickup/shipped-shipment.js +12 -0
  103. package/lib/models/pickup/shipped-shipment.js.map +1 -1
  104. package/lib/models/rates/rate.js +26 -0
  105. package/lib/models/rates/rate.js.map +1 -1
  106. package/lib/models/registration/credentials.js +4 -0
  107. package/lib/models/registration/credentials.js.map +1 -1
  108. package/lib/models/relay-points/opening-times.js +7 -0
  109. package/lib/models/relay-points/opening-times.js.map +1 -1
  110. package/lib/models/relay-points/relay-point-address.js +7 -0
  111. package/lib/models/relay-points/relay-point-address.js.map +1 -1
  112. package/lib/models/relay-points/relay-point-details.js +2 -0
  113. package/lib/models/relay-points/relay-point-details.js.map +1 -1
  114. package/lib/models/relay-points/relay-point.js +4 -0
  115. package/lib/models/relay-points/relay-point.js.map +1 -1
  116. package/lib/models/resource-download.js +4 -0
  117. package/lib/models/resource-download.js.map +1 -1
  118. package/lib/models/service-points/hours-of-operation.js +4 -0
  119. package/lib/models/service-points/hours-of-operation.js.map +1 -1
  120. package/lib/models/service-points/search-radius.js +8 -0
  121. package/lib/models/service-points/search-radius.js.map +1 -1
  122. package/lib/models/service-points/service-point-response-address.js +2 -0
  123. package/lib/models/service-points/service-point-response-address.js.map +1 -1
  124. package/lib/models/service-points/service-point.js +10 -0
  125. package/lib/models/service-points/service-point.js.map +1 -1
  126. package/lib/models/service-points/weekly-hours-of-operation.js +7 -0
  127. package/lib/models/service-points/weekly-hours-of-operation.js.map +1 -1
  128. package/lib/models/taxes/tax-identifier.js +10 -0
  129. package/lib/models/taxes/tax-identifier.js.map +1 -1
  130. package/lib/models/time-window.js +14 -0
  131. package/lib/models/time-window.js.map +1 -1
  132. package/lib/models/tracking/imported-tracking-event.js +12 -0
  133. package/lib/models/tracking/imported-tracking-event.js.map +1 -1
  134. package/lib/models/tracking/lat-long.js +4 -0
  135. package/lib/models/tracking/lat-long.js.map +1 -1
  136. package/lib/models/tracking/service.js +4 -0
  137. package/lib/models/tracking/service.js.map +1 -1
  138. package/lib/models/tracking/track-event.js +24 -0
  139. package/lib/models/tracking/track-event.js.map +1 -1
  140. package/lib/models/tracking/tracking-attribute.js +2 -0
  141. package/lib/models/tracking/tracking-attribute.js.map +1 -1
  142. package/lib/models/tracking/tracking-identifier.js +2 -0
  143. package/lib/models/tracking/tracking-identifier.js.map +1 -1
  144. package/lib/models/tracking/tracking-info.js +36 -0
  145. package/lib/models/tracking/tracking-info.js.map +1 -1
  146. package/lib/models/units/dimension-details.js +8 -0
  147. package/lib/models/units/dimension-details.js.map +1 -1
  148. package/lib/models/units/dimensions.js +3 -0
  149. package/lib/models/units/dimensions.js.map +1 -1
  150. package/lib/models/units/weight-details.js +8 -0
  151. package/lib/models/units/weight-details.js.map +1 -1
  152. package/lib/requests/base-request.js +3 -0
  153. package/lib/requests/base-request.js.map +1 -1
  154. package/lib/requests/cancel-notification-request.js +4 -0
  155. package/lib/requests/cancel-notification-request.js.map +1 -1
  156. package/lib/requests/cancel-pickup-request.js +7 -0
  157. package/lib/requests/cancel-pickup-request.js.map +1 -1
  158. package/lib/requests/create-label-request.js +35 -0
  159. package/lib/requests/create-label-request.js.map +1 -1
  160. package/lib/requests/create-manifest-request.js +6 -0
  161. package/lib/requests/create-manifest-request.js.map +1 -1
  162. package/lib/requests/create-notification-request.js +6 -0
  163. package/lib/requests/create-notification-request.js.map +1 -1
  164. package/lib/requests/get-manifest-request.js +10 -0
  165. package/lib/requests/get-manifest-request.js.map +1 -1
  166. package/lib/requests/get-rates-request.js +20 -0
  167. package/lib/requests/get-rates-request.js.map +1 -1
  168. package/lib/requests/get-relay-points-request.js +4 -0
  169. package/lib/requests/get-relay-points-request.js.map +1 -1
  170. package/lib/requests/get-service-point-request.js +4 -0
  171. package/lib/requests/get-service-point-request.js.map +1 -1
  172. package/lib/requests/get-service-points-request.js +8 -0
  173. package/lib/requests/get-service-points-request.js.map +1 -1
  174. package/lib/requests/register-request.js +1 -0
  175. package/lib/requests/register-request.js.map +1 -1
  176. package/lib/requests/schedule-pickup-request.js +4 -0
  177. package/lib/requests/schedule-pickup-request.js.map +1 -1
  178. package/lib/requests/tracking-request.js +4 -0
  179. package/lib/requests/tracking-request.js.map +1 -1
  180. package/lib/requests/void-labels-request.js +2 -0
  181. package/lib/requests/void-labels-request.js.map +1 -1
  182. package/lib/responses/base-response.js +1 -0
  183. package/lib/responses/base-response.js.map +1 -1
  184. package/lib/responses/cancel-notification-response.js +4 -0
  185. package/lib/responses/cancel-notification-response.js.map +1 -1
  186. package/lib/responses/cancel-pickup-response.js +4 -0
  187. package/lib/responses/cancel-pickup-response.js.map +1 -1
  188. package/lib/responses/create-label-response.js +17 -0
  189. package/lib/responses/create-label-response.js.map +1 -1
  190. package/lib/responses/create-manifest-response.js +8 -0
  191. package/lib/responses/create-manifest-response.js.map +1 -1
  192. package/lib/responses/create-notification-response.js +3 -0
  193. package/lib/responses/create-notification-response.js.map +1 -1
  194. package/lib/responses/error-response.js +1 -0
  195. package/lib/responses/error-response.js.map +1 -1
  196. package/lib/responses/get-rates-response.js +1 -0
  197. package/lib/responses/get-rates-response.js.map +1 -1
  198. package/lib/responses/get-relay-points-response.js +1 -0
  199. package/lib/responses/get-relay-points-response.js.map +1 -1
  200. package/lib/responses/get-service-point-response.js +2 -0
  201. package/lib/responses/get-service-point-response.js.map +1 -1
  202. package/lib/responses/get-service-points-response.js +2 -0
  203. package/lib/responses/get-service-points-response.js.map +1 -1
  204. package/lib/responses/normalize-tracking-data-response.js +7 -0
  205. package/lib/responses/normalize-tracking-data-response.js.map +1 -1
  206. package/lib/responses/register-response.js +2 -0
  207. package/lib/responses/register-response.js.map +1 -1
  208. package/lib/responses/schedule-pickup-response.js +5 -0
  209. package/lib/responses/schedule-pickup-response.js.map +1 -1
  210. package/lib/responses/tracking-response.js +1 -0
  211. package/lib/responses/tracking-response.js.map +1 -1
  212. package/lib/responses/validate-inbound-data-response.js +2 -0
  213. package/lib/responses/validate-inbound-data-response.js.map +1 -1
  214. package/lib/responses/void-labels-response.js +2 -0
  215. package/lib/responses/void-labels-response.js.map +1 -1
  216. package/package.json +3 -3
  217. package/src/app/carrier-app-definition.ts +1 -0
  218. package/src/carrier-app.ts +11 -0
  219. package/src/index.ts +1 -0
  220. package/src/models/pickup/shipped-shipment.ts +0 -2
  221. package/tsconfig.tsbuildinfo +1 -1
package/README.md CHANGED
@@ -1,24 +1,16 @@
1
- # TypeScript Library
1
+ [![ShipEngine Connect](https://connect.shipengine.com/static/shipengine-connect-logo-0077f6635b4add99dc9f1d5f2aa4ce01.svg)](https://connect.shipengine.com)
2
2
 
3
- The purpose of this library is to fill a similar role that CarrierApi.Common serves for C# but for JavaScript & TypeScript. It will contain the models and definitions for Request/Response Bodies.
3
+ # Carrier API TypeScript Library
4
4
 
5
- Additionally, any changes made to carrier-api library spec, need to manually update the spec.json file. The CI action does not update this file for this repo.
5
+ This library contains types used in building ShipEngine Connect Carrier apps - the requests, responses, and models used to implement the [Carrier API](https://connect.shipengine.com/shipping/).
6
6
 
7
- ## Building
7
+ Usage
8
+ -----------------------
9
+ Visit [our documentation website](https://connect.shipengine.com/) to learn how to build an app for ShipEngine Connect. You can also look at [these sample apps](https://github.com/shipengine/connect-samples), which demonstrate various features of the platform, as well as different possible ways to build and structure apps.
8
10
 
9
- From the repository root, navigate to this package directory.
11
+ About ShipEngine Connect
12
+ --------------------------------------------
13
+ ShipEngine Connect powers the world's leading e-commerce solutions, including [ShipStation](https://www.shipstation.com/), [ShipEngine](https://www.shipengine.com), [ShippingEasy](https://shippingeasy.com/), and [ShipWorks](https://www.shipworks.com/). ShipEngine Connect enables developers to integrate with all of these brands at once.
10
14
 
11
- Install dependencies
12
- ```shell
13
- yarn
14
- ```
15
+ Whether you are a shipping carrier, an online marketplace, or another service provider, ShipEngine Connect makes it easy for you to make your services available within each of our world class e-commerce solutions and gain immediate access to a worldwide user base eager to take advantage or your services.
15
16
 
16
- Build
17
- ```shell
18
- yarn build
19
- ```
20
-
21
- Test
22
- ```shell
23
- yarn test
24
- ```
@@ -10,8 +10,8 @@ const buildAppDeployment = (definition) => {
10
10
  id: definition.Metadata.Id,
11
11
  getSupportedCountries: () => {
12
12
  const countries = [];
13
- const rootCountries = definition.Metadata.Carriers.flatMap((c) => { var _a; return (_a = c.DefaultSupportedCountries) === null || _a === void 0 ? void 0 : _a.flatMap((sc) => sc.FromCountry); });
14
- const serviceCountries = definition.Metadata.Carriers.flatMap((c) => { var _a; return (_a = c.ShippingServices) === null || _a === void 0 ? void 0 : _a.flatMap((s) => s.SupportedCountries).flatMap((sc) => sc === null || sc === void 0 ? void 0 : sc.FromCountry); });
13
+ const rootCountries = definition.Metadata.Carriers.flatMap((c) => c.DefaultSupportedCountries?.flatMap((sc) => sc.FromCountry));
14
+ const serviceCountries = definition.Metadata.Carriers.flatMap((c) => c.ShippingServices?.flatMap((s) => s.SupportedCountries).flatMap((sc) => sc?.FromCountry));
15
15
  countries.push(...rootCountries);
16
16
  countries.push(...serviceCountries);
17
17
  return [...new Set(countries)].filter((c) => c !== undefined);
@@ -32,7 +32,7 @@ const buildAppDeployment = (definition) => {
32
32
  .filter(native_rating_data_validator_1.isDataValidationError)
33
33
  .flat();
34
34
  if (validationErrors.length > 0) {
35
- return validationErrors.map((error) => { var _a; return `${error.message} \n Duplicate Keys: ${(_a = error.duplicateKeys) === null || _a === void 0 ? void 0 : _a.join(', ')}`; });
35
+ return validationErrors.map((error) => `${error.message} \n Duplicate Keys: ${error.duplicateKeys?.join(', ')}`);
36
36
  }
37
37
  },
38
38
  };
@@ -1 +1 @@
1
- {"version":3,"file":"build-app-deployment.js","sourceRoot":"","sources":["../../src/app/build-app-deployment.ts"],"names":[],"mappings":";;;AAAA,2BAAgC;AAEhC,yCAAsD;AACtD,iFAA2F;AAG3F,8DAA8D;AACvD,MAAM,kBAAkB,GAAG,CAAC,UAAgC,EAAiB,EAAE;IACpF,OAAO;QACL,EAAE,EAAE,UAAU,CAAC,QAAQ,CAAC,EAAE;QAC1B,qBAAqB,EAAE,GAAG,EAAE;YAC1B,MAAM,SAAS,GAA2B,EAAE,CAAC;YAC7C,MAAM,aAAa,GAAG,UAAU,CAAC,QAAQ,CAAC,QAAQ,CAAC,OAAO,CAAC,CAAC,CAAC,EAAE,EAAE,WAC/D,OAAA,MAAA,CAAC,CAAC,yBAAyB,0CAAE,OAAO,CAAC,CAAC,EAAE,EAAE,EAAE,CAAC,EAAE,CAAC,WAAW,CAAC,CAAA,EAAA,CAC7D,CAAC;YACF,MAAM,gBAAgB,GAAG,UAAU,CAAC,QAAQ,CAAC,QAAQ,CAAC,OAAO,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ent } from '../models';
2
+ import type { Request } from 'express';
2
3
  import { RegisterRequest, CreateLabelRequest, VoidLabelsRequest, CreateManifestRequest, GetManifestRequest, SchedulePickupRequest, CancelPickupRequest, GetRatesRequest, TrackingRequest, CancelNotificationRequest, CreateNotificationRequest, ValidateInboundDataRequest, NormalizeTrackingDataRequest, GetRelayPointsRequest, GetServicePointsRequest, GetServicePointRequest, ImportTrackingEventsRequest } from '../requests';
3
4
  import { RegisterResponse, CreateLabelResponse, VoidLabelsResponse, CreateManifestResponse, SchedulePickupResponse, CancelPickupResponse, GetRatesResponse, TrackingResponse, CancelNotificationResponse, CreateNotificationResponse, ValidateInboundDataResponse, NormalizeTrackingDataResponse, GetRelayPointsResponse, GetServicePointsResponse, GetServicePointResponse } from '../responses';
4
5
  import { CarrierAppMetadata } from './metadata/carrier-app-metadata';
@@ -8,6 +8,9 @@ var AuthenticationType;
8
8
  AuthenticationType["OAuth"] = "oauth";
9
9
  })(AuthenticationType = exports.AuthenticationType || (exports.AuthenticationType = {}));
10
10
  class AuthIdentifier {
11
+ AuthenticationType;
12
+ Version;
13
+ IsSandbox;
11
14
  }
12
15
  exports.AuthIdentifier = AuthIdentifier;
13
16
  exports.AuthIdentifierSchema = joi_1.default.object({
@@ -1 +1 @@
1
- {"version":3,"file":"auth-identifier.js","sourceRoot":"","sources":["../../../src/app/metadata/auth-identifier.ts"],"names":[],"mappings":";;;;AAAA,sDAAsB;AAEtB,IAAY,kBAEX;AAFD,WAAY,kBAAkB;IAC5B,qCAAe,CAAA;AACjB,CAAC,EAFW,kBAAkB,GAAlB,0BAAkB,KAAlB,0BAAkB,QAE7B;AAED,MAAa,cAAc;CAI1B;AAJD,wCAIC;AAEY,QAAA,oBAAoB,GAAG,aAAG,CAAC,MAAM,CAAC;IAC7C,kBAAkB,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC;IAC1D,OAAO,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAChC,SAAS,EAAE,aAAG,CAAC,IAAI,EAAE,CAAC,QAAQ,EAAE;CACjC,CAAC,CAAC"}
1
+ {"version":3,"file":"auth-identifier.js","sourceRoot":"","sources":["../../../src/app/metadata/auth-identifier.ts"],"names":[],"mappings":";;;;AAAA,sDAAsB;AAEtB,IAAY,kBAEX;AAFD,WAAY,kBAAkB;IAC5B,qCAAe,CAAA;AACjB,CAAC,EAFW,kBAAkB,GAAlB,0BAAkB,KAAlB,0BAAkB,QAE7B;AAED,MAAa,cAAc;IACzB,kBAAkB,CAAsB;IACxC,OAAO,CAAU;IACjB,SAAS,CAAW;CACrB;AAJD,wCAIC;AAEY,QAAA,oBAAoB,GAAG,aAAG,CAAC,MAAM,CAAC;IAC7C,kBAAkB,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC;IAC1D,OAAO,EAAE,aAAG,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAChC,SAAS,EAAE,aAAG,CAAC,IAAI,EAAE,CAAC,QAAQ,EAAE;CACjC,CAAC,CAAC"}
@@ -7,6 +7,18 @@ const monoauth_1 = require("./monoauth");
7
7
  const joi_1 = tslib_1.__importDefault(require("joi"));
8
8
  /** @description Used to specify information about an integrations authentication */
9
9
  class AuthSpecification {
10
+ /** @description Identify the type of Auth being used by the integration */
11
+ Identifier;
12
+ /** @description Added to allow oauth 1.0 to work. */
13
+ access_token;
14
+ /** @description Authorization: the beginning of an OAuth2.0 flow that ensures the user is logged in and approves access to the Resource. */
15
+ authorization;
16
+ /** @description Request Token: server-server code for token exchange */
17
+ request_token;
18
+ /** @description Refresh Token: server-server refresh token exchange for access token **NOTE: sometimes a new RT is also created** */
19
+ refresh_token;
20
+ /** @description Advanced configurations used for oauth 1.0 */
21
+ advanced_configuration;
10
22
  }
11
23
  exports.AuthSpecification = AuthSpecification;
12
24
  exports.AuthSpecificationSchema = joi_1.default.object({
@@ -1 +1 @@
1
- {"version":3,"file":"auth-specification.js","sourceRoot":"","sources":["../../../src/app/metadata/auth-specification.ts"],"names":[],"mappings":";;;;AAAA,uDAAyE;AACzE,yCAWoB;AACpB,sDAAsB;AAEtB,oFAAoF;AACpF,MAAa,iBAAiB;CAa7B;AAbD,8CAaC;AAEY,QAAA,uBAAuB,GAAG,aAAG,CAAC,MAAM,CAAC;IAChD,UAAU,EAAE,sCAAoB;IAChC,YAAY,EAAE,4BAAiB,CAAC,QAAQ,EAAE;IAC1C,aAAa,EAAE,2CAAgC,CAAC,QAAQ,EAAE;IAC1D,aAAa,EAAE,0CAA+B,CAAC,QAAQ,EAAE;IACzD,aAAa,EAAE,0CAA+B,CAAC,QAAQ,EAAE;IACzD,sBAAsB,EAAE,aAAG,CAAC,KAAK,EAAE,CAAC,QAAQ,EAAE,CAAC,KAAK,CAAC,0BAAe,CAAC;CACtE,CAAC,CAAC"}
1
+ {"version":3,"file":"auth-specification.js","sourceRoot":"","sources":["../../../src/app/metadata/auth-specification.ts"],"names":[],"mappings":";;;;AAAA,uDAAyE;AACzE,yCAWoB;AACpB,sDAAsB;AAEtB,oFAAoF;AACpF,MAAa,iBAAiB;IAC5B,2EAA2E;IAC3E,UAAU,CAAkB;IAC5B,qDAAqD;IACrD,YAAY,CAAe;IAC3B,4IAA4I;IAC5I,aAAa,CAA8B;IAC3C,wEAAwE;IACxE,aAAa,CAA6B;IAC1C,qIAAqI;IACrI,aAAa,CAA6B;IAC1C,8DAA8D;IAC9D,sBAAsB,CAAe;CACtC;AAbD,8CAaC;AAEY,QAAA,uBAAuB,GAAG,aAAG,CAAC,MAAM,CAAC;IAChD,UAAU,EAAE,sCAAoB;IAChC,YAAY,EAAE,4BAAiB,CAAC,QAAQ,EAAE;IAC1C,aAAa,EAAE,2CAAgC,CAAC,QAAQ,EAAE;IAC1D,aAAa,EAAE,0CAA+B,CAAC,QAAQ,EAAE;IACzD,aAAa,EAAE,0CAA+B,CAAC,QAAQ,EAAE;IACzD,sBAAsB,EAAE,aAAG,CAAC,KAAK,EAAE,CAAC,QAAQ,EAAE,CAAC,KAAK,CAAC,0BAAe,CAAC;CACtE,CAAC,CAAC"}
@@ -4,6 +4,10 @@ exports.AuthorizationConfigurationSchema = exports.AuthorizationConfiguration =
4
4
  const tslib_1 = require("tslib");
5
5
  const joi_1 = tslib_1.__importDefault(require("joi"));
6
6
  class Parameter {
7
+ /** @description The name of the parameter */
8
+ name;
9
+ /** @description The value associated with the parameter */
10
+ value;
7
11
  }
8
12
  exports.Parameter = Parameter;
9
13
  exports.MethodSchema = joi_1.default.string().valid('GET', 'POST', 'DELETE', 'PUT', 'get', 'post', 'delete', 'put');
@@ -12,6 +16,11 @@ exports.ParameterSchema = joi_1.default.object({
12
16
  value: joi_1.default.string().required(),
13
17
  });
14
18
  class DateTimeConfiguration {
19
+ /** @description JSONPath to the JSON element containing the date-time */
20
+ path;
21
+ /** @description DateTime format string compliant with
22
+ * https://docs.microsoft.com/en-us/dotnet/standard/base-types/custom-date-and-time-format-strings */
23
+ date_time_format;
15
24
  }
16
25
  exports.DateTimeConfiguration = DateTimeConfiguration;
17
26
  exports.DateTimeConfigurationSchema = joi_1.default.object({
@@ -23,6 +32,26 @@ exports.DateTimeConfigurationSchema = joi_1.default.object({
23
32
  * Note for JSONPath: strings not starting with $ are interpreted as string literals
24
33
  */
25
34
  class ResponseTransformationConfiguration {
35
+ /** @description JSONPath to the JSON element for access_token. */
36
+ access_token;
37
+ /** @description JSONPath to the JSON element for token_type */
38
+ token_type;
39
+ /** @description JSONPath to the JSON element for refresh_token */
40
+ refresh_token;
41
+ /** @description JSONPath to the JSON element for expires_in. Mutually exclusive with expires_at */
42
+ expires_in;
43
+ /** @description Configuration for parsing a date-time, when the integration is lacking expires_in.
44
+ * Mutually exclusive with expires_in.
45
+ */
46
+ expires_at;
47
+ /** @description Optional collection of properties to include in the connection_context sent back with the auth flow result.
48
+ * Property value may be JSONPath or a string literal.
49
+ * E.g.
50
+ * "connection_context": {
51
+ * "account_number": "$.data.account_number"
52
+ * }
53
+ */
54
+ connection_context;
26
55
  }
27
56
  exports.ResponseTransformationConfiguration = ResponseTransformationConfiguration;
28
57
  exports.MapOfStringsSchema = joi_1.default.object().pattern(joi_1.default.string(), joi_1.default.string());
@@ -35,12 +64,26 @@ exports.ResponseTransformationConfigurationSchema = joi_1.default.object({
35
64
  connection_context: exports.MapOfStringsSchema.optional(),
36
65
  });
37
66
  class AccessToken {
67
+ /** @description OAuth1 only. The url to obtain the temporary Access (aka Request) Token to start a flow **/
68
+ url_template;
38
69
  }
39
70
  exports.AccessToken = AccessToken;
40
71
  exports.AccessTokenSchema = joi_1.default.object({
41
72
  url_template: joi_1.default.string().required(),
42
73
  });
43
74
  class RequestTokenConfiguration {
75
+ /** @description The url to obtain the access token using the authorization code on the backend @example "http://{auth_state:store_name}.store.com/admin/oauth/request", "http://store.com/oauth/request" */
76
+ url_template;
77
+ /** @description A list of query parameters that will be attached to the url */
78
+ query_parameters;
79
+ /** @description Method to use when making the server-server code for token request @example "GET", "POST" */
80
+ method;
81
+ /** @description List of parameters that are sent to the integration when exchanging the code for the token. These are built using ContentType */
82
+ body;
83
+ /** @description List of headers that are sent to the integration when requesting a token */
84
+ headers;
85
+ /** @description Response payload parsing */
86
+ response;
44
87
  }
45
88
  exports.RequestTokenConfiguration = RequestTokenConfiguration;
46
89
  exports.RequestTokenConfigurationSchema = joi_1.default.object({
@@ -52,6 +95,18 @@ exports.RequestTokenConfigurationSchema = joi_1.default.object({
52
95
  response: exports.ResponseTransformationConfigurationSchema.optional(),
53
96
  });
54
97
  class RefreshTokenConfiguration {
98
+ /** @description The url to refresh the access token using the authorization code on the backend @example "http://{auth_state:store_name}.store.com/admin/oauth/refresh", "http://store.com/oauth/refresh" */
99
+ url_template;
100
+ /** @description A list of query parameters that will be attached to the url */
101
+ query_parameters;
102
+ /** @description Method to use when making the server-server code for token request @example "GET", "POST" */
103
+ method;
104
+ /** @description List of parameters that are sent to the integration during the server-server refresh token request. These are built using the content type specified in the headers array. */
105
+ body;
106
+ /** @description List of headers that are sent to the integration when refreshing a token */
107
+ headers;
108
+ /** @description Response payload parsing */
109
+ response;
55
110
  }
56
111
  exports.RefreshTokenConfiguration = RefreshTokenConfiguration;
57
112
  exports.RefreshTokenConfigurationSchema = joi_1.default.object({
@@ -63,12 +118,25 @@ exports.RefreshTokenConfigurationSchema = joi_1.default.object({
63
118
  response: exports.ResponseTransformationConfigurationSchema.optional(),
64
119
  });
65
120
  class NonceConfiguration {
121
+ name;
66
122
  }
67
123
  exports.NonceConfiguration = NonceConfiguration;
68
124
  exports.NonceConfigurationSchema = joi_1.default.object({
69
125
  name: joi_1.default.string().required(),
70
126
  });
71
127
  class AuthorizationConfiguration {
128
+ /** @description The url to obtain the access token using the authorization code on the backend @example "http://{auth_state:store_name}.store.com/admin/oauth/authorize", "http://store.com/oauth/authorize" */
129
+ url_template;
130
+ /** @description A list of query parameters that will be attached to the url */
131
+ query_parameters;
132
+ /** @description Method to use when making the server-server code for token request @example "GET", "POST" */
133
+ method;
134
+ /** @description List of parameters that are sent to the integration during the server-server authorization request. These are built using the content type specified in the headers array. */
135
+ body;
136
+ /** @description List of headers that are sent to the integration when authorizing a token */
137
+ headers;
138
+ /** @description A nonce query parameter included on the accept request, then returned and validated on the redirect request */
139
+ nonce;
72
140
  }
73
141
  exports.AuthorizationConfiguration = AuthorizationConfiguration;
74
142
  exports.AuthorizationConfigurationSchema = joi_1.default.object({
@@ -1 +1 @@
1
- {"version":3,"file":"monoauth.js","sourceRoot":"","sources":["../../../src/app/metadata/monoauth.ts"],"names":[],"mappings":";;;;AAAA,sDAAsB;AAEtB,MAAa,SAAS;CAKrB;AALD,8BAKC;AAEY,QAAA,YAAY,GAAG,aAAG,CAAC,MAAM,EAAE,CAAC,KAAK,CAC5C,KAAK,EACL,MAAM,EACN,QAAQ,EACR,KAAK,EACL,KAAK,EACL,MAAM,EACN,QAAQ,EACR,KAAK,CACN,CAAC;AAEW,QAAA,e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= (0, fs_1.readFileSync)(dataFilePath);
24
24
  const json = JSON.parse(dataBuffer.toString());
25
- const data = (json === null || json === void 0 ? void 0 : json[dataType]) || [];
25
+ const data = json?.[dataType] || [];
26
26
  const duplicates = getDuplicateKeys(data);
27
27
  if (duplicates) {
28
28
  return {
@@ -35,13 +35,12 @@ const validate = (dataFilePath, dataType) => {
35
35
  const isDataValidationError = (errors) => errors !== undefined;
36
36
  exports.isDataValidationError = isDataValidationError;
37
37
  const validateRatingData = (carrier) => {
38
- var _a, _b, _c, _d;
39
38
  let errors = [];
40
- let basePath = (_b = (_a = carrier.NativeRating) === null || _a === void 0 ? void 0 : _a.Path) !== null && _b !== void 0 ? _b : '';
39
+ let basePath = carrier.NativeRating?.Path ?? '';
41
40
  let error = validate((0, path_1.resolve)(basePath, 'zones.json'), 'zones');
42
41
  if (error)
43
42
  errors.push(error);
44
- (_d = (_c = carrier.NativeRating) === null || _c === void 0 ? void 0 : _c.RateCards) === null || _d === void 0 ? void 0 : _d.forEach((rateCard) => {
43
+ carrier.NativeRating?.RateCards?.forEach((rateCard) => {
45
44
  error = validate((0, path_1.resolve)(basePath, rateCard.Id, 'rates.json'), 'rates');
46
45
  if (error)
47
46
  errors.push(error);
@@ -1 +1 @@
1
- {"version":3,"file":"native-rating-data-validator.js","sourceRoot":"","sources":["../../src/app/native-rating-data-validator.ts"],"names":[],"mappings":";;;AAAA,+BAA+B;AAC/B,2BAA8C;AAQ9C,MAAM,gBAAgB,GAAG,CAAC,SAA4B,EAAwB,EAAE;IAC9E,IAAI,IAAI,GAAa,EAAE,CAAC;IACxB,IAAI,YAAY,GAAG,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,CAAC;IACvC,SAAS,CAAC,OAAO,CAAC,CAAC,SAAS,EAAE,EAAE;QAC9B,IAAI,SAAS,CAAC,KAAK,CAAC,EAAE;YACpB,IAAI,YAAY,CAAC,SAAS,CAAC,KAAK,CAAC,CAAC,EAAE;gBAClC,IAAI,CAAC,IAAI,CAA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O,CAAC,YAAY,EAAE,SAAS,EAAE,OAAO,CAAC,CAAC,QAAQ,EAAE,EAAE;QACpD,KAAK,GAAG,QAAQ,CAAC,IAAA,cAAO,EAAC,QAAQ,EAAE,QAAQ,CAAC,EAAE,EAAE,YAAY,CAAC,EAAE,OAAO,CAAC,CAAC;QACxE,IAAI,KAAK;YAAE,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;QAC9B,KAAK,GAAG,QAAQ,CAAC,IAAA,cAAO,EAAC,QAAQ,EAAE,QAAQ,CAAC,EAAE,EAAE,gBAAgB,CAAC,EAAE,WAAW,CAAC,CAAC;QAChF,IAAI,KAAK;YAAE,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;IAChC,CAAC,CAAC,CAAC;IAEH,OAAO,MAAM,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,CAAC,SAAS,CAAC;AAChD,CAAC,CAAC;AAfW,QAAA,kBAAkB,sBAe7B"}
@@ -0,0 +1,7 @@
1
+ /**
2
+ * @deprecated Connect apps should no longer instantiate themselves.
3
+ * See https://connect.shipengine.com/getting-started/v2-v4-upgrade/ for more information on upgrading.
4
+ */
5
+ export declare class CarrierApp {
6
+ constructor(_: unknown);
7
+ }
@@ -0,0 +1,15 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.CarrierApp = void 0;
4
+ const connect_runtime_1 = require("@shipengine/connect-runtime");
5
+ /**
6
+ * @deprecated Connect apps should no longer instantiate themselves.
7
+ * See https://connect.shipengine.com/getting-started/v2-v4-upgrade/ for more information on upgrading.
8
+ */
9
+ class CarrierApp {
10
+ constructor(_) {
11
+ (0, connect_runtime_1.obsoleteAppError)();
12
+ }
13
+ }
14
+ exports.CarrierApp = CarrierApp;
15
+ //# sourceMappingURL=carrier-app.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"carrier-app.js","sourceRoot":"","sources":["../src/carrier-app.ts"],"names":[],"mappings":";;;AAAA,iEAA+D;AAE/D;;;GAGG;AACH,MAAa,UAAU;IACrB,YAAY,CAAU;QACpB,IAAA,kCAAgB,GAAE,CAAC;IACrB,CAAC;CACF;AAJD,gCAIC"}
package/lib/index.d.ts CHANGED
@@ -7,3 +7,4 @@ export * from './models';
7
7
  export * from './requests';
8
8
  export * from './responses';
9
9
  export * from './spec';
10
+ export * from './carrier-app';
package/lib/index.js CHANGED
@@ -11,4 +11,5 @@ tslib_1.__exportStar(require("./models"), exports);
11
11
  tslib_1.__exportStar(require("./requests"), exports);
12
12
  tslib_1.__exportStar(require("./responses"), exports);
13
13
  tslib_1.__exportStar(require("./spec"), exports);
14
+ tslib_1.__exportStar(require("./carrier-app"), exports);
14
15
  //# sourceMappingURL=index.js.map
package/lib/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;AAAA,2DAAmC;AACnC,+DAAuC;AACvC,iEAAyC;AAEzC,gDAAsB;AACtB,sDAA4B;AAC5B,mDAAyB;AACzB,qDAA2B;AAC3B,sDAA4B;AAC5B,iDAAuB"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;AAAA,2DAAmC;AACnC,+DAAuC;AACvC,iEAAyC;AAEzC,gDAAsB;AACtB,sDAA4B;AAC5B,mDAAyB;AACzB,qDAA2B;AAC3B,sDAA4B;AAC5B,iDAAuB;AACvB,wDAA8B"}
@@ -2,6 +2,36 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.AddressBase = void 0;
4
4
  class AddressBase {
5
+ /** @description The full name of the contact contact associated with the address */
6
+ name;
7
+ /** @description The first name of the contact associated with the address */
8
+ first_name;
9
+ /** @description The last name of the contact associated with the address */
10
+ last_name;
11
+ /** @description The email of the contact associated with the address */
12
+ email;
13
+ /** @description The phone number of the contact associated with the address (No Newline Characters) */
14
+ phone_number;
15
+ /** @description The name of the company associated with this address (No Newline Characters) max length 100 characters */
16
+ company_name;
17
+ /** @description The address lines of the address (No Newline Characters) max length 100 characters */
18
+ address_lines;
19
+ /** @description City or locality (No Newline Characters) */
20
+ city_locality;
21
+ /** @description State or province (No Newline Characters) */
22
+ state_province;
23
+ /** @description Zip or postal code (No Newline Characters) */
24
+ postal_code;
25
+ /** @description ISO 3166-1 two-letter country code max length 2 characters */
26
+ country_code;
27
+ /** @description Whether the address is residential or commercial */
28
+ address_residential_indicator;
29
+ /** @description Whether the country of the shipment address is a member of the EU */
30
+ is_eu;
31
+ /** @description Additional metadata provided for specific requests */
32
+ address_metadata;
33
+ /** @description Instructions to help the carrier navigate to the address */
34
+ instructions;
5
35
  }
6
36
  exports.AddressBase = AddressBase;
7
37
  //# sourceMappingURL=address-base.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"address-base.js","sourceRoot":"","sources":["../../../src/models/addresses/address-base.ts"],"names":[],"mappings":";;;AAEA,MAAa,WAAW;CA+BvB;AA/BD,kCA+BC"}
1
+ {"version":3,"file":"address-base.js","sourceRoot":"","sources":["../../../src/models/addresses/address-base.ts"],"names":[],"mappings":";;;AAEA,MAAa,WAAW;IACtB,oFAAoF;IACpF,IAAI,CAAU;IACd,6EAA6E;IAC7E,UAAU,CAAU;IACpB,4EAA4E;IAC5E,SAAS,CAAU;IACnB,wEAAwE;IACxE,KAAK,CAAU;IACf,uGAAuG;IACvG,YAAY,CAAU;IACtB,0HAA0H;IAC1H,YAAY,CAAU;IACtB,sGAAsG;IACtG,aAAa,CAAY;IACzB,4DAA4D;IAC5D,aAAa,CAAU;IACvB,6DAA6D;IAC7D,cAAc,CAAU;IACxB,8DAA8D;IAC9D,WAAW,CAAU;IACrB,+EAA+E;IAC/E,YAAY,CAAU;IACtB,oEAAoE;IACpE,6BAA6B,CAA+B;IAC5D,qFAAqF;IACrF,KAAK,CAAW;IAChB,sEAAsE;IACtE,gBAAgB,CAA6B;IAC7C,4EAA4E;IAC5E,YAAY,CAAU;CACvB;AA/BD,kCA+BC"}
@@ -4,6 +4,10 @@ exports.PudoLocation = void 0;
4
4
  const address_base_1 = require("./address-base");
5
5
  /** @description Pickup/Dropoff location used by carriers */
6
6
  class PudoLocation extends address_base_1.AddressBase {
7
+ /** @description Standardized carrier code the location id belongs to */
8
+ carrier_code;
9
+ /** @description Location id needed to look up the location */
10
+ location_id;
7
11
  }
8
12
  exports.PudoLocation = PudoLocation;
9
13
  //# sourceMappingURL=pudo-location.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"pudo-location.js","sourceRoot":"","sources":["../../../src/models/addresses/pudo-location.ts"],"names":[],"mappings":";;;AAAA,iDAA6C;AAE7C,4DAA4D;AAC5D,MAAa,YAAa,SAAQ,0BAAW;CAK5C;AALD,oCAKC"}
1
+ {"version":3,"file":"pudo-location.js","sourceRoot":"","sources":["../../../src/models/addresses/pudo-location.ts"],"names":[],"mappings":";;;AAAA,iDAA6C;AAE7C,4DAA4D;AAC5D,MAAa,YAAa,SAAQ,0BAAW;IAC3C,wEAAwE;IACxE,YAAY,CAAU;IACtB,8DAA8D;IAC9D,WAAW,CAAU;CACtB;AALD,oCAKC"}
@@ -4,6 +4,8 @@ exports.ServicePointAddress = void 0;
4
4
  const address_base_1 = require("./address-base");
5
5
  /** @description The basic address type related to service points */
6
6
  class ServicePointAddress extends address_base_1.AddressBase {
7
+ /** @description Geographical location */
8
+ geo;
7
9
  }
8
10
  exports.ServicePointAddress = ServicePointAddress;
9
11
  //# sourceMappingURL=service-point-address.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"service-point-address.js","sourceRoot":"","sources":["../../../src/models/addresses/service-point-address.ts"],"names":[],"mappings":";;;AACA,iDAA6C;AAE7C,oEAAoE;AACpE,MAAa,mBAAoB,SAAQ,0BAAW;CAGnD;AAHD,kDAGC"}
1
+ {"version":3,"file":"service-point-address.js","sourceRoot":"","sources":["../../../src/models/addresses/service-point-address.ts"],"names":[],"mappings":";;;AACA,iDAA6C;AAE7C,oEAAoE;AACpE,MAAa,mBAAoB,SAAQ,0BAAW;IAClD,yCAAyC;IACzC,GAAG,CAAW;CACf;AAHD,kDAGC"}
@@ -4,6 +4,8 @@ exports.ShipFrom = void 0;
4
4
  const address_base_1 = require("./address-base");
5
5
  /** @description The address for where the shipment will be shipped from */
6
6
  class ShipFrom extends address_base_1.AddressBase {
7
+ /** @description Tax IDs associated with the exporter */
8
+ tax_identifiers;
7
9
  }
8
10
  exports.ShipFrom = ShipFrom;
9
11
  //# sourceMappingURL=ship-from.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ship-from.js","sourceRoot":"","sources":["../../../src/models/addresses/ship-from.ts"],"names":[],"mappings":";;;AAAA,iDAA6C;AAG7C,2EAA2E;AAC3E,MAAa,QAAS,SAAQ,0BAAW;CAGxC;AAHD,4BAGC"}
1
+ {"version":3,"file":"ship-from.js","sourceRoot":"","sources":["../../../src/models/addresses/ship-from.ts"],"names":[],"mappings":";;;AAAA,iDAA6C;AAG7C,2EAA2E;AAC3E,MAAa,QAAS,SAAQ,0BAAW;IACvC,wDAAwD;IACxD,eAAe,CAAmB;CACnC;AAHD,4BAGC"}
@@ -4,6 +4,8 @@ exports.ShipTo = void 0;
4
4
  const address_base_1 = require("./address-base");
5
5
  /** @description The address that a shipment will be delivered to */
6
6
  class ShipTo extends address_base_1.AddressBase {
7
+ /** @description Tax IDs associated with the consignee */
8
+ tax_identifiers;
7
9
  }
8
10
  exports.ShipTo = ShipTo;
9
11
  //# sourceMappingURL=ship-to.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ship-to.js","sourceRoot":"","sources":["../../../src/models/addresses/ship-to.ts"],"names":[],"mappings":";;;AAAA,iDAA6C;AAG7C,oEAAoE;AACpE,MAAa,MAAO,SAAQ,0BAAW;CAGtC;AAHD,wBAGC"}
1
+ {"version":3,"file":"ship-to.js","sourceRoot":"","sources":["../../../src/models/addresses/ship-to.ts"],"names":[],"mappings":";;;AAAA,iDAA6C;AAG7C,oEAAoE;AACpE,MAAa,MAAO,SAAQ,0BAAW;IACrC,yDAAyD;IACzD,eAAe,CAAmB;CACnC;AAHD,wBAGC"}
@@ -3,6 +3,22 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.AdvancedOptions = void 0;
4
4
  /** @description Basic structure for shipping options */
5
5
  class AdvancedOptions {
6
+ /** @description Whether the shipment contains alcohol */
7
+ contains_alcohol;
8
+ /** @description Whether the shipment does not require postage */
9
+ no_postage;
10
+ /** @description Whether the shipment can be processed by machine */
11
+ nonmachineable;
12
+ /** @description Whether the shipment duties should be billed to the sender */
13
+ bill_duties_to_sender;
14
+ /** @description Whether Saturday delivery is permissible */
15
+ saturday_delivery;
16
+ /** @description Amount to be paid to the driver, used for local delivery and courier services */
17
+ tip;
18
+ /** @description Describes whether Additional Handling is requested for the shipment */
19
+ additional_handling;
20
+ /** @description Describes details for Collect on Delivery (COD) if requested for the shipment */
21
+ collect_on_delivery;
6
22
  }
7
23
  exports.AdvancedOptions = AdvancedOptions;
8
24
  //# sourceMappingURL=advanced-options.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"advanced-options.js","sourceRoot":"","sources":["../../src/models/advanced-options.ts"],"names":[],"mappings":";;;AAGA,wDAAwD;AACxD,MAAa,eAAe;CAmB3B;AAnBD,0CAmBC"}
1
+ {"version":3,"file":"advanced-options.js","sourceRoot":"","sources":["../../src/models/advanced-options.ts"],"names":[],"mappings":";;;AAGA,wDAAwD;AACxD,MAAa,eAAe;IAC1B,yDAAyD;IACzD,gBAAgB,CAAW;IAC3B,iEAAiE;IACjE,UAAU,CAAW;IACrB,oEAAoE;IACpE,cAAc,CAAW;IACzB,8EAA8E;IAC9E,qBAAqB,CAAW;IAChC,6DAA6D;IAC7D,iBAAiB,CAAW;IAC5B,iGAAiG;IACjG,GAAG,CAAY;IACf,wFAAwF;IACxF,mBAAmB,CAAW;IAC9B,iGAAiG;IACjG,mBAAmB,CAAqB;CAGzC;AAnBD,0CAmBC"}
@@ -2,6 +2,10 @@
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.Authorization = void 0;
4
4
  class Authorization {
5
+ /** @description The access token used to authorize the request */
6
+ access_token;
7
+ /** @description Optional - any additional information required to authorize the request */
8
+ connection_context;
5
9
  }
6
10
  exports.Authorization = Authorization;
7
11
  //# sourceMappingURL=authorization.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"authorization.js","sourceRoot":"","sources":["../../src/models/authorization.ts"],"names":[],"mappings":";;;AAAA,MAAa,aAAa;CAKzB;AALD,sCAKC"}
1
+ {"version":3,"file":"authorization.js","sourceRoot":"","sources":["../../src/models/authorization.ts"],"names":[],"mappings":";;;AAAA,MAAa,aAAa;IACxB,kEAAkE;IAClE,YAAY,CAAU;IACtB,2FAA2F;IAC3F,kBAAkB,CAAO;CAC1B;AALD,sCAKC"}
@@ -9,6 +9,10 @@ const addresses_1 = require("./addresses");
9
9
  another account. Additionally, this allows for a contact to be specified, if necessary.
10
10
  */
11
11
  class BillTo extends addresses_1.AddressBase {
12
+ /** @description The bill_to_party mentions the type of billing option*/
13
+ bill_to_party;
14
+ /** @description Specified if there is an account number associated with the Bill To Party, and the Bill To Party is not the account holder. */
15
+ account_number;
12
16
  }
13
17
  exports.BillTo = BillTo;
14
18
  //# sourceMappingURL=bill-to.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"bill-to.js","sourceRoot":"","sources":["../../src/models/bill-to.ts"],"names":[],"mappings":";;;AAAA,2CAA0C;AAG1C;;;;;GAKG;AACH,MAAa,MAAO,SAAQ,uBAAW;CAKtC;AALD,wBAKC"}
1
+ {"version":3,"file":"bill-to.js","sourceRoot":"","sources":["../../src/models/bill-to.ts"],"names":[],"mappings":";;;AAAA,2CAA0C;AAG1C;;;;;GAKG;AACH,MAAa,MAAO,SAAQ,uBAAW;IACrC,wEAAwE;IACxE,aAAa,CAAe;IAC5B,+IAA+I;IAC/I,cAAc,CAAU;CACzB;AALD,wBAKC"}
@@ -3,6 +3,18 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.BillingLineItem = void 0;
4
4
  /** @description Basic structure of each charge or line item */
5
5
  class BillingLineItem {
6
+ /** A generalized category for what type of billing line item this is */
7
+ billing_category;
8
+ /** @description If the carrier provides a description from their API about the billing charge (not specific to the user). Maximum length of 100 characters. */
9
+ carrier_description;
10
+ /** @description If the carrier provides a billing code for */
11
+ carrier_billing_code;
12
+ /** @description This will often be empty; however, if there was additionally specific information about the charge it should go here, could also be a reference number. Maximum length of 250 characters. */
13
+ memo;
14
+ /** @description Total amount of the line item displayed and charged to the buyer */
15
+ amount;
16
+ /** @description Total amount of the line item billed by the provider. This should only be populated if it differs from 'amount' **/
17
+ provider_billed_amount;
6
18
  }
7
19
  exports.BillingLineItem = BillingLineItem;
8
20
  //# sourceMappingURL=billing-line-item.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"billing-line-item.js","sourceRoot":"","sources":["../../../src/models/billing/billing-line-item.ts"],"names":[],"mappings":";;;AAGA,+DAA+D;AAC/D,MAAa,eAAe;CAa3B;AAbD,0CAaC"}
1
+ {"version":3,"file":"billing-line-item.js","sourceRoot":"","sources":["../../../src/models/billing/billing-line-item.ts"],"names":[],"mappings":";;;AAGA,+DAA+D;AAC/D,MAAa,eAAe;IAC1B,wEAAwE;IACxE,gBAAgB,CAAqB;IACrC,+JAA+J;IAC/J,mBAAmB,CAAU;IAC7B,8DAA8D;IAC9D,oBAAoB,CAAU;IAC9B,6MAA6M;IAC7M,IAAI,CAAU;IACd,oFAAoF;IACpF,MAAM,CAAY;IAClB,oIAAoI;IACpI,sBAAsB,CAAY;CACnC;AAbD,0CAaC"}
@@ -3,6 +3,10 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.CollectOnDelivery = void 0;
4
4
  /** @description This model represents the option to defer payment for a shipment, otherwise known as Collect on Delivery (COD) */
5
5
  class CollectOnDelivery {
6
+ /** @description The payment amount for Collect on Delivery (COD) */
7
+ payment_amount;
8
+ /** @description The payment method permitted for Collect on Delivery (COD) */
9
+ payment_type;
6
10
  }
7
11
  exports.CollectOnDelivery = CollectOnDelivery;
8
12
  //# sourceMappingURL=collect-on-delivery.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"collect-on-delivery.js","sourceRoot":"","sources":["../../src/models/collect-on-delivery.ts"],"names":[],"mappings":";;;AAGA,kIAAkI;AAClI,MAAa,iBAAiB;CAK7B;AALD,8CAKC"}
1
+ {"version":3,"file":"collect-on-delivery.js","sourceRoot":"","sources":["../../src/models/collect-on-delivery.ts"],"names":[],"mappings":";;;AAGA,kIAAkI;AAClI,MAAa,iBAAiB;IAC5B,oEAAoE;IACpE,cAAc,CAAY;IAC1B,8EAA8E;IAC9E,YAAY,CAAkB;CAC/B;AALD,8CAKC"}
@@ -3,6 +3,10 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.Currency = void 0;
4
4
  /** @description Basic structure for defining an amount of money and its currency */
5
5
  class Currency {
6
+ /** @description The ISO 4217 Currency Code (USD, EUR, etc) https://www.iso.org/iso-4217-currency-codes.html */
7
+ currency;
8
+ /** @description The amount */
9
+ amount;
6
10
  }
7
11
  exports.Currency = Currency;
8
12
  //# sourceMappingURL=currency.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"currency.js","sourceRoot":"","sources":["../../src/models/currency.ts"],"names":[],"mappings":";;;AAAA,oFAAoF;AACpF,MAAa,QAAQ;CAKpB;AALD,4BAKC"}
1
+ {"version":3,"file":"currency.js","sourceRoot":"","sources":["../../src/models/currency.ts"],"names":[],"mappings":";;;AAAA,oFAAoF;AACpF,MAAa,QAAQ;IACnB,+GAA+G;IAC/G,QAAQ,CAAU;IAClB,8BAA8B;IAC9B,MAAM,CAAU;CACjB;AALD,4BAKC"}
@@ -3,6 +3,16 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.CustomsCharges = void 0;
4
4
  /** @description This model represents the charges related with customs. */
5
5
  class CustomsCharges {
6
+ /** @description Freight charge for international shipments. */
7
+ freight_charge;
8
+ /** @description Other charge for international shipments. */
9
+ other_charge;
10
+ /** @description : Description for other charge for international shipments.*/
11
+ other_charge_description;
12
+ /** @description Insurance charge for international shipments. */
13
+ insurance_charge;
14
+ /** @description Discount for international shipments. */
15
+ discount;
6
16
  }
7
17
  exports.CustomsCharges = CustomsCharges;
8
18
  //# sourceMappingURL=customs-charges.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"customs-charges.js","sourceRoot":"","sources":["../../../src/models/customs/customs-charges.ts"],"names":[],"mappings":";;;AAEA,2EAA2E;AAC3E,MAAa,cAAc;CAW1B;AAXD,wCAWC"}
1
+ {"version":3,"file":"customs-charges.js","sourceRoot":"","sources":["../../../src/models/customs/customs-charges.ts"],"names":[],"mappings":";;;AAEA,2EAA2E;AAC3E,MAAa,cAAc;IACzB,+DAA+D;IAC/D,cAAc,CAAY;IAC1B,6DAA6D;IAC7D,YAAY,CAAY;IACxB,8EAA8E;IAC9E,wBAAwB,CAAU;IAClC,iEAAiE;IACjE,gBAAgB,CAAY;IAC5B,yDAAyD;IACzD,QAAQ,CAAY;CACrB;AAXD,wCAWC"}