Check API Page Index for Missing

Added a check when the API returns a negative page index to make sure
the page status is missing, not invalid. Also changed the error
message output from escaped() to text() because we don’t want
logged text to be escaped.

Follow-up on I2d9fd59e

Change-Id: Ice4b4b95c13e76a7c5ba6a069edfc6a8f43153fc