Retrieves the current tree credit balance for the authenticated organization.
https://api.bloomy.earth
/v1/credits
Authentication uses HTTP Basic Auth with your Bloomy Earth API credentials. You must use your Bloomy Earth platform username and application password.
You can find and manage these credentials in your Bloomy Earth dashboard, in the Integration API section:
👉 https://www.bloomy.earth/dashboard/#bloomy-integration-api
| Header | Value | Required | Description |
|---|---|---|---|
| Authorization | Basic BASE64(username:pwd) | Yes | Basic Auth using your Bloomy Earth username and application password. |
| Accept | application/json | Optional | Specifies JSON format for the response. |
curl -X GET "https://api.bloomy.earth/v1/credits" \
-u YOUR_BLOOMY_USERNAME:YOUR_APPLICATION_PASSWORD \
-H "Accept: application/json"
{
"credits": 19,
"organizationId": 12345
}
| Field | Type | Description |
|---|---|---|
| credits | integer | Number of available tree credits for the organization. |
| organizationId | integer | ID of the organization associated with the credit balance. |
If the request is missing required data or contains invalid parameters, the API returns a JSON object with an error code and a short message.
| HTTP | Error code | Message | Description |
|---|---|---|---|
| 400 | invalid_request | Bad request. | The request is malformed. |
| 401 | unauthorized | Authentication required. | The Authorization header was missing or invalid. |
| 403 | forbidden | Authentication failed. | The provided credentials are invalid or lack permissions. |
| 500 | server_error | Internal server error. | An unexpected error occurred on the server. |
{
"error": "forbidden",
"message": "Authentication failed."
}