• Dev
  • Rest Api for getting user by name?

There is a doc that shows that the api for getting user by name. However, I tried and failed. I don't know whether it exists.

{
	"errors": [
		{
			"status": "404",
			"code": "not_found"
		}
	]
}

Here is the link: https://github.com/flarum/flarum.github.io/blob/20322c0e6011e4f304ae7e95f41594a0b086bc27/_docs/api.md
Users
GET /api/users - get all users
filter[q] - filter by username/gambits
POST /api/users - register a new user
GET /api/users/:idOrUsername - get a user by ID or username
PATCH /api/users/:id - update a user
DELETE /api/users/:id - delete a user
POST /api/users/:id/avatar - upload a user avatar
DELETE /api/users/:id/avatar - delete a user avatar

Is there any docs about the rest apis? Thanks.

    yoshua what is the request you made that triggered the 404?

      luceos https://bbs.wangyx.com/api/users/admin I tried to get user by id such as https://bbs.wangyx.com/api/users/1 , it works. But the first request doesn't work well.

        yoshua not sure but i think that you need a custom filter for that purpose?