Project

plagscan

0.0
Low commit activity in last 3 years
No release in over a year
Ruby gem for PlagScan (https://www.plagscan.com/) plagiarism checking APIs
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
 Dependencies

Development

~> 2.0
>= 12.3.3
~> 3.0
~> 3.0
~> 1.28
~> 0.17, < 0.18
 Project Readme

Github Build Status Maintainability Test Coverage Gem Version

PlagScan

Ruby wrapper for PlagScan plagiarism API

Installation

Add this line to your application's Gemfile:

gem 'plagscan'

And then execute:

$ bundle install

Or install it yourself as:

$ gem install plagscan

Supported APIs

Ping

Check if the PlagScan API is available

Plagscan.ping
=> true

Token

Authenticate and fetch access_token to use with other APIs

Plagscan::Token.fetch client_id: '1234', client_secret: 'secret'
=> { access_token: 'secret_token', expires_in: 86400 }

Documents

Upload documents to be checked by PlagScan

Plagscan::Documents.create access_token: 'secret_token', file: file
=> { documentID: '1234', .... }

N.B. you can also pass through the document as raw text using the text parameter in place of the file parameter.

Optional parameters for userID, textname, toRepository and saveOrig. See document create documentation for further details

Begin check of document uploaded to PlagScan

Plagscan::Documents.check access_token: 'secret_token', document_id: 1234
=> nil

Retrieve results of document scan

Plagscan::Documents.retrieve access_token: 'secret_token', document_id: 1234, mode: 0
=> { ... }

See document retrieve documentation for further details

Users

List user details

Plagscan::Users.list access_token: 'secret_token'
=> [{ ... }, { ... }, ...]

See user list documentation for further details

Get user details

Plagscan::Users.get access_token: 'secret_token', user_id: 123456
=> { ... }

See user get documentation for further details

Development

For details of the PlagScan API see documentation at https://api.plagscan.com/v3docs/

Contributing

Bug reports and pull requests are welcome on GitHub at https://github.com/Studiosity/plagscan-ruby.

Note that spec tests are appreciated to minimise regressions. Before submitting a PR, please ensure that:

$ rspec

and

$ rubocop

both succeed

License

The gem is available as open source under the terms of the MIT License.