---
title: "Update the access a fine-grained personal access token has to organization resources"
method: POST
path: "/orgs/{org}/personal-access-tokens/{pat_id}"
tags: ["orgs"]
---

# Update the access a fine-grained personal access token has to organization resources

`POST /orgs/{org}/personal-access-tokens/{pat_id}`

Updates the access an organization member has to organization resources via a fine-grained personal access token. Limited to revoking the token's existing access. Limited to revoking a token's existing access.

Only GitHub Apps can use this endpoint.

## Path parameters

- `org` string, required
- `pat_id` integer, required

## Request body

- object
  - `action` 'revoke', required — Action to apply to the fine-grained personal access token.

## Response `204`

A header with no content is returned.

## Other responses

- `403` — Forbidden
- `404` — Resource not found
- `422` — Validation failed, or the endpoint has been spammed.
- `500` — Internal Error

---

[API](https://skmtc.net/github/apis/rest-api.md) · [All operations](https://skmtc.net/github/apis/rest-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/github/rest-api/versions/80850db290cd/schema)
