Resend an Existing Webhook Notification
code examples curl request post \\ \ url https //api mpay com au/subscriptions/v2/resend/{id} \\ \ header 'accept application/json'var myheaders = new headers(); myheaders append("accept", "application/json"); myheaders append("content type", "application/json"); var requestoptions = { method 'post', headers myheaders, redirect 'follow' }; fetch("https //api mpay com au/subscriptions/v2/resend/{id}", 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 //api mpay com au/subscriptions/v2/resend/{id}") 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" response = https request(request) puts response read body import requests import json url = "https //api mpay com au/subscriptions/v2/resend/{id}" payload = {} headers = { 'accept' 'application/json', 'content type' 'application/json' } response = requests request("post", url, headers=headers, data=payload) print(response text) responses // success the notification was queued for resending and the processing result is returned { "durationms" 213, "status" "ok", "statusdescription" "operation completed successfully", "debug" { "signinmaccountdetails" "maccount 4210000000 (active)", "finalsigninmaccountfinancials" "balance 15000 00, available 15000 00", "initialsigninmaccountfinancials" "balance 15000 00, available 15000 00", "tracelogid" "8f3c1d92 5b47 4a10 9f2e 6c7d81ab0e55", "exceptionid" 40312, "exceptionmsg" "notification could not be resent because the subscription is inactive " } }// bad request the request could not be processed because one or more fields are missing, malformed, or failed validation check the statusdescription for the field at fault, correct it and retry { "durationms" 12, "status" "error", "statusdescription" "validation failed targeturl is required and must be a valid url " }// unauthorized the request did not include valid basic authentication credentials, or the api key supplied is inactive or not permitted to use this endpoint confirm the api key is passed as the basic authentication username and retry { "durationms" 12, "status" "error", "statusdescription" "validation failed targeturl is required and must be a valid url " }// internal server error an unexpected error occurred while processing the request the request may not have been completed — do not assume the subscription changed retry the request and, if the error persists, contact monoova support quoting the statusdescription { "durationms" 12, "status" "error", "statusdescription" "validation failed targeturl is required and must be a valid url " }