🪛Web Application Integration

Bring support for the Looking Glass display to your web app

The best way to integrate with the Bridge Media Player using a web app is to use the Bridge.js libraryarrow-up-right. This is the same library that we use for Looking Glass Blocksarrow-up-right. The Bridge.js library exposes typesafe objects and methods for interacting with the Bridge REST API. See the Bridge.js README filearrow-up-right for detailed information on how to use Bridge.js in your web application.

REST API Reference

Get Bridge version

Endpoint: /bridge_version

Example Payload: none

Example Response:

{
    "name": "value",
    "payload": {
        "name": "payload",
        "type": "STRING",
        "value": "2.4.7"
    },
    "status": {
        "name": "status",
        "type": "WSTRING",
        "value": "Completion"
    }
}

Start media player session

Endpoint: /enter_orchestration

Example Payload:

Example Response:

Query Looking Glass displays

Endpoint: /available_output_devices

Example Payload:

Example Response:

Show the media player window

Endpoint: /show_window

Example Payload:

Example Response:

Create new playlist

Endpoint: /instance_playlist

Example Payload:

Example Response:

Add new playlist item

Endpoint: /insert_playlist_entry

Example Payload:

Example Response:

Play a playlist

Endpoint: /play_playlist

Example Payload:

Example Response:

Playback controls

Endpoints:

/transport_control_play

/transport_control_pause

/transport_control_next

/transport_control_previous

Example Payload:

Example Response:

Seek to playlist index

Endpoint: /transport_control_seek_to_index

Example Payload:

Example Response:

Delete playlist

Endpoint: /delete_playlist

Example Payload:

Example Response:

Last updated

Was this helpful?