ReceiptsAPI
public enum ReceiptsAPI
Caseless enumeration with static methods to send Receipt Requests
-
Sends a request to get receipts from the API.
Declaration
Swift
public static func getReceipts(with parameters: Parameters? = nil, completion: ResponseCompletion<[Receipt]> = nil)Parameters
parametersThe
Parametersto apply. Commonly used parameter keys for this list is:completionThe closure to be executed once the request has finished.
-
Sends a request to get a specific receipt with ID and optional
Parameters.Declaration
Swift
public static func getReceipt(id: String, with parameters: Parameters?, completion: ResponseCompletion<Receipt> = nil)Parameters
idID of the receipt.
parametersThe
Parametersto apply. Commonly used parameter keys for this list is:completionThe closure to be executed once the request has finished.
-
Sends a request to get a create a new receipt.
Declaration
Swift
public static func submitReceipt(image: UIImage, completion: ResponseCompletion<Receipt> = nil)Parameters
imageThe image of the receipt as
UIImage.completionThe closure to be executed once the request has finished.
View on GitHub
ReceiptsAPI Enumeration Reference