Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type APICredential ¶
type APICredential struct { ClientID string `yaml:"clientId"` ClientKey string `yaml:"clientKey"` SecretKey string `yaml:"secretKey"` CallbackToken string `yaml:"callbackToken"` }
APICredential stores the credential used for connecting to an API service
type DBCredential ¶
type DBCredential struct { Host string `yaml:"host"` Port int `yaml:"port"` UserName string `yaml:"username"` Password string `yaml:"password"` DBName string `yaml:"dbname"` }
DBCredential stores database credential
type PaymentSecret ¶
type PaymentSecret struct { Midtrans APICredential `yaml:"midtrans"` Xendit APICredential `yaml:"xendit"` }
PaymentSecret stores secret for payment gateway
type Secret ¶
type Secret struct { DB DBCredential `yaml:"db"` Payment PaymentSecret `yaml:"payment"` }
Secret used to keep App Secret.
func LoadSecret ¶
LoadSecret reads the file from path and return Secret
func LoadSecretFromBytes ¶
LoadSecretFromBytes reads the secret file from data bytes
Click to show internal directories.
Click to hide internal directories.