@shipengine/js-api 0.40.2 → 0.41.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/index.js CHANGED
@@ -3699,6 +3699,12 @@ class ShippingRulesAPI {
3699
3699
  this.create = (shippingRule) => {
3700
3700
  return this.client.post("/v1/shipping_rules", shippingRule);
3701
3701
  };
3702
+ /**
3703
+ * The `delete` method deletes a shipping rule by `shippingRuleId`.
3704
+ */
3705
+ this.delete = (shippingRuleId) => {
3706
+ return this.client.delete(`/v1/shipping_rules/${shippingRuleId}`);
3707
+ };
3702
3708
  this.client = client;
3703
3709
  }
3704
3710
  }
package/index.mjs CHANGED
@@ -3695,6 +3695,12 @@ class ShippingRulesAPI {
3695
3695
  this.create = (shippingRule) => {
3696
3696
  return this.client.post("/v1/shipping_rules", shippingRule);
3697
3697
  };
3698
+ /**
3699
+ * The `delete` method deletes a shipping rule by `shippingRuleId`.
3700
+ */
3701
+ this.delete = (shippingRuleId) => {
3702
+ return this.client.delete(`/v1/shipping_rules/${shippingRuleId}`);
3703
+ };
3698
3704
  this.client = client;
3699
3705
  }
3700
3706
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@shipengine/js-api",
3
- "version": "0.40.2",
3
+ "version": "0.41.0",
4
4
  "main": "./index.js",
5
5
  "types": "./index.d.ts",
6
6
  "exports": {
@@ -18,4 +18,4 @@
18
18
  "peerDependencies": {
19
19
  "axios": "^0.26.1"
20
20
  }
21
- }
21
+ }
@@ -16,4 +16,8 @@ export declare class ShippingRulesAPI {
16
16
  * The `create` method creates a new shipping rule for a given user.
17
17
  */
18
18
  create: (shippingRule: ShippingRuleInput) => Promise<import("axios").AxiosResponse<ShippingRule, any>>;
19
+ /**
20
+ * The `delete` method deletes a shipping rule by `shippingRuleId`.
21
+ */
22
+ delete: (shippingRuleId: string) => Promise<import("axios").AxiosResponse<any, any>>;
19
23
  }