You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It's a simple Ruby Datumbox Wrapper. It has only one class, called Datumbox (datumbox.rb), which makes all the work for you. We use the RestClient library to make remote calls to the Datumbox API. This class has one method to each available service provided by the Datumbox.
4
+
It's a simple Ruby Datumbox Wrapper. It has only one class, called Datumbox (`datumbox.rb`), which makes all the work for you. We use the RestClient library to make remote calls to the Datumbox API. This class has one method to each available service provided by the Datumbox.
5
5
6
6
7
-
First off, remember to get your API Key accessing and registering yourself at Datumbox website. Second, create a new instance of the Datumbox class passing your API Key as parameter to its constructor. Like this:
7
+
First off, remember to get your API Key accessing and registering yourself at the [Datumbox website](http://www.datumbox.com/). Second, create a new instance of the Datumbox class passing your API Key as parameter to its constructor. Like this:
8
8
9
+
`datumbox = Datumbox.new('YOUR API KEY GOES HERE')`
9
10
10
-
Datumbox.new('YOUR API KEY GOES HERE').
11
-
document_similarity("This document is unique.", "No, bastard! This document here is unique!.")
12
-
13
-
14
-
http://www.datumbox.com/
11
+
## Usage:
15
12
13
+
datumbox = Datumbox.new('YOUR API KEY GOES HERE')
14
+
15
+
datumbox.language_detection(text: 'El paraguas es de mi color favorito')
datumbox.document_similarity(original: 'This document is unique.',
20
+
copy: 'No, bastard! This document here is unique!.')
21
+
22
+
## Methods
23
+
24
+
You can call any method from the Datumbox API by writing it in underscore. For example the method `TopicClassification` should be called as `topic_classification`.
25
+
26
+
For a list of all the available methods, read the [Datumbox API documentation](http://www.datumbox.com/api-sandbox/)
27
+
28
+
When new methods are added to the API, this wrapper will automatically work with them.
0 commit comments