On this page

Which API should I use?

Who should use the HTTP V2 API?

Use the HTTP V2 API if you:

  • Want to send low-volume data partitions quickly
  • Want to ingest data as close to real-time as possible
  • Want the flexibility to adjust the data on the fly

The HTTP V2 API sends data directly from your server to the HTTP V2 endpoint.

What are the pros and cons of the HTTP V2 API?

Pros: Once data is received by Amplitude's servers, it's available in your instance within a relatively short time. This makes the HTTP V2 API the preferred choice for real-time or live-streaming data. Events sent with HTTP V2 (for the same device_id) are also processed in the exact order in which they're received. That doesn't always matter for analysis, but it can be critical when ordering does — for example, in time-sensitive funnel analyses.

If the same user is sending data on multiple devices, there is no ordering guarantee between events from different devices.

Cons: Amplitude throttles requests for users and devices that exceed 30 events per second (measured as an average over a recent time window). If you exceed the limit you receive an error and must pause sending events for that user or device for 30 seconds before retrying. The HTTP V2 API is a poor choice if you have high data volumes or need to scale.

What are examples of HTTP V2 API use cases?

The HTTP V2 API is most useful when you're:

  • Working with real-time data
  • Working with low data volumes
  • Working with small chunks of partitioned data

Who should use the Batch Event Upload API?

Use the Batch Event Upload API if you:

  • Plan to bulk-ingest data
  • Use other platforms and want to send their data to Amplitude
  • Are running into HTTP V2 throttling limits

The Batch Event Upload API lets you upload large amounts of event data at once.

Throttling is one of the most important things to consider when sending data to Amplitude. Because of how the data processing pipeline works, it can be challenging to process a high volume of events for a single device or user. Amplitude considers a rate of 10 events/second for a single user or device (EPUS/EPDS) high, and 30 events/second spammy — humans don't typically produce events at those rates, so they're often a sign of broken instrumentation or spam data.

There are still legitimate use cases that justify large volumes — primarily batch uploads. For example, some customers don't upload event data until the day ends so they can add extra information first. If a user produced 10,000 events that day and you try to send them all in a single minute, you'll average more than 100 EPUS, which the HTTP V2 API can't handle. The Batch Event Upload API is designed to absorb these bursts; it has much higher limits and buffers data for longer than the HTTP V2 API.

What are examples of Batch Event Upload API use cases?

The Batch Event Upload API is most useful when you're:

  • Backfilling (sending a historical dataset all at once)
  • Migrating data from another system
  • Working with non-real-time workloads
  • Working with data you don't need in Amplitude immediately

What are other options?

The HTTP V2 API and the Batch Event Upload API aren't the only ways to send data to Amplitude. Amplitude also offers:

In short: HTTP V2 is best for real-time workloads; Batch is best for batch processing; SDKs and source integrations cover most of the rest.

Was this helpful?