ESTRequestRegisterDevice

@interface ESTRequestRegisterDevice : ESTRequestPostJSON

Request allows to register device in Estimote Cloud. After registration device can remotely receive information about pending settings.

  • Initialise request with Device Token.

    Declaration

    Objective-C

    - (nonnull instancetype)initWithDeviceToken:(nonnull NSData *)deviceToken;

    Swift

    init(deviceToken: Data)

    Parameters

    deviceToken

    Device token delivered in application:didRegisterForRemoteNotificationsWithDeviceToken: method of App Delegate.

    Return Value

    Instance of request.

  • Methods allows to send request with completion block invoked as a result.

    Declaration

    Objective-C

    - (void)sendRequestWithCompletion:
        (nonnull ESTRequestRegisterDeviceBlock)completion;

    Swift

    func sendRequest(completion: @escaping ESTRequestRegisterDeviceBlock)

    Parameters

    completion

    Completion block with returned data (NSError object optional).