Skip to content

[Schema Inaccuracy] <Describe Problem> #5991

@yannick-cw

Description

@yannick-cw

Schema Inaccuracy

The latest_comment_url property on the subject object within the notification thread schema (GET /notifications) is marked as required with type string, but the API returns null for notifications where no comment exists yet.

Expected

The latest_comment_url property on the subject schema in the notification thread should be typed as string | null (nullable), since the API returns null when no comments exist on the notification subject (e.g., a newly created issue or PR with no comments).

Reproduction Steps

curl -H "Authorization: Bearer $TOKEN" \
     -H "Accept: application/vnd.github+json" \
     https://api.github.com/notifications

Response includes entries like:

{
  "id": "...",
  "subject": {
    "title": "Some PR title",
    "url": "https://api.github.com/repos/owner/repo/pulls/123",
    "latest_comment_url": null,
    "type": "PullRequest"
  },
  "reason": "review_requested",
  "unread": true
}

The schema at descriptions/api.github.com/api.github.com.json defines latest_comment_url as required and type string without nullable.

Metadata

Metadata

Assignees

No one assigned

    Labels

    invalidThis doesn't seem right

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions