---
title: "Test current user's Google Earth Engine credentials."
method: POST
path: "/api/v1/user/me/gee-credentials/test"
---

# Test current user's Google Earth Engine credentials.

`POST /api/v1/user/me/gee-credentials/test`

**Authentication**: JWT token required
**Authorization**: Any authenticated user

**Prerequisites**:
- User must have GEE credentials configured (OAuth or service account)

**Response Schema (Success)**:
```json
{
  "message": "GEE credentials are valid and working"
}
```

**What This Tests**:
- Initializes Google Earth Engine with user's credentials
- Verifies credentials are not expired
- Confirms GEE API access is working
- Validates credential format and permissions

**Typical Workflow**:
1. Check if credentials exist using GET /user/me/gee-credentials
2. Test credentials validity using this endpoint
3. If credentials are valid, proceed with GEE analysis
4. If credentials are invalid/expired, refresh or update credentials

**Error Responses**:
- `400 Bad Request`: GEE credentials not configured or invalid/expired
- `401 Unauthorized`: JWT token required or invalid
- `404 Not Found`: User not found
- `500 Internal Server Error`: Failed to test credentials

## Request body

- object

## Response `200`

Success

- object

## Other responses

- `400` — Bad Request
- `401` — Unauthorized
- `403` — Forbidden
- `404` — Not Found
- `500` — Internal Server Error

---

[API](https://skmtc.dev/trends/apis/trends-earth-api.md) · [All operations](https://skmtc.dev/trends/apis/trends-earth-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/trends/trends-earth-api/revisions/6bdbc0b84666/schema)
