Documentation
¶
Overview ¶
Package constant defines common constants used across the application. It includes error codes, status values, and other shared constant definitions.
Index ¶
Constants ¶
View Source
const ( // HeaderUserAgent represents the User-Agent HTTP header. HeaderUserAgent = "User-Agent" // HeaderRealIP represents the X-Real-Ip HTTP header. HeaderRealIP = "X-Real-Ip" // HeaderForwardedFor represents the X-Forwarded-For HTTP header. HeaderForwardedFor = "X-Forwarded-For" // HeaderForwardedHost represents the X-Forwarded-Host HTTP header. HeaderForwardedHost = "X-Forwarded-Host" // HeaderHost represents the Host HTTP header. HeaderHost = "Host" // DSL represents the domain-specific language identifier. DSL = "dsl" // FileExtension represents the gold file extension. FileExtension = ".gold" // HeaderID represents the X-Request-Id HTTP header. HeaderID = "X-Request-Id" // IdempotencyKey represents the X-Idempotency HTTP header. IdempotencyKey = "X-Idempotency" // IdempotencyTTL represents the X-TTL HTTP header. IdempotencyTTL = "X-TTL" // Authorization represents the Authorization HTTP header. Authorization = "Authorization" // Basic represents the Basic authentication method. Basic = "Basic" // BasicAuth represents the Basic Auth authentication method. BasicAuth = "Basic Auth" // WWWAuthenticate represents the WWW-Authenticate HTTP header. WWWAuthenticate = "WWW-Authenticate" )
View Source
const ( // MetadataID represents the metadata identifier key. MetadataID = "metadata_id" // MetadataTraceparent represents the traceparent metadata key. MetadataTraceparent = "traceparent" // MetadataAuthorization represents the authorization metadata key. MetadataAuthorization = "authorization" )
View Source
const ( // DEBIT represents a debit transaction type. DEBIT = "DEBIT" // CREDIT represents a credit transaction type. CREDIT = "CREDIT" // DefaultExternalAccountAliasPrefix represents the default prefix for external account aliases. DefaultExternalAccountAliasPrefix = "@external/" // ExternalAccountType represents the external account type identifier. ExternalAccountType = "external" )
Variables ¶
View Source
var ( // ErrInsufficientFunds indicates account has insufficient funds for transaction. ErrInsufficientFunds = errors.New("0018") // ErrAccountIneligibility indicates account is not eligible for transaction. ErrAccountIneligibility = errors.New("0019") // ErrAccountStatusTransactionRestriction indicates account status prevents transactions. ErrAccountStatusTransactionRestriction = errors.New("0024") // ErrAssetCodeNotFound indicates the specified asset code does not exist. ErrAssetCodeNotFound = errors.New("0034") // ErrTransactionValueMismatch indicates transaction values do not match expected amounts. ErrTransactionValueMismatch = errors.New("0073") // ErrTransactionAmbiguous indicates transaction details are ambiguous or unclear. ErrTransactionAmbiguous = errors.New("0090") // ErrOverFlowInt64 indicates an integer overflow occurred during calculation. ErrOverFlowInt64 = errors.New("0097") )
Functions ¶
This section is empty.
Types ¶
Click to show internal directories.
Click to hide internal directories.