quantbrasil credits
Consulta o saldo de créditos e o uso por ferramenta
Sintaxe
quantbrasil creditsEsta é uma operação de leitura. Modos de saída: json, human.
Argumentos e opções
| Nome | Tipo | Obrigatório | Descrição | Padrão |
|---|---|---|---|---|
--month <AAAA-MM> | Opção | Não | Detalha o uso de créditos em um mês específico | — |
--json | Opção | Não | Exibe saída JSON | — |
Exemplos
quantbrasil credits
quantbrasil credits --json
quantbrasil credits --month 2026-10Saída (--json)
Estrutura da resposta retornada com --json:
export interface CreditsGetResponse {
plan: "free" | "premium";
balance: number;
monthly: number;
earned: number;
monthly_allowance: number;
period_start: string;
refills_at: string;
spent_this_month: number;
usage: CreditsToolUsage[];
capability_costs: Record<string, number>;
question_credits: number;
phone_confirmation_required: boolean;
confirm_phone_url: string | null;
months: CreditsMonth[];
history: CreditsHistory | null;
}
export interface CreditsToolUsage {
key: string;
label: string;
credits: number;
runs: number;
}
export interface CreditsMonth {
month: string;
credits: number;
}
export interface CreditsHistory {
month: string;
group: "feature" | "surface";
start: string;
end: string;
total: number;
runs: number;
refunded_runs: number;
refunded_credits: number;
items: CreditsToolUsage[];
days: CreditsHistoryDay[];
}
export interface CreditsHistoryDay {
date: string;
credits: number;
items: CreditsHistoryDayItem[];
}
export interface CreditsHistoryDayItem {
key: string;
credits: number;
runs: number;
}Exemplo de resposta
{
"plan": "free",
"balance": 262,
"monthly": 62,
"earned": 200,
"monthly_allowance": 100,
"period_start": "2026-11-13T00:00:00-03:00",
"refills_at": "2026-12-13T00:00:00-03:00",
"spent_this_month": 38,
"usage": [
{
"key": "backtests",
"label": "Backtests",
"credits": 30,
"runs": 3
},
{
"key": "assistant",
"label": "Respostas do assistente",
"credits": 5,
"runs": 4
},
{
"key": "rankings",
"label": "Rankings",
"credits": 3,
"runs": 3
}
],
"capability_costs": {
"credits.get": 0,
"market.price": 1,
"rankings.current": 1,
"cointegration.pair": 1,
"backtests.run": 10,
"screening.run": 10
},
"question_credits": 1,
"phone_confirmation_required": false,
"confirm_phone_url": null,
"months": [
{
"month": "2026-11",
"credits": 38
},
{
"month": "2026-10",
"credits": 12
}
],
"history": null
}