Planting Trees
Plant trees, fetch the total number of trees you’ve planted, and access aggregated verification evidence.
Plant Trees
Section titled “Plant Trees”POST https://app.thegoodapi.com/plant/trees
Planting trees is this easy.
Headers
Section titled “Headers”| Name | Type | Description |
|---|---|---|
Authorization* | string | <API Key> |
Request body
Section titled “Request body”| Name | Type | Required | Description |
|---|---|---|---|
count | integer | Yes | The number of trees you’d like to plant |
attribution | string | No | Tag an order with a non-unique lookup key for filtering |
metadata | JSON | No | Tag an order with arbitrary key/value pairs |
idempotency_key | string | No | Use this to safely retry requests without double-planting |
Response — 200 OK
Section titled “Response — 200 OK”{ "total_planted_trees": 45, "tree_details": [ { "id": "i2SeocFjwNayo7PI7DpI", "count": 1, "fractional_count": 0, "created_at": "2025-07-01T22:07:31.374582-04:00", "idempotency_key": "", "metadata": { "key1": "val1", "key2": 786 }, "attribution": "saif@thegoodapi.com" } ], "total_planted_trees_month": 0}Get total trees planted
Section titled “Get total trees planted”GET https://app.thegoodapi.com/plant/trees
Headers
Section titled “Headers”| Name | Type | Description |
|---|---|---|
Authorization* | string | <API Key> |
Query parameters
Section titled “Query parameters”All query parameters are optional.
| Name | Type | Description |
|---|---|---|
attribution_key | string | Fetch by attribution key |
id | string | Fetch by Tree ID |
created_at | string | Trees registered after date (format: YYYY-MM-DD) |
end_at | string | Trees registered before date (format: YYYY-MM-DD) |
metadata | JSON | JSON filter with AND operations |
Response — 200 OK
Section titled “Response — 200 OK”{ "total_planted_trees": 45, "tree_details": [ { "id": "i2SeocFjwNayo7PI7DpI", "count": 1, "created_at": "2025-07-02T02:07:31.374582Z", "idempotency_key": "", "metadata": { "key1": "val1", "key2": 786 }, "attribution": "user1@test.com" } ]}Tree planting verification stats
Section titled “Tree planting verification stats”GET https://app.thegoodapi.com/evidence
Returns aggregated planting evidence including photos, videos, and impact metrics from verified projects.
Authentication
Section titled “Authentication”| Header | Required | Description |
|---|---|---|
Authorization | Yes | Bearer token with API key: Bearer <API_KEY> |
Example request
Section titled “Example request”curl -X GET "https://app.thegoodapi.com/evidence" \ -H "Authorization: Bearer your_api_key"Response — 200 OK
Section titled “Response — 200 OK”{ "summary": { "total_trees": 1847811, "trees_planted": 330447, "carbon_offset_tons": 81748.316, "area_restored_hectares": 190.37407, "countries": [ "Brazil", "Canada", "Haiti", "Indonesia", "Kenya", "Madagascar", "United States" ] }, "regions": [ { "id": "23", "name": "Kwale", "country": "Kenya", "evidence": [ { "id": "735545", "type": "image", "url": "https://d38us48sb13m7f.cloudfront.net/...", "date": "2025-09-23T14:11:17.000000Z" } ] } ]}- Response is cached for 30 days for performance.
- Evidence items are grouped by geographic region based on coordinates.
- Media URLs are served via Veritree’s CDN.