Documentation ¶
Overview ¶
Package rainv1 provides primitives to interact with the openapi HTTP API.
Code generated by github.com/deepmap/oapi-codegen version v1.12.4 DO NOT EDIT.
Index ¶
- func NewGetAllCoinsRequest(server string) (*http.Request, error)
- type Client
- type ClientInterface
- type ClientOption
- type ClientWithResponses
- type ClientWithResponsesInterface
- type Coin
- type Extension
- type GetAllCoinsResponse
- type GetCoinsResponse
- type HttpRequestDoer
- type Network
- type RequestEditorFn
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Client ¶
type Client struct { // The endpoint of the server conforming to this interface, with scheme, // https://api.deepmap.com for example. This can contain a path relative // to the server, such as https://api.deepmap.com/dev-test, and all the // paths in the swagger spec will be appended to the server. Server string // Doer for performing requests, typically a *http.Client with any // customized settings, such as certificate chains. Client HttpRequestDoer // A list of callbacks for modifying requests which are generated before sending over // the network. RequestEditors []RequestEditorFn }
Client which conforms to the OpenAPI3 specification for this service.
func NewClient ¶
func NewClient(server string, opts ...ClientOption) (*Client, error)
Creates a new Client, with reasonable defaults
func (*Client) GetAllCoins ¶
type ClientInterface ¶
type ClientInterface interface { // GetAllCoins request GetAllCoins(ctx context.Context, reqEditors ...RequestEditorFn) (*http.Response, error) }
The interface specification for the client above.
type ClientOption ¶
ClientOption allows setting custom parameters during construction
func WithHTTPClient ¶
func WithHTTPClient(doer HttpRequestDoer) ClientOption
WithHTTPClient allows overriding the default Doer, which is automatically created using http.Client. This is useful for tests.
func WithRequestEditorFn ¶
func WithRequestEditorFn(fn RequestEditorFn) ClientOption
WithRequestEditorFn allows setting up a callback function, which will be called right before sending the request. This can be used to mutate the request.
type ClientWithResponses ¶
type ClientWithResponses struct {
ClientInterface
}
ClientWithResponses builds on ClientInterface to offer response payloads
func NewClientWithResponses ¶
func NewClientWithResponses(server string, opts ...ClientOption) (*ClientWithResponses, error)
NewClientWithResponses creates a new ClientWithResponses, which wraps Client with return type handling
func (*ClientWithResponses) GetAllCoinsWithResponse ¶
func (c *ClientWithResponses) GetAllCoinsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetAllCoinsResponse, error)
GetAllCoinsWithResponse request returning *GetAllCoinsResponse
type ClientWithResponsesInterface ¶
type ClientWithResponsesInterface interface { // GetAllCoins request GetAllCoinsWithResponse(ctx context.Context, reqEditors ...RequestEditorFn) (*GetAllCoinsResponse, error) }
ClientWithResponsesInterface is the interface specification for the client with responses above.
type Coin ¶
type Coin struct { BlockExplorer string `json:"block_explorer"` Categories []string `json:"categories"` Code string `json:"code"` ExchangeWarningMinimum string `json:"exchange_warning_minimum"` Extensions []Extension `json:"extensions"` FiatPrecision int `json:"fiat_precision"` IconUrl string `json:"icon_url"` MinimumAmount string `json:"minimum_amount"` MinimumConfirmations int `json:"minimum_confirmations"` Name string `json:"name"` Networks []Network `json:"networks"` Precision int `json:"precision"` Status string `json:"status"` StatusChangedAt time.Time `json:"status_changed_at"` AdditionalProperties map[string]interface{} `json:"-"` }
Coin defines model for coin.
func (Coin) Get ¶
Getter for additional properties for Coin. Returns the specified element and whether it was found
func (Coin) MarshalJSON ¶
Override default JSON handling for Coin to handle AdditionalProperties
func (*Coin) UnmarshalJSON ¶
Override default JSON handling for Coin to handle AdditionalProperties
type Extension ¶
type Extension struct { Name string `json:"name"` Type string `json:"type"` Value string `json:"value"` AdditionalProperties map[string]interface{} `json:"-"` }
Extension defines model for extension.
func (Extension) Get ¶
Getter for additional properties for Extension. Returns the specified element and whether it was found
func (Extension) MarshalJSON ¶
Override default JSON handling for Extension to handle AdditionalProperties
func (*Extension) UnmarshalJSON ¶
Override default JSON handling for Extension to handle AdditionalProperties
type GetAllCoinsResponse ¶
type GetAllCoinsResponse struct { Body []byte HTTPResponse *http.Response JSON200 *GetCoinsResponse }
func ParseGetAllCoinsResponse ¶
func ParseGetAllCoinsResponse(rsp *http.Response) (*GetAllCoinsResponse, error)
ParseGetAllCoinsResponse parses an HTTP response from a GetAllCoinsWithResponse call
func (GetAllCoinsResponse) Status ¶
func (r GetAllCoinsResponse) Status() string
Status returns HTTPResponse.Status
func (GetAllCoinsResponse) StatusCode ¶
func (r GetAllCoinsResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type GetCoinsResponse ¶
type GetCoinsResponse struct { Coins []Coin `json:"coins"` AdditionalProperties map[string]interface{} `json:"-"` }
GetCoinsResponse defines model for getCoinsResponse.
func (GetCoinsResponse) Get ¶
func (a GetCoinsResponse) Get(fieldName string) (value interface{}, found bool)
Getter for additional properties for GetCoinsResponse. Returns the specified element and whether it was found
func (GetCoinsResponse) MarshalJSON ¶
func (a GetCoinsResponse) MarshalJSON() ([]byte, error)
Override default JSON handling for GetCoinsResponse to handle AdditionalProperties
func (*GetCoinsResponse) Set ¶
func (a *GetCoinsResponse) Set(fieldName string, value interface{})
Setter for additional properties for GetCoinsResponse
func (*GetCoinsResponse) UnmarshalJSON ¶
func (a *GetCoinsResponse) UnmarshalJSON(b []byte) error
Override default JSON handling for GetCoinsResponse to handle AdditionalProperties
type HttpRequestDoer ¶
Doer performs HTTP requests.
The standard http.Client implements this interface.
type Network ¶
type Network struct { DefaultFee string `json:"default_fee"` Extensions []Extension `json:"extensions"` Name string `json:"name"` AdditionalProperties map[string]interface{} `json:"-"` }
Network defines model for network.
func (Network) Get ¶
Getter for additional properties for Network. Returns the specified element and whether it was found
func (Network) MarshalJSON ¶
Override default JSON handling for Network to handle AdditionalProperties
func (*Network) UnmarshalJSON ¶
Override default JSON handling for Network to handle AdditionalProperties