Skip to content

Make API URLs more easily accessible #1474

Open
@cbunicef

Description

@cbunicef

As a PLATFORM OWNER I would like to be able to access the API via an easy to remember URL.

Right now I see that https://sandbox.iogt.site/api/v1/questionnaires/ works

But I can't remember what the base URL for the API is, where the documentation of endpoints is. These URLs all resolve to an error page because Wagtail interprets them within the URL scope for the content:

https://sandbox.iogt.site/api/v1/ --> https://sandbox.iogt.site/en/api/v1/ (note /en/)
https://sandbox.iogt.site/api/v1/docs/
https://sandbox.iogt.site/api/v1/doc/

It would be easy to find the API URL if all URLs under /api/v1/ that are NOT within valid endpoints (including /api/v1) redirect to the API documentation page.

I'm not sure if this is best practice, but it should be easy for the user to end up at the documentation for the API if they don't know the exact URLs.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions