Socket
Book a DemoInstallSign in
Socket

anti-captcha

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

anti-captcha

Captcha recognition services API wrapper.

0.0.3
latest
Source
npmnpm
Version published
Weekly downloads
15
66.67%
Maintainers
1
Weekly downloads
 
Created
Source

anti-captcha

Installation

npm install anti-captcha

Usage

var anticaptcha = require('anti-captcha');

var service = anticaptcha('http://anti-captcha.com', 'API_KEY');

function printCaptchaText(captcha) {
  console.log(captcha.text);
}

function captchaNotRecognized(captcha) {
   // do something for test then return actual state
   return true; // stub
}

function printReportBad(captcha) {
  console.log('Report recorded');
}

service.downloadImage('https://i.imgur.com/lGQdxBy.png').then(function(base64) {
  service.uploadCaptcha(base64, {phrase: true})
  .then(function(captcha) {
    service.getText(captcha).then(function(captcha) {
      printCaptchaText(captcha);
      if (captchaNotRecognized(captcha)) {
        service.reportBad(captcha).then(printReportBad);
      }
    });
  });
}).catch(function(error) {
    console.log('Error:', error);
});

Keywords

antigate

FAQs

Package last updated on 27 Nov 2015

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

About

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.

  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc

U.S. Patent No. 12,346,443 & 12,314,394. Other pending.