Listar faturas pendentes e vencidas
curl --request GET \
--url https://api.pipo.health/v1/invoices/pending-payment \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.pipo.health/v1/invoices/pending-payment"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.pipo.health/v1/invoices/pending-payment', 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.pipo.health/v1/invoices/pending-payment",
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: Bearer <token>"
],
]);
$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.pipo.health/v1/invoices/pending-payment"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
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.pipo.health/v1/invoices/pending-payment")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.pipo.health/v1/invoices/pending-payment")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"result": [
{
"id": "inv-2024-02-000456",
"company-id": "123e4567-e89b-12d3-a456-426614174000",
"invoice-config-id": "456e7890-e89b-12d3-a456-426614174007",
"company-name": "Acme Corporation",
"carrier-name": "HealthCorp",
"amount": 987650,
"due-date": "2024-03-10",
"reference-period-start": "2024-02-01",
"reference-period-end": "2024-02-29",
"invoice-status": "all-overdue",
"files": [
{
"file-id": "aaa11111-e89b-12d3-a456-426614174009",
"name": "boleto-02.pdf",
"type": "payment-slip",
"payment-slip-due-date": "2024-03-10",
"status": "overdue"
}
]
}
],
"pagination": {
"current-page": 1,
"total-items": 1,
"total-pages": 1,
"next-page": null,
"previous-page": null
}
}{
"error": "Invalid date filter: 'until-dt' must be greater than 'from-dt'"
}Faturas pendentes e vencidas
Lista as faturas com pagamento pendente ou vencido de todas as empresas às quais o cliente tem acesso. Sem filtro de data, retorna todas as faturas pendentes/vencidas.
GET
/
v1
/
invoices
/
pending-payment
Listar faturas pendentes e vencidas
curl --request GET \
--url https://api.pipo.health/v1/invoices/pending-payment \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.pipo.health/v1/invoices/pending-payment"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.pipo.health/v1/invoices/pending-payment', 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.pipo.health/v1/invoices/pending-payment",
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: Bearer <token>"
],
]);
$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.pipo.health/v1/invoices/pending-payment"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
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.pipo.health/v1/invoices/pending-payment")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.pipo.health/v1/invoices/pending-payment")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"result": [
{
"id": "inv-2024-02-000456",
"company-id": "123e4567-e89b-12d3-a456-426614174000",
"invoice-config-id": "456e7890-e89b-12d3-a456-426614174007",
"company-name": "Acme Corporation",
"carrier-name": "HealthCorp",
"amount": 987650,
"due-date": "2024-03-10",
"reference-period-start": "2024-02-01",
"reference-period-end": "2024-02-29",
"invoice-status": "all-overdue",
"files": [
{
"file-id": "aaa11111-e89b-12d3-a456-426614174009",
"name": "boleto-02.pdf",
"type": "payment-slip",
"payment-slip-due-date": "2024-03-10",
"status": "overdue"
}
]
}
],
"pagination": {
"current-page": 1,
"total-items": 1,
"total-pages": 1,
"next-page": null,
"previous-page": null
}
}{
"error": "Invalid date filter: 'until-dt' must be greater than 'from-dt'"
}Authorizations
Token Bearer obtido em POST /v1/authenticate.
Query Parameters
Data inicial do filtro (ISO 8601, YYYY-MM-DD).
Data final do filtro (ISO 8601, YYYY-MM-DD). Deve ser maior que from-dt.
Número da página (padrão 1).
Required range:
x >= 1Quantidade de itens por página (padrão 20).
Required range:
x >= 1