List activity log entries
const url = 'https://api.usegro.co/api/activity-logs?actor_type=customer&end_date=example&start_date=example';const options = { method: 'GET', headers: {Authorization: 'Bearer <token>', 'X-API-Key': '<X-API-Key>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url 'https://api.usegro.co/api/activity-logs?actor_type=customer&end_date=example&start_date=example' \ --header 'Authorization: Bearer <token>' \ --header 'X-API-Key: <X-API-Key>'Returns a paginated, account-scoped activity log covering both system-generated
events (subscription created/paused, order placed, billing failed, etc.) and custom entries
written by integrations via POST /api/activity-logs.
Filtering by loggable type and ID
Each row is attached to a “loggable” — the subscription or order the event describes. To narrow the feed to a single resource, pass exactly one of:
subscription_id— returns only rows whereloggable_type = "subscription"andloggable_idmatches the given subscription UUID.order_id— returns only rows whereloggable_type = "order"andloggable_idmatches the given order UUID.
The two filters are mutually exclusive; if both are supplied, order_id takes precedence.
When neither is supplied, the response includes both subscription and order rows.
The returned loggable_type and loggable_id fields on each row identify the source entity,
and the convenience fields subscription_id/subscription_number and
order_id/order_number are populated for the corresponding row type so clients can render
links without a second lookup.
Filtering by integration / custom actions
Custom entries written by integrations through POST /api/activity-logs are stored with
actor_type = "api" and an action name prefixed integration_ (e.g.
integration_shipment_dispatched). To filter the feed to integration activity:
actor_type=api: every row written with an API key, including the public log endpoint. These rows haveactor_nameset to the key’s last characters, e.g.API key •••a7f3c.action=integration_shipment_dispatched— a single custom action.action=integration_shipment_dispatched,integration_label_printed— comma-separated list of action names; matched asIN (...).
The set of distinct integration_* action names recorded for the account is available via
GET /api/activity-logs/integration-actions and is suitable for populating a filter
dropdown.
Other filters
actor_type=customer|admin|api|system— actor category, or a comma-separated list matched as any of them.systemalso includes webhook-triggered events and rows with no actor recorded.actor_name— whenactor_typeincludesadmin, restricts staff rows to these staff members (one name or a comma-separated list). Distinct names are available viaGET /api/activity-logs/actors.start_date/end_date(required) —yyyy-MM-dddate range interpreted in the account’s timezone.page/limit— pagination (limitcapped at 100, default 25).
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Query Parameters
Section titled “Query Parameters”Narrow to a single entity (a pet, person or other record on a profile). Equivalent to loggable_type=entity AND loggable_id=<uuid>. Takes precedence over order_id and subscription_id.
Narrow to a single order. Equivalent to loggable_type=order AND loggable_id=<uuid>. Takes precedence over subscription_id if both are supplied.
Narrow to a single subscription. Equivalent to loggable_type=subscription AND loggable_id=<uuid>. Mutually exclusive with order_id.
When actor_type includes admin, restricts staff entries to these staff members by display name (one name or a comma-separated list). Ignored for other actor types.
Filter by actor category, or a comma-separated list of categories (any of them). api returns every entry written by an integration through POST /api/activity-logs. system also includes webhook-triggered events and rows with no actor recorded.
Filter by action name. Accepts a single action (e.g. subscription_paused) or a comma-separated list. Use the integration_* prefix to match custom entries logged via POST /api/activity-logs.
Page size (1-100). Defaults to 25.
1-indexed page number. Defaults to 1.
Inclusive end of the date range, formatted yyyy-MM-dd. Interpreted in the account timezone.
Inclusive start of the date range, formatted yyyy-MM-dd. Interpreted in the account timezone.
Responses
Section titled “Responses”Paginated list of activity log entries.
object
object
Action name. System-generated actions use snake_case domain verbs (e.g. subscription_paused); integration entries are prefixed integration_.
Optional field-level diff captured when the entry was written.
object
Free-form metadata stored alongside the entry.
object
Category of the actor that triggered the entry. api indicates the entry was written by an integration via POST /api/activity-logs.
Type of entity the entry is attached to.
UUID of the subscription or order the entry is attached to.
object
Example
{ "data": [ { "loggable_type": "subscription" } ]}