# RandomUser API MCP

> RandomUser API delivers realistic dummy data right into your workflow. Your agent generates full user profiles—including names, emails, phone numbers, addresses, and profile pictures—on demand. Use it for testing application logic, auditing demographics, or building prototypes without touching a database or writing complex scripts.

## Overview
- **Category:** productivity
- **Price:** Free
- **Tags:** mock-data, data-generation, testing-tools, persona-generator, api-testing

## Description

**RandomUser API - Generate Mock User Data for Testing**

Listen up. If you're building anything that needs fake user data—and trust me, everything does—you don't wanna be messing with static JSON files or writing complicated scripts just to test your logic. This MCP server gives your agent access to a massive pool of realistic dummy profiles on demand. You tell it what you need; it generates the full records instantly.

**How It Works**

This tool set lets your AI client handle all the heavy lifting for generating and managing thousands of unique user records. When you use these tools, your agent pulls data that looks legit—names, emails, phone numbers, addresses, even profile pictures. You get to test application logic, audit demographics, or build out prototypes without ever touching a live database or worrying about API keys. It's pure plug-and-play for development.

**Checking the Service Status**

Before you run any big test suite, you gotta make sure the connection is solid. You can use `check_api_status` to verify if the entire RandomUser API service is up and running. It's a simple check that confirms the whole system is available for use.

**Generating New Profiles on Demand**

The main draw here is `get_random_users`. You can generate an entire batch of unique, fake user profiles using this tool. This isn't just throwing random names together; it gives you structured data including full names, valid-looking email addresses, and location details for each profile. By specifying parameters—like needing ten users from a specific region or only female users—you direct your agent to pull exactly what you need for your test case. Because this tool is so robust, you'll get reliable geographical information alongside the basic contact data.

**Reproducing Tests with Seeds**

Sometimes, especially when debugging, you gotta run a test and then re-run it *exactly* to see if something changed. That's where `get_seeded_users` comes in. Instead of getting a new set of random users each time, this tool lets you feed the API a specific seed string. When your agent uses that string, it guarantees that every profile generated—names, locations, emails—will be identical to the previous run. This is crucial for reliable, repeatable testing and auditing.

**Defining Your Scope: Country Codes**

If your app needs to support international users, you gotta know what regions this API recognizes. You can use `list_supported_nationalities` to retrieve a complete list of all country codes the RandomUser API accepts. This gives you a quick reference guide so you don't waste time testing unsupported locales.

**Summary of Capabilities**

*   **Health Check:** Use `check_api_status` to confirm the entire service is operational before starting any work.
*   **Batch Generation:** With `get_random_users`, your agent creates a fresh batch of fake users, supplying names, emails, and locations instantly. You'll get realistic profile pictures linked right in there too.
*   **Controlled Replication:** When you need to reproduce an exact data set for debugging, use `get_seeded_users` with a specific seed string; it guarantees identical results every time.
*   **Scope Definition:** To see all the regions your app needs to support, call `list_supported_nationalities`; this returns the complete list of accepted country codes.

## Tools

### check_api_status
Checks whether the RandomUser API service is currently running and available for use.

### get_random_users
Generates a batch of unique fake user profiles, including names, emails, and locations.

### get_seeded_users
Produces the exact same set of users every time by running the API with a specific seed string.

### list_supported_nationalities
Retrieves a list of all country codes that the RandomUser API recognizes.

## Prompt Examples

**Prompt:** 
```
Generate 5 random female users from 'UK' using RandomUser API.
```

**Response:** 
```
I've generated 5 female personas from the UK! They include names like 'Emma Smith' and 'Sarah Jones', complete with British addresses and profile pictures. Would you like the full JSON details?
```

**Prompt:** 
```
Generate a random user with seed 'vinkius_test'.
```

**Response:** 
```
I've retrieved the user for seed 'vinkius_test'. This will return the same persona every time you use this seed. Notable details include the name and city. Would you like me to check another seed?
```

**Prompt:** 
```
List all nationalities supported by RandomUser.
```

**Response:** 
```
I've scanned the nationality catalog. It includes 17 countries, from Australia (AU) and Brazil (BR) to the United States (US). I can help you generate users for any of these specific regions.
```

## Capabilities

### Generate random profiles
Creates a batch of fake users, supplying names, emails, and locations.

### Predict user data with seeds
Reproduces the exact same set of users by using a specific seed string.

### List supported countries
Returns a list of all country codes accepted by the RandomUser API.

### Check server health
Verifies if the entire RandomUser API service is currently operational.

## Use Cases

### Testing User Signup Flow (QA)
A QA engineer needs to test signup forms across 15 different countries. Instead of manually gathering 15 sets of fake data, they prompt their agent: 'Generate 3 users for Germany, 2 for Mexico, and 4 for Australia.' The agent runs `get_random_users` multiple times in one go, giving the engineer diverse, localized records to check.

### Validating Prototype UI (UX Designer)
A designer is building a dashboard that must display user details correctly. To verify local data handling, they use `list_supported_nationalities` first. Then, they ask for '5 users from the UK' via `get_random_users`, ensuring names and addresses format perfectly before handing it off to development.

### Replicating Edge Case Bugs (Developer)
A developer finds a bug that only appears with a specific user profile. They can't trust random data. By using `get_seeded_users` and providing the known seed, they force their agent to generate the exact same buggy profile repeatedly until the fix is verified.

### Auditing Market Coverage (Product Manager)
A PM needs to check if their planned feature set covers enough global demographics. They run `list_supported_nationalities` and see 17 options. They then prompt for 'a mix of users from Asia and South America' to quickly audit regional coverage.

## Benefits

- **High-Fidelity Data:** You get more than just names. The `get_random_users` tool provides full records, including street addresses and city coordinates, making your test environments feel real.
- **Predictable Testing:** Need to debug a specific bug using the same user profile 10 times? Use `get_seeded_users`. It guarantees the exact same data every time you run it.
- **Quick Scope Check:** Don't guess which countries you need. Run `list_supported_nationalities` to get an immediate list of all accepted country codes, mapping out your full scope.
- **Zero Setup Time:** The API is free and requires no key management within your client. You just ask your agent for data—no manual setup or authentication steps needed.
- **Operational Safety:** Before running large tests, run `check_api_status`. This confirms the server is up, preventing failures due to service outages.

## How It Works

The bottom line is that you interact with the server using natural language; the AI client handles the API calls underneath.

1. First, connect your AI client (Claude, Cursor, etc.) to the RandomUser MCP Server.
2. Next, tell your agent what data you need. For example: 'Generate 10 users from Japan.'
3. Your agent calls the appropriate tool and gets back a structured set of realistic user records.

## Frequently Asked Questions

**How do I test the same user profile repeatedly using RandomUser API?**
You use the `get_seeded_users` tool. You pass a specific seed string (like 'testuser123'), and the server will return the identical data set every single time you run that seed.

**Is RandomUser API good for testing global addresses?**
Yes, it's built for that. The `get_random_users` tool provides detailed geographic metadata, including street addresses and city coordinates, allowing you to test location logic globally.

**What should I do if my random user tests fail? Should I check the API status?**
Yes, start by checking the service health. Run `check_api_status` first. If it reports failure, you know the problem is external to your code.

**Can RandomUser API help me see what countries are supported?**
Absolutely. Use the `list_supported_nationalities` tool. It gives you a comprehensive list of all country codes available for generating users, so you know your full scope.

**Does the RandomUser API need an API key to generate user profiles?**
No, it doesn't. The service is free and open for use. You connect your agent directly without needing to handle any credentials or complex setup.

**How do I get profile images using the RandomUser API?**
You retrieve direct links to high-quality pictures. The API provides these image URLs, letting you build visually complete prototypes instantly for your designs.

**What specific data points does `get_random_users` return?**
It returns names, emails, and full location details. These records cover everything needed for rapid demographic auditing or verifying UI layouts.

**Is the RandomUser API suited for large-scale data testing?**
Yes. Your agent can generate thousands of user records quickly. This makes it ideal for load testing and ensuring your application scales with diverse, high-quality test data.

**Is an API Key required for RandomUser API?**
No. RandomUser.me is a free and open service. This server works out of the box without any static credentials required.

**Can I generate users from specific countries?**
Yes. Use the `getRandomUsers` tool and provide the `nat` parameter with a comma-separated list of country codes (e.g., 'US,FR').

**What profile pictures are provided?**
The API provides high-resolution profile picture URLs for every generated user, categorized by size (large, medium, and thumbnail).