Notification Webhooks
API
/token-updated
1 min
code examples curl location 'https //endpoint yourdomain com/token updated' \\ \ header 'accept application/json' \\ \ header 'content type application/json' \\ \ header 'signature +jwkfq4ynalk+ffzgghnp1jsmqjmbjeb87dlph24sxw=' \\ \ data '{ "token" "ftr1d8a56cfa6b3745a39e4a42d5ab1048c8", "card" { "bin" "123456", "lastfourdigits" "1234", "expiration" "1747305600000", "state" "active" }, "networktoken" { "networktoken" "5200828282828210", "expiration" "1747305600000", "paymentaccountreference" "a23b45c67d89e01f23g45h67i89j0", "state" "active" }, "source" "au", "updatedfields" { "paymentaccountreference" "a23b45c67d89e01f23g45h67i89j0", "networktokenexpirationmonth" "12", "networktokenexpirationyear" "2025", "networktokenstate" "active", "lastfourdigits" "1234", "expirationmonth" "12", "expirationyear" "2025", "cardstate" "active" }, "cardart" "ivborw0kggoaaaansuheugaaaaeaaaabcayaaaaffcsjaaaaduleqvr42mp8/5+hhgaggwj/ lmfr3waaaabjru5erkjggg==", "timestamp" "1747305600000" }'var myheaders = new headers(); myheaders append("accept", "application/json"); myheaders append("content type", "application/json"); myheaders append("signature", "+jwkfq4ynalk+ffzgghnp1jsmqjmbjeb87dlph24sxw="); var raw = json stringify({ "token" "ftr1d8a56cfa6b3745a39e4a42d5ab1048c8", "card" { "bin" "123456", "lastfourdigits" "1234", "expiration" "1747305600000", "state" "active" }, "networktoken" { "networktoken" "5200828282828210", "expiration" "1747305600000", "paymentaccountreference" "a23b45c67d89e01f23g45h67i89j0", "state" "active" }, "source" "au", "updatedfields" { "paymentaccountreference" "a23b45c67d89e01f23g45h67i89j0", "networktokenexpirationmonth" "12", "networktokenexpirationyear" "2025", "networktokenstate" "active", "lastfourdigits" "1234", "expirationmonth" "12", "expirationyear" "2025", "cardstate" "active" }, "cardart" "ivborw0kggoaaaansuheugaaaaeaaaabcayaaaaffcsjaaaaduleqvr42mp8/5+hhgaggwj/ lmfr3waaaabjru5erkjggg==", "timestamp" "1747305600000" }); var requestoptions = { method 'post', headers myheaders, body raw, redirect 'follow' }; fetch("https //endpoint yourdomain com/token updated", requestoptions) then(response => response text()) then(result => console log(result)) catch(error => console log('error', error));require "uri" require "json" require "net/http" url = uri("https //endpoint yourdomain com/token updated") https = net http new(url host, url port) https use ssl = true request = net http post new(url) request\["accept"] = "application/json" request\["content type"] = "application/json" request\["signature"] = "+jwkfq4ynalk+ffzgghnp1jsmqjmbjeb87dlph24sxw=" request body = json dump({ "token" "ftr1d8a56cfa6b3745a39e4a42d5ab1048c8", "card" { "bin" "123456", "lastfourdigits" "1234", "expiration" "1747305600000", "state" "active" }, "networktoken" { "networktoken" "5200828282828210", "expiration" "1747305600000", "paymentaccountreference" "a23b45c67d89e01f23g45h67i89j0", "state" "active" }, "source" "au", "updatedfields" { "paymentaccountreference" "a23b45c67d89e01f23g45h67i89j0", "networktokenexpirationmonth" "12", "networktokenexpirationyear" "2025", "networktokenstate" "active", "lastfourdigits" "1234", "expirationmonth" "12", "expirationyear" "2025", "cardstate" "active" }, "cardart" "ivborw0kggoaaaansuheugaaaaeaaaabcayaaaaffcsjaaaaduleqvr42mp8/5+hhgaggwj/ lmfr3waaaabjru5erkjggg==", "timestamp" "1747305600000" }) response = https request(request) puts response read body import requests import json url = "https //endpoint yourdomain com/token updated" payload = json dumps({ "token" "ftr1d8a56cfa6b3745a39e4a42d5ab1048c8", "card" { "bin" "123456", "lastfourdigits" "1234", "expiration" "1747305600000", "state" "active" }, "networktoken" { "networktoken" "5200828282828210", "expiration" "1747305600000", "paymentaccountreference" "a23b45c67d89e01f23g45h67i89j0", "state" "active" }, "source" "au", "updatedfields" { "paymentaccountreference" "a23b45c67d89e01f23g45h67i89j0", "networktokenexpirationmonth" "12", "networktokenexpirationyear" "2025", "networktokenstate" "active", "lastfourdigits" "1234", "expirationmonth" "12", "expirationyear" "2025", "cardstate" "active" }, "cardart" "ivborw0kggoaaaansuheugaaaaeaaaabcayaaaaffcsjaaaaduleqvr42mp8/5+hhgaggwj/ lmfr3waaaabjru5erkjggg==", "timestamp" "1747305600000" }) headers = { 'accept' 'application/json', 'content type' 'application/json', 'signature' '+jwkfq4ynalk+ffzgghnp1jsmqjmbjeb87dlph24sxw=' } response = requests request("post", url, headers=headers, data=payload) print(response text) responses