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

retrieving all registered paths / patterns #296

Open
h0ru5 opened this issue Jan 26, 2020 · 3 comments
Open

retrieving all registered paths / patterns #296

h0ru5 opened this issue Jan 26, 2020 · 3 comments

Comments

@h0ru5
Copy link

h0ru5 commented Jan 26, 2020

to create a lightweight automated api index, I wanted to retrieve all registered routes/patters with an existing handler and their verbs (basically tree traversal dumped to a data structure, resp. a map)

I found no possibility so far, so one would need to do this in the package, right?

@TitleBhoomtawath
Copy link

TitleBhoomtawath commented Mar 7, 2022

For reference, this is doable with
router.Endpoints(). It returns a slice of Endpoint.

@mitar
Copy link

mitar commented Mar 13, 2022

@TitleBhoomtawath I could not find Endpoints, are you sure it exists in this package?

@TitleBhoomtawath
Copy link

@mitar My bad. That's a function in our router, which wrap this package.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants