Credit note
BI
The CreditNote event is triggered when an existing order receives a credit note.
JSON schema & example
Section titled “JSON schema & example”{ "metadata": { "traceId": "7d0168f2-1c75-4996-b83d-c55a53488726", "occurredAt": "2024-12-24T12:04:06Z", "version": "1.0", "tenant": "14450", "type": "CREDIT_NOTE" }, "customerId": "rxrn:cx:14450:customer:1pyo2nqw0rvfj4d4ernm504d", "creditNoteId": "87654321", "orderId": "59308317", "creditedAmount": -696.56, "includedVatAmount": -108.99, "currency": "EUR", "paymentType": "BANK_TRANSFER", "creditedDateTime": "2023-01-22T22:40:49Z", "singleTickets": [ { "positionId": "PAC174772018", "eventId": "1942657", "seat": { "blockId": "311031", "block": "Osttribüne O17", "row": "8", "seat": "35", "areaId": "1337" }, "resale": false, "price": -329.56, "pricing": { "level": "Normalpreis", "levelNumber": "1", "category": "Kat. 7", "categoryNumber": "7" }, "priceComponents": [ { "type": "NET_PRICE", "amount": -329.56 } ] } ], "seasonTickets": [], "packages": [], "fees": [ { "amount": 2.00, "type": "RESALE", "detailType": "RESALE_FEE" } ], "custom": {}}{ "type": "object", "$schema": "http://json-schema.org/draft-07/schema#", "properties": { "metadata": { "type": "object", "properties": { "traceId": { "type": "string", "format": "uuid", "description": "Unique identifier to trace the event." }, "occurredAt": { "type": "string", "format": "date-time", "description": "The timestamp when the event occurred." }, "version": { "type": "string", "pattern": "^[0-9]+\\.[0-9]+$", "description": "The version of the event schema, following semantic versioning." }, "tenant": { "type": "string", "description": "Identifier of the tenant or organization associated with the event." }, "type": { "type": "string", "enum": [ "CUSTOMER", "CUSTOMER_DELETED", "EVENT", "EVENT_CAPACITY", "ORDER", "CANCELLATION", "CREDIT_NOTE", "RESERVATION", "RESERVATION_CANCELLATION", "PRICE_PROFILE", "PRICE_PROFILE_DELETED", "TICKET" ], "description": "Identifier of the tenant or organization associated with the event." } }, "required": [ "traceId", "occurredAt", "version", "tenant", "type" ], "additionalProperties": false }, "customerId": { "type": "string" }, "creditNoteId": { "type": "string" }, "orderId": { "type": "string" }, "creditedAmount": { "type": "number" }, "includedVatAmount": { "type": "number" }, "currency": { "type": "string" }, "paymentType": { "type": "string", "enum": [ "CASH", "EC", "VISA", "MASTERCARD", "POSTCARD", "CHECK", "AMEX", "AMEX_VOUCHER", "DINERS_CLUB", "HOUSE_BILL", "BANK_TRANSFER", "DIRECT_DEBIT", "CREDIT_CARD", "BILL", "PAYPAL", "SOFORTUEBERWEISUNG", "KLARNA", "NONE", "UNKNOWN" ] }, "creditedDateTime": { "type": "string", "format": "date-time", "description": "\"ISO 8601 formatted date and time of the credit note.", "examples": [ "2024-03-01T19:30:00Z" ] }, "singleTickets": { "type": "array", "description": "Array of tickets included in the credit note.", "items": { "$ref": "#/definitions/Ticket" } }, "seasonTickets": { "type": "array", "description": "Array of season tickets included in the credit note.", "items": { "$ref": "#/definitions/Ticket" } }, "packages": { "type": "array", "description": "Array of packages included in the credit note.", "items": { "$ref": "#/definitions/Package" } }, "articles": { "type": "array", "description": "Array of articles included in the credit note.", "items": { "$ref": "#/definitions/Article" } }, "fees": { "type": "array", "items": { "type": "object", "properties": { "amount": { "type": "number", "description": "The monetary value of the fee.", "examples": [ "0.25" ] }, "feeType": { "type": "string", "enum": [ "SHIPPING", "RESALE", "ADDITIONAL", "CANCELLATION", "SALE", "UNKNOWN" ], "description": "The type of fee being applied.", "examples": [ "RESALE" ] }, "detailType": { "type": "string", "enum": [ "ARTICLE_COMMISSION", "NET_PRICE", "ADVANCE_BOOKING_FEE", "SYSTEM_FEE", "DELIVERY_FEE", "ADDITIONAL_FEES", "FEE_1", "FEE_2", "FEE_3", "FEE_4", "FEE_5", "FEE_6", "REFUND_FEE", "RESALE_FEE", "RESALE_PURCHASE_FEE", "CANCELLATION_FEE", "DISCOUNT", "CREDIT", "CREDIT_VOUCHER", "COUPON_RESIDUAL_DISCHARGE", "UNKNOWN" ], "description": "The component type associated with the fee.", "examples": [ "ADVANCE_BOOKING_FEE" ] } }, "required": [ ] }, "description": "An array of credit note fees, each with an amount, type, and price component type." }, "custom": { "type": "object", "description": "Custom data object" } }, "definitions": { "Ticket": { "type": "object", "properties": { "positionId": { "type": "string", "description": "Identifier of the position within the order/credit note.", "examples": [ "POS124800101" ] }, "eventId": { "type": "string", "description": "Unique identifier for the event.", "examples": [ "987654" ] }, "seat": { "type": "object", "description": "Seating details for the ticket.", "properties": { "blockId": { "type": "string", "description": "Block id", "examples": [ "1337" ] }, "block": { "type": "string", "description": "Block name within the venue.", "examples": [ "Block A" ] }, "row": { "type": "string", "description": "Row identifier within the block.", "examples": [ "5" ] }, "seat": { "type": "string", "description": "Seat identifier within the row.", "examples": [ "42" ] }, "areaId": { "type": "string", "description": "Area identifier.", "examples": [ "98765" ] } } }, "price": { "type": "number", "description": "Price of the ticket.", "examples": [ 49.99 ] }, "pricing": { "type": "object", "description": "Details about pricing structure.", "properties": { "level": { "type": "string", "description": "Price level of the ticket.", "examples": [ "Normalpreis" ] }, "levelNumber": { "type": "string", "description": "Number/index of the price profile level", "examples": [ "1", "2" ] }, "category": { "type": "string", "description": "Price category of the ticket.", "examples": [ "1. Kategorie" ] }, "categoryNumber": { "type": "string", "description": "Number/Index of the category within the price profile.", "examples": [ "1", "5" ] } } }, "priceComponents": { "type": "array", "items": { "type": "object", "properties": { "priceComponentType": { "type": "string", "enum": [ "ARTICLE_COMMISSION", "NET_PRICE", "ADVANCE_BOOKING_FEE", "SYSTEM_FEE", "DELIVERY_FEE", "ADDITIONAL_FEES", "FEE_1", "FEE_2", "FEE_3", "FEE_4", "FEE_5", "FEE_6", "REFUND_FEE", "RESALE_FEE", "RESALE_PURCHASE_FEE", "CANCELLATION_FEE", "DISCOUNT", "CREDIT", "CREDIT_VOUCHER", "COUPON_RESIDUAL_DISCHARGE", "UNKNOWN" ], "description": "The type of the price component.", "examples": [ "ADVANCE_BOOKING_FEE", "NET_PRICE" ] }, "amount": { "type": "number", "description": "The monetary value of the price component.", "examples": [ 0.69 ] } }, "required": [ ] }, "description": "An array of price components, each with a type and amount." } }, "required": [] }, "Article": { "type": "object", "properties": { "articleId": { "type": "string", "description": "Identifier of the position within the credit note.", "examples": [ "5641587" ] }, "positionId": { "type": "string", "description": "Position identifier within the credit note for the article.", "examples": [ "POS171942728" ] }, "price": { "type": "number", "description": "Price of the article.", "examples": [ 24.99 ] }, "name": { "type": "string", "description": "Name of the article.", "examples": [ "Fan T-Shirt", "Tasse" ] } }, "required": [] }, "Package": { "type": "object", "properties": { "positionId": { "type": "string", "description": "Identifier of the position within the credit note.", "examples": [ "POS171942728" ] }, "ticket": { "type": "object", "description": "Array of ticket positions included in the credit note.", "$ref": "#/definitions/Ticket" }, "price": { "type": "number", "description": "Price of the article.", "examples": [ 24.99 ] }, "articles": { "type": "array", "description": "Array of ticket positions included in the credit note.", "items": { "$ref": "#/definitions/Article" } } }, "required": [] } }, "required": [ "orderId", "creditNoteId", "metadata" ], "additionalProperties": false}