Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 3 additions & 6 deletions specification/paths.json
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,9 @@
"/onboarding/v1/invitations/{invitation_id}/onboard": {
"$ref": "./paths/Onboarding-v1-invitations-invitation_id-onboard.json"
},
"/orders/v1/orders/{reference}": {
"$ref": "./paths/Orders-v1-orders-reference.json"
},
"/organizations": {
"$ref": "./paths/Organizations.json"
},
Expand Down Expand Up @@ -398,12 +401,6 @@
"/zones/{zone_id}": {
"$ref": "./paths/Zones-zone_id.json"
},
"/analytics/on-time-delivery/{interval}": {
"$ref": "./paths/Analytics-on-time-delivery.json"
},
"/analytics/volume/{group_by}/{interval}": {
"$ref": "./paths/Analytics-volume.json"
},
"/add-shipments-to-collection": {
"$ref": "./paths/AddShipmentsToCollection.json"
},
Expand Down
86 changes: 0 additions & 86 deletions specification/paths/Analytics-on-time-delivery.json

This file was deleted.

118 changes: 0 additions & 118 deletions specification/paths/Analytics-volume.json

This file was deleted.

80 changes: 80 additions & 0 deletions specification/paths/Orders-v1-orders-reference.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,80 @@
{
"parameters": [
{
"name": "reference",
"in": "path",
"description": "Order reference to retrieve the order by.",
"required": true,
"schema": {
"type": "string"
}
},
{
"name": "shop_id",
"in": "query",
"required": true,
"description": "Id of the shop to retrieve the order for.",
"schema": {
"$ref": "#/components/schemas/Uuid"
}
},
{
"name": "email",
"in": "query",
"description": "Email address of the receiver of the order. This query parameter is mutually exclusive with postal code query parameter. Either one is required.",
"schema": {
"$ref": "#/components/schemas/Email"
}
},
{
"name": "postal_code",
"in": "query",
"description": "Postal code of the receiver of the order. This query parameter is mutually exclusive with email query parameter. Either one is required.",
"schema": {
"type": "string",
"example": "1111AA"
}
}
],
"get": {
"tags": [
"Orders"
],
"security": [
{
"OAuth2": [
"returns.manage"
]
}
],
"summary": "Get an order resource by reference and email or postal code.",
"description": "This endpoint retrieves an order resource by the specified reference and either email address or postal code.",
"responses": {
"200": {
"description": "Retrieved the order.",
"content": {
"application/vnd.api+json": {
"schema": {
"type": "object",
"required": [
"data"
],
"additionalProperties": false,
"properties": {
"data": {
"$ref": "#/components/schemas/OrderResponse"
}
}
}
}
}
},
"404": {
"description": "No order was found with the provided input."
},
"409": {
"description": "One or more of the orders resource is handled by a 3rd party."
}
}
}
}
42 changes: 31 additions & 11 deletions specification/paths/Returns-v1-return-methods-resolve.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,19 +43,39 @@
"example": "35eddf50-1d84-47a3-8479-6bfda729cd99"
},
"consumer_address": {
"required": [
"country_code",
"email"
],
"properties": {
"country_code": {
"$ref": "#/components/schemas/CountryCode"
"oneOf": [
{
"title": "Resolve order by email",
"required": [
"country_code",
"email"
],
"properties": {
"country_code": {
"$ref": "#/components/schemas/CountryCode"
},
"email": {
"$ref": "#/components/schemas/Email"
}
}
},
"email": {
"$ref": "#/components/schemas/Email",
"example": "s.holmes@holmesinvestigations.com"
{
"title": "Resolve order by postal code",
"required": [
"country_code",
"postal_code"
],
"properties": {
"country_code": {
"$ref": "#/components/schemas/CountryCode"
},
"postal_code": {
"type": "string",
"example": "1111AA"
}
}
}
}
]
},
"weight": {
"type": "integer",
Expand Down
8 changes: 8 additions & 0 deletions specification/paths/Returns-v1-returns.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,14 @@
"type": "string"
}
},
{
"name": "filter[postal_code]",
"in": "query",
"description": "Postal code of the consumer_address of the return.",
"schema": {
"type": "string"
}
},
{
"name": "filter[search]",
"in": "query",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
]
}
],
"deprecated": true,
"summary": "Get an order resource.",
"description": "This endpoint retrieves an order resource by the specified reference and email address.",
"responses": {
Expand Down
3 changes: 0 additions & 3 deletions specification/schemas.json
Original file line number Diff line number Diff line change
Expand Up @@ -764,9 +764,6 @@
"Weight": {
"$ref": "./schemas/Weight.json"
},
"Analytics": {
"$ref": "./schemas/Analytics.json"
},
"TaxIdentificationNumber": {
"$ref": "./schemas/organizations/TaxIdentificationNumber.json"
},
Expand Down
Loading