Skip to main content

BRAccountLinkingConnection

Manages account linking connections to retail merchants. Inherits from NSObject.

SDK Version: 3.2.0

Declaration

@interface BRAccountLinkingConnection : NSObject
class BRAccountLinkingConnection : NSObject

Quick Reference

Properties

PropertyDescription
retailerThe linked retail merchant
usernameAccount username associated with the connection
lastExecutionTimeTimestamp of the most recent execution
lastExecutionCodeStatus code from the last execution attempt
isAuthenticatedWhether the connection is currently logged in
webviewAuthEnabledWhether users authenticate via the merchant's webpage
configurationConfiguration object controlling order search behavior

Initializers

InitializerDescription
initWithRetailer:Create a connection for a retailer
initWithRetailer:username:password:Create a connection with stored credentials

Properties

retailer (read-only)

@property (nonatomic, readonly) BRAccountLinkingRetailer retailer;
var retailer: BRAccountLinkingRetailer { get }

Identifies the linked retail merchant.


username (read-only)

@property (nonatomic, copy, readonly, nullable) NSString *username;
var username: String? { get }

The account username associated with the connection.


lastExecutionTime (read-only)

@property (nonatomic, readonly) NSTimeInterval lastExecutionTime;
var lastExecutionTime: TimeInterval { get }

Timestamp of the most recent execution.


lastExecutionCode (read-only)

@property (nonatomic, readonly) NSUInteger lastExecutionCode;
var lastExecutionCode: UInt { get }

Status code from the last execution attempt.


isAuthenticated (read-only)

@property (nonatomic, readonly) BOOL isAuthenticated;
var isAuthenticated: Bool { get }

It represents the logged in status of the connection. Check this property before calling loginUserForLinkedRetailer.


webviewAuthEnabled

@property (nonatomic) BOOL webviewAuthEnabled;
var webviewAuthEnabled: Bool { get set }

Set this property to YES if you want users to authenticate with merchant's webpage directly.

Default: YES


configuration

@property (nonatomic, strong, nullable) BRAccountLinkingConfiguration *configuration;
var configuration: BRAccountLinkingConfiguration? { get set }

A configuration object that defines the behavior when searching for new orders. See BRAccountLinkingConfiguration.


Initializers

init (Unavailable)

Default initializer is not available. Use one of the designated initializers below.


initWithRetailer:

- (nonnull instancetype)initWithRetailer:(BRAccountLinkingRetailer)retailer;
init(retailer: BRAccountLinkingRetailer)

Parameters:

ParameterDescription
retailerThe retailer to link

initWithRetailer:username:password:

- (nonnull instancetype)initWithRetailer:(BRAccountLinkingRetailer)retailer
username:(NSString * _Nullable)username
password:(NSString * _Nullable)password;
init(retailer: BRAccountLinkingRetailer, username: String?, password: String?)

Parameters:

ParameterDescription
retailerThe retailer to link
usernameThe account username
passwordThe account password