Sample Users – Free Fake API for Practicing & Prototyping

Updated: August 16, 2023 By: Frienzied Flame 3 comments

Most modern web and mobile applications store user information such as name, email, address, interests, profile picture, etc. Sling Academy provides API endpoints with information about 1000 fictitious users for software prototyping, learning, practicing, and testing purposes.

Get a List of Users

To get a collection of users, you can send a GET request to this:

https://api.slingacademy.com/v1/sample-data/users

Parameters for pagination and searching:

  • offset (optional): This specifies the number of records to skip before any records are retrieved. The default is 0.
  • limit (optional): The number of users you want to return on a page. The default is 10.
  • search (optional): Default is an empty string. This helps you find users whose first name, last name, email address, street, city, state, country, or job match the search term.

The fields of a user record include id, first_name, last_name, email, phone, gender, date_of_birth, street, city, state, country, zipcode, longitude, latitude, job, and profile_picture (not all users have profile pictures, and if a user chooses not to set a profile picture, a placeholder avatar will be used instead).

For example, if you send a GET request to the following URL:

https://api.slingacademy.com/v1/sample-data/users?offset=10&limit=20

You will get the following result in JSON format:

{
  "success": true,
  "time": "2023-08-15 22:45:33 UTC",
  "message": "Sample data for testing and learning purposes",
  "total_users": 1000,
  "offset": 10,
  "limit": 20,
  "users": [
    {
      "first_name": "Terry",
      "last_name": "Santos",
      "email": "[email protected]",
      "phone": "001-119-617-4472",
      "street": "10532 Villanueva Plaza",
      "state": "West Virginia",
      "country": "Uzbekistan",
      "longitude": 65.754216,
      "id": 11,
      "gender": "male",
      "date_of_birth": "1938-12-16T00:00:00",
      "job": "Wellsite geologist",
      "city": "Port Lisa",
      "zipcode": "96636",
      "latitude": -13.9749255,
      "profile_picture": "https://api.slingacademy.com/public/sample-users/11.png"
    },
    ...
  ]
}

To find all users whose country is Indonesia, you can send a GET request to this URL:

http://localhost:8000/v1/sample-data/users?search=Indonesia

Here, we set the search parameter to Indonesia. The result looks like this:

{
  "success": true,
  "time": "2023-08-15 22:54:25 UTC",
  "message": "Sample data for testing and learning purposes",
  "total_users": 5,
  "offset": 0,
  "limit": 10,
  "users": [
    {
      "email": "[email protected]",
      "first_name": "Jill",
      "last_name": "Montoya",
      "date_of_birth": "1933-11-27T00:00:00",
      "job": "Armed forces training and education officer",
      "city": "West Isabellastad",
      "zipcode": "24216",
      "latitude": -64.1567275,
      "profile_picture": "https://api.slingacademy.com/public/sample-users/default.png",
      "id": 578,
      "gender": "female",
      "phone": "598.737.8441x40501",
      "street": "31521 Mercedes Mountain",
      "state": "Florida",
      "country": "Indonesia",
      "longitude": 140.444811
    },
    {
      "email": "[email protected]",
      "first_name": "Christine",
      "last_name": "King",
      "date_of_birth": "1954-06-06T00:00:00",
      "job": "Physiotherapist",
      "city": "Kennedyport",
      "zipcode": "03067",
      "latitude": -27.736821,
      "profile_picture": "https://api.slingacademy.com/public/sample-users/default.png",
      "id": 661,
      "gender": "female",
      "phone": "914-565-8715x1846",
      "street": "67412 Myers Centers Suite 094",
      "state": "Colorado",
      "country": "Indonesia",
      "longitude": 14.311056
    },
    {
      "email": "[email protected]",
      "first_name": "Kristi",
      "last_name": "Reynolds",
      "date_of_birth": "2005-05-09T00:00:00",
      "job": "Police officer",
      "city": "Brownview",
      "zipcode": "57431",
      "latitude": 56.185935,
      "profile_picture": "https://api.slingacademy.com/public/sample-users/default.png",
      "id": 741,
      "gender": "female",
      "phone": "599.338.2267",
      "street": "15890 Ellis Corner",
      "state": "Alaska",
      "country": "Indonesia",
      "longitude": -53.535577
    },
    {
      "email": "[email protected]",
      "first_name": "Kelly",
      "last_name": "Young",
      "date_of_birth": "1974-05-10T00:00:00",
      "job": "Copy",
      "city": "Meganmouth",
      "zipcode": "37418",
      "latitude": 48.3023125,
      "profile_picture": "https://api.slingacademy.com/public/sample-users/default.png",
      "id": 849,
      "gender": "female",
      "phone": "(336)931-4869x94175",
      "street": "3974 Mcdonald Isle",
      "state": "Arizona",
      "country": "Indonesia",
      "longitude": 117.798387
    },
    {
      "email": "[email protected]",
      "first_name": "Leroy",
      "last_name": "Hansen",
      "date_of_birth": "1987-06-21T00:00:00",
      "job": "Market researcher",
      "city": "New Isaactown",
      "zipcode": "52078",
      "latitude": -82.7535495,
      "profile_picture": "https://api.slingacademy.com/public/sample-users/default.png",
      "id": 941,
      "gender": "male",
      "phone": "001-875-367-5170x832",
      "street": "31995 Allen Throughway",
      "state": "North Carolina",
      "country": "Indonesia",
      "longitude": 75.049428
    }
  ]
}

Get a Single User by ID

If you want to retrieve a single user with his or her id, use this endpoint:

https://api.slingacademy.com/v1/sample-data/users/[id]

For example, get data of the user whose id is 1:

https://api.slingacademy.com/v1/sample-data/users/1

Response:

{
  "success": true,
  "message": "fetched sample user whoose id is 1",
  "user": {
    "first_name": "Kayla",
    "last_name": "Lopez",
    "email": "[email protected]",
    "phone": "+1-971-533-4552x1542",
    "street": "3388 Roger Wells Apt. 010",
    "state": "Vermont",
    "country": "Jordan",
    "longitude": 112.16014,
    "id": 1,
    "gender": "female",
    "date_of_birth": "2002-04-25T00:00:00",
    "job": "Herbalist",
    "city": "Humphreyfurt",
    "zipcode": "79574",
    "latitude": 13.032103,
    "profile_picture": "https://api.slingacademy.com/public/sample-users/1.png"
  }
}

You can send requests with any programming language or library. Below is an example that uses JavaScript:

const fetchData = async (url) => {
    const response = await fetch(url)
    const data = await response.json()
    console.log(data);
}

const URL = 'https://api.slingacademy.com/v1/sample-data/users/1'
fetchData(URL)

That’s it. If you find something wrong, please let me know by leaving a comment. Happy coding & have a nice day!

3 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments