typefile
{
"audio_file": "https://replicate.delivery/pbxt/MOcvx4yzpgKwg6OWSEkVRB8CKyAHIpTU633RR0FpiBYXyC58/perplexity.wav",
"dot_color": "#00FFFF",
"dot_size": 6,
"dot_spacing": 6,
"fps": 10,
"height": 360,
"max_height": 60,
"width": 640
}npm install replicate
REPLICATE_API_TOKEN environment variable:export REPLICATE_API_TOKEN=r8_6EG**********************************
This is your API token. Keep it to yourself.
import Replicate from "replicate";
import fs from "node:fs";
const replicate = new Replicate({
auth: process.env.REPLICATE_API_TOKEN,
});
Run lucataco/dotted-waveform-visualizer using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
const output = await replicate.run(
"lucataco/dotted-waveform-visualizer:84fca61939f190b103755fee5fbc8813953067581ce3695cfcbcbd31744fe24b",
{
input: {
audio_file: "https://replicate.delivery/pbxt/MOcvx4yzpgKwg6OWSEkVRB8CKyAHIpTU633RR0FpiBYXyC58/perplexity.wav",
dot_color: "#00FFFF",
dot_size: 6,
dot_spacing: 6,
fps: 10,
height: 360,
max_height: 60,
width: 640
}
}
);
// To access the file URL:
console.log(output.url()); //=> "http://example.com"
// To write the file to disk:
fs.writeFile("my-image.png", output);
To learn more, take a look at the guide on getting started with Node.js.
pip install replicate
REPLICATE_API_TOKEN environment variable:export REPLICATE_API_TOKEN=r8_6EG**********************************
This is your API token. Keep it to yourself.
import replicate
Run lucataco/dotted-waveform-visualizer using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
output = replicate.run(
"lucataco/dotted-waveform-visualizer:84fca61939f190b103755fee5fbc8813953067581ce3695cfcbcbd31744fe24b",
input={
"audio_file": "https://replicate.delivery/pbxt/MOcvx4yzpgKwg6OWSEkVRB8CKyAHIpTU633RR0FpiBYXyC58/perplexity.wav",
"dot_color": "#00FFFF",
"dot_size": 6,
"dot_spacing": 6,
"fps": 10,
"height": 360,
"max_height": 60,
"width": 640
}
)
# To access the file URL:
print(output.url())
#=> "http://example.com"
# To write the file to disk:
with open("my-image.png", "wb") as file:
file.write(output.read())
To learn more, take a look at the guide on getting started with Python.
REPLICATE_API_TOKEN environment variable:export REPLICATE_API_TOKEN=r8_6EG**********************************
This is your API token. Keep it to yourself.
Run lucataco/dotted-waveform-visualizer using Replicate’s API. Check out the model's schema for an overview of inputs and outputs.
curl -s -X POST \
-H "Authorization: Bearer $REPLICATE_API_TOKEN" \
-H "Content-Type: application/json" \
-H "Prefer: wait" \
-d $'{
"version": "lucataco/dotted-waveform-visualizer:84fca61939f190b103755fee5fbc8813953067581ce3695cfcbcbd31744fe24b",
"input": {
"audio_file": "https://replicate.delivery/pbxt/MOcvx4yzpgKwg6OWSEkVRB8CKyAHIpTU633RR0FpiBYXyC58/perplexity.wav",
"dot_color": "#00FFFF",
"dot_size": 6,
"dot_spacing": 6,
"fps": 10,
"height": 360,
"max_height": 60,
"width": 640
}
}' \
https://api.replicate.com/v1/predictions
To learn more, take a look at Replicate’s HTTP API reference docs.
{
"id": "fera33gvd1rma0cnpn281x0se4",
"model": "lucataco/dotted-waveform-visualizer",
"version": "84fca61939f190b103755fee5fbc8813953067581ce3695cfcbcbd31744fe24b",
"input": {
"audio_file": "https://replicate.delivery/pbxt/MOcvx4yzpgKwg6OWSEkVRB8CKyAHIpTU633RR0FpiBYXyC58/perplexity.wav",
"dot_color": "#00FFFF",
"dot_size": 6,
"dot_spacing": 6,
"fps": 10,
"height": 360,
"max_height": 60,
"width": 640
},
"logs": "Loading audio file...\nFinished loading audio file\nGenerating frames...\nEncoding video...",
"output": "https://replicate.delivery/xezq/U7XhgODNke30WKHJ75RNAn6yByswhfwGIGkd5ZAstinz3iaUA/output.mp4",
"data_removed": false,
"error": null,
"source": "web",
"status": "succeeded",
"created_at": "2025-03-20T20:34:54.44Z",
"started_at": "2025-03-20T20:34:54.450346Z",
"completed_at": "2025-03-20T20:34:59.111702Z",
"urls": {
"cancel": "https://api.replicate.com/v1/predictions/fera33gvd1rma0cnpn281x0se4/cancel",
"get": "https://api.replicate.com/v1/predictions/fera33gvd1rma0cnpn281x0se4",
"stream": "https://stream.replicate.com/v1/files/bcwr-4kowzg5zvzelxnbrbmrlez36olfgmb2wzbrv377s3rr76zypwlca",
"web": "https://replicate.com/p/fera33gvd1rma0cnpn281x0se4"
},
"metrics": {
"predict_time": 4.66135574,
"total_time": 4.671702
}
}