{
  "openapi": "3.1.0",
  "info": {
    "title": "Random User API",
    "version": "1.0.0",
    "description": "Realistic fake users for ten countries, internally consistent and seedable, never real people.\n\nGenerate realistic, fully coherent fake users for demos, mockups, load tests and seeded test fixtures — never real people. Ten nationalities (US, CA, GB, AU, DE, FR, ES, NL, IE, NZ), each internally consistent: a German user gets a German name, a real German city with correct coordinates and timezone, a German street, postcode and phone format; a Canadian gets an A1A 1A1 postcode. Every user carries title and full name, gender, email on RFC-2606 reserved domains (can never reach a real inbox), username, login block with memorable password and UUID, landline and mobile in national formats, full address with coordinates and IANA timezone, date of birth and age, registration date, and avatar image URLs in three sizes. Request up to 100 users per call, restrict nationalities with nat=DE,FR, force gender, and — the killer feature for tests — pass seed=anything to get byte-identical reproducible output on every call. No database, no state, no third-party calls at request time.",
    "contact": {
      "name": "Data and APIs",
      "url": "https://dataandapis.com/contact"
    },
    "termsOfService": "https://dataandapis.com/terms-of-service",
    "license": {
      "name": "Data and APIs Terms of Service",
      "url": "https://dataandapis.com/terms-of-service"
    },
    "x-logo": {
      "url": "https://dataandapis.com/images/random-user.webp"
    }
  },
  "externalDocs": {
    "description": "Documentation, live tester and pricing",
    "url": "https://dataandapis.com/apis/random-user"
  },
  "servers": [
    {
      "url": "https://api-random-user.dataandapis.com"
    }
  ],
  "tags": [
    {
      "name": "Tools",
      "description": "Random User API belongs to the Tools category of the Data and APIs catalog."
    }
  ],
  "paths": {
    "/v1/user": {
      "get": {
        "operationId": "generateRandomUsers",
        "summary": "Generate Random Users",
        "description": "Generate Random Users endpoint of the Random User API. Costs 1 token per call.",
        "externalDocs": {
          "url": "https://dataandapis.com/apis/random-user/generate-random-users"
        },
        "parameters": [
          {
            "name": "count",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "5"
          },
          {
            "name": "gender",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "female"
          },
          {
            "name": "nat",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "DE,FR"
          },
          {
            "name": "seed",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string"
            },
            "example": "demo"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                },
                "example": {
                  "count": 1,
                  "seed": "demo",
                  "results": [
                    {
                      "gender": "male",
                      "nat": "DE",
                      "name": {
                        "title": "Mr",
                        "first": "Leon",
                        "last": "Neumann",
                        "full": "Leon Neumann"
                      },
                      "email": "leon.neumann@example.com",
                      "username": "leonneumann2174",
                      "login": {
                        "username": "leonneumann2174",
                        "password": "silent-canyon-57",
                        "uuid": "b0e45204-62b1-43cc-9cf2-3b8c9ec9fc7b"
                      },
                      "phone": "005 08381957",
                      "cell": "0154 2375314",
                      "location": {
                        "street": "8309 Hauptstraße",
                        "city": "Berlin",
                        "state": "Berlin",
                        "postcode": "24061",
                        "country": "Germany",
                        "coordinates": {
                          "latitude": 52.4806,
                          "longitude": 13.4263
                        },
                        "timezone": "Europe/Berlin"
                      },
                      "dob": {
                        "date": "1955-09-23",
                        "age": 71
                      },
                      "registered": {
                        "date": "2026-06-14"
                      },
                      "picture": {
                        "large": "https://api.dicebear.com/9.x/avataaars/svg?seed=leonneumann2174&size=256",
                        "medium": "https://api.dicebear.com/9.x/avataaars/svg?seed=leonneumann2174&size=128",
                        "thumbnail": "https://api.dicebear.com/9.x/avataaars/svg?seed=leonneumann2174&size=64"
                      },
                      "uuid": "c80f34c1-f3cc-4574-8a5f-2262823d67a0"
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid API key"
          },
          "402": {
            "description": "Subscription past due; the response carries a payment_url"
          },
          "429": {
            "description": "Monthly token allowance exhausted"
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ]
      }
    },
    "/v1/user/nationalities": {
      "get": {
        "operationId": "listNationalities",
        "summary": "List Nationalities",
        "description": "List Nationalities endpoint of the Random User API. Costs 1 token per call.",
        "externalDocs": {
          "url": "https://dataandapis.com/apis/random-user/list-nationalities"
        },
        "responses": {
          "200": {
            "description": "Successful response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                },
                "example": {
                  "count": 10,
                  "nationalities": [
                    {
                      "code": "US",
                      "country": "United States"
                    },
                    {
                      "code": "CA",
                      "country": "Canada"
                    },
                    {
                      "code": "GB",
                      "country": "United Kingdom"
                    },
                    {
                      "code": "AU",
                      "country": "Australia"
                    },
                    {
                      "code": "DE",
                      "country": "Germany"
                    },
                    {
                      "code": "FR",
                      "country": "France"
                    },
                    {
                      "code": "ES",
                      "country": "Spain"
                    },
                    {
                      "code": "NL",
                      "country": "Netherlands"
                    },
                    {
                      "code": "IE",
                      "country": "Ireland"
                    },
                    {
                      "code": "NZ",
                      "country": "New Zealand"
                    }
                  ]
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid API key"
          },
          "402": {
            "description": "Subscription past due; the response carries a payment_url"
          },
          "429": {
            "description": "Monthly token allowance exhausted"
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ]
      }
    }
  },
  "components": {
    "securitySchemes": {
      "ApiKey": {
        "type": "apiKey",
        "in": "header",
        "name": "X-Api-Key",
        "description": "Create a free key at https://dataandapis.com/sign-up. 500 tokens a month on the Free plan; this API costs 1 token per call."
      }
    }
  },
  "security": [
    {
      "ApiKey": []
    }
  ]
}