SudoVirtualCardsSimulatorError

public enum SudoVirtualCardsSimulatorError : Error, Equatable

Errors receieved from virtual cards simulator.

  • Not signed in.

    Declaration

    Swift

    case notSignedIn
  • Configuration is invalid.

    Declaration

    Swift

    case invalidConfig
  • Card information supplied did not match any record on the service.

    Declaration

    Swift

    case cardNotFound
  • Card is in a state that is considered irregular.

    Declaration

    Swift

    case cardStateError
  • Transaction information supplied did not match a transaction on the service.

    Declaration

    Swift

    case transactionNotFound
  • Two currency types do not match or are unsupported.

    Declaration

    Swift

    case currencyMismatch
  • Merchant information supplied did not match a merchant on the service.

    Declaration

    Swift

    case merchantNotFound
  • Attempt to reverse an amount larger than the remaining pending amount of an authorization

    Declaration

    Swift

    case excessiveReversal
  • Attempt to refund an amount larger than the remaining settled amount of a debit

    Declaration

    Swift

    case excessiveRefund
  • Attempt to expiry an authorization that is already expired

    Declaration

    Swift

    case alreadyExpired
  • Transaction type is invalid/illegal.

    Declaration

    Swift

    case InvalidTransactionType
  • Simulate authorization API call failed generically - this is generally a sign of a programmatic failure or bug within the kit.

    Declaration

    Swift

    case simulateAuthorizationFailed
  • Simulate incremental authorization API call failed generically - this is generally a sign of a programmatic failure or bug within the kit.

    Declaration

    Swift

    case simulateIncrementalAuthorizationFailed
  • Simulate reversal API call failed generically - this is generally a sign of a programmatic failure or bug within the kit.

    Declaration

    Swift

    case simulateReversalFailed
  • Simulate authorization expiry API call failed generically - this is generally a sign of a programmatic failure or bug within the kit.

    Declaration

    Swift

    case simulateAuthorizationExpiryFailed
  • Simulate refund API call failed generically - this is generally a sign of a programmatic failure or bug within the kit.

    Declaration

    Swift

    case simulateRefundFailed
  • Simulate credit API call failed generically - this is generally a sign of a programmatic failure or bug within the kit.

    Declaration

    Swift

    case simulateCreditFailed
  • Simulate debit API call failed generically - this is generally a sign of a programmatic failure or bug within the kit.

    Declaration

    Swift

    case simulateDebitFailed
  • Get simulator merchants API call failed generically - this is generally a sign of a programmatic failure or bug within the kit.

    Declaration

    Swift

    case getSimulatorMerchantsFailed
  • Get simulator conversion rates API call failed generically - this is generally a sign of a programmatic failure or bug within the kit.

    Declaration

    Swift

    case getSimulatorConversionRatesFailed
  • Indicates that the request operation failed due to authorization error. This maybe due to the authentication token being invalid or other security controls that prevent the user from accessing the API.

    Declaration

    Swift

    case notAuthorized
  • Operation failed due to an invalid request. This maybe due to the version mismatch between the client and the backend.

    Declaration

    Swift

    case invalidRequest
  • Indicates that there were too many attempts at sending API requests within a short period of time.

    Declaration

    Swift

    case rateLimitExceeded
  • Indicates that an internal server error caused the operation to fail. The error is possibly transient and retrying at a later time may cause the operation to complete successfully

    Declaration

    Swift

    case serviceError
  • Indicates that a GraphQL error was returned by the backend.

    Declaration

    Swift

    case graphQLError(description: String)
  • An internal error has occurred - contact the SudoPlatform team for more information.

    Declaration

    Swift

    case internalError(_: String)
  • Indicates that the request failed due to connectivity, availability or access error.

    Declaration

    Swift

    case requestFailed(response: HTTPURLResponse?, cause: Error?)
  • Indicates that a fatal error occurred. This could be due to coding error, out-of-memory condition or other conditions that is beyond control of SudoVirtualCardsSimulator implementation.

    Declaration

    Swift

    case fatalError(description: String)

Conformance: Equatable

  • Declaration

    Swift

    public static func == (lhs: SudoVirtualCardsSimulatorError, rhs: SudoVirtualCardsSimulatorError) -> Bool