The pagination code assumes a relative URL for the Next/Previous links
// GetPage will fetch a page via the Link object and decode it from out.
// Should be used like `client.GetPage(link.Previous, make([]Organization, 0))`
func (c *Client) GetPage(p Page, out interface{}) (*Link, error) {
return c.rawWithPagination("GET", strings.TrimPrefix(p.URL, c.Endpoint), out, nil)
}
It prepends the Endpoint URL to the link URL. This worked until recently as Sentry .io API now returns full URLs for the link.
The pagination code assumes a relative URL for the Next/Previous links
It prepends the Endpoint URL to the link URL. This worked until recently as Sentry .io API now returns full URLs for the link.