---
title: "Delete another user's Google Earth Engine credentials (Admin only)."
method: DELETE
path: "/api/v1/user/{user_id}/gee-credentials"
---

# Delete another user's Google Earth Engine credentials (Admin only).

`DELETE /api/v1/user/{user_id}/gee-credentials`

**Authentication**: JWT token required
**Authorization**: ADMIN or SUPERADMIN role required

**Path Parameters**:
- `user_id`: Target user's ID (string or integer)

**Response Schema**:
```json
{
  "message": "GEE credentials deleted for user user@example.com"
}
```

**What Gets Deleted**:
- All OAuth tokens (access and refresh tokens)
- Service account credentials
- Credentials type and metadata
- All encrypted credential data is permanently removed

**Admin Use Cases**:
- Revoke access for users leaving the organization
- Clean up expired or compromised credentials
- Force credential refresh by removing and re-adding
- Audit and compliance requirements

**Security & Audit**:
- Admin action is logged with both admin and target user details
- Irreversible operation - credentials cannot be recovered
- User will need to reconfigure GEE credentials to regain access

**Error Responses**:
- `401 Unauthorized`: JWT token required or invalid
- `403 Forbidden`: Admin access required
- `404 Not Found`: Target user not found or user has no GEE credentials
- `500 Internal Server Error`: Failed to delete credentials

## Path parameters

- `user_id` string, required

## 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)
