CARVIEW |
Select Language
HTTP/2 200
server: GitHub.com
content-type: text/html; charset=utf-8
last-modified: Tue, 19 Sep 2023 11:50:57 GMT
access-control-allow-origin: *
etag: W/"65098b21-30e6"
expires: Sat, 19 Jul 2025 07:44:37 GMT
cache-control: max-age=600
content-encoding: gzip
x-proxy-cache: MISS
x-github-request-id: FDAB:984B:4FFCDB:5162AC:687B4A8D
accept-ranges: bytes
date: Sat, 19 Jul 2025 07:34:38 GMT
via: 1.1 varnish
age: 0
x-served-by: cache-bom4730-BOM
x-cache: MISS
x-cache-hits: 0
x-timer: S1752910478.802918,VS0,VE322
vary: Accept-Encoding
x-fastly-request-id: c028f09b06addbf119c9fcb66b6efec8808c3f67
content-length: 3384
Preview GraphQL API v4 Node IDs in REST API v3 resources | GitHub Developer Guide
This content may be out of date. For the newest content, see the API posts on the GitHub Blog.
This content may be out of date. For the newest content, see the API posts on the GitHub Blog.
All of GitHub's Docs are now in one place! You can see Apps, REST API, and GraphQL API on GitHub Docs.
Preview GraphQL API v4 Node IDs in REST API v3 resources
- December 19, 2017
-
dewski
-
nickvanw
-
gjtorikian
To help with migrating from our REST API v3 to GraphQL API v4, we're introducing a new preview period to include the GraphQL node ID in the response for the following REST API v3 resources:
- Deployments
- Gists
- Git Blobs
- Git Commits
- Git References
- Git Tags
- Issues
- Labels
- Milestones
- Organizations
- Projects
- Pull Requests
- Reactions
- Releases
- Repositories
- Statuses
- Teams
- Users
To access the API during the preview period, you must provide a custom media type in the Accept header:
application/vnd.github.jean-grey-preview+json
Example response from Users which includes node_id
:
{
"id": 79995,
"login": "dewski",
"node_id": "MDQ6VXNlcjc5OTk1"
}
Fetching the same user using the node interface in our GraphQL API v4:
{
node(id: "MDQ6VXNlcjc5OTk1") {
... on User {
databaseId
login
id
}
}
}
Which would return:
{
"data": {
"node": {
"databaseId": 79995,
"login": "dewski",
"id": "MDQ6VXNlcjc5OTk1"
}
}
}
For more information, see "GraphQL Global Node IDs."
Please note that node_id
is only available to GitHub Enterprise customers on 2.12 (and future GHE versions when they are released).
If you have any questions or feedback, please let us know on the GitHub Platform Forum.
Recent Posts
- Antiope preview graduation
October 1, 2020 - Machine-man and sailor-v previews graduate
August 20, 2020 - GitHub Actions API - Introducing workflow usage endpoints
May 15, 2020 - Introducing the skipped check run and check suite conclusion
May 8, 2020 - Suspending GitHub App installations
May 1, 2020 - Expiring user-to-server access tokens for GitHub Apps
April 30, 2020 - Replacing the GitHub Apps "Creating an installation access token" endpoint
April 15, 2020 - Replacing the integration_installation and integration_installation_repositories webhook events
April 15, 2020