Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
42 changes: 21 additions & 21 deletions docs/api/01-overview.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ We document below:

As an alternative to reading data from the contracts or listening to onchain events, we use a set of subgraphs and
indexers. These act as a middleware between the chain and our interfaces and allow for caching, formatting and querying
data. For more advanced features like merkle generation (used in Drops) we've written out own SDKs and open sourced some
of them.
data. For more advanced features like merkle generation (used in Airdrops) we've written out own SDKs and open sourced
some of them.

:::note Playground

Expand All @@ -49,8 +49,8 @@ Sablier data from the official [endpoints](/api/lockup/endpoints). Every network
- [Lockup subgraph](https://github.com/sablier-labs/subgraphs/apps/lockup) (Vesting)
- [Flow endpoints](/api/flow/endpoints)
- [Flow subgraph](https://github.com/sablier-labs/subgraphs/apps/flow) (Payments)
- [Drops endpoints](/api/drops/endpoints)
- [Drops subgraph](https://github.com/sablier-labs/subgraphs/apps/merkle) (Drops, Airstreams)
- [Airdrops endpoints](/api/airdrops/endpoints)
- [Airdrops subgraph](https://github.com/sablier-labs/subgraphs/apps/merkle) (Airdrops, Airstreams)
- [The Graph docs](https://thegraph.com/docs/en/quick-start/)

<LinkPreview
Expand All @@ -65,12 +65,12 @@ Sablier data from the official [endpoints](/api/lockup/endpoints). Every network
Every subgraph deployment will have a `slug` generated by The Graph from its name. You'll find it in the Studio
Development Query URL. We define the following naming convention for subgraphs:

| Subgraph | Example | Product or Concept |
| ------------------- | ----------------------------------- | ------------------------------------------------- |
| `sablier-v2-*` | `sablier-v2`, `sablier-v2-optimism` | [Lockup](/concepts/lockup/overview) (Vesting) |
| `sablier-v2-flow-*` | `sablier-v2-flow-arbitrum` | [Flow](/concepts/flow/overview) (Payments) |
| `sablier-v2-ms-*` | `sablier-v2-ms-base` | [Airstreams](/concepts/lockup/airstreams) (Drops) |
| `sablier-*` | `sablier-optimism` | [V1](/api/legacy-v1) (Legacy) |
| Subgraph | Example | Product or Concept |
| ------------------- | ----------------------------------- | ---------------------------------------------------- |
| `sablier-v2-*` | `sablier-v2`, `sablier-v2-optimism` | [Lockup](/concepts/lockup/overview) (Vesting) |
| `sablier-v2-flow-*` | `sablier-v2-flow-arbitrum` | [Flow](/concepts/flow/overview) (Payments) |
| `sablier-v2-ms-*` | `sablier-v2-ms-base` | [Airstreams](/concepts/lockup/airstreams) (Airdrops) |
| `sablier-*` | `sablier-optimism` | [V1](/api/legacy-v1) (Legacy) |

### Envio

Expand All @@ -88,8 +88,8 @@ architecture.
- [Lockup indexer](https://github.com/sablier-labs/subgraphs/apps/lockup-envio) (Vesting)
- [Flow endpoints](/api/lockup/endpoints)
- [Flow indexer](https://github.com/sablier-labs/subgraphs/apps/flow-envio) (Payments)
- [Drops endpoints](/api/drops/endpoints)
- [Drops indexer](https://github.com/sablier-labs/subgraphs/apps/merkle-envio) (Drops, Airstreams)
- [Airdrops endpoints](/api/airdrops/endpoints)
- [Airdrops indexer](https://github.com/sablier-labs/subgraphs/apps/merkle-envio) (Airdrops, Airstreams)
- [The Graph docs](https://thegraph.com/docs/en/quick-start/)

<LinkPreview
Expand All @@ -103,15 +103,15 @@ architecture.

### Merkle API

To support our merkle distribution ([Drops](/apps/features/drops) / Airstreams) system we developed a backend service
called `@sablier/merkle-api`. This API deals with the validation, creation and management of merkle trees, used to
define eligibility and claiming rules for Sablier's Airstream campaigns.
To support our merkle distribution ([Airdrops](/apps/features/airdrops) / Airstreams) system we developed a backend
service called `@sablier/merkle-api`. This API deals with the validation, creation and management of merkle trees, used
to define eligibility and claiming rules for Sablier's Airstream campaigns.

This service is open-source and can be used by integrators as a plug-n-play solution to support (and even deploy)
similar campaigns from their own dashboards. Read more on the dedicated page about the `merkle-api`
[service](/api/drops/merkle-api/overview).
[service](/api/airdrops/merkle-api/overview).

- [Endpoints](/api/drops/endpoints)
- [Endpoints](/api/airdrops/endpoints)

<LinkPreview
href="https://github.com/sablier-labs/merkle-api"
Expand All @@ -129,15 +129,15 @@ The [vesting](/apps/features/vesting) side of the application will be powered by
- The `@sablier/subgraphs/apps/lockup` subgraph
- The `@sablier/subgraphs/apps/lockup-envio` indexer

### Drops (Airstreams)
### Airdrops (Airstreams)

The [drops](/apps/features/drops) side of the application will be powered by:
The [airdrops](/apps/features/airdrops) side of the application will be powered by:

- The `@sablier/subgraphs/apps/merkle` subgraph
- The `@sablier/subgraphs/apps/merkle-envio` indexer
- The `@sablier/merkle-api` rust service for drops
- The `@sablier/merkle-api` rust service for airdrops

These will work for both Airstreams and Instant Drops 🔜.
These will work for both Airstreams and Instant Airdrops 🔜.

### Flow

Expand Down
4 changes: 2 additions & 2 deletions docs/api/05-development.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -78,9 +78,9 @@ recommend using:
If you're integrated the Sablier subgraphs, we recommend using request and response wrappers/middleware to format
results coming from Envio's indexer in the same shape as those from The Graph. Suggestions:

1. Write queries in both systems (based on the [querying language specifics](differences#querying-language)) using the
1. Write queries in both systems (based on the [querying language specifics](/api/caveats#querying-language)) using the
same `operationName` and swap query strings between vendors based on it
2. Write response middleware that converts results into similar shapes (see these [important notes](differences))
2. Write response middleware that converts results into similar shapes (see these [important notes](/api/caveats))

<LinkPreview
href="https://github.com/sablier-labs/subgraphs"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@ title: "Overview"

import LinkPreview from "@site/src/components/LinkPreview";

# Sablier Drops
# Sablier Airdrops

Sablier's [Lockup](/concepts/lockup/overview) streams are used for the [Vesting](/apps/features/vesting) and (part of)
the [Drops](/apps/features/drops) components of the Sablier Interfaces. The Drops section, supported by our
the [Airdrops](/apps/features/airdrops) components of the Sablier Interfaces. The Airdrops section, supported by our
[Merkle](/concepts/lockup/airstreams) utilities focuses on the functionality of the Merkle Factory peripheries.

Drops-native functionality is powered by:
Airdrops-native functionality is powered by:

- The `@sablier/subgraphs/apps/merkle` subgraph
- The `@sablier/subgraphs/apps/merkle-envio` indexer
Expand All @@ -22,7 +22,7 @@ For the Lockup-native functionality, please check the dedicated [documentation](

:::info

[Airstreamed](/apps/features/drops) drops will create a Lockup stream once a claim is made.
[Airstreamed](/apps/features/airdrops) airdrops will create a Lockup stream once a claim is made.

:::

Expand All @@ -40,9 +40,9 @@ For the Lockup-native functionality, please check the dedicated [documentation](
title="Sablier SDK: Merkle API"
/>

## What are Drops / Airstreams?
## What are Airdrops / Airstreams?

**Drops** are large-scale campaigns developed to aid with token distribution towards millions of users. They rely on
**Airdrops** are large-scale campaigns developed to aid with token distribution towards millions of users. They rely on
**merkle trees** to efficiently store eligibility details.

Extending the classic instant airdrop, Sablier engineered Airstreams, a way to reward users with streams which vest
Expand All @@ -52,6 +52,6 @@ The first step before diving into this guide is to become familiar with the [con

#### Naming convention

As per our endpoint [naming convention](api/overview#endpoints--slugs), subgraph deployments of Sablier Airstreams and
Instant Drops will follow the `sablier-v2-ms-*` (short for "merkle subgraph") structure (e.g. `sablier-v2-ms` for
As per our endpoint [naming convention](/api/overview#endpoints--slugs), subgraph deployments of Sablier Airstreams and
Instant Airdrops will follow the `sablier-v2-ms-*` (short for "merkle subgraph") structure (e.g. `sablier-v2-ms` for
Mainnet, `sablier-v2-ms-base` for Base).
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,15 @@ title: "Endpoints"

import LinkPreview from "@site/src/components/LinkPreview";

# Drops / Airstreams
# Airdrops / Airstreams

## The Graph

This subgraph tracks events emitted by the `@sablier/lockup-periphery` contracts, specifically the ones in charge of
merkle distributions. It deals with drops-specific actions like the factory creating an airstream campaign, admin
merkle distributions. It deals with airdrops-specific actions like the factory creating an airstream campaign, admin
clawbacks, or users claiming stream NFTs as defined in the attached Merkle tree.

Drops work in tandem with [vesting](/apps/features/vesting) as merkle distributions will produce new
Airdrops work in tandem with [vesting](/apps/features/vesting) as merkle distributions will produce new
[lockup](/api/lockup/overview) streams. Be sure to check out that part of the docs too.

:::important
Expand Down Expand Up @@ -57,7 +57,7 @@ transitioned our subgraphs to either the Studio or The Decentralized Network (se
## Envio

This indexers tracks the events emitted by the `@sablier/lockup-periphery` contracts, specifically the ones in charge of
merkle distributions. It deals with drops-specific actions like the factory creating an airstream campaign, admin
merkle distributions. It deals with airdrops-specific actions like the factory creating an airstream campaign, admin
clawbacks, or users claiming stream NFTs as defined in the attached Merkle tree.

:::tip Chains: Individual vs. Aggregated
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"collapsed": false,
"label": "Sablier Drops",
"label": "Sablier Airdrops",
"position": 4
}
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,9 @@ title: "Similarities"
Envio indexers are designed to mirror the functionality and structure of the The Graph subgraphs.

For an introduction into the base Sablier primitives and some architectural choices, make sure to check out the
[merkle subgraph](/api/drops/the-graph/entities) before reading about the `merkle-envio` indexer.
[merkle subgraph](/api/airdrops/the-graph/entities) before reading about the `merkle-envio` indexer.

The same (or similar) entities are used throughout both The Graph and Envio setups, as well as protocol and merkle
deployments.

- [Entities](/api/drops/the-graph/entities)
- [Structure](/api/drops/the-graph/structure)
- [Architecture and Data Flow](/api/lockup/the-graph/architecture)
- [Entities](/api/airdrops/the-graph/entities)
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ sidebar_position: 2
title: "Queries"
---

Building on top of the [entity structure](/api/drops/the-graph/entities) defined earlier, here are some common GraphQL
queries for fetching data from the Sablier subgraph.
Building on top of the [entity structure](/api/airdrops/the-graph/entities) defined earlier, here are some common
GraphQL queries for fetching data from the Sablier subgraph.

### Recent streams

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,7 @@ title: "Overview"

import LinkPreview from "@site/src/components/LinkPreview";

## Overview

Sablier's Drops rely on pre-configured merkle trees. This data structure contains the list of recipients as well as
Sablier's Airdrops rely on pre-configured merkle trees. This data structure contains the list of recipients as well as
their individual claim details.

### General data flow
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ keys).

Feel free to reach out for any guidance or feedback.

The official endpoints can be seen in the [drops-endpoints](/api/drops/endpoints) registry.
The official endpoints can be seen in the [airdrops-endpoints](/api/airdrops/endpoints) registry.

## Create: `/api/create`

Expand Down Expand Up @@ -123,11 +123,11 @@ This endpoint uses an authentication scheme. Please reach out if you need to use
To check eligibility for an address, you'll be required to provide:

- the address of the user
- the CID of the IPFS file (see the [create](/api/drops/merkle-api/functionality#create-apicreate) flow above for
- the CID of the IPFS file (see the [create](/api/airdrops/merkle-api/functionality#create-apicreate) flow above for
context) the campaign is linked to

To get a hold of the second item you can see some options here in the
[Common flows](/api/drops/merkle-api/examples#get-a-campaigns-cid) page.
[Common flows](/api/airdrops/merkle-api/examples#get-a-campaigns-cid) page.

### Description

Expand Down Expand Up @@ -184,7 +184,7 @@ To check eligibility for an address, you'll be required to provide:
- the CID of the IPFS file the campaign is linked to

To get a hold of it you can see some options here in the
[Common flows](/api/drops/merkle-api/examples#get-a-campaigns-cid) page.
[Common flows](/api/airdrops/merkle-api/examples#get-a-campaigns-cid) page.

### Description

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@ import Tabs from "@theme/Tabs";
# Examples of common flows

Here are some common architectural flows you may need to integrate into your application. These include ways to gather
the prerequisite data necessary for each backend [functionality](/api/drops/merkle-api/functionality) described earlier.
the prerequisite data necessary for each backend [functionality](/api/airdrops/merkle-api/functionality) described
earlier.

## Get a campaign's CID

Expand Down Expand Up @@ -175,9 +176,10 @@ To check if a user has already claimed their stream from a campaign you can:
For approach "A" you'll need to perform the following actions:

1. Get a hold of the campaign's CID, Lockup contract address, and user address (for the first items, see the
[Get a campaign's CID](/api/drops/merkle-api/examples#get-a-campaigns-cid) example above)
2. Check the eligibility of a user (see [Eligibility](/api/drops/merkle-api/examples#check-eligibility-for-an-address)
example above) and extract their `index`
[Get a campaign's CID](/api/airdrops/merkle-api/examples#get-a-campaigns-cid) example above)
2. Check the eligibility of a user (see
[Eligibility](/api/airdrops/merkle-api/examples#check-eligibility-for-an-address) example above) and extract their
`index`
3. Call the `hasClaimed` method inside the `lockup` contract using the `index` retrieved at step 2

:::note
Expand All @@ -190,7 +192,7 @@ generate a proof in case the recipient is eligible and to register their claim d
#### Approach B

For approach "B", run the same query as in the
[Get the tokenId after a claim](/api/drops/merkle-api/examples#get-the-tokenid-after-a-claim) example. If the query
[Get the tokenId after a claim](/api/airdrops/merkle-api/examples#get-the-tokenid-after-a-claim) example. If the query
yields any results, that means the user has claimed their stream.

:::tip
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ sidebar_position: 2
title: "Queries"
---

Building on top of the [entity structure](/api/drops/the-graph/entities) defined earlier, here are some common GraphQL
queries for fetching data from the Sablier subgraph.
Building on top of the [entity structure](/api/airdrops/the-graph/entities) defined earlier, here are some common
GraphQL queries for fetching data from the Sablier subgraph.

### Recent streams

Expand Down
4 changes: 2 additions & 2 deletions docs/api/flow/01-overview.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -25,5 +25,5 @@ Flow-native functionality is powered by:

#### Naming convention

As per our endpoint [naming convention](api/overview#endpoints--slugs), subgraph deployments of Sablier Flow will follow
the `sablier-v2-flow-*` structure (e.g. `sablier-v2-flow` for Mainnet, `sablier-v2-flow-base` for Base).
As per our endpoint [naming convention](/api/overview#endpoints--slugs), subgraph deployments of Sablier Flow will
follow the `sablier-v2-flow-*` structure (e.g. `sablier-v2-flow` for Mainnet, `sablier-v2-flow-base` for Base).
4 changes: 2 additions & 2 deletions docs/api/lockup/01-overview.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import LinkPreview from "@site/src/components/LinkPreview";
# Sablier Lockup

Sablier's [Lockup](/concepts/lockup/overview) streams are used for the [vesting](/apps/features/vesting) and some of the
[drops](/apps/features/drops) functionality of the Sablier Interfaces.
[airdrops](/apps/features/airdrops) functionality of the Sablier Interfaces.

Lockup-native functionality is powered by:

Expand All @@ -25,5 +25,5 @@ Lockup-native functionality is powered by:

#### Naming convention

As per our endpoint [naming convention](api/overview#endpoints--slugs), subgraph deployments of Sablier Lockup will
As per our endpoint [naming convention](/api/overview#endpoints--slugs), subgraph deployments of Sablier Lockup will
follow the `sablier-v2-*` structure (e.g. `sablier-v2` for Mainnet, `sablier-v2-base` for Base).
2 changes: 1 addition & 1 deletion docs/api/lockup/envio/02-architecture.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ To offer a backwards compatible subgraph (between Sablier Core/ Sablier Peripher
the ABIs of the two versions. This will cause the configuration file to contain similar events between different
versions of Lockup contract.

Different from how we handle this for [subgraphs](/apps/lockup/the-graph), `Lockup Linear`, `Lockup Dynamic` and
Different from how we handle this for [subgraphs](/api/lockup/the-graph/entities), `Lockup Linear`, `Lockup Dynamic` and
`Lockup Tranched` will be bundled under the same `Lockup<Version>` contract tracker `config.yaml`. Versions of the
protocol will be tracked separately, which is why we have `Lockup_V20` (v2.0) and `Lockup_V21` (v2.1) in our
configuration. Later on, inside the handler logic, we'll separate contracts by flavor.
8 changes: 4 additions & 4 deletions docs/apps/features/01-overview.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ Our approach is to consider:
| -------- | -------------------------- | ----------------------------------------------------------------------- |
| Vesting | Sablier Lockup | Well defined rules and strict schedules |
| Payments | Sablier Flow | Adapts with time, less collateral-intensive for senders |
| Drops | Sablier Lockup, Airstreams | Instant or vested over time, with pre-configured recipients and amounts |
| Airdrops | Sablier Lockup, Airstreams | Instant or vested over time, with pre-configured recipients and amounts |

However, we invite everyone to use these features without any constraints and adapt them to their own unique use-case.

Expand All @@ -39,11 +39,11 @@ vesting-related features documented in [this section](/apps/features/vesting).
Read about the business use-case on the [dedicated webpage](https://sablier.com/payroll) or dive deeper into the
vesting-related features documented in [this section](/apps/features/payments).

## Drops / Airstreams
## Airdrops / Airstreams

Regardless of the type (Instant 🔜 or Airstreams) read more about the business use-case on the
[dedicated webpage](https://sablier.com/drops) or dive deeper into the vesting-related features documented in
[this section](/apps/features/drops).
[dedicated webpage](https://sablier.com/airdrops) or dive deeper into the vesting-related features documented in
[this section](/apps/features/airdrops).

## Others

Expand Down
Loading