More flag is not working properly

I am trying to get the list of incidents from the api for my team and send it to slack channel . But due to More flag it is not setting false value so instead of call should go 25 times it is going more than that . can you please suggest any solution ?

Hello,

Thanks for reaching out on our Community page! Just to clarify, are you getting more results than you need? Or are you stuck at 25?

John