v1API Kit

Random User API

Operational

Generate a random profile for UI prototypes.

Free Session · Free

Overview

Generate a random profile for UI prototypes. Customers never receive upstream URLs or credentials.

Authentication

Send x-api-key. Bearer tokens that start with ak_live_ are accepted.

Endpoints

GET /api/v1/randomuser

Parameters

    Response

    {
      "success": true,
      "data": {},
      "meta": { "requestId": "req_...", "timestamp": "...", "responseTime": 42 }
    }

    Errors

    INVALID_PARAMETER, INVALID_API_KEY, RATE_LIMIT_EXCEEDED, TRIAL_EXPIRED, PLAN_REQUIRED, CONFIGURATION_REQUIRED, PROVIDER_UNAVAILABLE, INTERNAL_ERROR.

    Rate Limits

    1,000 requests / day on the Free plan unless configured otherwise.

    Examples

    curl
    curl "https://labs.astrosia.tech/apikit-api/api/v1/randomuser" \
      -H "x-api-key: ak_live_xxxxx"
    javascript
    const res = await fetch("https://labs.astrosia.tech/apikit-api/api/v1/randomuser", {
      headers: { "x-api-key": process.env.APIKIT_KEY }
    });
    const json = await res.json();
    python
    import os, requests
    
    r = requests.get(
      "https://labs.astrosia.tech/apikit-api/api/v1/randomuser",
      headers={"x-api-key": os.environ["APIKIT_KEY"]},
    )
    print(r.json())
    java
    HttpRequest request = HttpRequest.newBuilder()
      .uri(URI.create("https://labs.astrosia.tech/apikit-api/api/v1/randomuser"))
      .header("x-api-key", System.getenv("APIKIT_KEY"))
      .GET()
      .build();
    php
    $ch = curl_init("https://labs.astrosia.tech/apikit-api/api/v1/randomuser");
    curl_setopt($ch, CURLOPT_HTTPHEADER, ["x-api-key: " . getenv("APIKIT_KEY")]);
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
    echo curl_exec($ch);
    Try in playground
    v1 API Kit | Astrosia