Skip to content

Add an HTML endpoint for /api with interactive docs #1418

Open
@bollwyvl

Description

@bollwyvl

References

Problem

Finding the docs for the REST API is semi-annoying, and then not particularly interactive.

Proposed Solution

If a user visits e.g. http://127.0.0.1:8888/api in a browser, show them an interactive HTML application (that we don't have to write).

Additional context

This could be achieved by sniffing the accept header on /api in .

The static assets could be provisioned via (likely) some additional npm packages and a small jinja template to inject client settings (e.g. _xsrf).

We ship the OpenAPI Specification for the Jupyter Server REST API. There are a number of static HTML apps that consume OpenAPI specs, and present the spec as human-centric UI, and can also make live requests via JS. Some examples:

This could be demonstrated initially with an extension.

A longer term play would be to build this type of content with the modern Jupyter Client framework, such that it would inherit local theme options.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions