funding

package
v0.0.0-...-eb215bf Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 11, 2024 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Deposit

type Deposit struct {
	// Name of deposit method
	Method string `json:"method"`
	// Asset class
	AssetClass string `json:"aclass"`
	// Asset
	Asset string `json:"asset"`
	// Reference ID
	ReferenceID string `json:"refid"`
	// Method transaction ID
	TransactionID string `json:"txid"`
	// Method transaction information
	Info string `json:"info"`
	// Amount deposited/withdrawn
	Amount string `json:"amount"`
	// Fees paid. Can be empty
	Fee string `json:"fee"`
	// Unix timestamp when request was made
	Time int64 `json:"time"`
	// Status of deposit - IFEX financial transaction states
	Status string `json:"status"`
	// Additional status property. Can be empty.
	StatusProperty string `json:"status-prop,omitempty"`
	// Client sending transaction id(s) for deposits that credit with a sweeping transaction
	Originators []string `json:"originators,omitempty"`
}

Transaction details for a deposit

type DepositAddress

type DepositAddress struct {
	// Deposit Address
	Address string `json:"address,omitempty"`
	// Expiration time as a unix timestamp (seconds). 0 if not expiring.
	Expiretm json.Number `json:"expiretm,omitempty"`
	// Whether or not address has ever been used
	New bool `json:"new"`
	// Only returned for STX, XLM, and EOS deposit addresses
	Memo string `json:"memo,omitempty"`
	// Only returned for XRP deposit addresses
	Tag string `json:"tag,omitempty"`
}

Data of a deposit address

type DepositMethod

type DepositMethod struct {
	// Name of deposit method
	Method string `json:"method,omitempty"`
	// Maximum net amount that can be deposited right now. Empty or "false" if no limit.
	Limit string `json:"limit,omitempty"`
	// Amount of fees that will be paid.
	Fee string `json:"fee,omitempty"`
	// Whether or not method has an address setup fee.
	AddressSetupFee string `json:"address-setup-fee,omitempty"`
	// Whether new addresses can be generated for this method.
	GenAddress bool `json:"gen-address"`
	// Minimum net amount that can be deposited right now
	Minimum string `json:"minimum,omitempty"`
}

Data of a deposit method

func (*DepositMethod) UnmarshalJSON

func (dm *DepositMethod) UnmarshalJSON(data []byte) error

type GetDepositAddressesRequestOptions

type GetDepositAddressesRequestOptions struct {
	// Whether or not to generate a new address.
	//
	// Defaults to false.
	New bool `json:"new"`
	// Amount user wish to deposit on the address.
	//
	// This options is only required for "Bitcoin Lightning" deposit method in order to
	// craft the Lightning network invoice.
	//
	// An empty string means option will not be used.
	Amount string `json:"amount,omitempty"`
}

GetDepositAddresses request options

type GetDepositAddressesRequestParameters

type GetDepositAddressesRequestParameters struct {
	// Asset being deposited
	Asset string `json:"asset"`
	// Name of the deposit method
	Method string `json:"method"`
}

GetDepositAddresses request parameters

type GetDepositAddressesResponse

type GetDepositAddressesResponse struct {
	common.KrakenSpotRESTResponse
	Result []DepositAddress `json:"result"`
}

Get Deposit Addresses response

type GetDepositMethodsRequestParameters

type GetDepositMethodsRequestParameters struct {
	// Asset being deposited
	Asset string `json:"asset"`
}

GetDepositMethods request parameters

type GetDepositMethodsResponse

type GetDepositMethodsResponse struct {
	common.KrakenSpotRESTResponse
	Result []DepositMethod `json:"result"`
}

Response returned by GetDepositMethods

type GetStatusOfRecentDepositsRequestOptions

type GetStatusOfRecentDepositsRequestOptions struct {
	// Filter for specific asset being deposited.
	//
	// An empty value means no filter.
	Asset string `json:"asset,omitempty"`
	// Filter for specific name of deposit method.
	//
	// An empty value means no filter.
	Method string `json:"method,omitempty"`
	// Start timestamp, deposits created strictly before will not be included in the response.
	//
	// An empty value means no filter.
	Start string `json:"start,omitempty"`
	// End timestamp, deposits created stricly after will be not be included in the response.
	//
	// An empty value means no filter.
	End string `json:"end,omitempty"`
	// Cursor for next page of results (string)
	//
	// An empty value means first page/request.
	Cursor string `json:"cursor,omitempty"`
	// Number of results to include per page.
	//
	// Default to 25. A zero value will trigger the default behavior.
	Limit int64 `json:"limit,omitempty"`
}

GetStatusOfRecentDeposits request options

type GetStatusOfRecentDepositsResponse

type GetStatusOfRecentDepositsResponse struct {
	common.KrakenSpotRESTResponse
	// Recent deposits
	Result *GetStatusOfRecentDepositsResult `json:"result,omitempty"`
}

GetStatusOfRecentDeposits response

type GetStatusOfRecentDepositsResult

type GetStatusOfRecentDepositsResult struct {
	// Provides next input to use for cursor in pagination.
	NextCursor string `json:"next_cursor,omitempty"`
	// Listed deposits
	Deposits []Deposit `json:"deposit"`
}

GetStatusOfRecentDeposits result

type GetStatusOfRecentWithdrawalsRequestOptions

type GetStatusOfRecentWithdrawalsRequestOptions struct {
	// Filter for specific name of withdrawal method.
	//
	// An empty string means no filter.
	Method string `json:"method,omitempty"`
	// Filter for specific asset being withdrawn.
	//
	// An empty string means no filter.
	Asset string `json:"asset,omitempty"`
	// Start timestamp, deposits created strictly before will not be included in the response.
	//
	// An empty value means no filter.
	Start string `json:"start,omitempty"`
	// End timestamp, deposits created stricly after will be not be included in the response.
	//
	// An empty value means no filter.
	End string `json:"end,omitempty"`
}

GetStatusOfRecentWithdrawals request options

type GetStatusOfRecentWithdrawalsResponse

type GetStatusOfRecentWithdrawalsResponse struct {
	common.KrakenSpotRESTResponse
	// Recent withdrawals
	Result []Withdrawal `json:"result"`
}

GetStatusOfRecentWithdrawals response

type GetWithdrawalAddressesRequestOptions

type GetWithdrawalAddressesRequestOptions struct {
	// Filter addresses for specific asset.
	//
	// An empty string means no filtering.
	Asset string `json:"asset,omitempty"`
	// Filter Addresses for specific method.
	//
	// An empty string means no filtering.
	Method string `json:"method,omitempty"`
	// Find address for by withdrawal key name, as set up on your account.
	//
	// An empty string means no filtering.
	Key string `json:"key,omitempty"`
	// Filter by verification status of the withdrawal address. Withdrawal addresses successfully
	// completing email confirmation will have a verification status of true.
	//
	// Defaults to false.
	Verified bool `json:"verified,omitempty"`
}

GetWithdrawalAddresses request options

type GetWithdrawalAddressesResponse

type GetWithdrawalAddressesResponse struct {
	common.KrakenSpotRESTResponse
	Result []WithdrawalAddress `json:"result,omitempty"`
}

GetWithdrawalAddresses response

type GetWithdrawalInformationRequestParameters

type GetWithdrawalInformationRequestParameters struct {
	// Asset being withdrawn
	Asset string `json:"asset"`
	// Withdrawal address name as setup on account
	Key string `json:"key"`
	// Anount to be withdrawn
	Amount string `json:"amount"`
}

GetWithdrawalInformation request parameters

type GetWithdrawalInformationResponse

type GetWithdrawalInformationResponse struct {
	common.KrakenSpotRESTResponse
	Result *GetWithdrawalInformationResult `json:"result,omitempty"`
}

Get Withdrawal Information response

type GetWithdrawalInformationResult

type GetWithdrawalInformationResult struct {
	// Name of the withdrawal method that will be used
	Method string `json:"method"`
	// Maximum net amount that can be withdrawn right now
	Limit string `json:"limit"`
	// Net amount that will be sent, after fees
	Amount string `json:"amount"`
	// Amount of fees that will be paid
	Fee string `json:"fee"`
}

GetWithdrawalInformation result

type GetWithdrawalMethodsRequestOptions

type GetWithdrawalMethodsRequestOptions struct {
	// Filter methods for specific asset.
	//
	// An empty string means no filtering.
	Asset string `json:"asset,omitempty"`
	// Filter methods for specific network.
	//
	// An empty string means no filtering.
	Network string `json:"network,omitempty"`
}

GetWithdrawalMethods request options

type GetWithdrawalMethodsResponse

type GetWithdrawalMethodsResponse struct {
	common.KrakenSpotRESTResponse
	Result []WithdrawalMethod `json:"result,omitempty"`
}

GetWithdrawalMethods response

type RequestWalletTransferRequestParameters

type RequestWalletTransferRequestParameters struct {
	// Asset being transfered
	Asset string `json:"asset"`
	// Source wallet.
	//
	// Refer to WalletTransferDestination for values.
	From string `json:"from"`
	// Destination wallet.
	//
	// Refer to WalletTransferDestination for values.
	To string `json:"to"`
	// Amount to be transfered
	Amount string `json:"amount"`
}

RequestWalletTransfer request parameters

type RequestWalletTransferResponse

type RequestWalletTransferResponse struct {
	common.KrakenSpotRESTResponse
	// RequestWalletTransfer result
	Result *RequestWalletTransferResult `json:"result,omitempty"`
}

RequestWalletTransfer response

type RequestWalletTransferResult

type RequestWalletTransferResult struct {
	// Reference ID
	ReferenceID string `json:"refid"`
}

RequestWalletTransfer result

type RequestWithdrawalCancellationRequestParameters

type RequestWithdrawalCancellationRequestParameters struct {
	// Asset being withdrawn
	Asset string `json:"asset"`
	// Withdrawal reference ID
	ReferenceId string `json:"refid"`
}

RequestWithdrawalCancellation request parameters

type RequestWithdrawalCancellationResponse

type RequestWithdrawalCancellationResponse struct {
	common.KrakenSpotRESTResponse
	// Result for RequestWithdrawalCancellation
	Result bool `json:"result"`
}

RequestWithdrawalCancellation response

type StatusPropertyEnum

type StatusPropertyEnum string

Enum for status property.

const (
	// A return transaction initiated by Kraken
	Return StatusPropertyEnum = "return"
	// Deposit is on hold pending review
	OnHold StatusPropertyEnum = "onhold"
)

Values for StatusPropertyEnum

type TransactionStateEnum

type TransactionStateEnum string

Enum for transaction states as described in https://github.com/globalcitizen/ifex-protocol/blob/master/draft-ifex-00.txt#L837

const (
	TxStateInitial TransactionStateEnum = "Initial"
	TxStatePending TransactionStateEnum = "Pending"
	TxStateSettled TransactionStateEnum = "Settled"
	TxStateSuccess TransactionStateEnum = "Success"
	TxStateFailure TransactionStateEnum = "Failure"
	TxStatePartial TransactionStateEnum = "Partial"
)

Values for TransactionStateEnum

type TransactionStatus

type TransactionStatus string

Enum for additional properties for transaction status

const (
	// A return transaction initiated by Kraken
	TxStatusReturn TransactionStatus = "return"
	// Deposit is on hold pending review
	TxStatusOnHold TransactionStatus = "onhold"
	// Cancelation requested
	TxCancelPending TransactionStatus = "cancel-pending"
	// Canceled
	TxCanceled TransactionStatus = "canceled"
	// CancelDenied
	TxCancelDenied TransactionStatus = "cancel-denied"
)

Values for TransactionStatus

type WalletTransferDestination

type WalletTransferDestination string

Enum for wallet destinations

const (
	// Spot wallet
	Spot WalletTransferDestination = "Spot Wallet"
	// Futures wallet
	Futures WalletTransferDestination = "Futures Wallet"
)

Values for WalletTransferDestination

type WithdrawFundsRequestOptions

type WithdrawFundsRequestOptions struct {
	// Optional, crypto address that can be used to confirm address matches key (will return
	// Invalid withdrawal address error if different).
	//
	// An empty value means no address confirmation is required.
	Address string `json:"address,omitempty"`
	// Optional, if the processed withdrawal fee is higher than max_fee, withdrawal will fail with
	// EFunding:Max fee exceeded
	//
	// An empty value means no maximum fee set.
	MaxFee string `json:"max_fee,omitempty"`
}

WithdrawFunds request options

type WithdrawFundsRequestParameters

type WithdrawFundsRequestParameters struct {
	// Asset being withdrawn
	Asset string `json:"asset"`
	// Withdrawal address name as setup on account
	Key string `json:"key"`
	// Amount to be withdrawn
	Amount string `json:"amount"`
}

WithdrawFunds request parameters

type WithdrawFundsResponse

type WithdrawFundsResponse struct {
	common.KrakenSpotRESTResponse
	// Results for WithdrawFunds
	Result *WithdrawFundsResult `json:"result"`
}

WithdrawFunds response

type WithdrawFundsResult

type WithdrawFundsResult struct {
	// Reference ID
	ReferenceID string `json:"refid"`
}

WithdrawFunds response

type Withdrawal

type Withdrawal struct {
	// Name of deposit method
	Method string `json:"method,omitempty"`
	// Network name based on the funding method used
	Network string `json:"network,omitempty"`
	// Asset class
	AssetClass string `json:"aclass,omitempty"`
	// Asset
	Asset string `json:"asset,omitempty"`
	// Reference ID
	ReferenceID string `json:"refid,omitempty"`
	// Method transaction ID
	TransactionID string `json:"txid,omitempty"`
	// Method transaction information
	Info string `json:"info,omitempty"`
	// Amount deposited/withdrawn
	Amount string `json:"amount"`
	// Fees paid. Can be empty
	Fee string `json:"fee,omitempty"`
	// Unix timestamp when request was made
	Time int64 `json:"time"`
	// Status of deposit - IFEX financial transaction states
	Status string `json:"status"`
	// Additional status property. Can be empty.
	StatusProperty string `json:"status-prop,omitempty"`
	// Withdrawal key name, as set up on your account
	Key string `json:"key,omitempty"`
}

Transaction details for a withdrawal

type WithdrawalAddress

type WithdrawalAddress struct {
	// Withdrawal address.
	Address string `json:"address"`
	// Name of asset being withdrawn.
	Asset string `json:"asset"`
	// Name of the withdrawal method.
	Method string `json:"method"`
	// Withdrawal key name, as set up on your account.
	Key string `json:"key"`
	// Memo for withdrawal address, as set up on your account, if applicable.
	Memo string `json:"memo,omitempty"`
	// Verification status of withdrawal address.
	Verified bool `json:"verified"`
}

Data of a withdrawal address.

type WithdrawalMethod

type WithdrawalMethod struct {
	// Name of asset being withdrawn
	Asset string `json:"asset"`
	// Name of the withdrawal method
	Method string `json:"method"`
	// Name of the blockchain or network being withdrawn on
	Network string `json:"network"`
	// Minimum net amount that can be withdrawn right now
	Minimum json.Number `json:"minimum"`
}

Data of a withdrawal method.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL