metabypass / captcha-solver-javascript

Metabypass | Javascript-based easy implementation for solving any type of captcha by Metabypass

Home Page:https://metabypass.tech

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Metabypass captcha solver javascript

Free demo (no credit card required) -> https://app.metabypass.tech/application

to install these packages use

npm install metabypass

for using this package first import metabypass

const solver = require("metabypass");

1.authentication

to authenticate and obtain the token first create the below object with your credentials and use getToken function from solver object

const user = {
  grant_type: "password", // Dont change it
  client_id: ",
  client_secret: ",
  username: "",
  password: "",
};
const token = await solver.getToken(user);

then saved the token in file or anywhere else for use in another function

2-text captcha

for solving text captcha use captchaSolver from solver object pass token and data

// use one of below function for base64 getBase64LocalCaptcha for local image and <b>getBase64Encoded</b> for external image
const localImage = await soler.getBase64LocalCaptcha('local image url)
const exernalImage = await solver.getBase64Encoded('external image url') 
const data = {
  image: externalImage // if you want you can use localImage
  numeric:0,
  min_len:0,
  max_len:0
}
const result = await solver.captchaSolver(token, data);

3-reCaptcha version 2

const data = {
   url: "", define protocol http or https
   sitekey: "",
   version: "2",
 };
 
const recaptchaId = await solver.getRecaptchaId(token, data);

after you get recaptcha Id you can use below function to get response

 const result = await solver.getRecaptchaResult(token, recaptchaId);

4-reCatpcha version 3

const data = {
   url: "", define protocol http or https
   sitekey: "",
   version: "3",
 };
 const result = await solver.getRecaptchaResponse(token, data);

5-Example for captcha

const solveCaptcha = async()=>{
  const user = {
  grant_type: "password", // Dont change it
  client_id: ",
  client_secret: ",
  username: "",
  password: "",
};
const token = await solver.getToken(user);
// use one of below function for base64 getBase64LocalCaptcha for local image and getBase64Encoded for external image
const image = await soler.getBase64LocalCaptcha('local image url)
const image = await solver.getBase64Encoded('external image url') 
data ={
image: image
numeric:0,
min_len:0,
max_len:0
}
const result = await solver.captchaSolver(token, data);
}