Running Maigret from a script or an AI agent

Maigret prints a colored, human-oriented report by default. If the output is read by a program or by an AI agent, use this command instead:

maigret USERNAME -J ndjson -fo ./out --no-color --no-progressbar

Then read ./out/report_USERNAME_ndjson.json, not the terminal output.

Things that are easy to get wrong

  • The username is positional. There is no --username flag. Several usernames are separated by spaces: maigret alice bob.

  • The default scan is the top 500 sites, not the whole database. Use --top-sites N to change it, -a for all sites, --site NAME or --tags to narrow it. A full -a scan is slow and brings more false positives, so start with the default.

  • Maigret follows what it finds. If a profile reveals another username, it is searched too and gets a report file of its own. Add --no-recursion to stay with the usernames you passed.

  • A site that is missing from the results was not necessarily checked. Blocked and failed checks are hidden by default. --print-errors shows them, so that “no account” can be told from “the site refused to answer”.

  • Found accounts are printed as they come; report files are written only when the scan ends. With --no-color --no-progressbar every account is one [+] Site: URL line, followed by indented lines with the data extracted from the profile, so the output can be read while the scan is still running. A run that is interrupted keeps what was printed but leaves an empty output folder. A full -a scan takes several minutes, and the time grows with the database. Raise the command timeout of your shell tool or run the scan in the background.

  • Check the version first. maigret --version should print 0.6 or newer. An old install earlier in PATH checks a fraction of the sites; if pip install -U maigret does not change the version, call the new binary by its full path.

  • Keep the database autoupdate on. An outdated site database is the most common reason for empty results and for false positives that are already fixed.

Reading the report

The ndjson report has one JSON object per line, one line per account found. The fields worth reading first:

  • sitename and url_user: the site and the profile link.

  • status.status: Claimed for a found account.

  • status.ids: data extracted from the profile page, such as a full name, an avatar or links to other accounts. An account with extracted data is much stronger evidence than a bare link.

  • is_similar: true for a similar-name guess, shown as [?] in the terminal. It is not a confirmed account.

  • http_status and site.checkType: how the site answered and which kind of check produced the verdict.

Checking a result for a false positive

Some sites answer “found” for every name. Before relying on a result, search the same site for a username that cannot exist:

maigret qzxvw93kfpl2 --site SiteName --no-color --no-progressbar

If the site reports that account too, its check is broken and the original result means nothing. Please report such sites in the issue tracker.