Channels API

Control or query what you're watching.

The Channels app exposes a simple HTTP API that you can reach on port 57000 of the IP address of your device. Learn more about how you can use it below. Monitor what's currently playing, integrate Channels into your home automation, or just make your family think there are ghosts.

Note

The Channels API will be as available as the platform it's running on allows. For tvOS, this means only when Channels is open and active. For Android and Fire TV, it will work if Channels is active or backgrounded, but only if it has been launched at least once.

Discovery

The Channels API advertisies itself with Bonjour. You can search for all of the apps on your network with Bonjour using the _channels_app._tcp service name.

HTTP API

Info

GET /api/status - Player's current status

GET /api/favorite_channels - List of favorite channels

Control

POST /api/toggle_mute - Toggle mute on and off

POST /api/pause - Pause playback

POST /api/resume - Resume playback

POST /api/stop - Stop playback

POST /api/seek/{seconds} - Seek in timeline by seconds

POST /api/seek_forward - Seek ahead duration in settings

POST /api/seek_backward - Seek back duration in settings

POST /api/skip_forward - Skip to the next chapter mark

POST /api/skip_backward - Skip to the previous chapter mark

POST /api/play/channel/{channel_number} - Play a channel

POST /api/play/recording/{recording_id} - Play a recording from Channels DVR

Example

You can simply use CURL to query or control Channels with the Channels API. All methods return a JSON representation of the current status of Channels.

$ curl -X POST http://192.168.1.50:57000/api/pause
{
  "status": "paused",
  "muted": false,
  "channel": {
    "number": "552",
    "name": "TBS HD",
    "image_url": "http://fanc.tmsimg.com/h5/NowShowing/58515/s58515_h5_aa.png"
  },
  "now_playing": {
    "title": "Seinfeld",
    "episode_title": "The Truth",
    "season_number": 3,
    "episode_number": 2,
    "summary": "A woman (Valerie Mahaffey) wants to know why George doesn't want to see her."
    "image_url": "http://fanc.tmsimg.com/assets/p183875_b_h6_ab.jpg",
  }
}

API Clients

Use these API clients in your existing projects. They're ready to roll. Let us know if you make one yourself.

  • rbchannels - Ruby client for talking directly to your Channels app.
  • pychannels - Python client for talking directly to your Channels app.

Home Automation

Add Channels to your smart home with these integrations. Let us know if you make one yourself.

  • Home Assistant - Integrate Channels as a media player with Home Assistant.

iOS Shortcuts

iOS 12 introduces a way to add automations that can be run manually or triggred with Siri via your voice.