import ( "github.com/juju/juju/api" "github.com/juju/juju/api/watcher" ) func GetUnitsStatus(apiConn api.Connection, modelName string) ([]watcher.Change, error) { st, err := apiConn.State() if err != nil { return nil, err } model, err := st.ModelByName(modelName) if err != nil { return nil, err } return model.WatchUnits() }This code connects to a Juju API server using an "api.Connection" object, retrieves the state of the given model using the "State" package, and then calls the "WatchUnits" method to return a stream of changes to the status of all units in the model. Overall, the "State" package in the Juju API client library provides developers with a powerful and flexible way to manage Juju deployments programmatically, and is an essential tool for building scalable and robust cloud applications.