oxford_dictionary 2.0.1 → 3.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (34) hide show
  1. checksums.yaml +4 -4
  2. data/.rubocop.yml +5 -0
  3. data/CHANGELOG.md +3 -0
  4. data/README.md +3 -0
  5. data/Rakefile +5 -1
  6. data/lib/oxford_dictionary/client.rb +8 -249
  7. data/lib/oxford_dictionary/deserialize.rb +10 -0
  8. data/lib/oxford_dictionary/endpoints/endpoint.rb +1 -0
  9. data/lib/oxford_dictionary/endpoints/entries.rb +14 -10
  10. data/lib/oxford_dictionary/endpoints/lemmas.rb +18 -0
  11. data/lib/oxford_dictionary/endpoints/search.rb +4 -0
  12. data/lib/oxford_dictionary/endpoints/sentences.rb +4 -0
  13. data/lib/oxford_dictionary/endpoints/thesaurus.rb +4 -0
  14. data/lib/oxford_dictionary/endpoints/translations.rb +4 -0
  15. data/lib/oxford_dictionary/request.rb +2 -0
  16. data/lib/oxford_dictionary/version.rb +1 -1
  17. data/oxford_dictionary.gemspec +1 -2
  18. metadata +9 -24
  19. data/fixtures/vcr_cassettes/v1_entry.yml +0 -526
  20. data/fixtures/vcr_cassettes/v1_entry_antonym_synonym.yml +0 -42
  21. data/fixtures/vcr_cassettes/v1_entry_antonyms.yml +0 -42
  22. data/fixtures/vcr_cassettes/v1_entry_definitions.yml +0 -228
  23. data/fixtures/vcr_cassettes/v1_entry_error.yml +0 -49
  24. data/fixtures/vcr_cassettes/v1_entry_es.yml +0 -108
  25. data/fixtures/vcr_cassettes/v1_entry_examples.yml +0 -242
  26. data/fixtures/vcr_cassettes/v1_entry_past_nouns.yml +0 -49
  27. data/fixtures/vcr_cassettes/v1_entry_pronunciations.yml +0 -156
  28. data/fixtures/vcr_cassettes/v1_entry_synonyms.yml +0 -42
  29. data/fixtures/vcr_cassettes/v1_entry_us.yml +0 -526
  30. data/fixtures/vcr_cassettes/v1_inflection.yml +0 -74
  31. data/fixtures/vcr_cassettes/v1_inflection_filters.yml +0 -52
  32. data/fixtures/vcr_cassettes/v1_search.yml +0 -42
  33. data/fixtures/vcr_cassettes/v1_search_prefix.yml +0 -42
  34. data/fixtures/vcr_cassettes/v1_search_translation.yml +0 -42
@@ -1,74 +0,0 @@
1
- ---
2
- http_interactions:
3
- - request:
4
- method: get
5
- uri: https://od-api.oxforddictionaries.com/api/v2/lemmas/en/changed
6
- body:
7
- encoding: US-ASCII
8
- string: ''
9
- headers:
10
- Accept-Encoding:
11
- - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
12
- Accept:
13
- - application/json
14
- User-Agent:
15
- - Ruby
16
- Host:
17
- - od-api.oxforddictionaries.com
18
- App-Id:
19
- - APP_ID
20
- App-Key:
21
- - APP_KEY
22
- response:
23
- status:
24
- code: 200
25
- message: OK
26
- headers:
27
- Api-Version:
28
- - v2
29
- Code-Version:
30
- - v2.3.2-g02aa52c
31
- Content-Type:
32
- - application/json;charset=utf-8
33
- Date:
34
- - Sun, 30 Jun 2019 04:24:14 GMT
35
- Server:
36
- - openresty/1.13.6.2
37
- Content-Length:
38
- - '708'
39
- Connection:
40
- - keep-alive
41
- body:
42
- encoding: UTF-8
43
- string: |-
44
- {
45
- "metadata": {
46
- "provider": "Oxford University Press"
47
- },
48
- "results": [
49
- {
50
- "id": "changed",
51
- "language": "en",
52
- "lexicalEntries": [
53
- {
54
- "inflectionOf": [
55
- {
56
- "id": "change",
57
- "text": "change"
58
- }
59
- ],
60
- "language": "en",
61
- "lexicalCategory": {
62
- "id": "verb",
63
- "text": "Verb"
64
- },
65
- "text": "changed"
66
- }
67
- ],
68
- "word": "changed"
69
- }
70
- ]
71
- }
72
- http_version:
73
- recorded_at: Sun, 30 Jun 2019 04:24:14 GMT
74
- recorded_with: VCR 4.0.0
@@ -1,52 +0,0 @@
1
- ---
2
- http_interactions:
3
- - request:
4
- method: get
5
- uri: https://od-api.oxforddictionaries.com/api/v2/lemmas/en/changed?grammaticalFeatures=singular,past&lexicalCategory=noun
6
- body:
7
- encoding: US-ASCII
8
- string: ''
9
- headers:
10
- Accept-Encoding:
11
- - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
12
- Accept:
13
- - application/json
14
- User-Agent:
15
- - Ruby
16
- Host:
17
- - od-api.oxforddictionaries.com
18
- App-Id:
19
- - APP_ID
20
- App-Key:
21
- - APP_KEY
22
- response:
23
- status:
24
- code: 200
25
- message: OK
26
- headers:
27
- Api-Version:
28
- - v2
29
- Code-Version:
30
- - v2.3.2-g02aa52c
31
- Content-Type:
32
- - application/json;charset=utf-8
33
- Date:
34
- - Sun, 30 Jun 2019 04:24:48 GMT
35
- Server:
36
- - openresty/1.13.6.2
37
- Content-Length:
38
- - '92'
39
- Connection:
40
- - keep-alive
41
- body:
42
- encoding: UTF-8
43
- string: |-
44
- {
45
- "metadata": {
46
- "provider": "Oxford University Press"
47
- },
48
- "results": []
49
- }
50
- http_version:
51
- recorded_at: Sun, 30 Jun 2019 04:24:47 GMT
52
- recorded_with: VCR 4.0.0
@@ -1,42 +0,0 @@
1
- ---
2
- http_interactions:
3
- - request:
4
- method: get
5
- uri: https://od-api.oxforddictionaries.com/api/v1/search/en?prefix=false&q=vapid
6
- body:
7
- encoding: US-ASCII
8
- string: ''
9
- headers:
10
- Accept-Encoding:
11
- - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
12
- Accept:
13
- - application/json
14
- User-Agent:
15
- - Ruby
16
- Host:
17
- - od-api.oxforddictionaries.com
18
- App-Id:
19
- - APP_ID
20
- App-Key:
21
- - APP_KEY
22
- response:
23
- status:
24
- code: 403
25
- message: Forbidden
26
- headers:
27
- Content-Type:
28
- - text/plain; charset=us-ascii
29
- Date:
30
- - Sun, 30 Jun 2019 04:42:49 GMT
31
- Server:
32
- - openresty/1.9.7.4
33
- Content-Length:
34
- - '21'
35
- Connection:
36
- - keep-alive
37
- body:
38
- encoding: UTF-8
39
- string: Authentication failed
40
- http_version:
41
- recorded_at: Sun, 30 Jun 2019 04:42:49 GMT
42
- recorded_with: VCR 4.0.0
@@ -1,42 +0,0 @@
1
- ---
2
- http_interactions:
3
- - request:
4
- method: get
5
- uri: https://od-api.oxforddictionaries.com/api/v1/search/en?prefix=true&q=condition
6
- body:
7
- encoding: US-ASCII
8
- string: ''
9
- headers:
10
- Accept-Encoding:
11
- - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
12
- Accept:
13
- - application/json
14
- User-Agent:
15
- - Ruby
16
- Host:
17
- - od-api.oxforddictionaries.com
18
- App-Id:
19
- - APP_ID
20
- App-Key:
21
- - APP_KEY
22
- response:
23
- status:
24
- code: 403
25
- message: Forbidden
26
- headers:
27
- Content-Type:
28
- - text/plain; charset=us-ascii
29
- Date:
30
- - Sun, 30 Jun 2019 04:42:49 GMT
31
- Server:
32
- - openresty/1.9.7.4
33
- Content-Length:
34
- - '21'
35
- Connection:
36
- - keep-alive
37
- body:
38
- encoding: UTF-8
39
- string: Authentication failed
40
- http_version:
41
- recorded_at: Sun, 30 Jun 2019 04:42:49 GMT
42
- recorded_with: VCR 4.0.0
@@ -1,42 +0,0 @@
1
- ---
2
- http_interactions:
3
- - request:
4
- method: get
5
- uri: https://od-api.oxforddictionaries.com/api/v1/search/en/translations=id?prefix=false&q=eye
6
- body:
7
- encoding: US-ASCII
8
- string: ''
9
- headers:
10
- Accept-Encoding:
11
- - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
12
- Accept:
13
- - application/json
14
- User-Agent:
15
- - Ruby
16
- Host:
17
- - od-api.oxforddictionaries.com
18
- App-Id:
19
- - APP_ID
20
- App-Key:
21
- - APP_KEY
22
- response:
23
- status:
24
- code: 403
25
- message: Forbidden
26
- headers:
27
- Content-Type:
28
- - text/plain; charset=us-ascii
29
- Date:
30
- - Sun, 30 Jun 2019 04:42:50 GMT
31
- Server:
32
- - openresty/1.9.7.4
33
- Content-Length:
34
- - '21'
35
- Connection:
36
- - keep-alive
37
- body:
38
- encoding: UTF-8
39
- string: Authentication failed
40
- http_version:
41
- recorded_at: Sun, 30 Jun 2019 04:42:50 GMT
42
- recorded_with: VCR 4.0.0