How to increase the amount of records returned by the xMatters API

Question

When using the API in an integration or just as a manual CURL request can you affect how many records return at a time? The default seems to suggest 100 records.

Environment

  • All versions of xMatters
  • xMatters REST API

Answer

Yes you can! Most endpoints support the limit parameter so by specifying the number of records to return per page you can get significantly more data.

For example if you take the event audit endpoint, the default looks like this:

  https://acmeco.xmatters.com/api/xm/1/audits?at=2018-11-02T08:00:00.000Z&from=2018-01-27T08:00:00.000Z&to=2018-06-30T08:00:00.000Z

If we add the Limit parameter it would look like this:

  https://acmeco.xmatters.com/api/xm/1/audits?at=2018-11-02T08:00:00.000Z&from=2018-01-27T08:00:00.000Z&to=2018-06-30T08:00:00.000Z&limit=500

This should increase the amount of records fetched.

For more information about our API see this page

Was this article helpful?
0 out of 0 found this helpful

Comments

0 comments

Article is closed for comments.