Quickstart V4

New to the API? Start here — get your first collected data in about 5 minutes.

With one API key you will call, in order: find a bot → check its settings → request a collection → wait until it finishes → download the data. Copy each command into your terminal and replace YOUR_API_KEY.

About 5 min
You need
A HashScraper account · one crawling bot · credits (or a plan)
  1. Copy your API key

    Copy the key from My info → API key. Send it on every request as the Authorization header in the form Bearer YOUR_API_KEY.

    Treat the key like a password. Do not commit it or show it on screen.

    View my API key
  2. Check the connection

    GET

    First make sure the key works. If your account email comes back, you are ready.

    cURL
    curl 'https://www.hashscraper.com/v4/api/me' \
      -H 'Authorization: Bearer YOUR_API_KEY'

    Success when you see "result": "success" and your email. On 401, copy the key again.

  3. Pick a bot

    GET

    List your crawling bots and pick the id of the one to run. You can also copy it from the bot page via More → Copy bot ID.

    cURL
    curl 'https://www.hashscraper.com/v4/api/schedules' \
      -H 'Authorization: Bearer YOUR_API_KEY'

    data[].id is the bot ID. Use it in the next step to check the bot's settings.

  4. Check the settings

    GET

    See which inputs the bot uses (keyword, sort order, …), their saved values, and the values you can choose from.

    Each key in param_info must be sent inside params when you request a collection. You may use the alias (e.g. keyword) instead of param1. For inputs with options, send one of the listed values.

    cURL
    curl 'https://www.hashscraper.com/v4/api/schedules/8f3a7c1e9b5d24f6/param_info' \
      -H 'Authorization: Bearer YOUR_API_KEY'

    For each key in data.param_info, check name (meaning), value (saved value) and options (choices).

  5. Request a collection

    POST

    Ask the bot to collect. Every input the bot uses must be inside params (a missing key returns MISSING_PARAM). Values sent here do not change the bot's settings.

    When accepted, credits are deducted and schedule_result_id identifies this collection (dataset).

    cURL
    curl -X POST 'https://www.hashscraper.com/v4/api/schedules/8f3a7c1e9b5d24f6/collections' \
      -H 'Authorization: Bearer YOUR_API_KEY' \
      -H 'Content-Type: application/json' \
      -d '{ "params": { "param1": "키성장" } }'

    Use data.schedule_result_id in the next step.

  6. Wait until it finishes

    GET

    Collection runs in the background. Poll the status every 10–30 seconds. Depending on the site and volume it takes from tens of seconds to tens of minutes.

    cURL
    curl 'https://www.hashscraper.com/v4/api/schedule_results/239758028' \
      -H 'Authorization: Bearer YOUR_API_KEY'

    Done when sr_status is finish or complete. data_count is the number of rows so far.

  7. Download the data

    GET

    Fetch the rows of the finished dataset, limit rows at a time. Pass the response's next_cursor as cursor to get the next page.

    cURL
    curl 'https://www.hashscraper.com/v4/api/schedule_results/239758028/results?limit=1000' \
      -H 'Authorization: Bearer YOUR_API_KEY'

    When next_cursor is null, you have the last page.

Next steps

All in one (Python)
import time
import requests

API_KEY = "YOUR_API_KEY"
BASE = "https://www.hashscraper.com/v4/api"
HEADERS = {"Authorization": f"Bearer {API_KEY}"}

# 2. Check the connection
me = requests.get(f"{BASE}/me", headers=HEADERS).json()
print("Account:", me["data"]["email"])

# 3. Choose the first bot in the list
bots = requests.get(f"{BASE}/schedules", headers=HEADERS).json()
bot = bots["data"][0]

# 4. Check configuration (inputs, saved values, available choices)
url = f"{BASE}/schedules/{bot['id']}/param_info"
data = requests.get(url, headers=HEADERS).json()["data"]
info = data["param_info"]
params = {}
for key, item in info.items():
    choices = [o["value"] for o in item.get("options", [])]
    print(key, item["name"], item.get("value"), choices)
    params[key] = item.get("value") or ""

# 5. Request collection
url = f"{BASE}/schedules/{bot['id']}/collections"
res = requests.post(url, headers=HEADERS, json={"params": params})
sr_id = res.json()["data"]["schedule_result_id"]

# 6. Wait for completion (check every 15 seconds)
while True:
    url = f"{BASE}/schedule_results/{sr_id}"
    data = requests.get(url, headers=HEADERS).json()["data"]
    status = data["sr_status"]
    if status in ("finish", "complete"):
        break
    if status in ("canceling", "canceled"):
        raise SystemExit("Collection was canceled")
    time.sleep(15)

# 7. Retrieve data (1,000 rows per page)
rows, cursor = [], None
while True:
    query = {"limit": 1000}
    if cursor:
        query["cursor"] = cursor
    url = f"{BASE}/schedule_results/{sr_id}/results"
    page = requests.get(url, headers=HEADERS, params=query).json()
    rows += page["data"]
    cursor = page["next_cursor"]
    if cursor is None:
        break

print(len(rows), "rows received")

Steps 1–7 chained together. Requires the requests package.