PayID Resolution
code examples curl request post \\ \ url https //api monoova com/au/core/payman v1/payid/payidresolution \\ \ header 'accept application/json' \\ \ header 'content type application/json' \\ \ data raw '{ "payid" "john smith\@monoova com", "payidtype" "email" }'var myheaders = new headers(); myheaders append("accept", "application/json"); myheaders append("content type", "application/json"); var raw = json stringify({ "payid" "john smith\@monoova com", "payidtype" "email" }); var requestoptions = { method 'post', headers myheaders, body raw, redirect 'follow' }; fetch("https //api monoova com/au/core/payman v1/payid/payidresolution", 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 monoova com/au/core/payman v1/payid/payidresolution") 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 body = json dump({ "payid" "john smith\@monoova com", "payidtype" "email" }) response = https request(request) puts response read body import requests import json url = "https //api monoova com/au/core/payman v1/payid/payidresolution" payload = json dumps({ "payid" "john smith\@monoova com", "payidtype" "email" }) headers = { 'accept' 'application/json', 'content type' 'application/json' } response = requests request("post", url, headers=headers, data=payload) print(response text) responses // ok the request was processed successfully and the payid resolution result is returned { "traceid" "0hmv9k2p4n7qt 00000001", "errors" \[ { "errorcode" "payid invalid format", "errormessage" "the supplied payid does not match the expected payidtype format ", "sourceerrorcode" "npp 1001", "sourceerrormessage" "payid format rejected by the addressing service " } ], "payidname" "john smith", "payidregistered" "2024 03 18t09 15 00z", "bankaccountnumber" "123456789" }// bad request the request payload failed validation, for example the payid does not match the format expected for the supplied payidtype { "traceid" "0hmv9k2p4n7qt 00000002", "errors" \[ { "errorcode" "payid invalid format", "errormessage" "the supplied payid does not match the expected payidtype format ", "sourceerrorcode" "npp 1001", "sourceerrormessage" "payid format rejected by the addressing service " } ] }// unauthorized the bearer token is missing, malformed, or has expired generate a new token and retry the request { "traceid" "0hmv9k2p4n7qt 00000002", "errors" \[ { "errorcode" "payid invalid format", "errormessage" "the supplied payid does not match the expected payidtype format ", "sourceerrorcode" "npp 1001", "sourceerrormessage" "payid format rejected by the addressing service " } ] }// internal server error the request could not be completed due to an unexpected condition retry using the same traceid when contacting support { "traceid" "0hmv9k2p4n7qt 00000002", "errors" \[ { "errorcode" "payid invalid format", "errormessage" "the supplied payid does not match the expected payidtype format ", "sourceerrorcode" "npp 1001", "sourceerrormessage" "payid format rejected by the addressing service " } ] }