Adds account_id to channel create (and update), missing functions

This commit is contained in:
Thomas Zarebczan 2019-09-05 18:16:49 -04:00 committed by Niko Storni
parent d032c842d5
commit 1f1848a408

View file

@ -259,6 +259,7 @@ type ChannelCreateOptions struct {
WebsiteURL *string `json:"website_url,omitempty"` WebsiteURL *string `json:"website_url,omitempty"`
CoverURL *string `json:"cover_url,omitempty"` CoverURL *string `json:"cover_url,omitempty"`
Featured []string `json:"featured,omitempty"` Featured []string `json:"featured,omitempty"`
AccountID *string `json:"account_id,omitempty"`
} }
func (d *Client) ChannelCreate(name string, bid float64, options ChannelCreateOptions) (*TransactionSummary, error) { func (d *Client) ChannelCreate(name string, bid float64, options ChannelCreateOptions) (*TransactionSummary, error) {
@ -436,6 +437,13 @@ func (d *Client) Status() (*StatusResponse, error) {
return response, d.call(response, "status", map[string]interface{}{}) return response, d.call(response, "status", map[string]interface{}{})
} }
func (d *Client) TransactionList(account *string) (*TransactionListResponse, error) {
response := new(TransactionListResponse)
return response, d.call(response, "transaction_list", map[string]interface{}{
"account_id": account,
})
}
func (d *Client) UTXOList(account *string) (*UTXOListResponse, error) { func (d *Client) UTXOList(account *string) (*UTXOListResponse, error) {
response := new(UTXOListResponse) response := new(UTXOListResponse)
return response, d.call(response, "utxo_list", map[string]interface{}{ return response, d.call(response, "utxo_list", map[string]interface{}{
@ -443,6 +451,13 @@ func (d *Client) UTXOList(account *string) (*UTXOListResponse, error) {
}) })
} }
func (d *Client) UTXORelease(account *string) (*UTXOReleaseResponse, error) {
response := new(UTXOReleaseResponse)
return response, d.call(response, "utxo_release", map[string]interface{}{
"account_id": account,
})
}
func (d *Client) Get(uri string) (*GetResponse, error) { func (d *Client) Get(uri string) (*GetResponse, error) {
response := new(GetResponse) response := new(GetResponse)
return response, d.call(response, "get", map[string]interface{}{ return response, d.call(response, "get", map[string]interface{}{