diff --git a/config.go b/config.go index 99f0c4b..cde6aeb 100644 --- a/config.go +++ b/config.go @@ -23,14 +23,6 @@ type Recipients struct { To string `json:"to"` } -// QueryParams object to use when limiting and sorting database query results -type QueryParams struct { - Page int `json:"page,omitempty"` - PageSize int `json:"page_size,omitempty"` - OrderByField string `json:"order_by_field,omitempty"` - SortDirection string `json:"sort_direction,omitempty"` -} - const ( // FieldMetadata is the field name for metadata FieldMetadata = "metadata" diff --git a/http.go b/http.go index 2e35445..edfa4cc 100644 --- a/http.go +++ b/http.go @@ -758,7 +758,7 @@ func (wc *WalletClient) AdminGetBlockHeaders( ctx context.Context, conditions map[string]interface{}, metadata map[string]any, - queryParams *QueryParams, + queryParams *filter.QueryParams, ) ([]*models.BlockHeader, ResponseError) { var models []*models.BlockHeader if err := wc.adminGetModels(ctx, conditions, metadata, queryParams, "/admin/block-headers/search", &models); err != nil { @@ -997,7 +997,7 @@ func (wc *WalletClient) adminGetModels( ctx context.Context, conditions map[string]interface{}, metadata map[string]any, - queryParams *QueryParams, + queryParams *filter.QueryParams, path string, models interface{}, ) ResponseError {