> ## Documentation Index
> Fetch the complete documentation index at: https://docs.upstackdata.com/llms.txt
> Use this file to discover all available pages before exploring further.

# invoice_paid Event

> Track when an invoice is paid

Fires when an invoice is paid.

## Example

```javascript theme={null}
window._upstack('track', 'invoice_paid', {
  // Standard parameters
  accountId: 'acct_abc123',
  invoiceId: 'inv_1042',
  value: 99.00,
  currency: 'USD',
  subscriptionId: 'sub_def456',
  amount: 9900,

  // User data
  email: 'jane@example.com',
  phone: '+15551234567',
  firstName: 'Jane',
  lastName: 'Smith',

  // Custom data
  paymentMethod: 'card',
  daysToPay: 3
});
```

## Standard parameters

| Name | Type | Required | Example value | Description |
| - | - | - | - | - |
| [`accountId`](https://docs.upstackdata.com/event-tracking/event-taxonomy/properties/saas#account-and-user) | `string` | Yes | `acct_abc123` | Your account or organization ID. |
| [`invoiceId`](https://docs.upstackdata.com/event-tracking/event-taxonomy/properties/saas#payment) | `string` | Yes | `inv_1042` | Your invoice ID. |
| [`value`](https://docs.upstackdata.com/event-tracking/event-taxonomy/properties/value) | `number` | Yes | `99.00` | Monetary value of the event, in major units. |
| [`currency`](https://docs.upstackdata.com/event-tracking/event-taxonomy/properties/currency) | `string` | Yes | `USD` | ISO 4217 currency code. |
| [`subscriptionId`](https://docs.upstackdata.com/event-tracking/event-taxonomy/properties/saas#subscription-and-revenue) | `string` | No | `sub_def456` | Your subscription ID. |
| [`amount`](https://docs.upstackdata.com/event-tracking/event-taxonomy/properties/saas#payment) | `number` | No | `9900` | Amount in cents. |

## User data

| Name | Type | Required | Example value | Description |
| - | - | - | - | - |
| [`email`](https://docs.upstackdata.com/event-tracking/event-taxonomy/properties/email) | `string` | Yes | `jane@example.com` | Email address. |
| [`phone`](https://docs.upstackdata.com/event-tracking/event-taxonomy/properties/phone) | `string` | Yes\* | `+15551234567` | Phone number in E.164 format. |
| [`firstName`](https://docs.upstackdata.com/event-tracking/event-taxonomy/properties/name) | `string` | Yes\* | `Jane` | First name. |
| [`lastName`](https://docs.upstackdata.com/event-tracking/event-taxonomy/properties/name) | `string` | Yes\* | `Smith` | Last name. |
| [`addresses`](https://docs.upstackdata.com/event-tracking/event-taxonomy/properties/address) | `Array<Address>` | No | [See address parameters](https://docs.upstackdata.com/event-tracking/event-taxonomy/properties/address.md) | Shipping and billing addresses. |

\* Required if you have it.

## Custom data

Examples for this event. See [how custom data works](https://docs.upstackdata.com/event-tracking/event-taxonomy/properties/custom-data.md).

| Name | Type | Example value | Description |
| - | - | - | - |
| `paymentMethod` | `string` | `card` | How the payment was made. |
| `daysToPay` | `number` | `3` | Days from invoice to payment. |

## Stripe webhook

Maps to `invoice.paid`.

## Related events

Paying a past-due invoice settles it. Pair this event with [`invoice_past_due`](https://docs.upstackdata.com/event-tracking/event-taxonomy/saas-events/invoice-past-due) to measure how many past-due accounts recover.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.