Skip to content

Commit

Permalink
feat(ResultInfo): add TotalPages field
Browse files Browse the repository at this point in the history
This changes adds the `TotalPages` field to the `ResultInfo` struct.

This field was added to the API a while ago and can be used in
combination with the `Pages` field to determine how many more calls you
need to make to fetch all data.
  • Loading branch information
jamesog committed Jan 11, 2017
1 parent 055e0a9 commit afb06af
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions cloudflare.go
Original file line number Diff line number Diff line change
Expand Up @@ -160,8 +160,9 @@ type Response struct {

// ResultInfo contains metadata about the Response.
type ResultInfo struct {
Page int `json:"page"`
PerPage int `json:"per_page"`
Count int `json:"count"`
Total int `json:"total_count"`
Page int `json:"page"`
PerPage int `json:"per_page"`
TotalPages int `json:"total_pages"`
Count int `json:"count"`
Total int `json:"total_count"`
}

0 comments on commit afb06af

Please sign in to comment.