Start with search, not with a download. The download flow returns one original source file as it was found. It does not filter that file down to your username, domain or keyword.
Availability and cost
Availability: every plan with a license in force. No plan feature is checked. Cost: no metered allowance. With an API key, every call counts once toward your monthly API Calls allowance, each search page and each status poll included. Only2xx responses count. See Rate limits.
When your organization’s license is not active, every endpoint on this page returns 403:
403, an allowance 429 or a capacity 409. See Plans and quotas.
Does a full download make sense?
Usually not. DarknetSearch indexes the contents of leak files, not only their names. A download gives you a local copy of raw leaked material that you still have to search yourself. Search the indexed leak when you want to:- browse every indexed record of one leak with
leakId:<id> - find one username, email, domain, keyword or file type inside that leak
- get more of each record’s
contentwithlength - hand over a file of the matching records, not the whole leak
Find data inside one leak
If a Raw Data result gave you aleakId, use it. Otherwise find the leak first:
leak_simple_database_searchreturns one row per leak that matches your query, withresultCount. The row’sidis the leak’s ID.leaks_listbrowses the leak index. Filter byname(3 to 100 characters).
query is one Lucene string of 3 to 1,024 characters. Narrow it with these fields:
leakId, fileName, fileExtension and createdAt are fields inside query, not separate parameters. A term without a field searches content.
Page and size the results with these parameters:
Increase
page until the response reads "last": true. Raw Data explains the query syntax and the record fields.
Export the matching records
To get the records of your search as one file, export them with theControlLeak catalog entry instead of paging.
1
Find the catalog entry
Call
list_export_services and take the id of the entry whose name is ControlLeak. Pick a format from its allowed_types.2
Create the export
Send your Lucene query as Here
query in args:3 is the ControlLeak entry’s id in this environment. To export only records you picked, add their id values in queryIds with includeIdStrategy set to INCLUDE. See Export only some records.3
Poll and download
Poll
get_export every 30 seconds until status is COMPLETE or FAILED. Then fetch the file with download_export. Export result sets covers the full flow and its errors.Download an original file
Use this flow when you need one source file exactly as it was found. Download requests belong to your organization:leaks_downloads lists every request your organization has made.
1
Find the leak
Find the leak’s ID as described above.
leak_detail returns its metadata, including name, numberOfFiles, numberOfRecords, tags and size. The path has no trailing slash.2
List the files in the leak
leak_files lists the files attached to the leak. It pages with page (from 0) and size (10 to 100). The path has no trailing slash.content has an id, a name, a size and a createdAt:name and size before you request a file. A large dump is better searched than downloaded.3
Request the file
request_to_download_leak_file prepares a copy of one file. Send the leak’s ID as leakId and the file’s id from leak_files as digest. Both are required.id, the file name and size, a status, an errorText, and createdAt and updatedAt. Keep the id.4
Wait for the file
leaks_downloads lists your organization’s download requests, newest first. It pages like leak_files.id and read its status. status and errorText come from the leak service unchanged. Download once status reports the file as ready. A non-empty errorText is the leak service’s message about the request; read it before you request the file again.5
Download the file
download_leak_file streams the prepared file. Pass the download request id. The path has no trailing slash.4xx status and body unchanged. Check the request in leaks_downloads again before you retry.Errors
Every error body the API returns is listed in Handle API errors.