> ## Documentation Index
> Fetch the complete documentation index at: https://docs.garu.com.br/llms.txt
> Use this file to discover all available pages before exploring further.

# Detalhes da Cobrança Agendada

> Busque uma cobrança junto com sua linha do tempo e transações geradas

## Visão Geral

Retorna a cobrança em pacote com:

* a linha do tempo de eventos (`events`, ordem cronológica),
* as transações Garu geradas a partir da cobrança (`transactions`).

É a chamada que alimenta a página de detalhes do dashboard.

## Exemplo de Requisição

```bash cURL theme={null}
curl -X GET https://garu.com.br/api/v1/scheduled-charges/sch_abc123 \
  -H "Authorization: Bearer sk_test_sua_chave"
```

```javascript JavaScript theme={null}
import { Garu } from '@garuhq/node';

const garu = new Garu({ apiKey: process.env.GARU_API_KEY });

const { charge, events, transactions } = await garu.scheduledCharges.get('sch_abc123');

console.log(charge.status);
events.forEach((e) => console.log(e.eventType, e.createdAt));
```

```python Python theme={null}
import requests
import os

response = requests.get(
    "https://garu.com.br/api/v1/scheduled-charges/sch_abc123",
    headers={"Authorization": f"Bearer {os.environ['GARU_API_KEY']}"}
)
detail = response.json()
print(detail["charge"]["status"])
```

## Parâmetros de Path

**id** `string` *required*

ID da cobrança (`sch_…`).

## Resposta

```json theme={null}
{
  "charge": {
    "id": "sch_abc123",
    "customerId": 42,
    "amount": 297.5,
    "type": "one_time",
    "dueDate": "2026-06-15",
    "methods": ["pix", "boleto"],
    "recurrence": null,
    "status": "paid",
    "subscriptionId": null,
    "trialEndsAt": null,
    "cancelAtPeriodEnd": false,
    "customer": { "id": 42, "name": "Maria Silva", "email": "maria@exemplo.com.br", "document": "12345678901" },
    "product": null,
    "createdAt": "2026-05-01T12:00:00Z",
    "updatedAt": "2026-06-15T13:42:00Z"
  },
  "events": [
    { "id": 1, "scheduledChargeId": "sch_abc123", "eventType": "created",
      "actor": { "type": "user", "id": 1 }, "payload": { "amount": 297.5 },
      "createdAt": "2026-05-01T12:00:00Z" },
    { "id": 2, "scheduledChargeId": "sch_abc123", "eventType": "d_day_reminder_sent",
      "actor": { "type": "system" }, "payload": null,
      "createdAt": "2026-06-15T11:00:00Z" },
    { "id": 3, "scheduledChargeId": "sch_abc123", "eventType": "paid",
      "actor": { "type": "system" }, "payload": { "transactionId": 4472 },
      "createdAt": "2026-06-15T13:42:00Z" }
  ],
  "transactions": [
    { "id": 4472, "value": 297.5, "paymentMethod": "pix", "status": "payedPix",
      "date": "2026-06-15T11:01:00Z", "refundedAt": null }
  ]
}
```

> [!NOTE]
>
> `charge.amount` e `transactions[].value` estão ambos em BRL decimal
> (`297.50`) — nunca centavos. Nenhuma conversão é necessária entre os dois.

### Tipos de evento

| `eventType` | Quando |
| - | - |
| `created` | Cobrança agendada |
| `postponed` | Data alterada |
| `paused` / `resumed` | Pausa / retomada manual |
| `manually_marked_paid` | Marcada como paga (pagamento off-Garu) |
| `paid` | Pagamento confirmado pela Garu |
| `d_day_reminder_sent` | E-mail enviado ao cliente no vencimento |
| `overdue_reminder_sent` | Lembrete enviado ao time financeiro (D+1, D+2 ou D+3) |

`actor.type` é `user` (com `id` numérico do usuário), `api_key` (com `id` da chave) ou `system` para ações automáticas dos crons.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.