Payments

Payments represent transaction records for your contacts. Linking a payment to a contact creates an event that can trigger automated review request campaigns.

The payment model

Properties

  • Name
    id
    Type
    integer
    Description

    Unique identifier for the payment.

  • Name
    external_id
    Type
    string
    Description

    Your system's ID for this payment. Can be used in place of id in requests.

  • Name
    amount
    Type
    decimal
    Description

    Payment amount.

  • Name
    status
    Type
    string
    Description

    Payment status (e.g. completed, pending, refunded).

  • Name
    tags
    Type
    array
    Description

    Tags associated with this payment.

  • Name
    contact_id
    Type
    string
    Description

    ID of the associated contact.

  • Name
    event_date
    Type
    timestamp
    Description

    The event date used for campaign scheduling.

  • Name
    created_at
    Type
    timestamp
    Description

    Timestamp of when the payment was created.

  • Name
    updated_at
    Type
    timestamp
    Description

    Timestamp of when the payment was last updated.


GET/v1/payments

List all payments

Optional attributes

  • Name
    status
    Type
    string
    Description

    Filter by status.

  • Name
    limit
    Type
    integer
    Description

    Results per page (1–100). Defaults to 25.

  • Name
    page
    Type
    integer
    Description

    Page number. Defaults to 1.

Request

GET
/v1/payments
curl -G https://dashboard.reviewrover.co/api/v1/payments \
  -H "Authorization: Bearer {token}" \
  -d status=completed

Response

{
  "payments": [
    {
      "id": 1,
      "external_id": "pay_001",
      "amount": "75.00",
      "status": "completed",
      "contact_id": "cont_KYdl3lftgZXGRbxqoj",
      "event_date": "2025-02-17T00:00:00Z",
      "created_at": "2025-02-17T02:00:34Z",
      "updated_at": "2025-02-17T02:00:34Z"
    }
  ],
  "pagination": {
    "page": 1,
    "limit": 25,
    "total": 1,
    "total_pages": 1
  }
}

POST/v1/payments

Create a payment

Required attributes

  • Name
    contact_id
    Type
    string
    Description

    ID of the contact this payment belongs to.

Optional attributes

  • Name
    external_id
    Type
    string
    Description

    Your system's ID for this payment.

  • Name
    amount
    Type
    decimal
    Description

    Payment amount.

  • Name
    status
    Type
    string
    Description

    Payment status.

  • Name
    event_date
    Type
    timestamp
    Description

    Event date for campaign scheduling. Defaults to created_at.

  • Name
    tags
    Type
    array
    Description

    Tags to associate with this payment.

Request

POST
/v1/payments
curl https://dashboard.reviewrover.co/api/v1/payments \
  -H "Authorization: Bearer {token}" \
  -d contact_id="cont_KYdl3lftgZXGRbxqoj" \
  -d external_id="pay_001" \
  -d amount=75.00 \
  -d status="completed"

Response

{
  "id": 1,
  "external_id": "pay_001",
  "amount": "75.00",
  "status": "completed",
  "contact_id": "cont_KYdl3lftgZXGRbxqoj",
  "event_date": "2025-02-17T02:00:34Z",
  "created_at": "2025-02-17T02:00:34Z",
  "updated_at": "2025-02-17T02:00:34Z"
}

GET/v1/payments/:id

Retrieve a payment

Retrieve by numeric ID or external_id.

Request

GET
/v1/payments/pay_001
curl https://dashboard.reviewrover.co/api/v1/payments/pay_001 \
  -H "Authorization: Bearer {token}"

PUT/v1/payments/:id

Update a payment

Optional attributes

  • Name
    status
    Type
    string
    Description
    New status.
  • Name
    amount
    Type
    decimal
    Description
    Updated amount.
  • Name
    event_date
    Type
    timestamp
    Description
    Updated event date.

Request

PUT
/v1/payments/1
curl -X PUT https://dashboard.reviewrover.co/api/v1/payments/1 \
  -H "Authorization: Bearer {token}" \
  -d status="refunded"

DELETE/v1/payments/:id

Delete a payment

Permanently deletes a payment.

Request

DELETE
/v1/payments/1
curl -X DELETE https://dashboard.reviewrover.co/api/v1/payments/1 \
  -H "Authorization: Bearer {token}"