API tenantów
Autor: Zespół Aether365 Odbiorcy: Deweloperzy Zakres: Endpointy API tenantów - odczytywanie i aktualizowanie konfiguracji tenanta
Pobieranie bieżącego tenanta
Zwraca profil i informacje o planie uwierzytelnionego tenanta.
GET /tenants/mePrzykładowe żądanie
bash
curl https://api.aether365.io/tenants/me \
-H "Authorization: Bearer <token>"Przykładowa odpowiedź
json
{
"success": true,
"data": {
"id": "t_abc123",
"email": "admin@example.com",
"companyName": "Example Corp",
"planTier": "pro",
"createdAt": "2026-01-15T10:00:00Z",
"updatedAt": "2026-04-01T08:30:00Z"
}
}Pola odpowiedzi
| Pole | Typ | Opis |
|---|---|---|
id | string | Identyfikator tenanta |
email | string | E-mail właściciela konta |
companyName | string | Nazwa firmy (pochodząca z domeny e-mail) |
planTier | string | Bieżący plan: free, pro, enterprise |
createdAt | string | Znacznik czasu ISO 8601 utworzenia konta |
updatedAt | string | Znacznik czasu ISO 8601 ostatniej aktualizacji |
Aktualizacja profilu tenanta
Aktualizuje wyświetlaną nazwę tenanta.
PATCH /tenants/meTreść żądania
json
{
"companyName": "Acme Security Ltd"
}| Pole | Typ | Wymagane | Opis |
|---|---|---|---|
companyName | string | Nie | Wyświetlana nazwa tenanta |
Przykładowe żądanie
bash
curl -X PATCH https://api.aether365.io/tenants/me \
-H "Authorization: Bearer <token>" \
-H "Content-Type: application/json" \
-d '{"companyName": "Acme Security Ltd"}'Przykładowa odpowiedź
json
{
"success": true,
"data": {
"id": "t_abc123",
"email": "admin@example.com",
"companyName": "Acme Security Ltd",
"planTier": "pro",
"createdAt": "2026-01-15T10:00:00Z",
"updatedAt": "2026-04-10T12:00:00Z"
}
}