Showing results for 
Show  only  | Search instead for 
Did you mean: 

nextPageKey syntax?


Sorry new to Dynatrace so perhaps a silly question...
Does anyone have an example of using curl and the Rest API with the "nextPageKey" parameter to fetch more than 1000 results when pulling down metrics?



nextPageKey you should add via query parameter. So there isn'y any magic here 🙂 just add https://uri?nexyPageKey=value

This value you should read from previous response.


Thank you Sebastian!

I can see that from the API Explorer as well, but still not quite wrapping my head around it. Do I need to add a header parameter that first specifies what the key is (in a similar way to adding the authorisation key) then follow that with nextPageKey=(value I just put in the header)?

No, you don't need. Just add nextPageKey to url as in my example. Nothing more. First request you can execute without this parameter (you will see value for it in response). Than read this value from first response (and all next) and just add it to url.


Sorry I am still being thick I think. What do I put in for "value" in nextPageKey=value - or just use the word value not an actual value?

Value is string that you receive from previous request. You should put there next page indicator returned in response. Treat value as placeholder here 🙂

Thank you! Now back to learning enough scripting to parse that into the next request.

New at all this, many thanks for your help.

If you will have any extra questions, please ask 🙂


Hello all
Hello @sebastian_kryst, i dont understand well

What is the exact value to put?


And what is the parameter if I have more than @ pages (2500 results for example)


Thanks for your help.

Sharing Knowledge

@Malaik In the current results, you have a nextPageKey value in the JSON response. You just need to put this value into URL query parameter named nextPageKeyto fetch the next page of the resultset.

TEMPEST a.s., Slovakia, Dynatrace Master Partner

Thanks @Julius_Loman Yes done

But the documentation is not well done because we must to omit also the optional options.

I used it, but the result was return a count of 3500 but only 500 items was in the json


Have a good day.

Sharing Knowledge

Community Team
Community Team

Hello Lisa! There is no such thing as a silly question, as every each of us was new to Dynatrace at some point. If you have any doubts about some topic, don't be shy and ask about it. Our community is very active and I'm sure that someone will help you with it 🙂

If you have any questions about the Forum, you can contact me at