Skip to main content

Documentation Index

Fetch the complete documentation index at: https://api.docs.onlydrams.app/llms.txt

Use this file to discover all available pages before exploring further.

Retrieves the complete payment history for a community member including all invoices, charges, and refunds.

URL Parameters

community_id
integer
required
The ID of the community
id
integer
required
The ID of the community membership

Returns

Returns detailed payment history including invoices, charges, and refunds.
curl -X GET https://api.onlydrams.app/odis/v1/communities/1/members/50/payment_history \
     -H "Authorization: Bearer $ACCESS_TOKEN"
{
  "payments": [
    {
      "id": "in_1234567890",
      "amount_cents": 999,
      "amount_dollars": 9.99,
      "currency": "usd",
      "status": "paid",
      "paid": true,
      "payment_intent": "pi_1234567890",
      "charge_id": "ch_1234567890",
      "created_at": "2024-11-01T00:00:00Z",
      "period_start": "2024-11-01T00:00:00Z",
      "period_end": "2024-12-01T00:00:00Z",
      "invoice_pdf": "https://pay.stripe.com/invoice/acct_.../pdf",
      "hosted_invoice_url": "https://invoice.stripe.com/i/acct_...",
      "charge_details": {
        "amount_refunded_cents": 0,
        "amount_refunded_dollars": 0.0,
        "refunded": false,
        "refundable_amount_cents": 999,
        "refundable_amount_dollars": 9.99,
        "can_refund": true
      },
      "refunds": []
    },
    {
      "id": "in_0987654321",
      "amount_cents": 999,
      "amount_dollars": 9.99,
      "currency": "usd",
      "status": "paid",
      "paid": true,
      "payment_intent": "pi_0987654321",
      "charge_id": "ch_0987654321",
      "created_at": "2024-10-01T00:00:00Z",
      "period_start": "2024-10-01T00:00:00Z",
      "period_end": "2024-11-01T00:00:00Z",
      "invoice_pdf": "https://pay.stripe.com/invoice/acct_.../pdf",
      "hosted_invoice_url": "https://invoice.stripe.com/i/acct_...",
      "charge_details": {
        "amount_refunded_cents": 999,
        "amount_refunded_dollars": 9.99,
        "refunded": true,
        "refundable_amount_cents": 0,
        "refundable_amount_dollars": 0.0,
        "can_refund": false
      },
      "refunds": [
        {
          "id": "re_1234567890",
          "amount_cents": 999,
          "amount_dollars": 9.99,
          "currency": "usd",
          "status": "succeeded",
          "reason": "requested_by_customer",
          "created_at": "2024-10-05T10:30:00Z"
        }
      ]
    }
  ],
  "total_paid_cents": 2997,
  "total_paid_dollars": 29.97,
  "total_refunded_cents": 999,
  "total_refunded_dollars": 9.99,
  "net_paid_cents": 1998,
  "net_paid_dollars": 19.98,
  "currency": "usd",
  "payment_count": 3
}

Response Fields

payments
array
Array of invoice objects with charge and refund details
total_paid_cents
integer
Total amount paid by member in cents
total_refunded_cents
integer
Total amount refunded to member in cents
net_paid_cents
integer
Net amount (paid minus refunded) in cents
payment_count
integer
Total number of successful payments

Notes

  • Authorization: Community owner or admin only
  • Limit: Returns last 100 invoices
  • Charge Details: Each payment includes refundability information
  • Refund Tracking: Shows all refunds associated with each charge
  • Currency: All amounts shown in both cents and dollars