Skip to main content
Version: 1.0.x

Welcome to Lunar.dev

Hi there! đź‘‹

Welcome to Lunar.dev, a solution for API consumption management and 3rd party traffic controls. With granular quota management, harness the power of consuming external APIs without compromising performance and scale.

Welcome

What is Lunar?​

Managing API consumption at scale is complex especially you’re making volumes of calls, consuming APIs on behalf of your clients, using flaky APIs, or sharing quota between environments.

Lunar solves these problems by offering a real-time API consumption management platform designed to handle your outbound traffic. No need for code changes—just seamless integration into your infrastructure.

Why Lunar?​

As organizations scale, so do the challenges associated with managing API consumption. 429 errors (rate limits) become inevitable. Lunar steps in as a unified, real-time API management solution, proactively preventing these errors and optimizing your API traffic.

With Lunar, your teams can:

  • Unify the management of third-party API consumption in production.
  • Diagnose and fix API performance issues in real time.
  • Create resilience with new and customizable flows.

Lunar is a powerful addition to your tech stack. It offers out-of-the-box support for all third-party APIs and optimizes outbound traffic without compromising latency.

Who is Lunar For?​

Lunar is designed for organizations that face complex challenges in managing API quotas and rate limits, especially when multiple services need to interact with the same API provider. These challenges often stem from a lack of centralized state or awareness among services, leading to bottlenecks and inefficient API usage. Timing is a critical issue in such cases, which makes it necessary to introduce a solution that can prioritize quotas and scale effectively.

Lunar is tailored for the following use cases:

  1. Consume APIs on Behalf of Your Clients:

    API rate limits are often unpredictable, as they depend on how frequently users decide to trigger the API engine. In this use case, the varying API consumption rates across different clients create a need for managing multiple quotas dynamically. Lunar allows you to handle these variations efficiently, ensuring fair distribution of resources and reducing the risk of exceeding quotas unexpectedly.

  2. Multiple Consumers Sharing the Same Quota:

    When multiple isolated environments share a single API key, managing their shared quota becomes a significant challenge. Without a solution, it is difficult to ensure that no single environment consumes too much of the quota, potentially affecting other environments. Lunar provides centralized quota management that balances usage across environments, helping avoid disruptions and ensuring API consumption remains within acceptable limits.

Lunar.dev API Consumption Gateway​

The Lunar Gateway optimizes and manages your API traffic out-of-the-box configurations called Lunar Flows, which provide detailed control over requests and responses, optimizing traffic management during peaks and unexpected surges. Whether deploying in siloed environments or using a shared-state configuration Lunar supports seamless installations across departments and infrastructures. Its failsafe mechanism ensures no data loss or service disruption by rerouting traffic during timeouts. The gateway's scalability and performance remain consistent, providing minimal latency while balancing even the most intensive API workloads across various architectures and cloud providers.

Route your API Traffic​

To optimize API usage and manage quotas more effectively, you should route your API traffic through the Lunar Gateway. This allows Lunar to enforce policies, prioritize requests, and ensure smooth API consumption. The easiest way to achieve this is through Direct Mode, the preferred method, which requires no installation—simply modify your HTTP requests with specific headers, and your traffic will be automatically routed through Lunar Gateway.

Alternatively, Lunar provides interceptors for more advanced use cases. These interceptors capture and redirect outgoing HTTP/S requests to Lunar Gateway, with built-in fail-safe mechanisms to maintain uninterrupted service if the proxy is temporarily unavailable.

Lunar Flows: The Core of API Consumption Management​

Lunar Flows are the core of Lunar’s API management system, enabling you to enforce API consumption policies with precision. Flows are YAML-based configurations that define how API requests and responses are processed in real time. You can customize and optimize traffic across multiple environments with ease, ensuring efficient API usage.

Available Flows:

Lunar Quotas: Centralized API Quota Management​

Lunar Quotas offer a flexible, centralized way to manage API consumption, supporting both internal and provider-defined quotas. With the Quota System, users can set precise limits for API consumption across various flows and user groups. This ensures real-time, scalable control of API usage, preventing any overconsumption of resources.

Lunar allows you to:

  • Monitor Real-time API Usage: Quotas update dynamically, giving you accurate, up-to-the-minute usage data.
  • Granular Control: Set quotas based on URLs, headers, or user groups for more detailed resource control.
  • Scalability: Manage and track quotas across multiple API flows and environments, ensuring smooth traffic management.

For more information, see the Configure Your API Quotas page.

Explore Lunar Control Plane​

The Lunar Control Plane is a powerful graphical user interface (GUI) designed to streamline API management within the Lunar.dev ecosystem. It offers advanced observability and management functionalities, making it easier to optimize your API performance and gain insights into usage.

With the Lunar Control Plane, you can:

  • Simplify Installation: Easily install and configure Lunar Gateway and Interceptors.
  • Monitor API Calls: Track total API calls, check error rates, and analyze latency with average runtime per API.
  • Review API Performance: Examine status code distributions, explore API functionality, and evaluate endpoint performance.
  • Manage Resources: Define path parameters, invite additional team members, view active flows, and review your API quota usage.
  • Access Pre-Made Flows: Browse a library of available flows with easy configuration steps.

To get started, sign up or sign in to the Lunar Control Plane. Follow the installation instructions to connect to Lunar, define path parameters, invite team members, and review your active flows and API quota usage.

For a detailed video walkthrough on installing lunar.dev consumption platform, click here.