Skip to main content
POST
/
api
/
v1
/
beam
/
datasets
/
entries
Add entries by name
curl --request POST \
  --url https://api.example.com/api/v1/beam/datasets/entries

Documentation Index

Fetch the complete documentation index at: https://docs.allium.so/llms.txt

Use this file to discover all available pages before exploring further.

Adds values to a dataset identified by name instead of ID. Duplicates are ignored. Changes are reflected immediately in beam.contains() lookups — no redeploy needed. Request body:
{
  "name": "my-dataset",
  "values": ["0x3c499c542cef5e3811e1192ce70d8cc03d5c3359", "0xc2132d05d31c914a87c6611c10748aeb04b58e8f"]
}
FieldRequiredDescription
nameYesName of the dataset (must belong to the authenticated API key)
valuesYesArray of string values to add
curl -X POST https://api.allium.so/api/v1/beam/datasets/entries \
  -H "X-API-Key: ${ALLIUM_API_KEY}" \
  -H "Content-Type: application/json" \
  -d '{ "name": "my-dataset", "values": ["0x3c499c542cef5e3811e1192ce70d8cc03d5c3359"] }'
Response:
{ "count": 1 }
Returns 404 if no dataset with the given name exists for the authenticated API key.

Uploading large datasets

Each request supports up to 250,000 values. For larger datasets, split into chunks and upload in parallel. We recommend a maximum of 5 concurrent requests to avoid overloading the database:
import asyncio
import httpx

CHUNK_SIZE = 250_000

async def upload_dataset(name: str, values: list[str], api_key: str):
    chunks = [values[i:i + CHUNK_SIZE] for i in range(0, len(values), CHUNK_SIZE)]
    semaphore = asyncio.Semaphore(5)  # max 5 concurrent requests

    async def upload_chunk(chunk: list[str]):
        async with semaphore:
            await client.post(
                "https://api.allium.so/api/v1/beam/datasets/entries",
                json={"name": name, "values": chunk},
                headers={"X-API-Key": api_key},
            )

    async with httpx.AsyncClient() as client:
        await asyncio.gather(*[upload_chunk(chunk) for chunk in chunks])
Use lowercase values when filtering by addresses — this is how values are normalized in the system.