Consultar os recebimentos
GET
/api/seller/external/v1/report/receipts
curl --request GET \ --get "https://api.spelt.com.br/api/seller/external/v1/report/receipts?mode=architecto&granularity=architecto&period=architecto&month=architecto" \ --header "Authorization: Bearer splt_live_SUA_CHAVE" \ --header "Content-Type: application/json" \ --header "Accept: application/json"const url = new URL( "https://api.spelt.com.br/api/seller/external/v1/report/receipts");
const params = { "mode": "architecto", "granularity": "architecto", "period": "architecto", "month": "architecto",};Object.keys(params) .forEach(key => url.searchParams.append(key, params[key]));
const headers = { "Authorization": "Bearer splt_live_SUA_CHAVE", "Content-Type": "application/json", "Accept": "application/json",};
fetch(url, { method: "GET", headers,}).then(response => response.json());$client = new \GuzzleHttp\Client();$url = 'https://api.spelt.com.br/api/seller/external/v1/report/receipts';$response = $client->get( $url, [ 'headers' => [ 'Authorization' => 'Bearer splt_live_SUA_CHAVE', 'Content-Type' => 'application/json', 'Accept' => 'application/json', ], 'query' => [ 'mode' => 'architecto', 'granularity' => 'architecto', 'period' => 'architecto', 'month' => 'architecto', ], ]);$body = $response->getBody();print_r(json_decode((string) $body));import requestsimport json
url = 'https://api.spelt.com.br/api/seller/external/v1/report/receipts'params = { 'mode': 'architecto', 'granularity': 'architecto', 'period': 'architecto', 'month': 'architecto',}headers = { 'Authorization': 'Bearer splt_live_SUA_CHAVE', 'Content-Type': 'application/json', 'Accept': 'application/json'}
response = requests.request('GET', url, headers=headers, params=params)response.json()Relatório de Recebimentos (regime de caixa).
Authorizations
Seção intitulada “Authorizations”Parameters
Seção intitulada “Parameters”Query Parameters
Seção intitulada “Query Parameters”mode
Cash (padrão) = movimento do período | cohort = safra por data de emissão.
string
Cash (padrão) = movimento do período | cohort = safra por data de emissão.
granularity
Month (padrão) | week | day. week/day cobrem apenas o mês de month.
string
Month (padrão) | week | day. week/day cobrem apenas o mês de month.
period
Só com granularity=month: last_6m | last_12m (padrão) | ytd | last_year | year:YYYY.
string
Só com granularity=month: last_6m | last_12m (padrão) | ytd | last_year | year:YYYY.
month
Obrigatório com granularity=week|day. Formato YYYY-MM. Default: mês corrente.
string
Obrigatório com granularity=week|day. Formato YYYY-MM. Default: mês corrente.
