API:Account Search

Attributes:

  • current_page: Current page # of results
  • total_entries: Total number of results for the given query
  • total_pages: Total number of pages of results
  • accounts: List of accounts
    • id: Id of the account record
    • name: Name of the account
    • profile_url: Url to retrieve the details of the account
    • location: Geographical location where the account is located
      • city: Name of city
      • state: Name of state
      • zip: Postal zip code
      • lat: Latitude
      • lng: Longitude

Methods:

List

URL: https://console.revolutionprep.com/api/v1/accounts.[format]
Method: GET
Optional Parameters:
query: This could be any combination of words separated by spaces and queries the name for a match
latlng: A latitude and longitude which returns results sorted by nearest to furthest. The input is seperated by a colon. Example: latlng=25.789:-80.2264
zip: A US zip code which returns results sorted by nearest to furthest
page: an integer value which specifies which page of results to fetch, starting at 1. Fetching successively higher page numbers will return additional results, until there are no results to return (in which case an empty result set will be returned). Defaults to 1 page and 50 records per page

JSON example

// https://console.revolutionprep.com/api/v1/accounts.json?query=Academia+Interamericana+Panama&latlng=25.789:-80.2264

{
  "current_page": 1,
  "total_entries": 1,
  "total_pages": 1,
  "accounts": [
      {
          "id": 5515,
          "name": "Academia Interamericana Panama",
          "profile_url": "http://localhost:3333/api/v1/accounts/5515",
          "location": {
              "city": "Miami",
              "state": "FL",
              "zip_code": null,
              "lat": -30,
              "lng": 119
          }
      }
  ]
}

API:Account Details

Attributes:

  • id: Id of the account record
  • name: Name of the account
  • website_url: Url to account website
  • level: Account level 0-3
  • private_school: Indicates if the school is private (true/false)
  • location: Geographical location where the account is located
    • address: Street Name and number
    • city: Name of city
    • state: Name of state
    • zip: Postal zip code
    • lat: Latitude
    • lng: Longitude

Methods:

List

URL: https://revolutionprep.com/api/v1/accounts/[id].[format]
Method: GET
Required Parameters:
id: This is the id of the account

JSON example

// https://console.revolutionprep.com/api/v1/accounts/5515.json

{
  "id": 5515,
  "name": "Academia Interamericana Panama",
  "website": ""
  "level": 3,
  "private_school": true,
  "location": {
      "address": ""
      "city": "Miami",
      "state": "FL",
      "zip_code": null,
      "lat": -30,
      "lng": 119
  }
}