Overview
The Stripe to NetSuite invoice import runs on a schedule and can process thousands of invoices in a single run. This article explains how long imports typically take and how to plan your runs for the most predictable results.
What each import does
For every Stripe invoice it processes, the batch import:
- Finds or creates the NetSuite customer.
- Creates the NetSuite invoice.
- Creates and applies the customer payment, when the invoice has been paid.
That is up to three NetSuite records for each Stripe invoice.
Typical processing times
In PayPack's load testing, the import processed roughly 6 to 8 Stripe invoices per minute. Processing time grows steadily with volume, so you can estimate a run's length from its size.
| Stripe invoices in a run | Approximate time |
| About 900 | 2.5 hours |
| About 2,000 | 4.5 hours |
| About 3,600 | 8 hours |
| About 7,400 | 15 hours |
Actual times vary with your NetSuite account activity, the number of line items per invoice, customizations on the invoice or customer records, and other scripts running at the same time. These figures came from a NetSuite test environment with a single Stripe account.
After the first run, each scheduled run only picks up invoices created since the previous run, so most runs are much smaller and finish quickly.
Recommended batch size
For the most predictable results, keep each run to 2,000 to 3,000 Stripe invoices. In this range, imports completed with full logging.
In testing, runs above this size still created the invoices, customers and payments in NetSuite. However, as run size grew, some entries in the PayPack Flow Record Log were not written. The NetSuite records themselves were not affected. Keeping runs within the recommended size avoids gaps in your logs.
Planning a large first run
The first run is usually the largest, because it brings in your existing Stripe invoices. To keep it manageable:
- Choose a recent Invoice Start Date. The first run imports invoices created on or after the Invoice Start Date you set on the script deployment, so a more recent date means a smaller first run.
- Reduce what you import. Turn on Exclude $0 Invoices and use the Status filter to import only the invoice statuses you need.
- Expect a long first run. A run of several thousand invoices can take many hours. Schedule it outside business hours.
- Talk to us first. If you expect to import more than about 3,000 invoices at once, contact PayPack Support before your first run and we will help you plan it.
Tips for smooth imports
- Run more often. More frequent schedules (for example, every 2 hours) mean smaller batches that finish sooner.
- Schedule at off-peak times. Running heavy imports when NetSuite is quiet helps them finish faster and reduces the chance of conflicts with other scripts.
- Avoid overlapping heavy scripts. If other large scheduled scripts run on your account, stagger them from the import.
- Use On-Demand for gaps. To import specific missing invoices, use the On-Demand import instead of re-running the batch.
Monitoring your runs
Use the PayPack Flow Status Log to see when a run started and finished and its overall result, and the PayPack Flow Record Log to see each invoice processed. If a Flow Record Log entry seems to be missing after a very large run, check the NetSuite invoice itself: invoices imported by PayPack carry the Stripe Invoice Id (PayPack) field.
For setup and scheduling details, see the Stripe to NetSuite Invoice Import article.