External API access requires a verified account token. Account
API docs
Generate random data over HTTP. All methods below use GET and return JSON.
How to use the API
GET /api/v1/*
The external API is available to registered users with a verified email. Every endpoint, including catalogs, requires a user Bearer token. Up to 100 results per run. Technical safety limits remain: up to 10,000 results per request, up to 20,000 field values in the builder, natural generator limits and external provider quotas. Standard API: 60 requests/minute.
- Register, verify your email and sign in. Open Account → API token → Show token and copy it. Account ↗
- Send the token only in the Authorization: Bearer TOKEN header. Replace TOKEN with your value, without quotes around it. A public Supabase key cannot be used here.
- Choose an endpoint below, copy its URL and use the parameters in its table. The examples use the integer generator; change the path and parameters for other generators.
This is a temporary Supabase session access token, not a permanent API key. Its lifetime is set in the project settings. On 401, reopen Account, sign in if needed and copy a current token. A static token in a script does not refresh itself. Keep it secret: it grants your session permissions.
Request
Requests: GET over HTTPS, with query string parameters and no JSON body. Encode values with URLSearchParams or your library equivalent; use one value per parameter. count is a positive integer, usually up to 10000; see each endpoint for exact limits and values. Opening a link without the token header returns 401.
GET https://rand.by/api/v1/integer?count=3&min=1&max=100
Authorization: Bearer TOKENResponse
Success: HTTP 200 and JSON containing an items array. Item types depend on the generator. Catalogs have separate shapes: money/currencies returns asOf and items; geo/catalog returns a catalog object. Responses are not cached. Check HTTP status before parsing JSON; the numbers shown are illustrative.
{ "items": [42, 7, 91] }Ready-to-run examples and setup
For server examples, set RANDBY_API_TOKEN in the process environment; the curl tab shows export and PowerShell shows the Windows version. Then follow the selected setup. Keep secrets out of Git, URLs, logs and public Nuxt variables. In browsers, use only the current user’s token; keep shared tokens on the server. The Nuxt route example needs your own authentication and rate limits, otherwise its proxy exposes access using your token.
Setup
export RANDBY_API_TOKEN='PASTE_TOKEN_HERE'curl
curl --fail-with-body --max-time 15 --get 'https://rand.by/api/v1/integer' \
--header "Authorization: Bearer $RANDBY_API_TOKEN" \
--data-urlencode 'count=3' \
--data-urlencode 'min=1' \
--data-urlencode 'max=100'| 400 | Invalid parameters, repeated values or a technical limit exceeded. Check the endpoint table and correct the request. |
|---|---|
| 401 | Missing, invalid or expired token; also check email verification. Obtain a current token in Account and retry. |
| 404 | Unknown path or generator. Check the URL; API paths do not use a language prefix such as /en. |
| 429 | Public demo rate exceeded. Wait a minute and avoid retrying in a loop without a delay. |
| 503 | The authentication service is unavailable or not configured. Retry later; service owners should check the Supabase configuration. |
The sandbox below works without a token through a separate demo route: up to 10 records and 60 requests per minute per IP. The external /api/v1/* remains private and uses endpoint technical limits.
Seeded generation for CI
POSTPremium
The same schema and seed produce the same test data with the same generation version and data catalogs.
- CI API keys · Create a key and store it as the CI secret RANDBY_CI_KEY.
- Export schema · Export your Builder schema as JSON and keep it with your test fixtures.
- Choose an example below and run it from the directory containing your exported schema.
Use a Premium CI key in the Authorization header. Keep it in your CI secret store. Each key expires after 90 days. To rotate it, create a replacement, update the secret, and revoke the old key after a successful run.
Request
Send a POST request with Content-Type application/json. The JSON body has three fields.
- schema
- Required JSON object. Use the contents of the exported Builder schema, including any linked tables.
- seed
- Required nonblank string of up to 128 characters. Keep it fixed for repeatable runs and change it to sample a different dataset.
- version
- Optional engine version. The current value and default are v1. Set it explicitly in CI.
POST https://rand.by/api/builder/ci/generate
Authorization: Bearer CI_KEY
Content-Type: application/json
{
"schema": {
"version": 1,
"count": 2,
"fields": [
{
"id": "id",
"path": "id",
"generator": "sequence",
"output": "value",
"settings": {
"start": 1,
"step": 1
},
"array": false,
"size": 1,
"nullPercent": 0
}
]
},
"seed": "fixtures-v1",
"version": "v1"
}Response
The response includes version and either items and columns, or tables for a multi-table schema. Keep the schema and seed fixed to repeat a run.
Single table
{
"version": "v1",
"columns": [
"id"
],
"items": [
{
"id": 1
},
{
"id": 2
}
]
}Multiple tables
{
"version": "v1",
"tables": [
{
"id": "main",
"name": "users",
"columns": [
"id"
],
"items": [
{
"id": 1
}
]
},
{
"id": "orders",
"name": "orders",
"columns": [
"user_id"
],
"items": [
{
"user_id": 1
}
]
}
]
}Keep the exported schema, seed and generation version in your repository or job configuration. Changes to the schema, engine or source catalogs can change the result. Seeded output is intended for tests.
Up to 8 tables, 10,000 rows in total and 20,000 values per request, including array elements. The rate limit is 60 requests per minute per account.
Ready-to-run examples and setup
The examples read randby-builder-schema.json and write fixtures.json. Save the code under the filename shown in Setup. In GitHub Actions, use the workflow step after checkout and load the result in a later step.
Setup
bash --version
curl --version
jq --version
bash generate-fixtures.shcurl + jq
set -euo pipefail
: "${RANDBY_CI_KEY:?RANDBY_CI_KEY is required}"
jq -n --slurpfile schema randby-builder-schema.json --arg seed 'fixtures-v1' \
'{schema: $schema[0], seed: $seed, version: "v1"}' |
curl --fail --silent --show-error --max-time 60 'https://rand.by/api/builder/ci/generate' \
--header "Authorization: Bearer $RANDBY_CI_KEY" \
--header 'Content-Type: application/json' \
--data-binary @- --output fixtures.json| 400 | Invalid JSON, seed, version or schema. For schema errors, inspect data.code and data.field in the response. |
|---|---|
| 401 | The CI key is missing, invalid, expired or revoked, or Premium is inactive. Check the secret and the account. |
| 413 | The request body exceeds 260 KiB. Reduce the size of the schema. |
| 429 | The account exceeded the request limit. Wait a minute before retrying. |
| 502 | The server could not generate the dataset. Retry later if the problem persists with a valid schema. |
| 503 | Key verification is temporarily unavailable. Retry later. |
API endpoints
Choose an endpoint, review its parameters and open the sandbox. Edit the query and run a GET request to inspect the actual JSON response.
The URL alone does not authorize a request. Get a token in your account and send it in the Authorization: Bearer TOKEN header. Do not put the token in the URL. To try the API without a token, use the sandbox in the documentation. How to use the API
Integer numbers
GET /api/v1/integerGenerating of positive and negative integer numbers
| Name | Description | Default value |
|---|---|---|
| count | Count of generated numbers (Integer number from 1 to 10000) | 100 |
| min | Left border of the range of generated numbers (Integer number from -100000000 to 100000000) | -100 |
| max | Right border of the range of generated numbers (Integer number from -100000000 to 100000000) | 100 |
| round | Rounding the received numbers to the nearest multiples of the number specified in this field. For example, you need to get a set of numbers that are multiples of 50. So 2489 becomes 2500, 131 becomes 100, and 851 becomes 900 | 0 |
Sandbox: up to 10 records and 60 requests per minute.
Float numbers
GET /api/v1/floatGenerating of float numbers with a given precision
| Name | Description | Default value |
|---|---|---|
| count | Count of generated numbers (Integer number from 1 to 10000) | 100 |
| min | Left border of the range of generated numbers (Integer number from -100000000 to 100000000) | -1 |
| max | Right border of the range of generated numbers (Integer number from -100000000 to 100000000) | 1 |
| precision | A number of symbols after comma (from 1 to 8). | 2 |
Sandbox: up to 10 records and 60 requests per minute.
Bytes
GET /api/v1/byteGenerating of bytes in various notations. Binary, octal, decimal, hexadecimal
| Name | Description | Default value |
|---|---|---|
| count | Count of generated bytes (Integer number from 1 to 10000) | 100 |
| min | Left border of the range of generated bytes (Integer number from 0 to 255) | 0 |
| max | Right border of the range of generated bytes (Integer number from 0 to 255) | 255 |
| radix | Numeral system (radix) of generated bytes (2, 8, 10 or 16). | 10 |
Sandbox: up to 10 records and 60 requests per minute.
Passwords
GET /api/v1/passwordGeneration of crack-resistant passwords
| Name | Description | Default value |
|---|---|---|
| count | Count of generated passwords (Integer number from 1 to 10000) | 1 |
| min | Minimum length of generated password (Integer number from 1 to 64) | 8 |
| max | Maximum length of generated password (Integer number from 1 to 64) | 12 |
| digits | Count of digits in the password (Integer number from 0 to 64). | 2 |
| capitals | Count of uppercase letters in the password (Integer number from 0 to 64). | 2 |
| special | Count of special characters in the password (Integer number from 0 to 64). | 2 |
Sandbox: up to 10 records and 60 requests per minute.
Times
GET /api/v1/timeGeneration of random time of day
| Name | Description | Default value |
|---|---|---|
| count | Count of generated times (Integer number from 1 to 1440) | 10 |
| min | Left border of the range of generated times (from 00:00 to 23:59) | 08:00 |
| max | Right border of the range of generated times (from 00:00 to 23:59) | 17:00 |
| interval | Interval of generated times (Integer number from 1 to 60). | 1 |
| sort | Result sorting ("asc" - ascending, "desc" - descending, or "none" - without sorting). | none |
Sandbox: up to 10 records and 60 requests per minute.
Dates
GET /api/v1/dateGeneration of random dates in different formats
| Name | Description | Default value |
|---|---|---|
| count | Number of dates: an integer from 1 to 10000. | 10 |
| min | Left border of the range of generated dates in format "YYYY-MM-DD" The format may vary, but it is important that it is valid for the function Date.parse() | 0000-01-01 |
| max | Right border of the range of generated dates in format "YYYY-MM-DD" The format may vary, but it is important that it is valid for the function Date.parse() | 2999-12-31 |
| format | The format in which the generated dates will be displayed Details here. | DD.MM.YYYY |
| locale | Language locale Two-letter code from ISO 639-1 standard | en (fallback) |
| days | The days of the week to include in the set of generated dates (Integers from 1 to 7 separated by a comma. 1 - Monday, 7 - Sunday) If parameter is not set, it is considered that any day of the week can be generated | 1,2,3,4,5,6,7 |
| sort | Result sorting ("asc" - ascending, "desc" - descending, or "none" - without sorting). | none |
Sandbox: up to 10 records and 60 requests per minute.
WEB-colors
GET /api/v1/colorWEB-colors generation in different formats
| Name | Description | Default value |
|---|---|---|
| count | Count of generated elements (Integer number from 1 to 10000) | 1 |
Sandbox: up to 10 records and 60 requests per minute.
Geographical coordinates
GET /api/v1/geoGenerate worldwide coordinates, land-only points or points on a selected continent. Pick random cities and airports with names and IATA codes.
| Name | Description | Default value |
|---|---|---|
| count | Result count: an integer from 1 to 10000; default 1. | 1 |
| mode | coordinates: worldwide; land: exclude oceans; city: cities; airport: airports with IATA codes. coordinateslandcityairport | coordinates |
| continent | any or AF, AN, AS, EU, NA, OC, SA. A selected continent restricts coordinates to land. A catalog filter with no matching records returns 400. anyAFANASEUNAOCSA | any |
Sandbox: up to 10 records and 60 requests per minute.
Random name generator
GET /api/v1/namesRandom names with ordered parts and culture metadata. Returns items with fullName, locale, sex, firstName, lastName and patronymic. Unselected or unsupported parts are null. Invalid parameters return HTTP 400. No identity verification or uniqueness guarantee.
| Name | Description | Default value |
|---|---|---|
| count | Number of names: integer from 1 to 10000. | 10 |
| locales | Comma-separated distinct culture codes, or be for Belarusian. All supported codes are listed below. One culture per name, equal probability. Marked locales use English name data when name data is missing. af_ZAarazbebn_BDcs_CZcydadede_ATde_CHdvelenen_AUen_AU_ockeren_BORKen_CAen_GBen_GHen_HKen_IEen_INen_NGen_USen_ZAeoeses_MXfafifrfr_BEfr_CAfr_CHfr_LUfr_SNhehrhuhyid_IDitjaka_GEkoku_ckbku_kmr_latinlvmknb_NOnenlnl_BEplpt_BRpt_PTroro_MDrusksl_SIsr_RS_latinsvta_INthtrukuruz_UZ_latinviyo_NGzh_CNzh_TWzu_ZA | ru |
| parts | Unique parts in output order: firstName, lastName, patronymic. Patronymics: ru, be, uk only; skipped elsewhere. Patronymic alone restricts sampling to compatible cultures; none available returns 400. | firstName,lastName |
| sex | Name forms: any, male or female. With any, male and female are equally likely for each record. | any |
Sandbox: up to 10 records and 60 requests per minute.
Random email address generator
GET /api/v1/emailGenerate random email addresses. Choose a name culture, random providers, example domains or your own domain, and optional name templates.
| Name | Description | Default value |
|---|---|---|
| count | Number of addresses: an integer from 1 to 10000. | 10 |
| locale | One supported name-culture code. See the list below. Default: en. af_ZAarazbebn_BDcs_CZcydadede_ATde_CHdvelenen_AUen_AU_ockeren_BORKen_CAen_GBen_GHen_HKen_IEen_INen_NGen_USen_ZAeoeses_MXfafifrfr_BEfr_CAfr_CHfr_LUfr_SNhehrhuhyid_IDitjaka_GEkoku_ckbku_kmr_latinlvmknb_NOnenlnl_BEplpt_BRpt_PTroro_MDrusksl_SIsr_RS_latinsvta_INthtrukuruz_UZ_latinviyo_NGzh_CNzh_TWzu_ZA | en |
| mode | free: random providers; example: example.com/net/org; custom: the provider parameter. | free |
| provider | Required only with mode=custom. Domain without a URL, port or mailbox. International domains are converted to ASCII. | |
| firstName | Optional name template, up to 80 characters; empty means random. The generator may normalize, transliterate or omit parts. | |
| lastName | Optional name template, up to 80 characters; empty means random. The generator may normalize, transliterate or omit parts. | |
| allowSpecialCharacters | true or false: allow additional punctuation in the local part. | false |
Sandbox: up to 10 records and 60 requests per minute.
Random money amount generator
GET /api/v1/moneyGenerate random monetary amounts within a chosen range. Select multiple currencies and set a separate formatting locale for each currency.
| Name | Description | Default value |
|---|---|---|
| count | Number of amounts: an integer from 1 to 10000. | 10 |
| min | Inclusive boundary from -1000000000 to 1000000000, with at most 4 decimal places. Use a point or comma, without grouping. | 0 |
| max | Inclusive boundary from -1000000000 to 1000000000, with at most 4 decimal places. Use a point or comma, without grouping. | 1000 |
| currencies | Distinct currency codes separated by commas. Each result chooses one currency with equal probability. AEDAFNALLAMDAOAARSAUDAWGAZNBAMBBDBDTBHDBIFBMDBNDBOBBRLBSDBTNBWPBYNBZDCADCDFCHFCLPCNYCOPCRCCUPCVECZKDJFDKKDOPDZDEGPERNETBEURFJDFKPGBPGELGHSGIPGMDGNFGTQGYDHKDHNLHTGHUFIDRILSINRIQDIRRISKJMDJODJPYKESKGSKHRKMFKPWKRWKWDKYDKZTLAKLBPLKRLRDLSLLYDMADMDLMGAMKDMMKMNTMOPMRUMURMVRMWKMXNMYRMZNNADNGNNIONOKNPRNZDOMRPABPENPGKPHPPKRPLNPYGQARRONRSDRUBRWFSARSBDSCRSDGSEKSGDSHPSLESOSSRDSSPSTNSYPSZLTHBTJSTMTTNDTOPTRYTTDTWDTZSUAHUGXUSDUYUUZSVESVNDVUVWSTXAFXCDXCGXOFXPFYERZARZMWZWG | USD,EUR |
| locales | Optional CURRENCY:locale pairs separated by commas, e.g. USD:en-US,EUR:fr-FR. Only selected currencies and their supported locales are accepted. Omitted currencies use their default locale. See money/currencies. |
Sandbox: up to 10 records and 60 requests per minute.
Currencies and locales
GET /api/v1/money/currenciesLists supported currency codes, fraction digits, defaultLocale and allowed locales. The asOf field indicates the catalog snapshot date.
Sandbox: up to 10 records and 60 requests per minute.
Tarot spread generator
GET /api/v1/tarotDraw a random tarot spread from a 78-card deck. Choose one card, past–present–future, a five-card cross or your own layout, with optional reversed cards. These brief editorial explanations offer symbolic themes for reflection. They are entertainment, not predictions or personality assessments. Minor cards combine rank and suit themes; reversed cards invite a look at obstacles and excess.
| Name | Description | Default value |
|---|---|---|
| spread | Preset: single (1), three (3), cross (5), or custom. | three |
| count | For custom: integer from 1 to the selected deck size (78, 22 or 56). For a preset, an explicitly supplied count must match its size. | 3 |
| deck | full: 78 cards; major: 22 Major Arcana; minor: 56 Minor Arcana. Cards never repeat. | full |
| reversed | true or false. If true, every drawn card independently has a 50% chance of being reversed. | true |
| locale | Language of card names, positions and orientations: one of the 13 interface locale codes. ruendeplbyukesfritptidjatr | en |
Sandbox: up to 10 records and 60 requests per minute.
Random zodiac sign generator
GET /api/v1/zodiacGenerate random signs from Western, Chinese, Vietnamese and Vedic traditions. Choose multiple systems, eastern elements and generation without repeats. These brief editorial explanations offer symbolic themes for reflection. They are entertainment, not predictions or personality assessments.
| Name | Description | Default value |
|---|---|---|
| count | Number of results: integer from 1 to 10000. | 1 |
| systems | Distinct comma-separated systems: western, chinese, vietnamese, vedic. Systems with available results are selected equally. westernchinesevietnamesevedic | western |
| withElements | true or false. Chinese and Vietnamese systems use 60 valid animal/element variants when true, or 12 animals when false. Western and Vedic elements stay fixed. | true |
| unique | true or false. Prevents repeating an id within one response. Count must not exceed the available variants (12 per Western/Vedic system; 12 or 60 per eastern system). | false |
| locale | One of the 13 interface locale codes; controls names only. Default: en. enrubyukdeplesfritptidjatr | en |
Sandbox: up to 10 records and 60 requests per minute.
Magic ball
GET /api/v1/magic-ballAsk a question in your mind and shake the magic ball to reveal a random reply in its glowing window. Tap the ball or use the button to play. Your question stays with you: the server receives only the reply language. Each of 20 replies is equally likely: 10 positive, 5 uncertain and 5 negative. This is a game, not a way to predict the future.
| Name | Description | Default value |
|---|---|---|
| locale | Language of card names, positions and orientations: one of the 13 interface locale codes. ruendebyukplesfritptidjatr | en |
Sandbox: up to 10 records and 60 requests per minute.
Geographic generator catalog
GET /api/v1/geo/catalogPool sizes by continent, snapshot date, open-source data links and source-file checksums. Generation uses a local data snapshot.
Sandbox: up to 10 records and 60 requests per minute.