module documentation

Provide endpoints that mimic the v2 API for legacy discoverability.

Class JPEGResponse A FastAPI response with media_type set for a JPEG image.
Function add_v2_endpoints Add the v2 API endpoints for legacy discoverability.
Constant FAKE_ROUTES Undocumented
def add_v2_endpoints(thing_server: lt.ThingServer): (source)

Add the v2 API endpoints for legacy discoverability.

Old versions of OpenFlexure Connect use the v2 endpoints to check for microscopes. This provides these routes so the microscope can be discovered by old versions of connect.

FAKE_ROUTES: list[str] = (source)

Undocumented

Value
['/api/v2/', '/api/v2/streams/snapshot', '/api/v2/instrument/settings/name']