Record usage in the Dashboard
Learn how to record your customer's usage in the Dashboard manually or using a CSV file.
You must record usage in Stripe to bill your customers the correct amounts each billing period. To record usage, you can manually add usage data or upload a CSV file with the usage data in the Dashboard. Stripe parses, validates, and transforms the usage data into meter events.
After the events upload successfully, you can see them in the live meter feed. You can also check the status of your uploaded files on the Data management page.
Add usage data manually
You can manually add usage data on the Meters page in the Stripe Dashboard.
- On the Meters page, select the meter name.
- On the meter page, click Add usage > Manually input usage.
- On the Add usage page, do the following:
- Select your customer from the Customer dropdown.
- For Value, enter a sample value.
- Click Submit.
Upload a CSV file with usage data
After you prepare your CSV file with the usage data, you can upload it in the Stripe Dashboard. Make sure to format your file to match the template that’s available in the Dashboard. The maximum file size allowed is 5 MB.
CSV file format and fields
Make sure your CSV file follows this sample file format:
timestamp | event_ -payload_ | payload_ | |
2024-09-25 | ai_search_api | cus_QMJJtcu70R1x46 | 400 |
2024-09-26 | ai_search_api | cus_GAXJtSu6021a6s | 600 |
2024-09-27 | cpu_usage | cus_Qz0fwcfSysB9Z3 | 600 |
Follow the meter event schema when including the following fields in your file:
Field | Description |
---|---|
| The date that the event occurred. We support the following timestamp formats:
|
event_ | The name of the meter event. |
payload_ | The stripe_customer_id that the event gets created against. You can obtain the customer_ details on the Customers page. |
payload_ | The numerical usage value of the meter event, such as the number of hours to invoice for. If you specified a different key in the value_ , you must update the column name to match the key value. For example, if you specify tokens in the value_ , update the column name to payload_ . |
Upload your CSV file
If your file contains errors, you can download an error file that includes the reason for each failed record. After you fix the errors, you can upload the updated file.
- On the Meters page, select the meter name that you want to add usage events to.
- On the meter page, click Add usage > Upload file to add usage.
- On the Upload file to add usage page, select your file.
- Click Upload file.
- Verify the meter event count and aggregated value on the meter page.