go-unifi

Migrating

Pick the right guide — upgrading go-unifi 1.x to 2.0, or switching from paultyng/go-unifi.

There are two ways you can arrive at go-unifi 2.0.0. Pick the guide that matches where you're coming from.

What changed in 2.0.0

The headline changes, all covered in detail by the 1.x upgrade guide:

  • API-key authentication only. Username/password login was removed. You authenticate with an API key on a UniFi OS console running UniFi Network 9.0.114 or newer (a Network Application version, distinct from the UniFi OS version).
  • Module path is now /v2. Import github.com/filipowm/go-unifi/v2/unifi.
  • TLS verification is on by default. The old VerifySSL field became SkipVerifySSL — renamed and inverted.
  • A second API surface. c.Official() exposes the official UniFi OpenAPI (integration/v1) alongside the legacy Internal API. It's additive — see Choosing a surface.
  • Go 1.26 is the minimum toolchain.

Want the exhaustive, status-tracked changelog with provenance for every change? See Breaking changes.

Where to go next

On this page