Skip to content

REST API error when getting users with non-admin role #26747

Closed

Description

@ellatrix

Describe the bug

GET http://localhost:8888/gutenberg/index.php?rest_route=%2Fwp%2Fv2%2Fusers&who=authors&context=edit&_locale=user 403 (Forbidden)
{
  "code": "rest_forbidden_context",
  "message": "Sorry, you are not allowed to list users.",
  "data": {
    "status": 403
  }
}

To reproduce
Steps to reproduce the behavior:

  1. Visit a post as a user in e.g. an editor or author role.
  2. Check the console for the error.

Activity

  1. added
    [Type] Bug
    REST API Interaction
    on Nov 5, 2020
  2. changed the title [-]Post lock modal: REST API error when getting users with non-admin role[/-] [+]REST API error when getting users with non-admin role[/+] on Nov 5, 2020
  3. ellatrix commented on Nov 5, 2020

    @ellatrix
    MemberAuthor

    This actually happens when you load any post.

  4. youknowriad commented on Nov 6, 2020

    @youknowriad
    Contributor

    @ellatrix This is being worked on here #26554

  5. ellatrix commented on Nov 6, 2020

    @ellatrix
    MemberAuthor

    Ah, thanks! I'll close this one since there's another issue for it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    REST API Interaction[Type] Bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions