Skip to content

Get audit

Retrieve audit for the requested company.

Base URL

GET https://app.datashake.com/api/v2/local_naps/local_nap

Request parameters

KEY DATATYPE REQUIRED DESCRIPTION
job_id integer yes Job ID of the task to retrieve

Job identification

This value can be found in the response from /add endpoint.

curl GET --url 'https://app.datashake.com/api/v2/local_naps/local_nap?job_id=92222' -H 'spiderman-token: 1234567890'
import requests

url = "https://app.datashake.com/api/v2/local_naps/local_nap"
params = {
    "job_id": 92222,
}
headers = {
    "spiderman-token": "1234567890"
}
response = requests.get(
    url=url,
    params=params,
    headers=headers
}
coming soon
coming soon
coming soon

Response

Our response is a JSON object containing these keys:

KEY DATATYPE DESCRIPTION
success boolean Job outcome
status integer HTTP status code
percentage_complete integer Completion status in %
company_name string Given company name
phone_number* string Given company phone number
post_code* string Given company post code
local_nap_sources list[JSON] Audits per source

*

You will receive these values only if you provided them when creating the job_id.

Audits

Those are job results scraped from different sources. It's a JSON structure containing these keys:

KEY DATATYPE DESCRIPTION
company_name string Name of the company
phone string Phone number of the company
address string Company address
url string Company (source) profile URL
average_rating float Average rating of the company
rating_count integer The number of ratings on the website
source_name string Name of the source of the provided data
rating_distribution JSON | null The distribution of ratings
Rating distribution

This is a JSON structure describing the distribution of ratings on the website.

It has the following structure:

{
    "5 stars": "[number of ratings]",
    "4 stars": "[number of ratings]",
    "3 stars": "[number of ratings]",
    "2 stars": "[number of ratings]",
    "1 stars": "[number of ratings]"
}
curl GET --url 'https://app.datashake.com/api/v2/local_naps/local_nap?job_id=92222' -H 'spiderman-token: 1234567890'
{
    "success": true,
    "status": 200,
    "company_name": "Brooklyn Burgers & Beer",
    "phone_number": "718-788-1458",
    "address": "11215",
    "percentage_complete": 100,
    "local_nap_sources": [
        {
            "company_name": "Brooklyn Burgers & Beer",
            "phone": "(718) 788-1458",
            "address": "259 5th Ave Brooklyn NY, 11215",
            "url": "https://foursquare.com/v/brooklyn-burgers--beer/5579bd50498e191d31ad8270",
            "average_rating": 8.3,
            "rating_count": 195,
            "rating_distribution": null,
            "source_name": "foursquare.com"
        },
        {
            "average_rating": 4.6,
            "review_count": 526,
            "rating_distribution": null,
            "url": "https://www.google.com/search?q=Brooklyn+Burgers+%26+Beer+11215&hl=en",
            "source_name": "google.com",
            "business_name": "Brooklyn Burgers & Beer",
            "address": "259 5th Ave, Brooklyn, NY 11215, USA",
            "phone": "+1 718-788-1458"
        },
        {
            "review_count": 35,
            "average_rating": 4.5,
            "rating_distribution": {
                "5 stars": "17",
                "4 stars": "4",
                "3 stars": "4",
                "2 stars": "1",
                "1 stars": "0"
            },
            "url": "https://www.tripadvisor.com/Restaurant_Review-g60827-d9453698-Reviews-Brooklyn_Burgers_and_Beers-Brooklyn_New_York.html",
            "source_name": "tripadvisor.com",
            "company_name": "Brooklyn Burgers and Beers",
            "phone_number": "17187881458",
            "address": "259 5th Ave, Brooklyn, New York 11215-1909"
        },
        {
            "average_rating": 4.8,
            "review_count": 113,
            "rating_distribution": null,
            "url": "https://www.facebook.com/BrooklynBurgersandBeer/",
            "source_name": "facebook.com",
            "phone": "+1 718-788-1458",
            "address": "259 5th Ave, Brooklyn, New York 11215",
            "company_name": "Brooklyn Burgers&Beer"
        },
        {
            "company_name": "Brooklyn Burgers & Beer",
            "phone_number": "+17187881458",
            "review_count": 315,
            "average_rating": 4,
            "rating_distribution": {
                "5 stars": 168,
                "4 stars": 80,
                "3 stars": 24,
                "2 stars": 22,
                "1 star": 21
            },
            "address": "259 5th Ave, Brooklyn, NY 11215",
            "url": "https://www.yelp.com/biz/brooklyn-burgers-and-beer-brooklyn?osq=Brooklyn+Burgers",
            "source_name": "yelp.com"
        }
    ]
}
{
    "success": false,
    "status": 400,
    "message": "This job ID doesn't exist, please create it"
}