Contents

addUser(completionHandler:)

Adds a user to the home.

Declaration

func addUser(completionHandler completion: @escaping  @Sendable (HMUser?, (any Error)?) -> Void)
func addUser() async throws -> HMUser

Parameters

  • completion:

    The block executed after the request is processed.

    user

    The user that was added to the home.

    error

    nil on success; otherwise, error object indicating the reason for failure. error.userInfo[HMUserFailedAccessoriesKey] contains more information in case of failure. See Hmuserfailedaccessorieskey for more details.

See Also

Deprecated symbols