SDK Functions Definition

In this article, you will understand the definitions of various functions within our iOS SDK.

FunctionsDefinitions
public init(clientID: String, clientSecret: String, authorizeUrl: URLConvertible, accessTokenUrl: URLConvertible? = nil, responseType: String, contentType: String? = nil, baseURL: String)Initializes the SDK. This function needs to be called first before the SDK usage to set up all the important parameters.
open func authorize(withCallbackURL callbackURL: URLConvertible?, scope: String, state: String, parameters: Parameters = [:], headers: RMSOAuth.Headers? = nil, completionHandler completion: @escaping TokenCompletionHandler) -> RMSOAuthRequestHandle?The SDK function to authorize the user.
open func authorize(withCallbackURL callbackURL: URLConvertible?, scope: String, state: String, parameters: Parameters = [:], headers: RMSOAuth.Headers? = nil, completionHandler completion: @escaping TokenCompletionHandler) -> RMSOAuthRequestHandle?Disables the debug logs into the logcat. Logging is disabled by default.
open func getTerminalList( parameters: RMSOAuth.Parameters = [:], headers: RMSOAuth.Headers? = nil, completionHandler completion: RMSOAuthHTTPRequest.CompletionHandler?) -> RMSOAuthRequestHandle?The SDK function to list all the terminals.
open func getTransactionList( parameters: RMSOAuth.Parameters = [:], headers: RMSOAuth.Headers? = nil, completionHandler completion: RMSOAuthHTTPRequest.CompletionHandler?) -> RMSOAuthRequestHandle?Lists all the transactions.
open func getTransactionListByType(transactionType: String, parameters: RMSOAuth.Parameters = [:], headers: RMSOAuth.Headers? = nil, completionHandler completion: RMSOAuthHTTPRequest.CompletionHandler?) -> RMSOAuthRequestHandle?Filters all the transactions by type.
open func getTransactionListByStage(transactionStage: String, parameters: RMSOAuth.Parameters = [:], headers: RMSOAuth.Headers? = nil, completionHandler completion: RMSOAuthHTTPRequest.CompletionHandler?) -> RMSOAuthRequestHandle?Filters all the transactions by stage.
open func getTransactionListByStatus(transactionStatus: String, parameters: RMSOAuth.Parameters = [:], headers: RMSOAuth.Headers? = nil, completionHandler completion: RMSOAuthHTTPRequest.CompletionHandler?) -> RMSOAuthRequestHandle?Filters all the transactions by status.
open func checkTransactionStatus(transactionId: String, parameters: RMSOAuth.Parameters = [:], headers: RMSOAuth.Headers? = nil, completionHandler completion: RMSOAuthHTTPRequest.CompletionHandler?) -> RMSOAuthRequestHandle?Retrieves the transaction details.
open func setActiveTerminal(terminal: NSDictionary)Sets the active terminal among multiple terminals.
open func setActiveTerminalById(terminalId: NSString)Sets the active terminals by the terminal ID.
open func requestReportByType(type: String, parameters: RMSOAuth.Parameters = [:], headers: RMSOAuth.Headers? = nil, body: Data? = nil, completionHandler completion: RMSOAuthHTTPRequest.CompletionHandler?) -> RMSOAuthRequestHandle?Creates the report from the active terminal.
open func cancelTransaction(transactionId: String, parameters: RMSOAuth.Parameters = [:], headers: RMSOAuth.Headers? = nil, completionHandler completion: RMSOAuthHTTPRequest.CompletionHandler?) -> RMSOAuthRequestHandle?Cancels the transactions.
open func renewAccessToken(accessTokenUrl: URLConvertible?, withRefreshToken refreshToken: String, parameters: RMSOAuth.Parameters? = nil, headers: RMSOAuth.Headers? = nil, contentType: String? = nil, accessTokenBasicAuthentification: Bool = false, completionHandler completion: @escaping RMSOAuth.TokenCompletionHandler) -> RMSOAuthRequestHandle?Refreshes the token

💬 We're here to help!

If you're looking for help, shoot us an email. Please include a description of the issues that you are running into.