Application Management

Papertrail Log search API for accounts with limited group access

This article suggests how to run an API search for members that only have access to specific groups in Papertrail Settings > Members > Log Access Permissions

First published date

6/4/2021 4:37 PM

Last published date

6/4/2021 4:37 PM

Overview

Log search API requires the account to have full access to all groups. The following error may show up from the client side when an account without full access runs an API search:
Status: 403 Forbidden
Content-Type: application/json; charset=utf-8

{"message":"Account access does not permit this request"}

Product section

Papertrail

Cause

The API Endpoint api/v1/events/search.json won't allow accounts without access to all groups.

Resolution

Add the group_id into the API request. Here's an example:
https://papertrailapp.com/api/v1/events/search.json?group_id=group_id