List sources groupable in one payment receipt
curl --request GET \
--url https://api.piriod.com/payment-receipts/candidates/ \
--header 'Authorization: <api-key>' \
--header 'x-simple-workspace: <x-simple-workspace>'import requests
url = "https://api.piriod.com/payment-receipts/candidates/"
headers = {
"x-simple-workspace": "<x-simple-workspace>",
"Authorization": "<api-key>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {'x-simple-workspace': '<x-simple-workspace>', Authorization: '<api-key>'}
};
fetch('https://api.piriod.com/payment-receipts/candidates/', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.piriod.com/payment-receipts/candidates/",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>",
"x-simple-workspace: <x-simple-workspace>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.piriod.com/payment-receipts/candidates/"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-simple-workspace", "<x-simple-workspace>")
req.Header.Add("Authorization", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.piriod.com/payment-receipts/candidates/")
.header("x-simple-workspace", "<x-simple-workspace>")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.piriod.com/payment-receipts/candidates/")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-simple-workspace"] = '<x-simple-workspace>'
request["Authorization"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"results": [
{
"source": "<string>",
"payment": "<string>",
"invoice": {
"id": "<string>",
"number": 123,
"currency": "<string>",
"total": 123
},
"amount": 123,
"received_currency": "<string>",
"received_amount": 123,
"exchange_rate": 123,
"payment_date": "2023-12-25"
}
]
}{
"name": [
"This field is required."
],
"non_field_errors": [
"x-simple-workspace header is required."
]
}{
"detail": "Authentication credentials were not provided."
}Payment receipts
List sources groupable in one payment receipt
Sources that can share a payment receipt with source: same customer,
same payment date and received currency, eligible invoice and no
current receipt. Includes source itself.
GET
/
payment-receipts
/
candidates
/
List sources groupable in one payment receipt
curl --request GET \
--url https://api.piriod.com/payment-receipts/candidates/ \
--header 'Authorization: <api-key>' \
--header 'x-simple-workspace: <x-simple-workspace>'import requests
url = "https://api.piriod.com/payment-receipts/candidates/"
headers = {
"x-simple-workspace": "<x-simple-workspace>",
"Authorization": "<api-key>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {'x-simple-workspace': '<x-simple-workspace>', Authorization: '<api-key>'}
};
fetch('https://api.piriod.com/payment-receipts/candidates/', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.piriod.com/payment-receipts/candidates/",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: <api-key>",
"x-simple-workspace: <x-simple-workspace>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.piriod.com/payment-receipts/candidates/"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-simple-workspace", "<x-simple-workspace>")
req.Header.Add("Authorization", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.piriod.com/payment-receipts/candidates/")
.header("x-simple-workspace", "<x-simple-workspace>")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.piriod.com/payment-receipts/candidates/")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-simple-workspace"] = '<x-simple-workspace>'
request["Authorization"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"results": [
{
"source": "<string>",
"payment": "<string>",
"invoice": {
"id": "<string>",
"number": 123,
"currency": "<string>",
"total": 123
},
"amount": 123,
"received_currency": "<string>",
"received_amount": 123,
"exchange_rate": 123,
"payment_date": "2023-12-25"
}
]
}{
"name": [
"This field is required."
],
"non_field_errors": [
"x-simple-workspace header is required."
]
}{
"detail": "Authentication credentials were not provided."
}