---
title: "Revoke one issued database credential"
method: DELETE
path: "/v1/projects/{project_id}/database/access/{access_id}"
---

# Revoke one issued database credential

`DELETE /v1/projects/{project_id}/database/access/{access_id}`

## Request

- Base URL: `https://app.ohmyho.st`
- URL: `https://app.ohmyho.st/v1/projects/{project_id}/database/access/{access_id}`
- Auth: HTTP bearer

Ends the credential's open sessions and removes its PostgreSQL role. Revocation is idempotent for an already revoked credential and never affects the application's own roles or any data.

## Path parameters

- `project_id` string, required
- `access_id` string, required

## Headers

- `X-Request-Id` string

## Response `200`

The revoked credential record without any connection URI.

- ProjectDatabaseAccess
  - `access_id` string, required
  - `environment` 'dev' | 'prod', required
  - `mode` 'read' | 'write', required
  - `role_name` string, required
  - `host` string, required
  - `database` 'neondb', required
  - `label` string, nullable, required
  - `state` 'active' | 'expired' | 'revoked', required
  - `issued_at` string, date-time, required
  - `expires_at` string, date-time, required
  - `revoked_at` string, date-time, nullable, required
  - `revocation_reason` 'principal' | 'expired' | 'budget' | 'creation_failed' | 'data_change' | 'null', nullable, required

## Other responses

- `400`: The request failed.
- `401`: The request failed.
- `404`: The resource does not exist or is not visible to the authenticated principal.
- `429`: The request failed.
- `503`: The request failed.

---

[API](https://skmtc.dev/ohmyho/apis/ohmyho-st-api.md) · [All operations](https://skmtc.dev/ohmyho/apis/ohmyho-st-api/llms.txt) · [OpenAPI document](https://skmtc.dev/ohmyho/apis/ohmyho-st-api/revisions/d069888c0017?raw)
