DELETE
/
admin
/
shipping-options
/
{id}
JS SDK
import Medusa from "@medusajs/js-sdk"

export const sdk = new Medusa({
  baseUrl: import.meta.env.VITE_BACKEND_URL || "/",
  debug: import.meta.env.DEV,
  auth: {
    type: "session",
  },
})

sdk.admin.shippingOption.delete("so_123")
.then(({ deleted }) => {
  console.log(deleted)
})
{
"id": "<string>",
"object": "shipping_option",
"deleted": true
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

id
string
required

The shipping option's ID.

Response

OK

The details of the shipping option's deletion.

id
string
required

The shipping option's ID.

object
string
default:shipping_option
required

The name of the deleted object.

deleted
boolean
required

Whether the shipping option was deleted.