BetterCallDevOperation
public struct BetterCallDevOperation : Codable
A model matching the response that comes back from BetterCallDev’s API: v1/opg/<operation-hash>
-
An ID used by BCD
Declaration
Swift
public let id: Int
-
The operation hash
Declaration
Swift
public let hash: String
-
The operations numeric counter
Declaration
Swift
public let counter: Int
-
Indicating if the operation was successful, failed, backtracked etc.
Declaration
Swift
public let status: String
-
Detailed error objects, also including unique smart contract errors
Declaration
Swift
public let errors: [BetterCallDevOperationError]?
-
Helper to determine if the operation failed or not
Declaration
Swift
public func isFailed() -> Bool
-
Helper to check for existance of errors
Declaration
Swift
public func containsError() -> Bool
-
When looking for more detailed errors through Better-Call.dev, effectively we are looking for an error containing a
location
and/or awith
. We already have the other bits, but only location and with can identify the specific Dexter errorDeclaration
Swift
public func moreDetailedError() -> BetterCallDevOperationError?