Account information and customization
Retrieve account details and fees, and customize the checkout's appearance.
Confirm the integration's company and environment, and retrieve your company's branch and financial account number at Raims. You can also check the commercial terms to estimate receipt costs in your integration and configure the images, colors, and support contact shown in the checkout.
| Purpose | Method and path |
|---|---|
| Retrieve company, environment, and status | GET /v1/accounts/context |
| Retrieve branch and account number | GET /v1/accounts/account_number |
| Retrieve current fees | GET /v1/accounts/fees |
| Retrieve checkout customization | GET /v1/accounts/checkout_settings |
| Update checkout customization | PATCH /v1/accounts/checkout_settings |
| Prepare a logo upload | POST /v1/accounts/checkout_settings/logo_uploads |
| Prepare an icon upload | POST /v1/accounts/checkout_settings/favicon_uploads |
| Discard an unused upload | DELETE /v1/accounts/checkout_settings/uploads/{id} |
Replace the logo from upload to checkout
This example prepares a logo upload, sends the file and tracks its application. Use the actual metadata of the same file throughout; the IDs and URL below illustrate the returned format.
Prepare the upload
Send the file metadata to Prepare a logo upload.
Request examplePOST /v1/accounts/checkout_settings/logo_uploadsImage details
JSON{ "content_type": "image/png", "file_size": 12345, "width": 512, "height": 128 }Keep the
idand upload details from the response:HTTP 201 response example excerptPOST /v1/accounts/checkout_settings/logo_uploadsTemporary URL and upload conditions
JSON{ "id": "cau_3AbHiWSrsZBoaTg47OcMzC", "upload_url": "https://uploads.example.com/checkout/logo?signature=example", "method": "PUT", "content_type": "image/png", "file_size": 12345, "expires_at": 1792186200 }Send the bytes of the same file
Use the returned
upload_url,content_typeandfile_sizeasUPLOAD_URL,CONTENT_TYPEandFILE_SIZE. Do not send Bearer credentials to this URL.Shellcurl --request PUT \ --url "$UPLOAD_URL" \ --header "Content-Type: $CONTENT_TYPE" \ --header "Content-Length: $FILE_SIZE" \ --data-binary @logo.pngApply the logo and query the result
In the customization PATCH, copy the actual upload
idintologo_upload_id.Request example excerptPATCH /v1/accounts/checkout_settingsAssociate uploaded files
JSON{ "logo_upload_id": "cau_3AbHiWSrsZBoaTg47OcMzC" }Then retrieve the settings. An example that is still processing contains:
HTTP 200 response example excerptGET /v1/accounts/checkout_settingsLogo change still processing
JSON{ "logo": { "url": "https://images.example.com/checkout/previous-logo.png", "status": "pending", "error_code": null } }Consider the change complete when
logo.statusisready. Until then, the previous image can remain in use. Do not prepare another upload just to track it.
| PATCH intent | Submitted field | Effect |
|---|---|---|
| Keep the logo | Omit logo_upload_id | Keeps the current image. |
| Replace the logo | ID of a completed upload | Requests application of that image. |
| Remove the logo | logo_upload_id: null | Requests removal; track it until absent. |
Retrieve account context
Use Retrieve account context, with
GET /v1/accounts/context, to get the public identifier, display name, and
status of the authenticated company. The response also provides the
authenticated environment and the currency, unit, and time zone references used by
the integration. The request accepts no parameters or body.
Use the environment you want to query, with an API key or an authorized OAuth connection. A company with a pending registration can query its context only in Sandbox.
checked_at reports when the details were retrieved, in Unix seconds UTC.
Compare access_revision with a previous response to recognize changes in
the account context or integration access. This value is an opaque revision;
do not use it as a credential.
This request does not identify an owner or employee and does not confirm that a charge, refund, or withdrawal can be executed. Each endpoint retains its own requirements and checks.
Retrieve the account number
Use Retrieve the account number, with
GET /v1/accounts/account_number, to get agency and account for your
company's financial account. The request uses the authenticated company
and accepts no parameters or body.
This request requires authorized Production access and an approved, enabled financial
account. Sandbox has no financial branch or account number and returns
403 DATA_ENVIRONMENT_NOT_SUPPORTED. The console in this documentation
accepts only Sandbox keys; retrieve the details from your integration's
server, without entering a Production key in the documentation or browser.
If the account is not approved and enabled, or its details are unavailable,
the response is 404 ACCOUNT_NUMBER_NOT_AVAILABLE. Check the account's
status in the Dashboard before trying again.
Keep the branch and account as text, including leading zeros and the returned formatting. The request does not register an account or change the destination of withdrawals.
Retrieve account fees
Use Retrieve account fees, with
GET /v1/accounts/fees. The response contains the current Pix and boleto
fee rules in the plan selected by the company.
The request does not change the plan or fees. Current values also do not indicate which fee applied to a past transaction. To check a fee already charged, retrieve the entries in the Statement.
Understand the values
Each payment method returns its configured percentage component, fixed amount, and fee limits:
| Field | Meaning |
|---|---|
percentage_rate | Fee percentage. For example, 0.8 represents 0.8%. |
fixed_fee_cents | Fixed component of the fee, in Brazilian real cents. |
minimum_fee_cents | Minimum fee amount, in Brazilian real cents. |
maximum_fee_cents | Maximum fee amount, in Brazilian real cents. |
A value of 85 in a cents field represents R$ 0.85. A null field indicates
that the component or limit is not configured. Both percentage and fixed
components can be present in the same rule.
If pix or boleto is null, there is no current rule for that method
in the selected plan. This does not mean that receiving payments is free.
The presence of a rule also does not confirm that the method is enabled
to receive payments.
Checkout customization
Use Retrieve checkout customization to check the company's images, colors, support email, and default payment methods in the authenticated environment. Sandbox and Production have separate settings; changing one environment preserves the other's settings.
To change the colors or contact, use
Update checkout customization.
Send hex_primary_color for the primary color and hex_secondary_color
for the background color, in #RRGGBB format. Omitting a field keeps its
value. In support_email, null or empty text removes the support contact.
Colors must retain valid values. An empty body keeps the current settings.
payment_method_types identifies the default methods enabled and available
for the checkout. Updating through the API does not change this list.
To choose Pix and boleto, use
Account, Settings, Payment checkout.
The account's default methods apply when the charge and link have no settings of their own. Changing this default may change the options on charges that use it. A charge's own list continues to apply; the link can restrict those options. See Checkout and payment methods.
These preferences do not change a charge's amount, due date, or status, and do not confirm payment. The request returns the current settings; it does not show the appearance used on a past date.
Checkout logo and icon
Uploading each image has three steps:
- Use Prepare a logo upload or Prepare an icon upload. Send the file's type, size in bytes, width, and height. PNG and JPEG are accepted; the icon must be square. Check the limits in the corresponding endpoint's parameters.
- Send the file bytes to
upload_urlwith thePUTmethod. SetContent-TypeandContent-Lengthaccording tocontent_typeandfile_sizein the response. Do not send the Raims API key to this address. The URL is temporary. Complete the upload and association beforeexpires_at, expressed in Unix seconds UTC. - Use Update checkout customization
and send the returned
idinlogo_upload_idorfavicon_upload_id. The two fields are independent. Use a logo upload in the logo field and an icon upload in the icon field, always for the same company and environment.
Getting the URL or completing the PUT does not change the image shown
in the checkout. Association through PATCH may return 202 while the
image is checked. Retrieve the settings to track logo.status and favicon.status:
status | How to interpret it |
|---|---|
absent | No image is configured. |
ready | The image is ready to use in the checkout. |
pending | The uploaded image is still being processed. |
failed | The uploaded image could not be applied. Check error_code. |
url contains the current image or null when none is available.
During processing or after a failure, the previous image remains in use,
if one exists. The new image is used when the change finishes with
status: ready.
If you need to repeat the PATCH while the image is being processed, use
the same upload ID. An upload that failed or has already been replaced
cannot be applied again. Prepare a new upload to replace the image again.
When error_code has a value, check the reason:
error_code | What to do |
|---|---|
CHECKOUT_ASSET_INVALID_IMAGE | Check the file, type, and dimensions before preparing another upload. |
CHECKOUT_ASSET_UPLOAD_NOT_FOUND | The file is unavailable. Prepare another upload. |
CHECKOUT_ASSET_PROCESSING_FAILED | Applying the image failed. Prepare another upload; if the problem persists, contact support. |
Remove a checkout image
To remove an image, send logo_upload_id: null or favicon_upload_id: null.
Omitting these fields keeps the current images. Removal can also require
processing; it finishes with status: absent. You can also change this
setting in the checkout appearance section of the Dashboard.
Discard an unused upload
If you abandon an upload before associating it, use
Discard an image upload, with the
same id returned when preparing it. Discarding also accepts an expired
authorization. The deleted: true response confirms that the upload was
discarded and can no longer be applied; repeating the request keeps this
result. An upload already associated with the checkout cannot be discarded
through this endpoint. To remove the image, use PATCH with the corresponding
field set to null.
Company and environment
These requests identify the company through API-key or OAuth authentication. You do not need to send the company identifier in the request.
Fees are shared between Sandbox and Production. A query in Sandbox retrieves the same rules for the company, while test payments remain separate from real transactions.
Protect the credentials on your integration's server. Handle errors using the HTTP
status and error.code, as described in
HTTP response codes.