Rejected Transactions Report
GET
https://api.mpay.com.au/receivables/v2/rejectedTransactions/{date}
Path Parameters
- datestringrequiredExampleDescriptionDefault20200918000000Pattern^\d{4}(0[1-9]|1[0-2])(0[1-9]|[12]\d|3[01])([01]\d|2[0-3])[0-5]\d[0-5]\d$
Query Parameters
- endDatestringExampleDescriptionDefault20200918235959Pattern^\d{4}(0[1-9]|1[0-2])(0[1-9]|[12]\d|3[01])([01]\d|2[0-3])[0-5]\d[0-5]\d$
- transactionTypestringExampleDescriptionDefaultNPPPattern^(DE|NPP)$
- pageNumberstringExampleDescriptionDefault1Pattern^[1-9]\d{0,8}$
- pageSizestringExampleDescriptionDefault50Pattern^([1-9]|[1-9]\d|1\d{2}|200)$
Header Parameters
- acceptstringDescriptionDefaulttext/csvAllowedtext/csvapplication/json
Responses
200
400
- badRequestResponse_V2Example
{ "durationMs": 4, "status": "Error", "statusDescription": "The date supplied is invalid. Provide the date in yyyyMMddHHmmss format, for example 20200918000000." }Description- durationMsinteger<int64>ExampleDescriptionDefault4Formatint64Pattern^\d{1,10}$
- statusstringExampleDescriptionDefaultErrorPattern^[A-Za-z]{2,50}$
- statusDescriptionstringExampleDescriptionDefaultThe date supplied is invalid. Provide the date in yyyyMMddHHmmss format, for example 20200918000000.Pattern^.{1,500}$
401
- unauthorisedResponse_V2Example
{ "durationMs": 2, "status": "Unauthorized", "statusDescription": "Authentication failed. Supply a valid API key as the basic authentication username." }Description- durationMsinteger<int64>ExampleDescriptionDefault2Formatint64Pattern^\d{1,10}$
- statusstringExampleDescriptionDefaultUnauthorizedPattern^[A-Za-z]{2,50}$
- statusDescriptionstringExampleDescriptionDefaultAuthentication failed. Supply a valid API key as the basic authentication username.Pattern^.{1,500}$
500
- internalServerErrorResponse_V2Example
{ "durationMs": 118, "status": "Error", "statusDescription": "An unexpected error occurred while processing the request. Please try again later." }Description- durationMsinteger<int64>ExampleDescriptionDefault118Formatint64Pattern^\d{1,10}$
- statusstringExampleDescriptionDefaultErrorPattern^[A-Za-z]{2,50}$
- statusDescriptionstringExampleDescriptionDefaultAn unexpected error occurred while processing the request. Please try again later.Pattern^.{1,500}$
curl
curl --request GET \
--url 'https://api.mpay.com.au/receivables/v2/rejectedTransactions/{date}?endDate=20200918235959&transactionType=NPP&pageNumber=1&pageSize=50' \
--header 'accept: text/csv'javascript
var myHeaders = new Headers();
myHeaders.append("accept", "text/csv");
myHeaders.append("content-type", "application/json");
var requestOptions = {
method: 'GET',
headers: myHeaders,
redirect: 'follow'
};
fetch("https://api.mpay.com.au/receivables/v2/rejectedTransactions/{date}?endDate=20200918235959&transactionType=NPP&pageNumber=1&pageSize=50", requestOptions)
.then(response => response.text())
.then(result => console.log(result))
.catch(error => console.log('error', error));ruby
require "uri"
require "json"
require "net/http"
url = URI("https://api.mpay.com.au/receivables/v2/rejectedTransactions/{date}?endDate=20200918235959&transactionType=NPP&pageNumber=1&pageSize=50")
https = Net::HTTP.new(url.host, url.port)
https.use_ssl = true
request = Net::HTTP::Get.new(url)
request["accept"] = "text/csv"
request["content-type"] = "application/json"
response = https.request(request)
puts response.read_body
python
import requests
import json
url = "https://api.mpay.com.au/receivables/v2/rejectedTransactions/{date}?endDate=20200918235959&transactionType=NPP&pageNumber=1&pageSize=50"
payload = {}
headers = {
'accept': 'text/csv',
'content-type': 'application/json'
}
response = requests.request("GET", url, headers=headers, data=payload)
print(response.text)
200
// Successful validation. The rejected transactions report was generated and is returned as comma-separated values (CSV): a header row followed by one row per rejected transaction. The schema below describes each column, in the order the columns appear.
400
// Bad request. One or more parameters failed validation, for example a date or endDate that is not in yyyyMMddHHmmss format.
{
"durationMs": 4,
"status": "Error",
"statusDescription": "The date supplied is invalid. Provide the date in yyyyMMddHHmmss format, for example 20200918000000."
}401
// Unauthorised. The API key supplied as the basic authentication username is missing or invalid. In the live environment, the Sign-In Account is locked for one hour after five failed authentication attempts.
{
"durationMs": 2,
"status": "Unauthorized",
"statusDescription": "Authentication failed. Supply a valid API key as the basic authentication username."
}500
// Internal server error. An unexpected error prevented the Platform from generating the report. Retry the request and contact Monoova support if the error persists.
{
"durationMs": 118,
"status": "Error",
"statusDescription": "An unexpected error occurred while processing the request. Please try again later."
}