Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Ruby wrapper for Copyscape API

branch: master

Fetching latest commit…

Octocat-spinner-32-eaf2f5

Cannot retrieve the latest commit at this time

Octocat-spinner-32 lib
Octocat-spinner-32 test
Octocat-spinner-32 .gitignore
Octocat-spinner-32 Gemfile
Octocat-spinner-32 Gemfile.lock
Octocat-spinner-32 README.md
Octocat-spinner-32 Rakefile
Octocat-spinner-32 copyscape.gemspec
README.md

copyscape

Ruby wrapper for the Copyscape API.

Usage

First, you'll need to setup your Copyscape account and whatnot. You can do that here.

Next, install the gem.

$ gem install copyscape

And then you can do things like this...

Copyscape.username = 'yourname'
Copyscape.api_key = 'abc123'

# URL search
search = Copyscape.url_search("http://www.copyscape.com/example.html")
search.duplicate? # => true
search.count # => 81
search.duplicates.each do |duplicate|
  puts duplciate['title']
  puts duplicate['url']
  puts duplicate['textsnippet']
  puts duplicate['htmlsnippet']
  puts duplicate['minwordsmatched']
end

# Text search
search = Copyscape.text_search('This is some text I want to check for plagurism')
search.duplicate? # => false

Currently, there is no support in the gem for "private index" searching, though it would be pretty easy to add.

More...

I'm in no way associated with Copyscape.

Something went wrong with that request. Please try again.