Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Meta ¶
type Meta struct { Status string `json:"status,omitempty"` Message string `json:"message,omitempty"` Context map[string]interface{} `json:"context,omitempty"` }
Meta - generic api output metadata
type PaginationResponse ¶
type PaginationResponse struct { Page int `json:"page,omitempty"` Items int `json:"items,omitempty"` MaxPage int `json:"max_page,omitempty"` Ordered []string `json:"order,omitempty"` Data interface{} `json:"data,omitempty"` }
PaginationResponse - a response structure wrapper for pagination
func (*PaginationResponse) Render ¶
func (pr *PaginationResponse) Render(ctx context.Context, w http.ResponseWriter, status int) error
Render - render response response structure { page: 1, items: 50, max_page: 10, ordered: ["id", "..."], transactions: [...] }
Click to show internal directories.
Click to hide internal directories.