Events API Beta

The events API allows you to view the activity on your account. Note that some actions may create multiple events.

It’s expected that additional event types will be introduced over time. Event types currently include:

  • charge.authorised
  • charge.captured
  • charge.failed
  • customer.created
  • customer.updated
  • customer.deleted
  • recipient.created
  • recipient.updated
  • recipient.deleted
  • refund.created
  • refund.succeeded
  • refund.failed
  • transfer.created

Events are only guaranteed to be stored for 30 days after they are created.

GET /events

Returns a paginated list of all events.

Example

curl https://test-api.pinpayments.com/1/events -u your-secret-api-key:
200 OK
{
  "response": [
    {
      "token": "evt_12K4fafROQsdI5PdwLkX",
      "type": "charge.captured",
      "data": {
        "token": "ch_lfUYEBK14zotCTykezJkfg",
        "success": true,
        "amount": 400,
        "currency": "AUD",
        "description": "test charge",
        "email": "roland@pinpayments.com",
        "ip_address": "203.192.1.172",
        "created_at": "2012-06-20T03:10:49Z",
        "status_message": "Success",
        "error_message": null,
        "card": {
          "token": "card_pIQJKMs93GsCc9vLSLevbw",
          "scheme": "master",
          "display_number": "XXXX-XXXX-XXXX-0000",
          "issuing_country": "US",
          "expiry_month": 5,
          "expiry_year": 2019,
          "name": "Roland Robot",
          "address_line1": "42 Sevenoaks St",
          "address_line2": "",
          "address_city": "Lathlain",
          "address_postcode": "6454",
          "address_state": "WA",
          "address_country": "Australia",
          "customer_token": null,
          "primary": null
        },
        "transfer": [],
        "amount_refunded": 0,
        "total_fees": 42,
        "merchant_entitlement": 358,
        "refund_pending": false,
        "authorisation_expired": false,
        "captured": true,
        "captured_at": "2012-06-20T03:10:49Z",
        "settlement_currency": "AUD",
        "metadata": {
          "OrderNumber": "123456",
          "CustomerName": "Roland Robot"
        }
      },
      "created_at": "2018-12-14T15:50:17Z"
    }
  ],
  "pagination": {
    "count": 1,
    "per_page": 25,
    "current": 1
  }
}

GET /events/event-token

Returns the details of the specified event.

Example

curl https://test-api.pinpayments.com/1/events/evt_12K4fafROQsdI5PdwLkX -u your-secret-api-key:
200 OK
{
  "response": {
    "token": "evt_12K4fafROQsdI5PdwLkX",
    "type": "charge.captured",
    "data": {
      "token": "ch_lfUYEBK14zotCTykezJkfg",
      "success": true,
      "amount": 400,
      "currency": "AUD",
      "description": "test charge",
      "email": "roland@pinpayments.com",
      "ip_address": "203.192.1.172",
      "created_at": "2012-06-20T03:10:49Z",
      "status_message": "Success",
      "error_message": null,
      "card": {
        "token": "card_pIQJKMs93GsCc9vLSLevbw",
        "scheme": "master",
        "display_number": "XXXX-XXXX-XXXX-0000",
        "issuing_country": "US",
        "expiry_month": 5,
        "expiry_year": 2019,
        "name": "Roland Robot",
        "address_line1": "42 Sevenoaks St",
        "address_line2": "",
        "address_city": "Lathlain",
        "address_postcode": "6454",
        "address_state": "WA",
        "address_country": "Australia",
        "customer_token": null,
        "primary": null
      },
      "transfer": [],
      "amount_refunded": 0,
      "total_fees": 42,
      "merchant_entitlement": 358,
      "refund_pending": false,
      "authorisation_expired": false,
      "captured": true,
      "captured_at": "2012-06-20T03:10:49Z",
      "settlement_currency": "AUD",
      "metadata": {
        "OrderNumber": "123456",
        "CustomerName": "Roland Robot"
      }
    },
    "created_at": "2018-12-14T15:50:17Z"
  }
}

Error Responses

404 resource_not_found {...}
{
  "error": "resource_not_found",
  "error_description": "No resource was found at this URL."
}

Pin Payments is owned and operated by
Southern Payment Systems Pty Ltd
ABN: 46 154 451 582
Level 1, 34 Queen St,
Melbourne VIC 3000

Privacy Policy Terms Security Status

Australia