-
Notifications
You must be signed in to change notification settings - Fork 0
/
external_fund_move.go
38 lines (33 loc) · 1.32 KB
/
external_fund_move.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
package transactapi
import (
"net/http"
)
type ExternalFundMoveRequest struct {
ClientID string `json:"clientID"`
DeveloperAPIKey string `json:"developerAPIKey"`
AccountID string `json:"accountId"`
OfferingID string `json:"offeringId"`
TradeID string `json:"tradeId"`
NickName string `json:"NickName"`
Amount int64 `json:"amount"`
Description string `json:"description"`
CheckNumber string `json:"checkNumber"`
CreatedIPAddress string `json:"createdIpAddress"`
}
type ExternalFundMoveResponse struct {
StatusCode string `json:"statusCode"`
StatusDesc string `json:"statusDesc"`
TradeFinancialDetails []tradeFinancialDetail `json:"TradeFinancialDetails"`
}
type tradeFinancialDetail struct {
AccountID string `json:"accountId"`
TradeID string `json:"tradeId"`
OfferingID string `json:"offeringId"`
TotalAmount string `json:"totalAmount"`
RefNum string `json:"RefNum"`
FundStatus string `json:"fundStatus"`
}
// Reference: https://transactapi.readme.io/reference/externalfundmove
func (c *Client) ExternalFundMove(req *ExternalFundMoveRequest) (*ExternalFundMoveResponse, error) {
return request[ExternalFundMoveRequest, ExternalFundMoveResponse](c, http.MethodPost, EndpointExternalFundMove, req)
}