API v1 is deprecated. It keeps working until the end date you receive from us. Build new integrations on API v2 and read the migration guide.
Developers

Authentication

Bearer tokens created in the old woodyou.care dashboard.

v1 uses personal access tokens (Laravel Sanctum) that were created in the old woodyou.care dashboard under Account > API tokens. Send the token in the Authorization header of every request, and ask for JSON:

Authorization: Bearer {YOUR_TOKEN}
Accept: application/json

What a token can do

  • A token belongs to a user and sees the company that user belongs to. All reads are scoped to that company.
  • Tokens were created with the permissions read, create, update and delete. Since every remaining endpoint is a read, only read still matters.
  • A token without a company, or with a company that never became a customer, gets 403 with the message No company is linked to this API user. on get-stats.

After the move to the Platform

Existing tokens were imported into the WoodYouCare Platform and keep working on v1 until the end date. You cannot create new v1 tokens: the old dashboard is gone. New tokens are Platform API tokens and only work on v2.

Language

v1 answers in Dutch, as the old shop did: country names in get-trees and get-projects, validation messages and pagination labels. Add ?locale=en for English. Other values fall back to Dutch.

Laravel SDK

The WoodYouCare Laravel SDK for v1 sets the token from its config:

return [
    'bearer_token' => '{YOUR_TOKEN}',
];

The SDK is deprecated together with v1. There is no v2 SDK yet (to be confirmed).

On this page