Gráfico do ritmo de gastos
curl --request GET \
--url https://api.despezzas.com/v2/spending-pace/chart \
--header 'Authorization: Basic <encoded-value>'const options = {method: 'GET', headers: {Authorization: 'Basic <encoded-value>'}};
fetch('https://api.despezzas.com/v2/spending-pace/chart', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.despezzas.com/v2/spending-pace/chart"
headers = {"Authorization": "Basic <encoded-value>"}
response = requests.get(url, headers=headers)
print(response.text)package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.despezzas.com/v2/spending-pace/chart"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Basic <encoded-value>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"current_month": [
{
"cumulative_cents": 420000,
"day": 15
}
],
"current_total_cents": 420000,
"diff_cents": -32000,
"previous_month": [
{
"cumulative_cents": 420000,
"day": 15
}
],
"previous_total_cents": 452000
}{
"message": "Credenciais de API inválidas",
"statusCode": 401,
"error": "Unauthorized"
}{
"message": "Credenciais de API inválidas",
"statusCode": 401,
"error": "Unauthorized"
}{
"message": "Credenciais de API inválidas",
"statusCode": 401,
"error": "Unauthorized"
}Limites de gastos
Gráfico do ritmo de gastos
Gasto acumulado dia a dia do mês e do mês anterior.
Escopo necessário: read.
GET
/
v2
/
spending-pace
/
chart
Gráfico do ritmo de gastos
curl --request GET \
--url https://api.despezzas.com/v2/spending-pace/chart \
--header 'Authorization: Basic <encoded-value>'const options = {method: 'GET', headers: {Authorization: 'Basic <encoded-value>'}};
fetch('https://api.despezzas.com/v2/spending-pace/chart', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://api.despezzas.com/v2/spending-pace/chart"
headers = {"Authorization": "Basic <encoded-value>"}
response = requests.get(url, headers=headers)
print(response.text)package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.despezzas.com/v2/spending-pace/chart"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Basic <encoded-value>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}{
"current_month": [
{
"cumulative_cents": 420000,
"day": 15
}
],
"current_total_cents": 420000,
"diff_cents": -32000,
"previous_month": [
{
"cumulative_cents": 420000,
"day": 15
}
],
"previous_total_cents": 452000
}{
"message": "Credenciais de API inválidas",
"statusCode": 401,
"error": "Unauthorized"
}{
"message": "Credenciais de API inválidas",
"statusCode": 401,
"error": "Unauthorized"
}{
"message": "Credenciais de API inválidas",
"statusCode": 401,
"error": "Unauthorized"
}Authorizations
basicAuthapiSecret & apiToken
HTTP Basic com o token como usuário e o secret como senha: curl -u dpz_tk_…:dpz_sk_…. Crie a chave em https://despezzas.com/settings/api-keys.
Query Parameters
Mês de referência no formato YYYY-MM-DD (qualquer dia do mês). Padrão: mês atual.
Example:
"2026-09-01"
Response
Sucesso.
Gasto acumulado por dia no mês.
Show child attributes
Show child attributes
Total do mês até o dia de referência. Em centavos.
Example:
420000
Diferença (atual − anterior). Em centavos.
Example:
-32000
Gasto acumulado por dia no mês anterior.
Show child attributes
Show child attributes
Total do mês anterior até o mesmo dia. Em centavos.
Example:
452000