@shipengine/js-api 0.30.0 → 0.32.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/errors/types.d.ts CHANGED
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * @category Entities
3
3
  */
4
- export type CodedErrorCode = "auto_fund_not_supported" | "batch_cannot_be_modified" | "carrier_conflict" | "carrier_disconnected" | "carrier_not_connected" | "carrier_not_supported" | "confirmation_not_supported" | "default_warehouse_cannot_be_deleted" | "duplicated_rate_card" | "empty_file" | "field_conflict" | "field_value_required" | "forbidden" | "identifier_conflict" | "identifiers_must_match" | "insufficient_funds" | "insufficient_rate_card_data" | "invalid_address" | "invalid_billing_plan" | "invalid_field_value" | "invalid_file_type" | "invalid_identifier" | "invalid_status" | "invalid_string_length" | "invalid_zones" | "invalid_packages" | "invalid_weight_bands" | "invalid_rates" | "label_images_not_supported" | "meter_failure" | "not_found" | "order_source_not_active" | "rate_limit_exceeded" | "refresh_not_supported" | "request_body_required" | "return_label_not_supported" | "settings_not_supported" | "subscription_inactive" | "terms_not_accepted" | "tracking_not_supported" | "trial_expired" | "unauthorized" | "unknown" | "unspecified" | "verification_failure" | "warehouse_conflict" | "webhook_event_type_conflict";
4
+ export type CodedErrorCode = "auto_fund_not_supported" | "batch_cannot_be_modified" | "carrier_conflict" | "carrier_disconnected" | "carrier_not_connected" | "carrier_not_supported" | "confirmation_not_supported" | "default_warehouse_cannot_be_deleted" | "duplicated_rate_card" | "empty_file" | "field_conflict" | "field_value_required" | "forbidden" | "identifier_conflict" | "identifiers_must_match" | "insufficient_funds" | "insufficient_rate_card_data" | "invalid_address" | "invalid_billing_plan" | "invalid_field_value" | "invalid_file_type" | "invalid_file_size" | "invalid_identifier" | "invalid_status" | "invalid_string_length" | "invalid_zones" | "invalid_packages" | "invalid_weight_bands" | "invalid_rates" | "label_images_not_supported" | "meter_failure" | "not_found" | "order_source_not_active" | "rate_limit_exceeded" | "refresh_not_supported" | "request_body_required" | "return_label_not_supported" | "settings_not_supported" | "subscription_inactive" | "terms_not_accepted" | "tracking_not_supported" | "trial_expired" | "unauthorized" | "unknown" | "unspecified" | "verification_failure" | "warehouse_conflict" | "webhook_event_type_conflict";
5
5
  /**
6
6
  * @category Entities
7
7
  */
package/index.js CHANGED
@@ -3330,6 +3330,12 @@ class RateCardsAPI {
3330
3330
  this.publish = (rateCardId) => {
3331
3331
  return this.client.post(`/v1/rate_cards/${rateCardId}/publish`);
3332
3332
  };
3333
+ /**
3334
+ * @description https://auctane.atlassian.net/wiki/spaces/TE/pages/3837431603/Inc+1+3.+Rate+Card+Details#Delete-Rate-Card
3335
+ */
3336
+ this.delete = (rateCardId) => {
3337
+ return this.client.delete(`/v1/rate_cards/${rateCardId}`);
3338
+ };
3333
3339
  this.client = client;
3334
3340
  }
3335
3341
  }
package/index.mjs CHANGED
@@ -3326,6 +3326,12 @@ class RateCardsAPI {
3326
3326
  this.publish = (rateCardId) => {
3327
3327
  return this.client.post(`/v1/rate_cards/${rateCardId}/publish`);
3328
3328
  };
3329
+ /**
3330
+ * @description https://auctane.atlassian.net/wiki/spaces/TE/pages/3837431603/Inc+1+3.+Rate+Card+Details#Delete-Rate-Card
3331
+ */
3332
+ this.delete = (rateCardId) => {
3333
+ return this.client.delete(`/v1/rate_cards/${rateCardId}`);
3334
+ };
3329
3335
  this.client = client;
3330
3336
  }
3331
3337
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@shipengine/js-api",
3
- "version": "0.30.0",
3
+ "version": "0.32.0",
4
4
  "main": "./index.js",
5
5
  "types": "./index.d.ts",
6
6
  "exports": {
@@ -12,4 +12,8 @@ export declare class RateCardsAPI {
12
12
  download: (rateCardId: string) => Promise<import("axios").AxiosResponse<Blob, any>>;
13
13
  upload: (rateCardId: string, file: File) => Promise<import("axios").AxiosResponse<RateCard, any>>;
14
14
  publish: (rateCardId: string) => Promise<import("axios").AxiosResponse<any, any>>;
15
+ /**
16
+ * @description https://auctane.atlassian.net/wiki/spaces/TE/pages/3837431603/Inc+1+3.+Rate+Card+Details#Delete-Rate-Card
17
+ */
18
+ delete: (rateCardId: string) => Promise<import("axios").AxiosResponse<any, any>>;
15
19
  }