← All tool references

Generators · execute

Random Integer Generator

Draw cryptographically strong random integers from an inclusive range, optionally without repeats, with lottery-style results and sample statistics.

Open public tool

Overview

Category
Generators
API mode
execute
Processing
client-side
Privacy
no-data-stored

Public descriptor

The descriptor is available without an API key and supplies this tool’s metadata, schemas, modes, and examples.

GET /api/v1/tools/random-integer-generator

View this descriptor as JSON

Execute availability

This tool has an execute route defined by its descriptor. Server-side execution is currently unavailable, so requests return api_not_launched.

POST /api/v1/tools/random-integer-generator/execute

Authentication is not issued during the preview. A bearer API key is planned for execution after launch.

Input schema

object object; additional properties are not accepted.

min · number · required
Enter the inclusive lower bound for generated values.
max · number · required
Enter the inclusive upper bound for generated values.
count · number · required
Enter how many swatches, rolls, picks, names, letters, or values you want returned.
unique · boolean · optional
Prevent repeated integers in the generated result.
{
    "type": "object",
    "properties": {
        "min": {
            "type": "number",
            "description": "Enter the inclusive lower bound for generated values."
        },
        "max": {
            "type": "number",
            "description": "Enter the inclusive upper bound for generated values."
        },
        "count": {
            "type": "number",
            "description": "Enter how many swatches, rolls, picks, names, letters, or values you want returned."
        },
        "unique": {
            "type": "boolean",
            "description": "Prevent repeated integers in the generated result."
        }
    },
    "required": [
        "min",
        "max",
        "count"
    ],
    "additionalProperties": false
}

Output schema

On a successful execution, schema values appear in data.result.values.

numbers · array
Browser-calculated numbers.
result · string
Browser-calculated result.
min · number
Browser-calculated min.
max · number
Browser-calculated max.
{
    "type": "object",
    "properties": {
        "numbers": {
            "type": "array",
            "items": [],
            "description": "Browser-calculated numbers."
        },
        "result": {
            "type": "string",
            "description": "Browser-calculated result."
        },
        "min": {
            "type": "number",
            "description": "Browser-calculated min."
        },
        "max": {
            "type": "number",
            "description": "Browser-calculated max."
        }
    },
    "additionalProperties": false
}

Random Integer Generator: 1..100

The request body follows the published input schema. The response below shows the success-envelope shape returned after execution is available.

curl -X POST "https://utilitypages.org/api/v1/tools/random-integer-generator/execute" \
  -H "Content-Type: application/json" \
  -d '{
    "min": 1,
    "max": 100,
    "count": 5,
    "unique": false
}'
{
    "ok": true,
    "data": {
        "slug": "random-integer-generator",
        "result": {
            "values": {
                "numbers": [
                    4,
                    18,
                    42,
                    77,
                    91
                ],
                "result": "4, 18, 42, 77, 91",
                "min": 1,
                "max": 100
            },
            "display": {
                "display": "[4,18,42,77,91]"
            },
            "warnings": [],
            "assumptions": [],
            "steps": []
        }
    },
    "meta": [],
    "request_id": "req_example_123"
}

Errors

api_not_launched · 503
Returned by the current launch gate for every execute request.
invalid_json · 400
Returned when an enabled execute request does not contain valid JSON.
validation_failed · 422
Returned when a request does not satisfy the input schema.
browser_interaction_required · 422
Returned for browser capability tools instead of inventing a server-side result.
tool_not_found · 404
Returned when a requested descriptor slug does not exist.
execution_failed · 503
Returned when an enabled server-side execution cannot complete.