raims refunds
Inspect refunds and receipts
From command to result
Refund requests use charges refunds create. This group reads the refund, history, and receipt when available.
Configure the profile and credential before running real reads. With an API
key, the key determines the company and environment. --environment selects
an environment only for OAuth.
Check eligibility
Shellraims --profile sandbox --output json charges refund-eligibility CHARGE_IDThe read reports what can be requested now. It does not reserve funds or create a refund.
Prepare the request
Shellraims charges refunds create CHARGE_ID --amount-cents 2500 --dry-runReview the explicit amount in cents. To request it, use the profile and an operation idempotency key after removing
--dry-run; keep the returned refund ID.Follow before downloading a receipt
Shellraims --profile sandbox --output json refunds get REFUND_IDRead the refund status. After confirming the result, use
refunds receipt REFUND_ID --save estorno.pdfwhen a receipt is available. A read does not request another refund.
Choose a command
| Command | Purpose |
|---|---|
raims refunds get | Get a refund |
raims refunds list | List refunds |
raims refunds receipt | Get the refund receipt download information |
The previews below use --dry-run and do not send the request. Replace placeholders and review the result before sending a write.
Body fields, filters, and headers are sent only when supplied. Execution option defaults do not fill API fields.
raims refunds
Inspect refunds and receipts
raims refunds [flags]Execution options
--help,-hbooldefault: false- help for refunds
See global options.
Subcommands: raims refunds get, raims refunds list, raims refunds receipt.
raims refunds get
Get a refund
raims refunds get ID [flags]OAuth environments: Sandbox, Production. Success responses: 200.
Example
raims --profile PROFILE --output json refunds get ID --dry-runThe excerpt below shows the CLI contents of data. The envelope also reports status_code and the received request_id.
Refund awaiting confirmation
{
"id": "rf_3AbHiWSrsZBoaTg47OcMzC",
"charge_id": "ch_3AbHiWSrsZBoaTg47OcMzC",
"status": "accepted",
"amount_cents": 2500,
"description": "Devolução parcial do serviço",
"created_at": 1791964800
}Execution options
--dry-runbooldefault: false- Validate and preview the request without credentials or network access
--help,-hbooldefault: false- help for get
--show-headersbooldefault: false- Show public response headers without credentials or cookies
--timeoutdurationdefault: 1m0s- Total request timeout, including retries (for example 30s or 2m)
See global options.
Get a refund.
GET /v1/refunds/{id}
Uses https://api.raims.com and the credential referenced by the selected profile. The API validates the credential's company, environment and permissions. API keys determine their own environment; --environment is available only with OAuth.
Use --dry-run to validate and preview the request without reading a profile, loading credentials or contacting the API. Add --environment to preview an OAuth request; without it, the preview uses API-key authentication and has no environment header.
OAuth environments accepted by this operation: Sandbox, Production.raims refunds list
List refunds
raims refunds list [flags]OAuth environments: Sandbox, Production. Success responses: 200.
Example
raims --profile PROFILE --output json refunds list --dry-runThe excerpt below shows the CLI contents of data. The envelope also reports status_code and the received request_id.
Refunds for different charges
{
"list": [
{
"id": "rf_3AbHiWSrsZBoaTg47OcMzC",
"charge_id": "ch_3AbHiWSrsZBoaTg47OcMzC",
"amount_cents": 2500,
"description": "Devolução parcial do serviço",
"status": "accepted",
"created_at": 1791964800,
"completed_at": null,
"failed_at": null,
"failure_reason": null
},
{
"id": "rf_3AbHiWSrsZBoaTg47OcMzD",
"charge_id": "ch_3AbHiWSrsZBoaTg47OcMzD",
"amount_cents": 1000,
"description": "Devolução parcial do serviço",
"status": "completed",
"created_at": 1791878400,
"completed_at": 1791878580,
"failed_at": null,
"failure_reason": null
}
],
"page": {
"page_size": 10,
"has_next": false,
"has_previous": false,
"next_after": null,
"previous_before": null
}
}Query filters
--afterstringsent only when supplied- Read after this opaque cursor (cannot be combined with --before)
--beforestringsent only when supplied- Read before this opaque cursor (cannot be combined with --after)
--created-gteint64sent only when supplied- Created at or after this Unix timestamp (seconds)
--created-lteint64sent only when supplied- Created at or before this Unix timestamp (seconds)
--page-sizeint64sent only when supplied- Results per page (the API normalizes the requested size)
Execution options
--allbooldefault: false- Read all pages as separate results (JSON Lines with --output json)
--dry-runbooldefault: false- Validate and preview the request without credentials or network access
--help,-hbooldefault: false- help for list
--max-pagesintdefault: 100- Maximum pages to read with --all (1-10000)
--show-headersbooldefault: false- Show public response headers without credentials or cookies
--timeoutdurationdefault: 1m0s- Total request timeout, including retries (for example 30s or 2m)
See global options.
List refunds.
GET /v1/refunds
Uses https://api.raims.com and the credential referenced by the selected profile. The API validates the credential's company, environment and permissions. API keys determine their own environment; --environment is available only with OAuth.
Use --dry-run to validate and preview the request without reading a profile, loading credentials or contacting the API. Add --environment to preview an OAuth request; without it, the preview uses API-key authentication and has no environment header.
OAuth environments accepted by this operation: Sandbox, Production.raims refunds receipt
Get the refund receipt download information
raims refunds receipt ID [flags]OAuth environments: Sandbox, Production. Success responses: 200.
Example
raims --profile PROFILE --output json refunds receipt ID --dry-runThe excerpt below shows the CLI contents of data. The envelope also reports status_code and the received request_id.
Download a refund receipt
{
"url": "https://files.raims.com/documents/comprovante-estorno/exemplo.pdf?Expires=1792080180&Signature=EXEMPLO&Key-Pair-Id=EXEMPLO",
"expires_at": 1792080180
}Execution options
--dry-runbooldefault: false- Validate and preview the request without credentials or network access
--help,-hbooldefault: false- help for receipt
--savestringdefault: empty- Save the PDF to PATH (up to 32 MiB); the parent directory must exist and the file must not exist
--show-headersbooldefault: false- Show public response headers without credentials or cookies
--timeoutdurationdefault: 1m0s- Total request timeout, including retries (for example 30s or 2m)
See global options.
Get the refund receipt download information.
GET /v1/refunds/{id}/receipt
Uses https://api.raims.com and the credential referenced by the selected profile. The API validates the credential's company, environment and permissions. API keys determine their own environment; --environment is available only with OAuth.
Use --dry-run to validate and preview the request without reading a profile, loading credentials or contacting the API. Add --environment to preview an OAuth request; without it, the preview uses API-key authentication and has no environment header.
OAuth environments accepted by this operation: Sandbox, Production.