What is SuperAPI?

SuperAPI is an API gateway that intelligently caches your API requests to make them at least 10x faster.

What's so intelligent about SuperAPI's caching?

SuperAPI automatically invalidates the cached APIs when any update to the relevant data occurs. This means your users always get fast responses with the most up-to-date information, without your team spending months refactoring your code or adding cache invalidation logic across your entire codebase.

How does SuperAPI work?

A. Database changelog monitoring

SuperAPI automatically listens to your database's replication stream, which allows us to detect any changes to your data that occurs by:

  • Internal cron jobs
  • Batch processes
  • Direct database modifications
  • Changes made outside your API layer
  • Database Triggers

This monitoring has no impact on the database's performance.

B. API-Level Monitoring

Simultaneously, SuperAPI monitors mutation API requests (POST, PUT, PATCH) and intelligently determines which cached responses might be affected by these changes.

C. Targeted Cache Invalidation

When changes are detected, SuperAPI doesn't simply purge the entire cache. Instead, it performs surgical invalidation of only the affected data. In many cases, it can even update the cache in-place, modifying only the portions that have changed rather than invalidating the entire response.

This selective approach means:

  1. Your cache maintains a high hit rate.
  2. Database and compute resources experience reduced load.
  3. Users consistently receive fresh data with low latency.
  4. Overall cloud infrastructure costs decrease.

Supported types of APIs

SuperAPI is specifically designed to handle caching challenges that other solutions struggle with:

  • GraphQL Operations: SuperAPI understands GraphQL operations and can cache responses at the field level.
  • POST-based APIs: Unlike traditional cache systems that primarily work with GET requests, SuperAPI can cache POST requests where search parameters are included in the request body.
  • Frequently Changing Data: By monitoring database changes, SuperAPI can keep cache fresh even when the underlying data changes rapidly.

How is SuperAPI different from other caching solutions?

Traditional caching solutions often struggle with dynamic APIs because they can't reliably determine when cached data becomes stale. Common approaches like time-based expiration (TTL) are either too aggressive (causing unnecessary origin requests) or too lenient (serving stale data).

SuperAPI takes a fundamentally different approach by:

  1. Monitoring Data Changes at the Source: By connecting directly to your database replication stream, SuperAPI knows exactly when and what data has changed.
  2. Understanding API-Data Relationships: SuperAPI maps relationships between your API endpoints and database tables.
  3. Performing Smart Cache Operations: Instead of simple invalidation, SuperAPI can perform targeted updates and invalidations.

This results in a more intelligent caching system that maintains high performance without compromising data freshness.

Deployment Options

SuperAPI offers flexible deployment options:

  • As a standalone API gateway.
  • Self-hosted or deployed to your AWS or GCP account.

This flexibility allows you to integrate SuperAPI into your existing infrastructure with minimal disruption while maximizing performance benefits.

On this page