OrderLinesModifiedFailedv0.0.1
OrderLinesModifiedFailed
This event is triggered when an order lines modification has been started but the operation failed.
OrderLinesModifiedFailed Schema (json)
{
"$schema": "http://json-schema.org/draft-04/schema#",
"title": "OrderLinesModifiedFailed",
"required": [
"detail-type",
"resources",
"detail",
"id",
"source",
"time",
"region",
"version",
"account"
],
"type": "object",
"x-amazon-events-detail-type": "OrderLinesModifiedFailed",
"x-amazon-events-source": "brink.external.v1",
"properties": {
"account": {
"type": "string"
},
"detail": {
"$ref": "#/definitions/Detail"
},
"detail-type": {
"type": "string"
},
"id": {
"type": "string"
},
"region": {
"type": "string"
},
"resources": {
"items": {
"type": "string"
},
"type": "array"
},
"source": {
"type": "string"
},
"time": {
"format": "date-time",
"type": "string"
},
"version": {
"type": "string"
}
},
"definitions": {
"Detail": {
"properties": {
"data": {
"$ref": "#/definitions/Data"
},
"metadata": {
"$ref": "#/definitions/Metadata"
}
},
"required": [
"metadata",
"data"
],
"type": "object"
},
"Metadata": {
"type": "object",
"required": [
"awsRequestId"
],
"properties": {
"awsRequestId": {
"type": "string"
}
}
},
"Data": {
"$ref": "#/definitions/OrderLinesModified"
},
"OrderLinesModified": {
"type": "object",
"required": [
"id",
"orderId",
"orderReference",
"paymentProvider",
"orderLines",
"created",
"updated",
"completed",
"restarts",
"revision"
],
"properties": {
"id": {
"type": "string",
"description": "The order lines modification id"
},
"orderId": {
"type": "string",
"description": "The order id"
},
"orderReference": {
"type": "string",
"description": "The order short reference"
},
"paymentProvider": {
"$ref": "#/definitions/ProviderStatus"
},
"shippingProvider": {
"$ref": "#/definitions/Provider"
},
"giftCardProvider": {
"$ref": "#/definitions/Provider"
},
"giftCardProductProvider": {
"$ref": "#/definitions/Provider"
},
"voucherProvider": {
"$ref": "#/definitions/Provider"
},
"promotionProvider": {
"$ref": "#/definitions/Provider"
},
"bonusProvider": {
"$ref": "#/definitions/Provider"
},
"orderLines": {
"type": "array",
"items": {
"$ref": "#/definitions/OrderLineModification"
}
},
"reason": {
"$ref": "#/definitions/Reason"
},
"created": {
"type": "string",
"format": "date-time",
"description": "Created date for the order lines modification"
},
"updated": {
"type": "string",
"format": "date-time",
"description": "Updated date for the order lines modification"
},
"started": {
"type": "string",
"format": "date-time",
"description": "Started date for the order lines modification"
},
"completed": {
"type": "string",
"format": "date-time",
"description": "Completed date for the order lines modification"
},
"failed": {
"type": "string",
"format": "date-time",
"description": "Failed date for the order lines modification"
},
"restarted": {
"type": "string",
"format": "date-time",
"description": "Restarted date for the order lines modification"
},
"restarts": {
"description": "The number of restarts",
"type": "integer"
},
"revision": {
"description": "The revision number of the order lines modification",
"type": "integer"
}
}
},
"ProviderStatus": {
"type": "object",
"required": [
"providerId",
"providerName",
"status"
],
"properties": {
"providerId": {
"type": "string",
"description": "The id for the provider"
},
"providerName": {
"type": "string",
"description": "The name of the provider"
},
"status": {
"$ref": "#/definitions/ProviderStatusLog"
}
}
},
"ProviderStatusLog": {
"type": "object",
"required": [
"current",
"history"
],
"properties": {
"current": {
"type": "string",
"description": "The latest status for the provider"
},
"history": {
"type": "array",
"items": {
"$ref": "#/definitions/ProviderStatusLogEntry"
}
}
}
},
"ProviderStatusLogEntry": {
"type": "object",
"required": [
"status",
"timestamp",
"type"
],
"properties": {
"message": {
"type": "string",
"description": "Optional message for the status"
},
"errorMessage": {
"type": "string",
"description": "Optional error message from the provider"
},
"status": {
"type": "string",
"description": "The actual status"
},
"timestamp": {
"type": "string",
"format": "date-time",
"description": "Timestamp for the status"
},
"type": {
"type": "string",
"description": "Status type"
}
}
},
"Provider": {
"type": "object",
"required": [
"providerId",
"providerName"
],
"properties": {
"providerId": {
"type": "string",
"description": "The id of the provider"
},
"providerName": {
"type": "string",
"description": "The name of the provider"
}
}
},
"Reason": {
"type": "object",
"properties": {
"code": {
"type": "string",
"description": "Optional code for the reason, useful for BI tracking"
},
"cause": {
"type": "string",
"description": "Optional human readable cause for the reason"
}
}
},
"ModificationType": {
"title": "ModificationType",
"type": "string",
"enum": [
"CREATE",
"UPDATE",
"DELETE"
]
},
"OrderLineModification": {
"type": "object",
"required": [
"modificationType",
"data"
],
"properties": {
"modificationType": {
"$ref": "#/definitions/ModificationType"
},
"data": {
"oneOf": [
{
"$ref": "#/definitions/OrderLineModificationCreate"
},
{
"$ref": "#/definitions/OrderLineModificationUpdate"
},
{
"$ref": "#/definitions/OrderLineModificationDelete"
}
]
}
}
},
"OrderLineModificationCreate": {
"type": "object",
"required": [
"id",
"name",
"description",
"imageUrl",
"quantity",
"basePriceAmount",
"salePriceAmount",
"discountAmount",
"taxPercentage",
"taxPercentageDecimals",
"totalPriceAmount",
"totalDiscountAmount",
"totalTaxAmount",
"distributedTotalPriceAmount",
"distributedTotalDiscountAmount",
"distributedTotalTaxAmount"
],
"properties": {
"id": {
"type": "string",
"description": "The id for the created order line"
},
"name": {
"type": "string",
"description": "The name for the created order line"
},
"description": {
"type": "string",
"description": "The description for the created order line"
},
"productParentId": {
"type": "string",
"description": "Optional productParentId for the created order line"
},
"productVariantId": {
"type": "string",
"description": "Optional productVariantId for the created order line"
},
"taxGroupId": {
"type": "string",
"description": "Optional taxGroupId for the created order line"
},
"imageUrl": {
"type": "string",
"description": "The imageUrl for the created order line"
},
"options": {
"$ref": "#/definitions/Options"
},
"campaign": {
"$ref": "#/definitions/Campaign"
},
"quantity": {
"type": "integer",
"description": "The quantity of the created order line"
},
"basePriceAmount": {
"type": "integer",
"description": "Per unit base price of the created order line"
},
"salePriceAmount": {
"type": "integer",
"description": "Per unit sale price of the created order line"
},
"discountAmount": {
"type": "integer",
"description": "Calculated per unit discount amount of the order line `basePriceAmount` - `salePriceAmount`"
},
"taxPercentage": {
"type": "integer",
"description": "Tax percentage for the order line"
},
"taxPercentageDecimals": {
"type": "integer",
"description": "Optional number of decimals in `taxPercentage`. Default 2"
},
"totalPriceAmount": {
"type": "integer",
"description": "Total amount of the created order line"
},
"totalDiscountAmount": {
"type": "integer",
"description": "Total discount amount of the created order line"
},
"totalTaxAmount": {
"type": "integer",
"description": "Total tax amount for the order line"
},
"distributedTotalPriceAmount": {
"type": "integer",
"description": "Total amount of the created order line including distributed order discount"
},
"distributedTotalDiscountAmount": {
"type": "integer",
"description": "Total discount amount of the created order line including distributed order discount"
},
"distributedTotalTaxAmount": {
"type": "integer",
"description": "Total tax amount of the created order line based on `distributedTotalPriceAmount`"
}
}
},
"OrderLineModificationUpdate": {
"type": "object",
"required": [
"id"
],
"properties": {
"id": {
"type": "string",
"description": "The id for the updated order line"
},
"name": {
"type": "string",
"description": "Updated name for the order line"
},
"displayName": {
"type": "string",
"description": "Updated displayName for the order line"
},
"description": {
"type": "string",
"description": "Updated description for the order line"
},
"displayDescription": {
"type": "string",
"description": "Updated displayDescription for the order line"
},
"productParentId": {
"type": "string",
"description": "Updated productParentId for the order line"
},
"productVariantId": {
"type": "string",
"description": "Updated productVariantId for the order line"
},
"taxGroupId": {
"type": "string",
"description": "Updated taxGroupId for the order line"
},
"imageUrl": {
"type": "string",
"description": "Updated imageUrl for the order line"
},
"options": {
"$ref": "#/definitions/Options"
},
"campaign": {
"$ref": "#/definitions/Campaign"
},
"price": {
"$ref": "#/definitions/OrderLineModificationUpdatePrice"
}
}
},
"OrderLineModificationUpdatePrice": {
"type": "object",
"required": [
"quantity",
"basePriceAmount",
"salePriceAmount",
"discountAmount",
"taxPercentage",
"taxPercentageDecimals",
"totalPriceAmount",
"totalDiscountAmount",
"totalTaxAmount",
"distributedTotalPriceAmount",
"distributedTotalTaxAmount",
"distributedTotalDiscountAmount"
],
"properties": {
"quantity": {
"type": "integer",
"description": "Updated quantity of the order line"
},
"basePriceAmount": {
"type": "integer",
"description": "Updated per unit base price of the created order line"
},
"salePriceAmount": {
"type": "integer",
"description": "Updated per unit sale price of the created order line"
},
"discountAmount": {
"type": "integer",
"description": "Updated per unit discount amount of the order line"
},
"taxPercentage": {
"type": "integer",
"description": "Updated per tax percentage of the order line"
},
"taxPercentageDecimals": {
"type": "integer",
"description": "Updated per tax percentage decimals of the order line"
},
"totalPriceAmount": {
"type": "integer",
"description": "Updated total price amount of the order line"
},
"totalDiscountAmount": {
"type": "integer",
"description": "Updated total discount amount of the order line"
},
"totalTaxAmount": {
"type": "integer",
"description": "Updated total tax amount of the order line"
},
"distributedTotalPriceAmount": {
"type": "integer",
"description": "Updated total price amount including distributed order discounts of the order line"
},
"distributedTotalTaxAmount": {
"type": "integer",
"description": "Updated total tax amount including distributed order discounts of the order line"
},
"distributedTotalDiscountAmount": {
"type": "integer",
"description": "Updated total discount amount including distributed order discounts of the order line"
}
}
},
"OrderLineModificationDelete": {
"type": "object",
"required": [
"id"
],
"properties": {
"id": {
"type": "string",
"description": "The id for the deleted order line"
}
}
},
"Options": {
"type": [
"object",
"null"
],
"description": "Order line options",
"patternProperties": {
"^[A-Za-z0-9_-]{1,40}$": {
"type": "string",
"maxLength": 256
}
},
"additionalProperties": false,
"maxProperties": 10
},
"Campaign": {
"type": "object",
"required": [
"campaignId",
"name",
"campaignGroupId"
],
"properties": {
"campaignId": {
"type": "string",
"description": "The campaign id"
},
"name": {
"type": "string",
"description": "The name of the campaign"
},
"campaignGroupId": {
"type": "string",
"description": "The campaign group id"
}
}
}
}
}
Last updated on 2024/11/15