Sample from Agents (JSON)

Select a quantity of agents at random, and return the results as JSON.

GET /batch/(int: quantity)/sample.json
Query Parameters:
 
  • quantity – an integer > 0 and ≤ 500
Request Headers:
 
Status Codes:

Try it:

In this example, sample a quantity of 2 agents.

http://pplapi.com/batch/2/sample.json

Example request:

GET /batch/2/sample.json HTTP/1.1
Host: pplapi.com

Example response:

HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 679

[
    {
        "age": 2,
        "country_name": "India",
        "country_tld": "in",
        "date_of_birth": "2013-11-09",
        "id": 2333140543,
        "id_str": "NE9-gRf",
        "income": 7100,
        "internet": false,
        "language": "Telugu",
        "religion": "Hindu",
        "sex": "Male"
    },
    {
        "age": 90,
        "country_name": "United Kingdom",
        "country_tld": "uk",
        "date_of_birth": "1925-05-28",
        "id": 5665787231,
        "id_str": "NAM-74j",
        "income": 43674,
        "internet": true,
        "language": "English",
        "religion": "Christian",
        "sex": "Female"
    }
]