exception

package
v0.0.0-...-9fd7169 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 20, 2024 License: MIT Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BadRequestError

func BadRequestError(errorMessage string) error

func NotFoundError

func NotFoundError(errorMessage string) error

Types

type BadRequest

type BadRequest string
const (
	NATIONAL_ID_IS_REQUIRED         BadRequest = "NATIONAL_ID_IS_REQUIRED"
	MERCHANT_ID_IS_REQUIRED         BadRequest = "MERCHANT_ID_IS_REQUIRED"
	CUSTOMER_ID_IS_REQUIRED         BadRequest = "CUSTOMER_ID_IS_REQUIRED"
	TRANSACTION_CODE_IS_REQUIRED    BadRequest = "TRANSACTION_CODE_IS_REQUIRED"
	CARD_TOKEN_IS_REQUIRED          BadRequest = "CARD_TOKEN_IS_REQUIRED"
	NAME_IS_REQUIRED                BadRequest = "NAME_IS_REQUIRED"
	INVALID_AMOUNT                  BadRequest = "INVALID_AMOUNT"
	INSUFFICIENT_FUNDS              BadRequest = "INSUFFICIENT_FUNDS"
	INVALID_TRANSACTION             BadRequest = "INVALID_TRANSACTION"
	INVALID_CARD_TOKEN              BadRequest = "INVALID_CARD_TOKEN"
	TRANSACTION_IS_ALREADY_REFUNDED BadRequest = "TRANSACTION_IS_ALREADY_REFUNDED"

	UNAVAILABLE_NATIONAL_ID BadRequest = "UNAVAILABLE_NATIONAL_ID"
	UNAVAILABLE_MERCHANT_ID BadRequest = "UNAVAILABLE_MERCHANT_ID"
)

type BadRequestException

type BadRequestException struct {
	ErrorMessage string
}

func (*BadRequestException) Error

func (badRequestException *BadRequestException) Error() string

type NotFound

type NotFound string
const (
	CUSTOMER_NOT_FOUND    NotFound = "CUSTOMER_NOT_FOUND"
	MERCHANT_NOT_FOUND    NotFound = "MERCHANT_NOT_FOUND"
	TRANSACTION_NOT_FOUND NotFound = "TRANSACTION_NOT_FOUND"
)

type NotFoundException

type NotFoundException struct {
	ErrorMessage string
}

func (*NotFoundException) Error

func (notFoundException *NotFoundException) Error() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL