Documentation ¶
Index ¶
- Constants
- func Bitcoind(w http.ResponseWriter, req *http.Request, log *logger.L)
- func BitmarkCliExec(w http.ResponseWriter, req *http.Request, log *logger.L, command string, ...)
- func BitmarkPay(w http.ResponseWriter, req *http.Request, log *logger.L, command string)
- func BitmarkPayJobHash(w http.ResponseWriter, req *http.Request, log *logger.L)
- func BitmarkPayKill(w http.ResponseWriter, req *http.Request, log *logger.L)
- func Bitmarkd(w http.ResponseWriter, req *http.Request, webguiFilePath string, ...)
- func GetAndCheckCookie(w http.ResponseWriter, req *http.Request, log *logger.L) error
- func ListConfig(w http.ResponseWriter, req *http.Request, ...)
- func LoginBitmarkWebgui(w http.ResponseWriter, req *http.Request, ...)
- func LoginStatus(w http.ResponseWriter, configuration *configuration.Configuration, ...)
- func LogoutBitmarkWebgui(w http.ResponseWriter, req *http.Request, filePath string, ...)
- func LogoutBitmarkWebguiOnestep(w http.ResponseWriter, req *http.Request, filePath string, ...)
- func OnestepExec(w http.ResponseWriter, req *http.Request, log *logger.L, command string, ...)
- func Prooferd(w http.ResponseWriter, req *http.Request, webguiFilePath string, ...)
- func Register(service interface{})
- func SetBitmarkWebguiPassword(w http.ResponseWriter, req *http.Request, bitmarkWebguiConfigFile string, ...)
- func SetCORSHeader(w http.ResponseWriter, req *http.Request)
- func UpdateConfig(w http.ResponseWriter, req *http.Request, ...)
- func WriteGlobalErrorResponse(w http.ResponseWriter, err error, log *logger.L) error
- type BitmarkCliGenerateResponse
- type BitmarkCliInfoResponse
- type BitmarkCliIssueResponse
- type BitmarkCliTransferResponse
- type BitmarkIdentityType
- type BitmarkPayInfoResponse
- type BitmarkPaymentAddress
- type OnestepIssueFailResponse
- type OnestepIssueRequest
- type OnestepIssueResponse
- type OnestepSetupRequest
- type OnestepStatusRequest
- type OnestepStatusResponse
- type OnestepTransferFailResponse
- type OnestepTransferRequest
- type OnestepTransferResponse
- type Response
Constants ¶
View Source
const (
CookieName = "bitmark-webgui"
)
Variables ¶
This section is empty.
Functions ¶
func BitmarkCliExec ¶
func BitmarkCliExec(w http.ResponseWriter, req *http.Request, log *logger.L, command string, webguiFilePath string, configuration *configuration.Configuration)
POST /api/bitmarkCli/*
func BitmarkPay ¶
POST /api/bitmarkPay/info, pay, encrypt, status, result for info, pay, encrypt. They are calling bitmark-pay, will return a job hash, use status to know if the job is still running, when the status shows success, fail, stopped, use the job hash and result api to get the result if the result is nil, it means the async job failed.
func BitmarkPayJobHash ¶
Get /api/bitmarkPay
func BitmarkPayKill ¶
DELETE /api/bitmarkPay
func Bitmarkd ¶
func Bitmarkd(w http.ResponseWriter, req *http.Request, webguiFilePath string, webguiConfig *configuration.Configuration, log *logger.L)
POST /api/bitmarkd
func GetAndCheckCookie ¶
func ListConfig ¶
func ListConfig(w http.ResponseWriter, req *http.Request, bitmarkConfigFile, prooferdConfigFile string, log *logger.L)
Get /api/config
func LoginBitmarkWebgui ¶
func LoginBitmarkWebgui(w http.ResponseWriter, req *http.Request, configuration *configuration.Configuration, log *logger.L)
POST /api/login
func LoginStatus ¶
func LoginStatus(w http.ResponseWriter, configuration *configuration.Configuration, log *logger.L)
GET /api/login
func LogoutBitmarkWebgui ¶
func LogoutBitmarkWebgui(w http.ResponseWriter, req *http.Request, filePath string, webguiConfiguration *configuration.Configuration, log *logger.L)
POST /api/logout
func LogoutBitmarkWebguiOnestep ¶
func LogoutBitmarkWebguiOnestep(w http.ResponseWriter, req *http.Request, filePath string, webguiConfiguration *configuration.Configuration, log *logger.L)
POST /api/logoutOnestep
func OnestepExec ¶
func OnestepExec(w http.ResponseWriter, req *http.Request, log *logger.L, command string, webguiFilePath string, configuration *configuration.Configuration)
POST /api/onestep/status, setup, issue, transfer
func Prooferd ¶
func Prooferd(w http.ResponseWriter, req *http.Request, webguiFilePath string, webguiConfig *configuration.Configuration, log *logger.L)
POST /api/bitmarkd
func SetBitmarkWebguiPassword ¶
func SetBitmarkWebguiPassword(w http.ResponseWriter, req *http.Request, bitmarkWebguiConfigFile string, configs *configuration.Configuration, log *logger.L)
POST /api/password
func SetCORSHeader ¶
func SetCORSHeader(w http.ResponseWriter, req *http.Request)
func UpdateConfig ¶
func UpdateConfig(w http.ResponseWriter, req *http.Request, chain, bitmarkConfigFile, prooferdConfigFile string, log *logger.L)
Post /api/config
Types ¶
type BitmarkCliInfoResponse ¶
type BitmarkCliInfoResponse struct { Default_identity string `json:"default_identity"` Network string `json:"network"` Connect string `json:"connect"` Identities []BitmarkIdentityType `json:"identities"` }
type BitmarkCliIssueResponse ¶
type BitmarkCliIssueResponse struct { AssetId string `json:"assetId"` IssueIds []string `json:"issueIds"` PaymentAddress []BitmarkPaymentAddress `json:"paymentAddress"` }
type BitmarkCliTransferResponse ¶
type BitmarkCliTransferResponse struct { TransferId string `json:"transferId"` PaymentAddress []BitmarkPaymentAddress `json:"paymentAddress"` }
type BitmarkIdentityType ¶
type BitmarkPayInfoResponse ¶
type BitmarkPaymentAddress ¶
type OnestepIssueFailResponse ¶
type OnestepIssueFailResponse struct { CliResult BitmarkCliIssueResponse `json:"cli_result"` FailStart int `json:"fail_start"` }
type OnestepIssueRequest ¶
type OnestepIssueRequest struct { Network string `json:"network"` PayConfig string `json:"pay_config"` Identity string `json:"identity"` Asset string `json:"asset"` Description string `json:"description"` Fingerprint string `json:"fingerprint"` Quantity int `json:"quantity"` Password string `json:"password"` }
type OnestepIssueResponse ¶
type OnestepIssueResponse struct { CliResult BitmarkCliIssueResponse `json:"cli_result"` JobHash string `json:"job_hash"` }
type OnestepSetupRequest ¶
type OnestepSetupRequest struct { Network string `json:"network"` CliConfig string `json:"cli_config"` PayConfig string `json:"pay_config"` Connect string `json:"connect"` Identity string `json:"identity"` Description string `json:"description"` CliPassword string `json:"cli_password"` PayPassword string `json:"pay_password"` }
type OnestepStatusRequest ¶
type OnestepStatusResponse ¶
type OnestepStatusResponse struct { CliResult BitmarkCliInfoResponse `json:"cli_result"` JobHash string `json:"job_hash"` }
type OnestepTransferFailResponse ¶
type OnestepTransferFailResponse struct {
CliResult BitmarkCliTransferResponse `json:"cli_result"`
}
type OnestepTransferRequest ¶
type OnestepTransferResponse ¶
type OnestepTransferResponse struct { CliResult BitmarkCliTransferResponse `json:"cli_result"` JobHash string `json:"job_hash"` }
Click to show internal directories.
Click to hide internal directories.