get: operationId: GetShippingOptions summary: List Shipping Options description: >- Retrieve a list of Shipping Options. The shipping options can be filtered by fields such as `region_id` or `is_return`. The shipping options can also be sorted or paginated. x-authenticated: true parameters: - in: query name: name description: Filter by name. schema: type: string - in: query name: region_id description: Filter by the ID of the region the shipping options belong to. schema: type: string - in: query name: is_return description: Filter by whether the shipping options are return shipping options. schema: type: boolean - in: query name: admin_only description: >- Filter by whether the shipping options are available for admin users only. schema: type: boolean - in: query name: q description: Term used to search shipping options' name. schema: type: string - in: query name: order description: A shipping option field to sort-order the retrieved shipping options by. schema: type: string - in: query name: id style: form explode: false description: Filter by shipping option IDs. schema: oneOf: - type: string description: ID of the shipping option. - type: array items: type: string description: ID of a shipping option. - in: query name: created_at description: Filter by a creation date range. schema: type: object properties: lt: type: string description: filter by dates less than this date format: date gt: type: string description: filter by dates greater than this date format: date lte: type: string description: filter by dates less than or equal to this date format: date gte: type: string description: filter by dates greater than or equal to this date format: date - in: query name: updated_at description: Filter by an update date range. schema: type: object properties: lt: type: string description: filter by dates less than this date format: date gt: type: string description: filter by dates greater than this date format: date lte: type: string description: filter by dates less than or equal to this date format: date gte: type: string description: filter by dates greater than or equal to this date format: date - in: query name: deleted_at description: Filter by a deletion date range. schema: type: object properties: lt: type: string description: filter by dates less than this date format: date gt: type: string description: filter by dates greater than this date format: date lte: type: string description: filter by dates less than or equal to this date format: date gte: type: string description: filter by dates greater than or equal to this date format: date - in: query name: offset description: The number of users to skip when retrieving the shipping options. schema: type: integer default: 0 - in: query name: limit description: Limit the number of shipping options returned. schema: type: integer default: 20 - in: query name: expand description: >- Comma-separated relations that should be expanded in the returned shipping options. schema: type: string - in: query name: fields description: >- Comma-separated fields that should be included in the returned shipping options. schema: type: string x-codegen: method: list queryParams: AdminGetShippingOptionsParams x-codeSamples: - lang: JavaScript label: JS Client source: $ref: ../code_samples/JavaScript/admin_shipping-options/get.js - lang: tsx label: Medusa React source: $ref: ../code_samples/tsx/admin_shipping-options/get.tsx - lang: Shell label: cURL source: $ref: ../code_samples/Shell/admin_shipping-options/get.sh security: - api_token: [] - cookie_auth: [] - jwt_token: [] tags: - Shipping Options responses: '200': description: OK content: application/json: schema: $ref: ../components/schemas/AdminShippingOptionsListRes.yaml '400': $ref: ../components/responses/400_error.yaml '401': $ref: ../components/responses/unauthorized.yaml '404': $ref: ../components/responses/not_found_error.yaml '409': $ref: ../components/responses/invalid_state_error.yaml '422': $ref: ../components/responses/invalid_request_error.yaml '500': $ref: ../components/responses/500_error.yaml post: operationId: PostShippingOptions summary: Create Shipping Option description: Create a Shipping Option. x-authenticated: true requestBody: content: application/json: schema: $ref: ../components/schemas/AdminPostShippingOptionsReq.yaml x-codegen: method: create x-codeSamples: - lang: JavaScript label: JS Client source: $ref: ../code_samples/JavaScript/admin_shipping-options/post.js - lang: tsx label: Medusa React source: $ref: ../code_samples/tsx/admin_shipping-options/post.tsx - lang: Shell label: cURL source: $ref: ../code_samples/Shell/admin_shipping-options/post.sh security: - api_token: [] - cookie_auth: [] - jwt_token: [] tags: - Shipping Options responses: '200': description: OK content: application/json: schema: $ref: ../components/schemas/AdminShippingOptionsRes.yaml '400': $ref: ../components/responses/400_error.yaml '401': $ref: ../components/responses/unauthorized.yaml '404': $ref: ../components/responses/not_found_error.yaml '409': $ref: ../components/responses/invalid_state_error.yaml '422': $ref: ../components/responses/invalid_request_error.yaml '500': $ref: ../components/responses/500_error.yaml