Skip to main content
GET
/
events
Query usage events
curl --request GET \
  --url https://api-m.paypal.com/v1/commerce/billing/events \
  --header 'Authorization: Bearer <token>'
{
  "events": [
    {
      "transaction_id": "event_1752016113",
      "external_subscription_id": "49fac470-fa34-4471-915e-bff1d05308ce",
      "metric_code": "EvolvAI_Billable_Metrics_1750804981",
      "timestamp": "2025-01-01T00:00:00Z",
      "properties": {
        "gb": 12
      },
      "id": "87b5897d-083f-490c-b5f5-d219087b4d73",
      "created_at": "2025-07-08T16:08:33-07:00"
    },
    {
      "transaction_id": "event_1752016329",
      "external_subscription_id": "b40f7d03-cf36-4cb6-b7af-bb3468f91072",
      "metric_code": "EvolvAI_Billable_Metrics_1751495485",
      "timestamp": "2025-01-02T00:00:00Z",
      "properties": {
        "gb": 12
      },
      "id": "42365b30-368a-4a0e-be4f-b790dab2cde9",
      "created_at": "2025-01-02T00:00:00Z"
    },
    {
      "transaction_id": "event_1752016319",
      "external_subscription_id": "b40f7d03-cf36-4cb6-b7af-bb3468f91072",
      "metric_code": "EvolvAI_Billable_Metrics_1751495485",
      "timestamp": "2025-01-01T00:00:00Z",
      "properties": {
        "gb": 12
      },
      "id": "38d78dd1-219e-43bb-af97-7e888e952605",
      "created_at": "2025-01-02T00:00:00Z"
    },
    {
      "transaction_id": "event_1752016316",
      "external_subscription_id": "b40f7d03-cf36-4cb6-b7af-bb3468f910721",
      "metric_code": "EvolvAI_Billable_Metrics_1751495485",
      "timestamp": "2025-01-01T00:00:00Z",
      "properties": {
        "gb": 12
      },
      "id": "2ee6fbfc-132c-4628-9138-450b27d68b32",
      "created_at": "2025-01-02T00:00:00Z"
    },
    {
      "transaction_id": "event_1752016310",
      "external_subscription_id": "b40f7d03-cf36-4cb6-b7af-bb3468f91072",
      "metric_code": "EvolvAI_Billable_Metrics_17514954851",
      "timestamp": "2025-01-01T00:00:00Z",
      "properties": {
        "gb": 12
      },
      "id": "67505fef-8dae-4547-b595-5f4265ac6a82",
      "created_at": "2025-01-02T00:00:00Z"
    },
    {
      "transaction_id": "event_1752016198",
      "external_subscription_id": "b40f7d03-cf36-4cb6-b7af-bb3468f91072",
      "metric_code": "EvolvAI_Billable_Metrics_1751495485",
      "timestamp": "2025-01-01T00:00:00Z",
      "properties": {
        "gb": 12
      },
      "id": "7f4d2d59-4691-4372-9931-aabef31a1cec",
      "created_at": "2025-01-02T00:00:00Z"
    },
    {
      "transaction_id": "event_1752016186",
      "external_subscription_id": "b40f7d03-cf36-4cb6-b7af-bb3468f91072",
      "metric_code": "EvolvAI_Billable_Metrics_1751495485",
      "timestamp": "2025-01-01T00:00:00Z",
      "properties": {
        "gb": 12
      },
      "id": "aa237cc9-e975-4486-a5cf-f2c0999190a9",
      "created_at": "2025-01-02T00:00:00Z"
    },
    {
      "transaction_id": "event_1752016165",
      "external_subscription_id": "b40f7d03-cf36-4cb6-b7af-bb3468f91072",
      "metric_code": "EvolvAI_Billable_Metrics_1751495485",
      "timestamp": "2025-01-06T00:00:00Z",
      "properties": {
        "gb": 12
      },
      "id": "528be51f-ee55-4c14-8306-50a26638190f",
      "created_at": "2025-01-06T00:00:00Z"
    },
    {
      "transaction_id": "event_1752016139",
      "external_subscription_id": "b40f7d03-cf36-4cb6-b7af-bb3468f91072",
      "metric_code": "EvolvAI_Billable_Metrics_1751495485",
      "timestamp": "2025-01-01T00:00:00Z",
      "properties": {
        "gb": 12
      },
      "id": "fe027df2-078f-4a92-9335-1c0f1c0d4123",
      "created_at": "2025-01-05T00:00:00Z"
    },
    {
      "transaction_id": "event_1752016138",
      "external_subscription_id": "b40f7d03-cf36-4cb6-b7af-bb3468f91072",
      "metric_code": "EvolvAI_Billable_Metrics_1751495485",
      "timestamp": "2025-01-04T00:00:00Z",
      "properties": {
        "gb": 12
      },
      "id": "91b72931-6c5e-48e4-8156-27621857c9c5",
      "created_at": "2025-01-03T00:00:00Z"
    }
  ],
  "metadata": {
    "current_page": 1,
    "total_pages": 4,
    "total_count": 32
  }
}

Authorizations

Authorization
string
header
required

Use the /v1/oauth2/token endpoint to obtain an access token and pass it as a Bearer token in the Authorization header.

Query Parameters

page
integer

Page number

per_page
integer

Number of records per page

external_subscription_id
string

Filter events by external subscription ID

Example:

"sub_1234567890abcdef"

metric_code
string

Filter events by metric code

Example:

"metric_123456ef"

from_date
string<date-time>

Start date for filtering events

Example:

"2023-01-01T00:00:00Z"

to_date
string<date-time>

End date for filtering events

Example:

"2023-01-01T00:00:00Z"

Response

A list of usage events

events
object[]
metadata
object
I