The BrightSign CLI tool bsc
is the command line interface for interacting with the Diagnostic Web Server (DWS).
This is the second version of bsc
, with the deprecated code being found here. This code contains breaking changes, so update with caution.
- Install the CLI
- Getting Started
- Filepath Naming Convention
- Key Features
- Requirements
- Contributing
- License
It is recommended to install the CLI through a package manager. You can use either npm or pnpm:
# Using npm
npm install --global @brightsign/bsc
# Using pnpm
pnpm add -g @brightsign/bsc
Before using most commands, you need to configure your BrightSign credentials. You can do this in one of two ways:
- Run the configuration wizard:
bsc configure
- Set the following environment variables:
# Required
BRIGHTSIGN_CLIENT_ID=your_client_id
BRIGHTSIGN_CLIENT_SECRET=your_client_secret
# Optional - specify one of these as a default
BRIGHTSIGN_NETWORK_NAME=your_network_name
BRIGHTSIGN_NETWORK_ID=your_network_id
Note: You can obtain your BrightSign Client ID and Secret by creating an application at https://adminpanel.bsn.cloud/.
Many commands require either a filePath
or a source
parameter to be passed in. When we refer to a file on the player, or any path locally (file or directory), this is filePath
. When referring to a directory on the player, this is source
or destination
.
To upload a file, for example:
bsc files upload --ip 192.168.1.1 --username admin --password yourpassword --source ./path-to-your-file --destination sd/path-on-player
Note that the --destination
option is optional, and without it the file will be uploaded to the root of the SD card. Also note that you can upload directories or files with --source
.
- Player Management: List and retrieve BrightSign player information.
- File Operations: Upload, download, delete, and list files.
- Registry Management: Get, set, and delete registry entries.
- System Information: Retrieve player information, including hardware details, network configuration, and system status.
- Power Management: Reboot, reset, and control player power state.
- Screenshot Capture: Take screenshots from connected players.
- Node.js 20.11.1 or later
- Network connectivity to your BrightSign player
We welcome contributions! Please see our CONTRIBUTING.md for guidelines on how to get started developing bsc
.
MIT License - See LICENSE file for details.
Connection Modes:
Almost all commands support both remote (BSN.Cloud) and local connection options:
- Remote (BSN.Cloud): Use the player's serial number with
--player <serial>
. This just requires internet access.- Local: Use the player's IP address with
--ip <address>
,--username <name>
(defaults toadmin
), and--password <password>
. Local DWS must be enabled on the player for this to work.Tip: If you are unsure which to use, remote is for cloud-managed devices and devices in a production environment, local is mostly for development work.
Here are some common commands and their expected outputs:
bsc players list
Expected output:
+--------------+-------------------+-------------------+
| Serial | Model | Status |
+--------------+-------------------+-------------------+
| UTF12481632 | XD234 | Online |
| UTF12481633 | XT1144 | Offline |
+--------------+-------------------+-------------------+
bsc players get --player UTF12481632
Expected output:
{
"serial": "UTF12481632",
"model": "XD234",
"firmware": "9.0.45",
"ip": "192.168.1.1",
...
}
bsc players get --ip 192.168.1.1 --username admin --password abcdefg
Expected output:
{
"serial": "UTF12481632",
"model": "XD234",
"firmware": "9.0.45",
"ip": "192.168.1.1",
...
}
bsc files upload --ip 192.168.1.1 --username admin --password abcdefg --source ./video.mp4 --destination sd
Expected output:
Uploading ./video.mp4 to sd on 192.168.1.1...
Upload complete.
bsc players screenshot --ip 192.168.1.1 --username admin --password abcdefg --output-path ./screen.jpg
Expected output:
Screenshot saved to ./screen.jpg