Gateway codes in a bot log: E01 to E53 and what your bot should do

2026-11-20 · Bazyl

Every refusal from our gateway on port 2115 carries a status and one short line that starts with a code: E01 invalid proxy login, E20 no exit for this targeting, change it or retry. After this post your bot can read that line and do the right thing on its own. The mistake most bots make is treating every non-200 the same and retrying in a tight loop, which turns a spent balance or a typo into thousands of identical failures.

The codes fall into five actions: fix the string, wait, rotate, change targeting, or stop.

Read the line, not just the status

A status alone is ambiguous. 407 is both a wrong password (E01) and a disabled login (E03). The line tells them apart. For an http:// target the line is the response body. For an https:// target it answers the CONNECT, before any tunnel to the site exists, so nothing from the site is involved.

The fastest way to see one is an http:// request with a deliberately wrong password:

curl -s -x "http://USER-cc-gb:[email protected]:2115" http://example.com
# E01 invalid proxy login

That line is what your bot should parse. The code is always the first word.

Fix the string: E01 and E10 to E15

These say the username you sent is wrong, and no number of retries changes that.

  • E01 invalid proxy login (407): the pair doesn't match. Most often a targeting token landed on the password. Every token rides the username; the password carries nothing.
  • E10 unknown key, E11 bad value, E12 city and isp cannot be combined, E13 city and isp need cc, E14 ttl needs sess, E15 duplicate key. All 400. The text names the token.

Example: USER-cc-de-ttl-60 returns E14, because a ttl without a session has nothing to hold. Add -sess- with an id and it passes. An unknown key is always an error and never silently ignored, so a typo like -countr-de fails loudly instead of exiting worldwide.

Bot action: stop the task, log the full username (never the password), surface it.

Wait: E53 and the warm-up

E53 login not ready yet, retry in a minute (503) comes from a login that is brand new and still reaching every gateway. A new login can also answer a plain 407 in that first minute or two. Nothing is wrong with the string.

Bot action: back off 30 seconds, retry, give up after a few minutes and alert. Better still, generate and test strings well before the task starts, as the pre-drop checklist says, so this never shows up mid-run.

Rotate: E50

E50 exit failed, retry with a new session (502) means the residential exit dropped the connection. Residential IPs are home connections and home connections go away.

On a rotating line, just retry: the next request gets another IP anyway. On a sticky line, retrying the same -sess- id asks for the same exit. Generate a new id and restart that task's flow, because to the site a new IP is a new visitor. The sticky vs rotating post covers when that restart costs you.

Change targeting: E20

E20 no exit for this targeting, change it or retry (460) means nothing in the pool matches your country, city, ISP or OS at that moment. Targeting never falls back to a wider area, by design: you asked for Berlin, you never silently get Munich.

Bot action: one or two retries after a pause, then drop the narrowest token first, -city- or -isp-, and keep -cc-. If a country alone returns E20 repeatedly, supply there is thin right now.

Stop: E02, E03 and E21

  • E02 no data left on this login (402): the balance is spent. Every new tunnel is refused until someone tops up, and a bot that keeps retrying does not recover on its own.
  • E03 proxy login disabled (407): access is switched off, for example an ended plan or a deleted sub-account. The dashboard says which.
  • E21 target not allowed (403): that site is blocked on this pool for everyone. It isn't your string.

Bot action for all three: stop every task on that login and alert a person.

A handler you can drop in

This reads the code from an http:// probe and returns an action. Run it when a task fails to decide what the bot does next.

# ecode.py: map a gateway reply to a bot action. pip install requests
import requests

ACTIONS = {
    "E01": "fix",  "E10": "fix", "E11": "fix", "E12": "fix",
    "E13": "fix",  "E14": "fix", "E15": "fix",
    "E53": "wait", "E50": "rotate", "E20": "retarget",
    "E02": "stop", "E03": "stop", "E21": "stop",
}

def probe(proxy):
    try:
        r = requests.get("http://example.com", proxies={"http": proxy}, timeout=20)
    except requests.RequestException as e:
        return "network", str(e)
    if r.status_code == 200:
        return "ok", ""
    code = r.text.strip().split(" ", 1)[0]
    return ACTIONS.get(code, "unknown"), r.text.strip()

if __name__ == "__main__":
    p = "http://USER-cc-gb-sess-k4mz61pq-ttl-30:[email protected]:2115"
    print(probe(p))

Treat unknown as stop and log it. The docs carry the full table, and they are the place to check if a code you don't recognise turns up.

Two things that look like errors and aren't

A tunnel that carries no traffic for about 60 seconds is closed. That isn't a code; it's a closed connection. Open a new one, and a sticky line comes back on the same IP.

A res2_ login predates 27 October 2026 and speaks the legacy format on other ports, so its replies differ: the legacy docs cover it.

If you are building a bot on the pool, the bot developers page has the account API calls that sit next to this handler.

Common questions

Where does the E-code appear?
In the one-line body of the gateway's reply, for example E01 invalid proxy login with a 407 status. For an http:// target the bot reads it as the response body. For an https:// target it arrives as the answer to the CONNECT, before any tunnel opens.
Which E-codes should a bot retry?
E53 after a short wait, because the login is still being switched on. E50 with a new session id, because that exit dropped. E20 after a pause or with wider targeting. Never retry E01, E02, E03, E10 to E15 or E21 in a loop: nothing changes until a person changes the string, the balance or the target.
What does E02 mean in a bot log?
No data left on this login, with a 402 status. The balance is spent and the gateway refuses every new tunnel until it is topped up. The bot does not recover on its own, so it should stop the tasks and alert you.
Is a 407 always a wrong password?
No. A 407 with E01 means the login and password don't match, often because a token was put on the password. A brand-new login can also answer 407 or E53 for its first minute or two while it reaches every gateway. Read the code, not just the status.