{"templateId":"markdown","sharedDataIds":{"sidebar":"sidebar-@l10n/en/sidebars.yaml"},"props":{"metadata":{"markdoc":{"tagList":["admonition"]},"type":"markdown"},"seo":{"title":"Event: transaction:status_changed","description":"Znajdziesz tutaj wszystkie niezbędne informacje dotyczące integracji i obsługi systemu płatności SimPay.pl","siteUrl":"https://docs.simpay.pl"},"dynamicMarkdocComponents":[],"compilationErrors":[],"ast":{"$$mdtype":"Tag","name":"article","attributes":{},"children":[{"$$mdtype":"Tag","name":"Heading","attributes":{"level":1,"id":"event-transactionstatus_changed","__idx":0},"children":["Event: transaction:status_changed"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["The ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["transaction:status_changed"]}," event is the most important element of online payment integration. It informs your system about every change in the state (lifecycle) of a specific transaction initiated by the customer."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["It is based on this event that your store should make business decisions – e.g., deliver the purchased goods to the customer (when the status changes to paid) or restore products to inventory (when the payment expires or is rejected)."]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"when-is-this-event-sent","__idx":1},"children":["When Is This Event Sent?"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["This notification is triggered asynchronously every time a payment transaction moves to a new stage in the SimPay system. You will receive it, among others, when:"]},{"$$mdtype":"Tag","name":"ul","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["The bank or operator ultimately confirms receipt of funds (change to ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["transaction_paid"]}," status)."]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["The payment attempt is rejected by the customer's bank due to insufficient funds (change to ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["transaction_failure"]},")."]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["The customer does not pay for the order within the designated time and the payment gateway is closed (change to ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["transaction_expired"]},")."]}]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"data-object-structure","__idx":2},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["data"]}," Object Structure"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["When the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["type"]}," field in the main notification object has the value ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["transaction:status_changed"]},", the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["data"]}," object will contain the following information:"]},{"$$mdtype":"Tag","name":"div","attributes":{"className":"md-table-wrapper"},"children":[{"$$mdtype":"Tag","name":"table","attributes":{"className":"md"},"children":[{"$$mdtype":"Tag","name":"thead","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"th","attributes":{"align":"left","data-label":"Field"},"children":["Field"]},{"$$mdtype":"Tag","name":"th","attributes":{"align":"left","data-label":"Type"},"children":["Type"]},{"$$mdtype":"Tag","name":"th","attributes":{"align":"left","data-label":"Description"},"children":["Description"]},{"$$mdtype":"Tag","name":"th","attributes":{"align":"left","data-label":"Example Value"},"children":["Example Value"]}]}]},{"$$mdtype":"Tag","name":"tbody","attributes":{},"children":[{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["id"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["UUID"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["Transaction ID sent after generating the transaction"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["00554475-7ebb-4f16-b30b-0ce21da1a03b"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["payer_transaction_id"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["char(8)"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["Transaction ID shown to the payer on the gateway screen"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["4878R2PN"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["service_id"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["char(8)"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["Service identifier (in SimPay Flow - parent service ID)"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["e65c7519"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["status"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["TransactionStatusEnum"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["Current ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/payment/statuses#statusGroup=Transaction+Statuses"},"children":["transaction status"]}," (e.g., ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["transaction_paid"]},", ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["transaction_failure"]},")"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["transaction_paid"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["amount"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["object"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["Amount information object"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["amount.final_currency"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["ISO 4217"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["Currency in which the payer made the payment"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["PLN"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["amount.final_value"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["string"]}," (%.2f)"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["Final amount paid by the payer (e.g., \"0.30\", \"10.00\", \"12.37\")"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["8.47"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["amount.original_currency"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["ISO 4217"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["Currency declared at payment initiation"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["EUR"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["amount.original_value"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["string"]}," (%.2f)"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["Amount declared at payment initiation (e.g., \"0.30\", \"10.00\", \"12.37\")"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["2.00"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["amount.commission_system"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["string"]}," (%.2f) or ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["null"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["Commission amount charged by SimPay (e.g., \"0.30\", \"10.00\", \"12.37\")"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["0.13"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["amount.commission_partner"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["string"]}," (%.2f) or ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["null"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["Commission amount for the Partner (e.g., \"0.30\", \"10.00\", \"12.37\")"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["0.13"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["amount.commission_currency"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["ISO 4217"]}," or ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["null"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["Currency in which the commission was charged (PLN/EUR)"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["PLN"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["amount.commission_flow"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["string"]}," (%.2f) or absent"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/simpay-flow/commissions"},"children":["SimPay Flow"]}," commission (submerchant transactions only, when greater than zero)"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["0.25"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["control"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["string"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["Field sent only when it was passed during payment initiation"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["SHOP_ORDER_1"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["payment"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["object"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["Payment method information field"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["payment.channel"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["string"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["Payment channel used by the payer (see: ",{"$$mdtype":"Tag","name":"em","attributes":{},"children":["Direct Channels"]},")"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["blik"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["payment.type"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["string"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["Type/group of payment method"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["blik"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["customer"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["object"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["Payer information object"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["customer.country_code"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["ISO 3166-1 Alpha-2"]}," or ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["null"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["Buyer's country (e.g., \"PL\")"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["PL"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["paid_at"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["ISO 8601"]}," or ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["null"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["Payment date and time (may not be sent when the transaction is not paid)"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["2025-05-26T15:10:24Z"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["created_at"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["ISO 8601"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["Transaction creation date and time"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["2025-05-26T15:09:59Z"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["flow"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["object"]}," or absent"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["Only for ",{"$$mdtype":"Tag","name":"MarkdownLink","attributes":{"href":"/simpay-flow/webhooks#payment-webhooks-ipn-in-simpay-flow"},"children":["SimPay Flow"]}," submerchants"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["flow.submerchant_id"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["string"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["Submerchant ID"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["flsm_aaaabbbb"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["flow.submerchant_custom_id"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["string"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["Submerchant ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["customId"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["user-123"]}]}]},{"$$mdtype":"Tag","name":"tr","attributes":{},"children":[{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["flow.flow_service_id"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["string"]}]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":["Flow service ID"]},{"$$mdtype":"Tag","name":"td","attributes":{"align":"left"},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["flow_aaaabbbb"]}]}]}]}]}]},{"$$mdtype":"Tag","name":"Admonition","attributes":{"type":"info","name":"Tip"},"children":[{"$$mdtype":"Tag","name":"p","attributes":{},"children":["To check order payment, always verify the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["status"]}," field. The expected value for a successfully"," ","completed process is ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["transaction_paid"]}]},". You should also absolutely check that ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["amount.original_value"]}," and"," ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["amount.original_currency"]}," match the amount stored in your database for the given order."]}]},{"$$mdtype":"Tag","name":"hr","attributes":{},"children":[]},{"$$mdtype":"Tag","name":"Heading","attributes":{"level":2,"id":"example-json-payload","__idx":3},"children":["Example JSON Payload"]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Below is a complete dump (payload) of the notification sent for the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["transaction:status_changed"]}," event (in"," ","this case a rejected transaction – ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["transaction_failure"]},")."]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":[{"$$mdtype":"Tag","name":"em","attributes":{},"children":["(The example signature was generated using the IPN key: ",{"$$mdtype":"Tag","name":"strong","attributes":{},"children":[{"$$mdtype":"Tag","name":"code","attributes":{},"children":["UwSkKiIwlxIeOMF8MIq9iDkQWBTtjoJQ"]}]},". You can use this key and the data below to test your validation algorithm)."]}]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"json","header":{"controls":{"copy":{}}},"source":"{\n  \"type\": \"transaction:status_changed\",\n  \"notification_id\": \"0196fec6-7a61-7219-9458-bcc45237c252\",\n  \"date\": \"2025-05-23T22:12:22+02:00\",\n  \"data\": {\n    \"id\": \"dbc87423-b121-4ad4-977f-b63c3d3831e8\",\n    \"payer_transaction_id\": \"Q68KLAKN\",\n    \"service_id\": \"e65c7519\",\n    \"status\": \"transaction_failure\",\n    \"amount\": {\n      \"final_currency\": \"PLN\",\n      \"final_value\": \"8.00\",\n      \"original_currency\": \"PLN\",\n      \"original_value\": \"8.00\",\n      \"commission_system\": \"0.06\",\n      \"commission_partner\": \"7.94\",\n      \"commission_currency\": \"PLN\"\n    },\n    \"control\": \"3e63e31d-f08d-4942-a223-3bad2dce8096\",\n    \"payment\": {\n      \"channel\": \"blik\",\n      \"type\": \"blik\"\n    },\n    \"customer\": {\n      \"country_code\": null\n    },\n    \"created_at\": \"2024-08-10T15:41:50+02:00\"\n  },\n  \"signature\": \"095a7be5d77c4bab667dbd0f35d9b1cb0c9cec50d8af42842cc37a95b233925e\"\n}\n","lang":"json"},"children":[]},{"$$mdtype":"Tag","name":"details","attributes":{},"children":[{"$$mdtype":"Tag","name":"summary","attributes":{},"children":["See signature calculation"]},{"$$mdtype":"Tag","name":"ol","attributes":{},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Flatten all elements sequentially + ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["|"]}," separation:"]}]},{"$$mdtype":"Tag","name":"p","attributes":{},"children":["Our string will look like this:"]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"header":{"controls":{"copy":{}}},"source":"transaction:status_changed|0196fec6-7a61-7219-9458-bcc45237c252|2025-05-23T22:12:22+02:00|dbc87423-b121-4ad4-977f-b63c3d3831e8|Q68KLAKN|e65c7519|transaction_failure|PLN|8.00|PLN|8.00|0.06|7.94|PLN|3e63e31d-f08d-4942-a223-3bad2dce8096|blik|blik||2024-08-10T15:41:50+02:00\n"},"children":[]},{"$$mdtype":"Tag","name":"ol","attributes":{"start":2},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Append the IPN key at the end of the string:"," ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["...|UwSkKiIwlxIeOMF8MIq9iDkQWBTtjoJQ"]}]},{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Calculate SHA256 from the above string and encode it in hex:"]}]},{"$$mdtype":"Tag","name":"CodeBlock","attributes":{"data-language":"php","header":{"controls":{"copy":{}}},"source":"<?php\n\n$signature = hash('sha256', 'transaction:status_changed|0196fec6-7a61-7219-9458-bcc45237c252|2025-05-23T22:12:22+02:00|dbc87423-b121-4ad4-977f-b63c3d3831e8|Q68KLAKN|e65c7519|transaction_failure|PLN|8.00|PLN|8.00|0.06|7.94|PLN|3e63e31d-f08d-4942-a223-3bad2dce8096|blik|blik||2024-08-10T15:41:50+02:00|UwSkKiIwlxIeOMF8MIq9iDkQWBTtjoJQ');\n","lang":"php"},"children":[]},{"$$mdtype":"Tag","name":"ol","attributes":{"start":4},"children":[{"$$mdtype":"Tag","name":"li","attributes":{},"children":["Compare using a secure comparison function (e.g., ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["hash_equals"]}," in PHP) the calculated signature with the one sent in the ",{"$$mdtype":"Tag","name":"code","attributes":{},"children":["signature"]}," field of the notification."]}]}]}]},"headings":[{"value":"Event: transaction:status_changed","id":"event-transactionstatus_changed","depth":1},{"value":"When Is This Event Sent?","id":"when-is-this-event-sent","depth":2},{"value":"data Object Structure","id":"data-object-structure","depth":2},{"value":"Example JSON Payload","id":"example-json-payload","depth":2}],"frontmatter":{"seo":{"title":"Event: transaction:status_changed"}},"lastModified":"2026-10-01T15:18:54.000Z","pagePropGetterError":{"message":"","name":""}},"slug":"/en/notifications/payment/events/transaction_status_changed","userData":{"isAuthenticated":false,"teams":["anonymous"]},"isPublic":true}