Parker Rex
All projects

Eight Sleep Controller

Reverse-engineered Eight Sleep's API to control a smart bed with hardware buttons instead of the app.

Overview

SmartBedAPI authenticates through OAuth, discovers devices, and sets temperature for each bed side. A ButtonController abstraction supports GPIO, USB HID, serial, and wireless inputs.

Problem

Adjusting bed temperature through the iPhone app was slower than using a physical control, and Eight Sleep has no official API.

Solution

Used mitmproxy with custom Python scripts to bypass certificate pinning and capture the auth flow, then built a TypeScript client.

Lessons learned

  • Certificate pinning can be bypassed at the TLS interception layer.
  • API reverse-engineering is mostly pattern recognition after the first capture.
  • Designing hardware extensibility upfront kept later integrations cheap.