Skip to main content

Prerequisites

Before you begin, you’ll need:
1

Create an Account

Sign up at oathnet.org if you haven’t already.
2

Get Your API Key

Navigate to Dashboard > Account and generate a new API key.
3

Save Your Key

Copy your API key and store it securely. You won’t be able to see it again.
Never commit your API key to version control or share it publicly. Use environment variables to store sensitive credentials.

Try the API Playground

The fastest way to explore the API is using the interactive playground. Each endpoint page has a built-in playground where you can:
  1. Enter your API key in the Authorization section
  2. Set parameters for the request
  3. Click Send to see live responses

Try Breach Search Playground

Test the breach search API with live requests

Your First API Call

Let’s search the breach database for a test email:
curl -X GET "https://oathnet.org/api/service/[email protected]" \
  -H "x-api-key: YOUR_API_KEY"

Response

{
  "success": true,
  "message": "Breach search completed",
  "data": {
    "results": [
      {
        "email": "[email protected]",
        "password": "p@ssw0rd123",
        "username": "testuser",
        "source": "example_breach_2023",
        "date": "2023-05-15"
      }
    ],
    "results_found": 1,
    "results_shown": 1,
    "nextCursorMark": null
  },
  "lookups_left": 999,
  "search_session": {
    "id": "sess_abc123def456"
  }
}

Understanding the Response

FieldDescription
successtrue if the request succeeded, false otherwise
messageHuman-readable status message
data.resultsArray of matching records
data.results_foundTotal number of matching records
data.results_shownNumber of results in this response
data.nextCursorMarkPagination cursor for next page (null if no more)
lookups_leftYour remaining daily lookup quota
search_sessionSession info for grouping related queries

Using Search Sessions

For better quota management, initialize a search session before making multiple queries:
# Step 1: Initialize session
session_response = requests.post(
    "https://oathnet.org/api/service/search/init",
    json={"query": "[email protected]"},
    headers={"x-api-key": API_KEY}
)
session_id = session_response.json()["data"]["session"]["id"]

# Step 2: Use session for related queries
breach_response = requests.get(
    "https://oathnet.org/api/service/search-breach",
    params={
        "q": "[email protected]",
        "search_id": session_id
    },
    headers={"x-api-key": API_KEY}
)

stealer_response = requests.get(
    "https://oathnet.org/api/service/v2/stealer/search",
    params={
        "q": "[email protected]",
        "search_id": session_id
    },
    headers={"x-api-key": API_KEY}
)

Common Query Types

OathNet automatically detects your query type:
QueryDetected TypeExample
Emailemail[email protected]
Domaindomainexample.com
Usernameusernamejohn_doe
IP Addressip192.168.1.1
Discord IDdiscord_id123456789012345678
Steam IDsteam_id76561198012345678

Next Steps

Congratulations! You’ve made your first OathNet API call. Explore the API Reference to discover all available endpoints.