From c142d4dc4be42f30d0acb3e2e4bd669a22626414 Mon Sep 17 00:00:00 2001 From: Ed Harrod Date: Fri, 23 Feb 2024 11:57:03 +0000 Subject: [PATCH] api: Regenerate types - add TransferID (#122) --- api.go | 22 ++++++++++++++++------ types.go | 7 +++++-- 2 files changed, 21 insertions(+), 8 deletions(-) diff --git a/api.go b/api.go index 4f34262..f894a46 100644 --- a/api.go +++ b/api.go @@ -35,6 +35,9 @@ type CancelWithdrawalResponse struct { // Status Status Status `json:"status"` + // Transfer ID is the identifier of the Withdrawal's transfer once it completes. + TransferId string `json:"transfer_id"` + // Type distinguishes between different withdrawal methods where more than one is supported // for the given currency. Type string `json:"type"` @@ -188,6 +191,9 @@ type CreateWithdrawalResponse struct { // Status Status Status `json:"status"` + // Transfer ID is the identifier of the Withdrawal's transfer once it completes. + TransferId string `json:"transfer_id"` + // Type distinguishes between different withdrawal methods where more than one is supported // for the given currency. Type string `json:"type"` @@ -588,7 +594,7 @@ type GetOrderV2Response struct { // Use this field and `side` to determine credit or debit of funds. Base decimal.Decimal `json:"base"` - // The base account ID used to place the order + // The base currency account BaseAccountId int64 `json:"base_account_id"` // Client Order ID has the value that was passed in when the Order was posted. @@ -606,7 +612,7 @@ type GetOrderV2Response struct { // Use this field and `side` to determine credit or debit of funds. Counter decimal.Decimal `json:"counter"` - // The counter account ID used to place the order + // The counter currency account CounterAccountId int64 `json:"counter_account_id"` // Time of order creation (Unix milliseconds) @@ -698,7 +704,7 @@ type GetOrderV3Response struct { // Use this field and `side` to determine credit or debit of funds. Base decimal.Decimal `json:"base"` - // The base account ID used to place the order + // The base currency account BaseAccountId int64 `json:"base_account_id"` // Client Order ID has the value that was passed in when the Order was posted. @@ -716,7 +722,7 @@ type GetOrderV3Response struct { // Use this field and `side` to determine credit or debit of funds. Counter decimal.Decimal `json:"counter"` - // The counter account ID used to place the order + // The counter currency account CounterAccountId int64 `json:"counter_account_id"` // Time of order creation (Unix milliseconds) @@ -898,6 +904,9 @@ type GetWithdrawalResponse struct { // Status Status Status `json:"status"` + // Transfer ID is the identifier of the Withdrawal's transfer once it completes. + TransferId string `json:"transfer_id"` + // Type distinguishes between different withdrawal methods where more than one is supported // for the given currency. Type string `json:"type"` @@ -918,8 +927,7 @@ func (cl *Client) GetWithdrawal(ctx context.Context, req *GetWithdrawalRequest) } // ListBeneficiariesResponseRequest is the request struct for ListBeneficiariesResponse. -type ListBeneficiariesResponseRequest struct { -} +type ListBeneficiariesResponseRequest struct{} // ListBeneficiariesResponseResponse is the response struct for ListBeneficiariesResponse. type ListBeneficiariesResponseResponse struct { @@ -1031,6 +1039,8 @@ type ListOrdersV2Response struct { // oldest. This endpoint will list up to 100 most recent open orders by // default. // +// Please note: This data is archived 100 days after an exchange order is completed. +// // Permissions required: Perm_R_Orders func (cl *Client) ListOrdersV2(ctx context.Context, req *ListOrdersV2Request) (*ListOrdersV2Response, error) { var res ListOrdersV2Response diff --git a/types.go b/types.go index 08cd3ee..80d8615 100644 --- a/types.go +++ b/types.go @@ -235,7 +235,7 @@ type OrderV2 struct { // Use this field and `side` to determine credit or debit of funds. Base decimal.Decimal `json:"base"` - // The base account ID used to place the order + // The base currency account BaseAccountId int64 `json:"base_account_id"` // Client Order ID has the value that was passed in when the Order was posted. @@ -253,7 +253,7 @@ type OrderV2 struct { // Use this field and `side` to determine credit or debit of funds. Counter decimal.Decimal `json:"counter"` - // The counter account ID used to place the order + // The counter currency account CounterAccountId int64 `json:"counter_account_id"` // Time of order creation (Unix milliseconds) @@ -557,6 +557,9 @@ type Withdrawal struct { // Status Status Status `json:"status"` + // Transfer ID is the identifier of the Withdrawal's transfer once it completes. + TransferId string `json:"transfer_id"` + // Type distinguishes between different withdrawal methods where more than one is supported // for the given currency. Type string `json:"type"`