GitHub user dosubot[bot] added a comment to the discussion: Create role using API
<!-- Answer --> The /api/v1/security/roles/search endpoint does exist in the Superset codebase and is the correct API for listing roles, but it must be accessed with a trailing slash: /api/v1/security/roles/search/—omitting the slash can result in a 404 error because there is no handler for GET on /api/v1/security/roles/ without /search/ [source](https://github.com/apache/superset/blob/98b35125c2a562bb2a61a26e6acd3430339320aa/superset/security/api.py). If you’re still getting a 404 with the correct path, please check your Superset version (older or customized deployments may not have this endpoint), and make sure any reverse proxy or URL prefix isn’t stripping or altering the endpoint or trailing slash. If everything looks correct, check your Superset logs for more details on why the endpoint isn’t available. <!-- Dosu Comment Footer --> *To reply, just mention [@dosu](https://go.dosu.dev/dosubot).* --- <sup>How did I do? [Good](https://app.dosu.dev/response-feedback/3afc7c02-2722-49b6-95f8-dbf891715e36?feedback_type=great_response) | [Irrelevant](https://app.dosu.dev/response-feedback/3afc7c02-2722-49b6-95f8-dbf891715e36?feedback_type=irrelevant_answer) | [Incorrect](https://app.dosu.dev/response-feedback/3afc7c02-2722-49b6-95f8-dbf891715e36?feedback_type=incorrect_sources) | [Verbose](https://app.dosu.dev/response-feedback/3afc7c02-2722-49b6-95f8-dbf891715e36?feedback_type=too_verbose) | [Hallucination](https://app.dosu.dev/response-feedback/3afc7c02-2722-49b6-95f8-dbf891715e36?feedback_type=hallucination) | [Report 🐛](https://app.dosu.dev/response-feedback/3afc7c02-2722-49b6-95f8-dbf891715e36?feedback_type=bug_report) | [Other](https://app.dosu.dev/response-feedback/3afc7c02-2722-49b6-95f8-dbf891715e36?feedback_type=other)</sup> [](https://go.dosu.dev/discord-bot) [](https://twitter.com/intent/tweet?text=%40dosu_ai%20helped%20me%20solve%20this%20issue!&url=https%3A//github.com/apache/superset/discussions/33878) GitHub link: https://github.com/apache/superset/discussions/33878#discussioncomment-13558913 ---- This is an automatically sent email for [email protected]. To unsubscribe, please send an email to: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
