Documentation
¶
Index ¶
- type Client
- func (h *Client) BaseURL() *url.URL
- func (h *Client) Delete(ctx context.Context, path string, reqOptions RequestOptions) (*HttpResponse, error)
- func (h *Client) Do(ctx context.Context, method, path string, reqOptions RequestOptions) (*HttpResponse, error)
- func (h *Client) Get(ctx context.Context, path string, reqOptions RequestOptions) (*HttpResponse, error)
- func (h *Client) Patch(ctx context.Context, path string, reqOptions RequestOptions) (*HttpResponse, error)
- func (h *Client) Post(ctx context.Context, path string, reqOptions RequestOptions) (*HttpResponse, error)
- func (h *Client) Put(ctx context.Context, path string, reqOptions RequestOptions) (*HttpResponse, error)
- type Config
- type HttpResponse
- func Delete(ctx context.Context, path string, reqOptions RequestOptions) (*HttpResponse, error)
- func Do(ctx context.Context, method, path string, reqOptions RequestOptions) (*HttpResponse, error)
- func Get(ctx context.Context, path string, reqOptions RequestOptions) (*HttpResponse, error)
- func Patch(ctx context.Context, path string, reqOptions RequestOptions) (*HttpResponse, error)
- func Post(ctx context.Context, path string, reqOptions RequestOptions) (*HttpResponse, error)
- func Put(ctx context.Context, path string, reqOptions RequestOptions) (*HttpResponse, error)
- type RequestOptions
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct { Config // contains filtered or unexported fields }
func NewFromClient ¶
func (*Client) Delete ¶
func (h *Client) Delete(ctx context.Context, path string, reqOptions RequestOptions) (*HttpResponse, error)
func (*Client) Do ¶
func (h *Client) Do(ctx context.Context, method, path string, reqOptions RequestOptions) (*HttpResponse, error)
func (*Client) Get ¶
func (h *Client) Get(ctx context.Context, path string, reqOptions RequestOptions) (*HttpResponse, error)
func (*Client) Patch ¶
func (h *Client) Patch(ctx context.Context, path string, reqOptions RequestOptions) (*HttpResponse, error)
func (*Client) Post ¶
func (h *Client) Post(ctx context.Context, path string, reqOptions RequestOptions) (*HttpResponse, error)
func (*Client) Put ¶
func (h *Client) Put(ctx context.Context, path string, reqOptions RequestOptions) (*HttpResponse, error)
type HttpResponse ¶
func Delete ¶
func Delete(ctx context.Context, path string, reqOptions RequestOptions) (*HttpResponse, error)
Delete is a shortcut for New(path).Delete(ctx, path, reqOptions)
func Do ¶
func Do(ctx context.Context, method, path string, reqOptions RequestOptions) (*HttpResponse, error)
Do is a shortcut for New(path).Do(ctx, method, "", reqOptions)
func Get ¶
func Get(ctx context.Context, path string, reqOptions RequestOptions) (*HttpResponse, error)
Get is a shortcut for New(path).Get(ctx, path, reqOptions)
func Patch ¶
func Patch(ctx context.Context, path string, reqOptions RequestOptions) (*HttpResponse, error)
Patch is a shortcut for New(path).Patch(ctx, path, reqOptions)
func Post ¶
func Post(ctx context.Context, path string, reqOptions RequestOptions) (*HttpResponse, error)
Post is a shortcut for New(path).Post(ctx, path, reqOptions)
func Put ¶
func Put(ctx context.Context, path string, reqOptions RequestOptions) (*HttpResponse, error)
Put is a shortcut for New(path).Put(ctx, path, reqOptions)
func (*HttpResponse) UnmarshalBody ¶
func (r *HttpResponse) UnmarshalBody(out any) error
Click to show internal directories.
Click to hide internal directories.