chore(docs): Refactor API Reference (#1883)
This commit is contained in:
@@ -0,0 +1,135 @@
|
||||
delete:
|
||||
operationId: DeleteRegionsRegion
|
||||
summary: Delete a Region
|
||||
description: Deletes a Region.
|
||||
x-authenticated: true
|
||||
parameters:
|
||||
- in: path
|
||||
name: id
|
||||
required: true
|
||||
description: The ID of the Region.
|
||||
schema:
|
||||
type: string
|
||||
tags:
|
||||
- Region
|
||||
responses:
|
||||
'200':
|
||||
description: OK
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
properties:
|
||||
id:
|
||||
type: string
|
||||
description: The ID of the deleted Region.
|
||||
object:
|
||||
type: string
|
||||
description: The type of the object that was deleted.
|
||||
default: region
|
||||
deleted:
|
||||
type: boolean
|
||||
description: Whether or not the items were deleted.
|
||||
default: true
|
||||
get:
|
||||
operationId: GetRegionsRegion
|
||||
summary: Retrieve a Region
|
||||
description: Retrieves a Region.
|
||||
x-authenticated: true
|
||||
parameters:
|
||||
- in: path
|
||||
name: id
|
||||
required: true
|
||||
description: The ID of the Region.
|
||||
schema:
|
||||
type: string
|
||||
tags:
|
||||
- Region
|
||||
responses:
|
||||
'200':
|
||||
description: OK
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
properties:
|
||||
region:
|
||||
$ref: ../components/schemas/region.yaml
|
||||
post:
|
||||
operationId: PostRegionsRegion
|
||||
summary: Update a Region
|
||||
description: Updates a Region
|
||||
x-authenticated: true
|
||||
parameters:
|
||||
- in: path
|
||||
name: id
|
||||
required: true
|
||||
description: The ID of the Region.
|
||||
schema:
|
||||
type: string
|
||||
requestBody:
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
properties:
|
||||
name:
|
||||
description: The name of the Region
|
||||
type: string
|
||||
currency_code:
|
||||
description: The 3 character ISO currency code to use for the Region.
|
||||
type: string
|
||||
externalDocs:
|
||||
url: https://en.wikipedia.org/wiki/ISO_4217#Active_codes
|
||||
description: See a list of codes.
|
||||
automatic_taxes:
|
||||
description: >-
|
||||
If true Medusa will automatically calculate taxes for carts in
|
||||
this region. If false you have to manually call POST
|
||||
/carts/:id/taxes.
|
||||
type: boolean
|
||||
gift_cards_taxable:
|
||||
description: >-
|
||||
Whether gift cards in this region should be applied sales tax
|
||||
when purchasing a gift card
|
||||
type: boolean
|
||||
tax_provider_id:
|
||||
description: >-
|
||||
The ID of the tax provider to use; if null the system tax
|
||||
provider is used
|
||||
type: string
|
||||
tax_code:
|
||||
description: An optional tax code the Region.
|
||||
type: string
|
||||
tax_rate:
|
||||
description: The tax rate to use on Orders in the Region.
|
||||
type: number
|
||||
payment_providers:
|
||||
description: >-
|
||||
A list of Payment Provider IDs that should be enabled for the
|
||||
Region
|
||||
type: array
|
||||
items:
|
||||
type: string
|
||||
fulfillment_providers:
|
||||
description: >-
|
||||
A list of Fulfillment Provider IDs that should be enabled for
|
||||
the Region
|
||||
type: array
|
||||
items:
|
||||
type: string
|
||||
countries:
|
||||
description: >-
|
||||
A list of countries' 2 ISO Characters that should be included in
|
||||
the Region.
|
||||
type: array
|
||||
items:
|
||||
type: string
|
||||
tags:
|
||||
- Region
|
||||
responses:
|
||||
'200':
|
||||
description: OK
|
||||
content:
|
||||
application/json:
|
||||
schema:
|
||||
properties:
|
||||
region:
|
||||
$ref: ../components/schemas/region.yaml
|
||||
Reference in New Issue
Block a user