Skip to content

Commit

Permalink
Add support for Undetected ChromeDriver
Browse files Browse the repository at this point in the history
  • Loading branch information
david96182 committed Apr 26, 2024
1 parent a2f502d commit 0b9880d
Show file tree
Hide file tree
Showing 93 changed files with 1,981 additions and 5 deletions.
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ ninja = Ninjemail(
)
```

The `browser` parameter specifies the browser to be used for automation. The default value is "firefox". Currently, **Firefox and Chrome are supported**.
The `browser` parameter specifies the browser to be used for automation. The default value is "firefox". Currently, Ninjemail supports **Firefox, Chrome and Undetected Chrome**. The acceptable values for the browser parameter are `firefox`, `chrome` and `undetected-chrome` respectively.

The `captcha_keys` parameter is a dictionary that contains the **API keys for supported captcha solving services**, based on `config.toml`. The default value is an empty dictionary. You can provide API keys for specific captcha solving services if required. Currently, **"capsolver"** is supported.

Expand Down Expand Up @@ -200,13 +200,14 @@ Ninjemail logs its activities to a file named `ninjemail.log` in the `logs` dire

## Example

Here's an example that shows how to use Ninjemail to create an Outlook account:
Here's an example that shows how to use Ninjemail to create an Outlook account with `undetected-chrome`:

```python
from ninjemail import Ninjemail

# Replace "YOUR_API_KEY", "USERNAME" and "TOKEN" with your actual keys
ninja = Ninjemail(
browser="undetected-chrome",
captcha_keys={"capsolver": "YOUR_API_KEY"},
sms_keys={"getsmscode": {"user": "USERNAME", "token": "TOKEN"}},
auto_proxy=True)
Expand Down
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -0,0 +1,168 @@
{
"extName": {
"message": "Captcha Solver: Auto Recognition and Bypass"
},
"extDescription": {
"message": "Capsolver Solver plugin allows you to automatically solve CAPTCHAs found on any webpage."
},
"extShortName": {
"message": "Captcha solver"
},
"optionsPageTitle": {
"message": "Capsolver Extension Settings"
},
"accountSettings": {
"message": "Account Settings:"
},
"apiKey": {
"message": "API-KEY:"
},
"connect": {
"message": "Connect"
},
"doNotHaveApiKey": {
"message": "Do not have API-KEY?"
},
"createAccountToGetIt": {
"message": "<a href=\"#\" data-lang-link=\"$link$\" target=\"_blank\">Create account</a> to get it.",
"placeholders": {
"link": {
"content": "$1"
}
}
},
"generalSettings": {
"message": "General settings:"
},
"enablePlugin": {
"message": "Enable plugin"
},
"submitFormsAutomatically": {
"message": "Submit forms automatically"
},
"settingsLink": {
"message": "Settings"
},
"manualLink": {
"message": "Manual"
},
"enabledSolveAutomatically": {
"message": "Enabled / Solve automatically"
},
"minScore": {
"message": "min. score:"
},
"haveAnyQuestions": {
"message": "Have any questions/suggestions?"
},
"contactUs": {
"message": "Contact us: <a href=\"mailto:$email$\">$email$</a>",
"placeholders": {
"email": {
"content": "$1"
}
}
},
"balance": {
"message": "Balance"
},
"login": {
"message": "Login"
},
"logout": {
"message": "Logout"
},
"accountSuccessfullyConnected": {
"message": "Account successfully connected!"
},
"solveWithCapsolver": {
"message": "Solve with Capsolver"
},
"solving": {
"message": "Solving..."
},
"solved": {
"message": "Captcha solved!"
},
"delay": {
"message": "Delay"
},
"seconds": {
"message": "seconds"
},
"ifErrorRepeat": {
"message": "If error happens, repeat"
},
"times": {
"message": "times"
},
"proxySettings": {
"message": "Proxy settings"
},
"useProxy": {
"message": "Use proxy"
},
"proxyType": {
"message": "Proxy type"
},
"images": {
"message": "Images"
},
"markAsCaptchaSource": {
"message": "Mark as captcha source"
},
"putCaptchaAnswerHere": {
"message": "Put captcha answer here"
},
"normalManual": {
"message": "Location of image with captcha is saved. Now, please choose where to put answer."
},
"autoSubmitRules": {
"message": "AutoSubmit rules"
},
"autoSubmitDescription": {
"message": "By default, \"AutoSubmit\" feature submits form which contains captcha answer field. If something else must be done after captcha is solved, for example some button must be clicked, please define it here:"
},
"autoSubmitNoRules": {
"message": "No rules added yet..."
},
"autoSubmitCreateNewRule": {
"message": "Create new rule"
},
"autoSubmitAlertFormOpened": {
"message": "Please save or cancel previously opened form first!"
},
"autoSubmitAlertUrlRequired": {
"message": "URL pattern is required!"
},
"autoSubmitAlertUrlInvalid": {
"message": "URL pattern must be valid regular expression!"
},
"autoSubmitAlertCodeRequired": {
"message": "Code is required!"
},
"autoSubmitConfirmDelete": {
"message": "Delete rule"
},
"autoSubmitPlaceholderUrl": {
"message": "URL pattern (regexp), for example:"
},
"autoSubmitPlaceholderCode": {
"message": "Sequence of actions to execute, for example:"
},
"save": {
"message": "Save"
},
"cancel": {
"message": "Cancel"
},
"edit": {
"message": "Edit"
},
"delete": {
"message": "Delete"
},
"blackListDomain": {
"message": "Domain blacklist"
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,168 @@
{
"extName": {
"message": "Captcha Solver: Auto Evitar"
},
"extDescription": {
"message": "La extensión para resolver automáticalmente los CAPTCHAs en cualqer página web."
},
"extShortName": {
"message": "Captcha Solver"
},
"optionsPageTitle": {
"message": "Ajustes de Capsolver Extensión"
},
"accountSettings": {
"message": "Ajustes de la cuenta"
},
"apiKey": {
"message": "API-KEY:"
},
"connect": {
"message": "Conectar"
},
"doNotHaveApiKey": {
"message": "¿No tiene API-KEY?"
},
"createAccountToGetIt": {
"message": "<a href=\"#\" data-lang-link=\"$link$\" target=\"_blank\">Crea una cuenta </a> para obtenerlo.",
"placeholders": {
"link": {
"content": "$1"
}
}
},
"generalSettings": {
"message": "Ajustes generales:"
},
"enablePlugin": {
"message": "Habilitar extensión"
},
"submitFormsAutomatically": {
"message": "Enviar formularios automáticalmente"
},
"settingsLink": {
"message": "Ajustes"
},
"manualLink": {
"message": "Manual"
},
"enabledSolveAutomatically": {
"message": "Activado / Resolver automáticalmente"
},
"minScore": {
"message": "min. score:"
},
"haveAnyQuestions": {
"message": "¿Tiene preguntas o sugerencias?"
},
"contactUs": {
"message": "Contactenos: <a href=\"mailto:$email$\">$email$</a>",
"placeholders": {
"email": {
"content": "$1"
}
}
},
"balance": {
"message": "Saldo"
},
"login": {
"message": "Iniciar sesión"
},
"logout": {
"message": "Cerrar sesión"
},
"accountSuccessfullyConnected": {
"message": "¡La cuenta conectada con éxito!"
},
"solveWithCapsolver": {
"message": "Resolver con Capsolver"
},
"solving": {
"message": "Resolviendo..."
},
"solved": {
"message": "Captcha está resuelta!"
},
"delay": {
"message": "Retraso"
},
"seconds": {
"message": "segundos"
},
"ifErrorRepeat": {
"message": "En caso de error, repetir"
},
"times": {
"message": "veces"
},
"proxySettings": {
"message": "Ajustes de proxy"
},
"useProxy": {
"message": "Usar proxy"
},
"proxyType": {
"message": "Tipo de proxy"
},
"images": {
"message": "Imagenes"
},
"markAsCaptchaSource": {
"message": "Marcar como fuente de captcha"
},
"putCaptchaAnswerHere": {
"message": "Pon la respuesta de captcha aquí"
},
"normalManual": {
"message": "La ubicación de la imagen de captcha fue guardado. Ahora, elija dónde poner la respuesta."
},
"autoSubmitRules": {
"message": "Reglas de envío automático"
},
"autoSubmitDescription": {
"message": "De forma predeterminada, la función \"AutoSubmit\" envía un formulario que contiene un campo de respuesta captcha. Si se debe hacer algo más después de resolver el captcha, por ejemplo, se debe hacer clic en algún botón, defínalo aquí:"
},
"autoSubmitNoRules": {
"message": "Aún no se agregaron reglas..."
},
"autoSubmitCreateNewRule": {
"message": "Crear nueva regla"
},
"autoSubmitAlertFormOpened": {
"message": "¡Guarde o cancele primero el formulario abierto anteriormente!"
},
"autoSubmitAlertUrlRequired": {
"message": "¡Se requiere un patrón de URL!"
},
"autoSubmitAlertUrlInvalid": {
"message": "El patrón de URL debe ser una expresión regular válida."
},
"autoSubmitAlertCodeRequired": {
"message": "¡Se requiere código!"
},
"autoSubmitConfirmDelete": {
"message": "Eliminar regla"
},
"autoSubmitPlaceholderUrl": {
"message": "Patrón de URL (regex), por ejemplo:"
},
"autoSubmitPlaceholderCode": {
"message": "Secuencia de acciones a ejecutar, por ejemplo:"
},
"save": {
"message": "Ahorrar"
},
"cancel": {
"message": "Cancelar"
},
"edit": {
"message": "Editar"
},
"delete": {
"message": "Borrar"
},
"blackListDomain": {
"message": "Lista negra de dominio"
}
}
Loading

0 comments on commit 0b9880d

Please sign in to comment.