Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Missing REST API body parameter 'user_dismissible' for creating announcement banner #36198

Closed
1 task done
GarrettGeorge opened this issue Feb 6, 2025 · 4 comments
Closed
1 task done
Labels
content This issue or pull request belongs to the Docs Content team fix-internally Triggers a workflow to copy the issue internally and close the current issue

Comments

@GarrettGeorge
Copy link

GarrettGeorge commented Feb 6, 2025

Code of Conduct

What article on docs.github.com is affected?

The pages in question are:

What part(s) of the article would you like to see updated?

TL:DR: The body parameters only mention announcement and expires_at whereas the example request and response schema include user_dismissible.

Image

Example request

await octokit.request('PATCH /enterprises/{enterprise}/announcement', {
  enterprise: 'ENTERPRISE',
  announcement: 'Very **important** announcement about _something_.',
  expires_at: '2021-01-01T00:00:00.000+00:00',
  user_dismissible: false,
  headers: {
    'X-GitHub-Api-Version': '2022-11-28'
  }
})

Response schema

{
  "title": "Announcement Banner",
  "description": "Announcement at either the repository, organization, or enterprise level",
  "type": "object",
  "properties": {
    "announcement": {
      "type": [
        "string",
        "null"
      ],
      "description": "The announcement text in GitHub Flavored Markdown. For more information about GitHub Flavored Markdown, see \"[Basic writing and formatting syntax](https://docs.github.com/enterprise-cloud@latest//github/writing-on-github/getting-started-with-writing-and-formatting-on-github/basic-writing-and-formatting-syntax).\"",
      "examples": [
        "Very **important** announcement about _something_."
      ]
    },
    "expires_at": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time",
      "description": "The time at which the announcement expires. This is a timestamp in [ISO 8601](https://en.wikipedia.org/wiki/ISO_8601) format: `YYYY-MM-DDTHH:MM:SSZ`. To set an announcement that never expires, omit this parameter, set it to `null`, or set it to an empty string.",
      "examples": [
        "\"2021-01-01T00:00:00.000-07:00\""
      ]
    },
    "user_dismissible": {
      "type": [
        "boolean",
        "null"
      ],
      "description": "Whether an announcement can be dismissed by the user.",
      "default": false,
      "examples": [
        false
      ]
    }
  },
  "required": [
    "announcement",
    "expires_at",
    "user_dismissible"
  ]
}

Problem

The field user_dismissible is missing from the "human readable" body parameters section.

Additional information

No response

@GarrettGeorge GarrettGeorge added the content This issue or pull request belongs to the Docs Content team label Feb 6, 2025
Copy link

welcome bot commented Feb 6, 2025

Thanks for opening this issue. A GitHub docs team member should be by to give feedback soon. In the meantime, please check out the contributing guidelines.

@github-actions github-actions bot added the triage Do not begin working on this issue until triaged by the team label Feb 6, 2025
@GarrettGeorge GarrettGeorge changed the title Missing body parameter for REST API for creating announcement banner Missing body parameter 'user_dismissible' for REST API for creating announcement banner Feb 6, 2025
@GarrettGeorge GarrettGeorge changed the title Missing body parameter 'user_dismissible' for REST API for creating announcement banner Missing REST API body parameter 'user_dismissible' for creating announcement banner Feb 6, 2025
@isaacmbrown
Copy link
Contributor

@GarrettGeorge 👋 Thanks for the issue and the detailed description, looks like a miss in our docs! Since these docs come from our API schemas and not our open source repo, I'm going to apply a label to move this to an internal repo, then reach out to the engineering team to ask for a fix. Thanks!

@isaacmbrown isaacmbrown added fix-internally Triggers a workflow to copy the issue internally and close the current issue and removed triage Do not begin working on this issue until triaged by the team labels Feb 7, 2025
@docs-bot
Copy link
Collaborator

docs-bot commented Feb 7, 2025

Thank you for opening this issue! Updates to this documentation must be made internally. I have copied your issue to an internal issue, so I will close this issue.

@docs-bot docs-bot closed this as completed Feb 7, 2025
@vaindil
Copy link
Contributor

vaindil commented Feb 10, 2025

@GarrettGeorge Thanks for reporting this! This has been fixed internally, the changes should roll out to the public docs within the next 24-48 hours.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
content This issue or pull request belongs to the Docs Content team fix-internally Triggers a workflow to copy the issue internally and close the current issue
Projects
None yet
Development

No branches or pull requests

4 participants