Create Beam Config Handler
curl --request POST \
--url https://api.allium.so/api/v1/beam \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <api-key>' \
--data '
{
"name": "<string>",
"description": "<string>",
"pipeline_config": {
"source": {
"type": "pubsub",
"is_zerolag": false
},
"transforms": [
{
"script": "<string>",
"uid": "<string>",
"type": "v8"
}
],
"sinks": [
{
"name": "<string>",
"uid": "<string>",
"type": "kafka"
}
]
},
"tags": [
"<string>"
],
"static_egress_ip": false
}
'import requests
url = "https://api.allium.so/api/v1/beam"
payload = {
"name": "<string>",
"description": "<string>",
"pipeline_config": {
"source": {
"type": "pubsub",
"is_zerolag": False
},
"transforms": [
{
"script": "<string>",
"uid": "<string>",
"type": "v8"
}
],
"sinks": [
{
"name": "<string>",
"uid": "<string>",
"type": "kafka"
}
]
},
"tags": ["<string>"],
"static_egress_ip": False
}
headers = {
"X-API-KEY": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-API-KEY': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
description: '<string>',
pipeline_config: {
source: {type: 'pubsub', is_zerolag: false},
transforms: [{script: '<string>', uid: '<string>', type: 'v8'}],
sinks: [{name: '<string>', uid: '<string>', type: 'kafka'}]
},
tags: ['<string>'],
static_egress_ip: false
})
};
fetch('https://api.allium.so/api/v1/beam', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.allium.so/api/v1/beam",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'name' => '<string>',
'description' => '<string>',
'pipeline_config' => [
'source' => [
'type' => 'pubsub',
'is_zerolag' => false
],
'transforms' => [
[
'script' => '<string>',
'uid' => '<string>',
'type' => 'v8'
]
],
'sinks' => [
[
'name' => '<string>',
'uid' => '<string>',
'type' => 'kafka'
]
]
],
'tags' => [
'<string>'
],
'static_egress_ip' => false
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-KEY: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.allium.so/api/v1/beam"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"pipeline_config\": {\n \"source\": {\n \"type\": \"pubsub\",\n \"is_zerolag\": false\n },\n \"transforms\": [\n {\n \"script\": \"<string>\",\n \"uid\": \"<string>\",\n \"type\": \"v8\"\n }\n ],\n \"sinks\": [\n {\n \"name\": \"<string>\",\n \"uid\": \"<string>\",\n \"type\": \"kafka\"\n }\n ]\n },\n \"tags\": [\n \"<string>\"\n ],\n \"static_egress_ip\": false\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-API-KEY", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.allium.so/api/v1/beam")
.header("X-API-KEY", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"pipeline_config\": {\n \"source\": {\n \"type\": \"pubsub\",\n \"is_zerolag\": false\n },\n \"transforms\": [\n {\n \"script\": \"<string>\",\n \"uid\": \"<string>\",\n \"type\": \"v8\"\n }\n ],\n \"sinks\": [\n {\n \"name\": \"<string>\",\n \"uid\": \"<string>\",\n \"type\": \"kafka\"\n }\n ]\n },\n \"tags\": [\n \"<string>\"\n ],\n \"static_egress_ip\": false\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.allium.so/api/v1/beam")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-API-KEY"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"pipeline_config\": {\n \"source\": {\n \"type\": \"pubsub\",\n \"is_zerolag\": false\n },\n \"transforms\": [\n {\n \"script\": \"<string>\",\n \"uid\": \"<string>\",\n \"type\": \"v8\"\n }\n ],\n \"sinks\": [\n {\n \"name\": \"<string>\",\n \"uid\": \"<string>\",\n \"type\": \"kafka\"\n }\n ]\n },\n \"tags\": [\n \"<string>\"\n ],\n \"static_egress_ip\": false\n}"
response = http.request(request)
puts response.read_body{
"id": "<string>",
"name": "<string>",
"description": "<string>",
"owner_org_team_user_id": "<string>",
"pipeline_config": {
"source": {
"type": "pubsub",
"is_zerolag": false
},
"transforms": [
{
"script": "<string>",
"uid": "<string>",
"type": "v8"
}
],
"sinks": [
{
"name": "<string>",
"uid": "<string>",
"type": "kafka"
}
]
},
"organization_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"tags": [
"<string>"
],
"static_egress_ip": false,
"pod_size": "S"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Configs
Create config
Creates a new pipeline configuration.
POST
/
api
/
v1
/
beam
Create Beam Config Handler
curl --request POST \
--url https://api.allium.so/api/v1/beam \
--header 'Content-Type: application/json' \
--header 'X-API-KEY: <api-key>' \
--data '
{
"name": "<string>",
"description": "<string>",
"pipeline_config": {
"source": {
"type": "pubsub",
"is_zerolag": false
},
"transforms": [
{
"script": "<string>",
"uid": "<string>",
"type": "v8"
}
],
"sinks": [
{
"name": "<string>",
"uid": "<string>",
"type": "kafka"
}
]
},
"tags": [
"<string>"
],
"static_egress_ip": false
}
'import requests
url = "https://api.allium.so/api/v1/beam"
payload = {
"name": "<string>",
"description": "<string>",
"pipeline_config": {
"source": {
"type": "pubsub",
"is_zerolag": False
},
"transforms": [
{
"script": "<string>",
"uid": "<string>",
"type": "v8"
}
],
"sinks": [
{
"name": "<string>",
"uid": "<string>",
"type": "kafka"
}
]
},
"tags": ["<string>"],
"static_egress_ip": False
}
headers = {
"X-API-KEY": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'X-API-KEY': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
description: '<string>',
pipeline_config: {
source: {type: 'pubsub', is_zerolag: false},
transforms: [{script: '<string>', uid: '<string>', type: 'v8'}],
sinks: [{name: '<string>', uid: '<string>', type: 'kafka'}]
},
tags: ['<string>'],
static_egress_ip: false
})
};
fetch('https://api.allium.so/api/v1/beam', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.allium.so/api/v1/beam",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'name' => '<string>',
'description' => '<string>',
'pipeline_config' => [
'source' => [
'type' => 'pubsub',
'is_zerolag' => false
],
'transforms' => [
[
'script' => '<string>',
'uid' => '<string>',
'type' => 'v8'
]
],
'sinks' => [
[
'name' => '<string>',
'uid' => '<string>',
'type' => 'kafka'
]
]
],
'tags' => [
'<string>'
],
'static_egress_ip' => false
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"X-API-KEY: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.allium.so/api/v1/beam"
payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"pipeline_config\": {\n \"source\": {\n \"type\": \"pubsub\",\n \"is_zerolag\": false\n },\n \"transforms\": [\n {\n \"script\": \"<string>\",\n \"uid\": \"<string>\",\n \"type\": \"v8\"\n }\n ],\n \"sinks\": [\n {\n \"name\": \"<string>\",\n \"uid\": \"<string>\",\n \"type\": \"kafka\"\n }\n ]\n },\n \"tags\": [\n \"<string>\"\n ],\n \"static_egress_ip\": false\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("X-API-KEY", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.allium.so/api/v1/beam")
.header("X-API-KEY", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"pipeline_config\": {\n \"source\": {\n \"type\": \"pubsub\",\n \"is_zerolag\": false\n },\n \"transforms\": [\n {\n \"script\": \"<string>\",\n \"uid\": \"<string>\",\n \"type\": \"v8\"\n }\n ],\n \"sinks\": [\n {\n \"name\": \"<string>\",\n \"uid\": \"<string>\",\n \"type\": \"kafka\"\n }\n ]\n },\n \"tags\": [\n \"<string>\"\n ],\n \"static_egress_ip\": false\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.allium.so/api/v1/beam")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["X-API-KEY"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"name\": \"<string>\",\n \"description\": \"<string>\",\n \"pipeline_config\": {\n \"source\": {\n \"type\": \"pubsub\",\n \"is_zerolag\": false\n },\n \"transforms\": [\n {\n \"script\": \"<string>\",\n \"uid\": \"<string>\",\n \"type\": \"v8\"\n }\n ],\n \"sinks\": [\n {\n \"name\": \"<string>\",\n \"uid\": \"<string>\",\n \"type\": \"kafka\"\n }\n ]\n },\n \"tags\": [\n \"<string>\"\n ],\n \"static_egress_ip\": false\n}"
response = http.request(request)
puts response.read_body{
"id": "<string>",
"name": "<string>",
"description": "<string>",
"owner_org_team_user_id": "<string>",
"pipeline_config": {
"source": {
"type": "pubsub",
"is_zerolag": false
},
"transforms": [
{
"script": "<string>",
"uid": "<string>",
"type": "v8"
}
],
"sinks": [
{
"name": "<string>",
"uid": "<string>",
"type": "kafka"
}
]
},
"organization_id": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z",
"tags": [
"<string>"
],
"static_egress_ip": false,
"pod_size": "S"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Creates a new pipeline configuration. The response includes auto-generated fields (
Request body:
Response:
See the Configuration reference for full details on sources, transforms, and sink types.
id, owner_org_team_user_id, created_at, updated_at). The caller is automatically granted owner, and their team is granted viewer_team (read access for teammates).
Required permission: any authenticated user (creator becomes the owner).
CreateBeamConfigRequest
curl -X POST https://api.allium.so/api/v1/beam \
-H "X-API-Key: ${ALLIUM_API_KEY}" \
-H "Content-Type: application/json" \
-d '{
"name": "USDC Transfer Monitor",
"description": "Monitors USDC ERC20 transfers on Base",
"tags": ["production", "base"],
"pipeline_config": {
"source": {
"type": "pubsub",
"chain": "base",
"entity": "erc20_token_transfer",
"is_zerolag": false
},
"transforms": [
{
"type": "redis_set_filter",
"filter_expr": "root = this.token_address"
}
],
"sinks": [
{
"type": "kafka",
"name": "usdc-transfers"
}
]
}
}'
BeamConfig
Filter values are managed separately from the pipeline config. After creating a pipeline, use the filter values endpoints to populate set filter transforms.
Authorizations
Body
application/json
Response
Successful Response
Show child attributes
Show child attributes
Available options:
S, M, L, XL Was this page helpful?
⌘I