bolognese 0.8.3 → 0.8.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (44) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile.lock +2 -2
  3. data/lib/bolognese/doi_utils.rb +10 -11
  4. data/lib/bolognese/utils.rb +2 -1
  5. data/lib/bolognese/version.rb +1 -1
  6. data/spec/doi_utils_spec.rb +14 -9
  7. data/spec/fixtures/vcr_cassettes/Bolognese_CLI/convert_from_id/crossref/default.yml +55 -25
  8. data/spec/fixtures/vcr_cassettes/Bolognese_CLI/convert_from_id/crossref/to_bibtex.yml +55 -25
  9. data/spec/fixtures/vcr_cassettes/Bolognese_CLI/convert_from_id/crossref/to_crossref.yml +55 -25
  10. data/spec/fixtures/vcr_cassettes/Bolognese_CLI/convert_from_id/crossref/to_datacite.yml +53 -25
  11. data/spec/fixtures/vcr_cassettes/Bolognese_CLI/convert_from_id/crossref/to_schema_org.yml +55 -25
  12. data/spec/fixtures/vcr_cassettes/Bolognese_CLI/convert_from_id/datacite/default.yml +75 -45
  13. data/spec/fixtures/vcr_cassettes/Bolognese_CLI/convert_from_id/datacite/to_bibtex.yml +75 -45
  14. data/spec/fixtures/vcr_cassettes/Bolognese_CLI/convert_from_id/datacite/to_datacite.yml +73 -45
  15. data/spec/fixtures/vcr_cassettes/Bolognese_CLI/convert_from_id/datacite/to_datacite_json.yml +73 -45
  16. data/spec/fixtures/vcr_cassettes/Bolognese_CLI/convert_from_id/datacite/to_schema_org.yml +73 -45
  17. data/spec/fixtures/vcr_cassettes/Bolognese_CLI/convert_from_id/schema_org/default.yml +62 -53
  18. data/spec/fixtures/vcr_cassettes/Bolognese_CLI/convert_from_id/schema_org/to_bibtex.yml +62 -53
  19. data/spec/fixtures/vcr_cassettes/Bolognese_CLI/convert_from_id/schema_org/to_datacite.yml +62 -53
  20. data/spec/fixtures/vcr_cassettes/Bolognese_CLI/convert_from_id/schema_org/to_schema_org.yml +62 -53
  21. data/spec/fixtures/vcr_cassettes/Bolognese_Metadata/doi_registration_agency/crossref.yml +74 -0
  22. data/spec/fixtures/vcr_cassettes/Bolognese_Metadata/doi_registration_agency/datacite.yml +74 -0
  23. data/spec/fixtures/vcr_cassettes/Bolognese_Metadata/doi_registration_agency/medra.yml +72 -0
  24. data/spec/fixtures/vcr_cassettes/Bolognese_Metadata/doi_registration_agency/not_found.yml +67 -0
  25. data/spec/fixtures/vcr_cassettes/Bolognese_Metadata/find_from_format_by_ID/crossref.yml +50 -20
  26. data/spec/fixtures/vcr_cassettes/Bolognese_Metadata/find_from_format_by_ID/crossref_doi_not_url.yml +50 -20
  27. data/spec/fixtures/vcr_cassettes/Bolognese_Metadata/find_from_format_by_ID/datacite.yml +50 -20
  28. data/spec/fixtures/vcr_cassettes/Bolognese_Metadata/find_from_format_by_ID/datacite_doi_http.yml +48 -20
  29. data/spec/utils_spec.rb +2 -3
  30. metadata +5 -15
  31. data/spec/fixtures/vcr_cassettes/Bolognese_CLI/convert_from_id/crossref/as_bibtex.yml +0 -760
  32. data/spec/fixtures/vcr_cassettes/Bolognese_CLI/convert_from_id/crossref/as_crossref.yml +0 -760
  33. data/spec/fixtures/vcr_cassettes/Bolognese_CLI/convert_from_id/crossref/as_datacite.yml +0 -760
  34. data/spec/fixtures/vcr_cassettes/Bolognese_CLI/convert_from_id/crossref/as_schema_org.yml +0 -760
  35. data/spec/fixtures/vcr_cassettes/Bolognese_CLI/convert_from_id/datacite/as_bibtex.yml +0 -214
  36. data/spec/fixtures/vcr_cassettes/Bolognese_CLI/convert_from_id/datacite/as_datacite.yml +0 -214
  37. data/spec/fixtures/vcr_cassettes/Bolognese_CLI/convert_from_id/datacite/as_schema_org.yml +0 -214
  38. data/spec/fixtures/vcr_cassettes/Bolognese_CLI/convert_from_id/schema_org/as_bibtex.yml +0 -653
  39. data/spec/fixtures/vcr_cassettes/Bolognese_CLI/convert_from_id/schema_org/as_datacite.yml +0 -653
  40. data/spec/fixtures/vcr_cassettes/Bolognese_CLI/convert_from_id/schema_org/as_schema_org.yml +0 -653
  41. data/spec/fixtures/vcr_cassettes/Bolognese_Crossref/doi_registration_agency/crossref.yml +0 -971
  42. data/spec/fixtures/vcr_cassettes/Bolognese_Crossref/doi_registration_agency/datacite.yml +0 -971
  43. data/spec/fixtures/vcr_cassettes/Bolognese_Crossref/doi_registration_agency/medra.yml +0 -971
  44. data/spec/fixtures/vcr_cassettes/Bolognese_Crossref/doi_registration_agency/not_found.yml +0 -971
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 0f624193ecf8a118b01013a5a0a442fe57f304b6
4
- data.tar.gz: e4c32a8f60033476ecd438956e0abbe6e891f4e2
3
+ metadata.gz: 063f676946258c78127e1d88782896a0b897e8a5
4
+ data.tar.gz: 3b9f829af641f7aa53394eb79e588a838bc88abb
5
5
  SHA512:
6
- metadata.gz: bbddae6659ad97a27ea93411936b868403597a260de06e5398e20e4e6da95086c02598bab75cf99021a5cffa915178be8c499d72ecbbbabf7ebe35daf34629bf
7
- data.tar.gz: 70dac5753375a8fd3c288c129e5580b9ad4489f1721638c63a53c85cca1379890417f28a56a952af45a73cecc7f508e6dc5c76d3d072509b3715ba8cc1fc7a97
6
+ metadata.gz: 0583e3e9ec72227314e388c395b2d03c9e61421e6b5307b2bfa8254c988dca539cad1ffa3f94f1775d8f3f0ca2848d6fb6e6be808e2089b19657ac30eb17020a
7
+ data.tar.gz: dd8d205fa555873683f496c5e49572bcc3a953fbb7d128baba3ca062e7ea206e86dc1592080edbea5e982d8fdccdfb042a29f0ad52d009ea7ba85d9c7a70c768
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- bolognese (0.8.3)
4
+ bolognese (0.8.4)
5
5
  activesupport (~> 4.2, >= 4.2.5)
6
6
  bibtex-ruby (~> 4.1)
7
7
  builder (~> 3.2, >= 3.2.2)
@@ -123,4 +123,4 @@ DEPENDENCIES
123
123
  webmock (~> 1.22, >= 1.22.3)
124
124
 
125
125
  BUNDLED WITH
126
- 1.14.6
126
+ 1.12.5
@@ -4,6 +4,10 @@ module Bolognese
4
4
  Array(/\A(?:(http|https):\/\/(dx\.)?doi.org\/)?(doi:)?(10\.\d{4,5}\/.+)\z/.match(doi)).last
5
5
  end
6
6
 
7
+ def validate_prefix(doi)
8
+ Array(/\A(?:(http|https):\/\/(dx\.)?doi.org\/)?(doi:)?(10\.\d{4,5})\/.+\z/.match(doi)).last
9
+ end
10
+
7
11
  def normalize_doi(doi)
8
12
  doi = validate_doi(doi)
9
13
  return nil unless doi.present?
@@ -26,20 +30,15 @@ module Bolognese
26
30
  "https://doi.org/#{clean_doi(doi)}" if doi.present?
27
31
  end
28
32
 
29
- # get DOI registration agency, assume a normalized DOI
33
+ # get DOI registration agency
30
34
  def get_doi_ra(doi)
31
- return {} if doi.blank?
35
+ prefix = validate_prefix(doi)
36
+ return nil if prefix.blank?
32
37
 
33
- url = "https://doi.crossref.org/doiRA/#{doi_from_url(doi)}"
34
- response = Maremma.get(url, host: true, timeout: 120)
38
+ url = "https://api.datacite.org/prefixes/#{prefix}"
39
+ result = Maremma.get(url)
35
40
 
36
- ra = response.body.fetch("data", {}).first.fetch("RA", nil)
37
- if ra.present?
38
- { "id" => ra.downcase,
39
- "name" => ra }
40
- else
41
- { "errors" => response.body.fetch("errors", nil) || response.body.fetch("data", nil) }
42
- end
41
+ result.body.fetch("data", {}).fetch('attributes', {}).fetch('registration-agency', nil)
43
42
  end
44
43
  end
45
44
  end
@@ -21,7 +21,8 @@ module Bolognese
21
21
  id = normalize_id(id)
22
22
 
23
23
  if /\A(?:(http|https):\/\/(dx\.)?doi.org\/)?(doi:)?(10\.\d{4,5}\/.+)\z/.match(id)
24
- get_doi_ra(id).fetch("id", nil)
24
+ ra = get_doi_ra(id)
25
+ ra.present? ? ra.downcase : nil
25
26
  elsif /\A(?:(http|https):\/\/orcid\.org\/)?(\d{4}-\d{4}-\d{4}-\d{3}[0-9X]+)\z/.match(id)
26
27
  "orcid"
27
28
  elsif /\A(http|https):\/\/github\.com\/(.+)\z/.match(id)
@@ -1,3 +1,3 @@
1
1
  module Bolognese
2
- VERSION = "0.8.3"
2
+ VERSION = "0.8.4"
3
3
  end
@@ -1,9 +1,8 @@
1
1
  require 'spec_helper'
2
2
 
3
- describe Bolognese::Crossref, vcr: true do
4
- let(:id) { "https://doi.org/10.1371/journal.pone.0000030" }
3
+ describe Bolognese::Metadata, vcr: true do
5
4
 
6
- subject { Bolognese::Crossref.new(id: id) }
5
+ subject { Bolognese::Metadata.new }
7
6
 
8
7
  context "normalize doi" do
9
8
  it "doi" do
@@ -65,25 +64,31 @@ describe Bolognese::Crossref, vcr: true do
65
64
  it "datacite" do
66
65
  doi = "https://doi.org/10.5061/dryad.8515"
67
66
  response = subject.get_doi_ra(doi)
68
- expect(response["name"]).to eq("DataCite")
67
+ expect(response).to eq("DataCite")
69
68
  end
70
69
 
71
70
  it "crossref" do
72
- doi = "https://doi.org/10.1371/journal.pone.0000030"
71
+ doi = "10.1371/journal.pone.0000030"
73
72
  response = subject.get_doi_ra(doi)
74
- expect(response["name"]).to eq("Crossref")
73
+ expect(response).to eq("Crossref")
75
74
  end
76
75
 
77
76
  it "medra" do
78
77
  doi = "https://doi.org/10.1392/roma081203"
79
78
  response = subject.get_doi_ra(doi)
80
- expect(response["name"]).to eq("mEDRA")
79
+ expect(response).to eq("mEDRA")
80
+ end
81
+
82
+ it "not a valid prefix" do
83
+ doi = "https://doi.org/10.a/dryad.8515x"
84
+ response = subject.get_doi_ra(doi)
85
+ expect(response).to be_nil
81
86
  end
82
87
 
83
88
  it "not found" do
84
- doi = "https://doi.org/10.5061/dryad.8515x"
89
+ doi = "https://doi.org/10.99999/dryad.8515x"
85
90
  response = subject.get_doi_ra(doi)
86
- expect(response["errors"]).to eq([{"DOI"=>"10.5061/dryad.8515x", "status"=>"Invalid DOI"}])
91
+ expect(response).to be_nil
87
92
  end
88
93
  end
89
94
  end
@@ -2,7 +2,7 @@
2
2
  http_interactions:
3
3
  - request:
4
4
  method: get
5
- uri: https://doi.crossref.org/doiRA/10.7554/elife.01567
5
+ uri: https://api.datacite.org/prefixes/10.7554
6
6
  body:
7
7
  encoding: US-ASCII
8
8
  string: ''
@@ -16,31 +16,61 @@ http_interactions:
16
16
  code: 200
17
17
  message: ''
18
18
  headers:
19
- Server:
20
- - Apache-Coyote/1.1
21
- Crossref-Deployment-Name:
22
- - svc1-1
19
+ Access-Control-Allow-Credentials:
20
+ - 'true'
21
+ Access-Control-Allow-Headers:
22
+ - Content-Type,Accept,Accept-Encoding,Origin,User-Agent,Cache-Control,Keep-Alive
23
+ Access-Control-Allow-Methods:
24
+ - POST, GET, OPTIONS
25
+ Access-Control-Allow-Origin:
26
+ - "*"
27
+ Access-Control-Max-Age:
28
+ - '1728000'
29
+ Cache-Control:
30
+ - max-age=0, private, must-revalidate
23
31
  Content-Type:
24
- - application/json;charset=UTF-8
25
- Content-Language:
26
- - en-US
27
- Content-Length:
28
- - '57'
32
+ - application/vnd.api+json; charset=utf-8
29
33
  Date:
30
- - Wed, 22 Feb 2017 17:21:17 GMT
34
+ - Sun, 12 Mar 2017 09:09:07 GMT
35
+ Etag:
36
+ - W/"daf85afdb45f3c2713bc7e75916ba82a"
37
+ Server:
38
+ - openresty/1.11.2.2
39
+ Status:
40
+ - 200 OK
41
+ Vary:
42
+ - Accept-Encoding
43
+ Via:
44
+ - kong/0.10.0rc3
45
+ X-Content-Type-Options:
46
+ - nosniff
47
+ X-Frame-Options:
48
+ - SAMEORIGIN
49
+ X-Kong-Proxy-Latency:
50
+ - '18'
51
+ X-Kong-Upstream-Latency:
52
+ - '545'
53
+ X-Powered-By:
54
+ - Phusion Passenger 5.1.2
55
+ X-Ratelimit-Limit-Hour:
56
+ - '10000'
57
+ X-Ratelimit-Remaining-Hour:
58
+ - '9992'
59
+ X-Request-Id:
60
+ - 4a1c67ea-4ffb-4674-93d8-e4b2e1fa71a4
61
+ X-Runtime:
62
+ - '0.543916'
63
+ X-Xss-Protection:
64
+ - 1; mode=block
65
+ Content-Length:
66
+ - '124'
31
67
  Connection:
32
- - close
68
+ - keep-alive
33
69
  body:
34
70
  encoding: UTF-8
35
- string: |-
36
- [
37
- {
38
- "DOI": "10.7554/elife.01567",
39
- "RA": "Crossref"
40
- }
41
- ]
71
+ string: '{"data":{"id":"10.7554","type":"prefixes","attributes":{"registration-agency":"Crossref","updated":"2016-09-21T21:07:27Z"}}}'
42
72
  http_version:
43
- recorded_at: Wed, 22 Feb 2017 17:21:18 GMT
73
+ recorded_at: Sun, 12 Mar 2017 09:09:07 GMT
44
74
  - request:
45
75
  method: get
46
76
  uri: https://doi.org/10.7554/elife.01567
@@ -64,20 +94,20 @@ http_interactions:
64
94
  Location:
65
95
  - http://data.crossref.org/10.7554%2Felife.01567
66
96
  Expires:
67
- - Wed, 22 Feb 2017 17:45:01 GMT
97
+ - Sun, 12 Mar 2017 09:59:19 GMT
68
98
  Content-Type:
69
99
  - text/html;charset=utf-8
70
100
  Content-Length:
71
101
  - '177'
72
102
  Date:
73
- - Wed, 22 Feb 2017 17:21:26 GMT
103
+ - Sun, 12 Mar 2017 09:09:14 GMT
74
104
  body:
75
105
  encoding: UTF-8
76
106
  string: |-
77
107
  <html><head><title>Handle Redirect</title></head>
78
108
  <body><a href="http://data.crossref.org/10.7554%2Felife.01567">http://data.crossref.org/10.7554%2Felife.01567</a></body></html>
79
109
  http_version:
80
- recorded_at: Wed, 22 Feb 2017 17:21:27 GMT
110
+ recorded_at: Sun, 12 Mar 2017 09:09:15 GMT
81
111
  - request:
82
112
  method: get
83
113
  uri: http://data.crossref.org/10.7554%2Felife.01567
@@ -113,7 +143,7 @@ http_interactions:
113
143
  Server:
114
144
  - http-kit
115
145
  Date:
116
- - Wed, 22 Feb 2017 17:21:27 GMT
146
+ - Sun, 12 Mar 2017 09:09:15 GMT
117
147
  Connection:
118
148
  - close
119
149
  body:
@@ -756,5 +786,5 @@ http_interactions:
756
786
  aWNsZT4NCiAgICAgIDwvam91cm5hbD4NCiAgICA8L2Nyb3NzcmVmPg0KICA8
757
787
  L2RvaV9yZWNvcmQ+DQo8L2RvaV9yZWNvcmRzPg==
758
788
  http_version:
759
- recorded_at: Wed, 22 Feb 2017 17:21:27 GMT
789
+ recorded_at: Sun, 12 Mar 2017 09:09:15 GMT
760
790
  recorded_with: VCR 3.0.3
@@ -2,7 +2,7 @@
2
2
  http_interactions:
3
3
  - request:
4
4
  method: get
5
- uri: https://doi.crossref.org/doiRA/10.7554/elife.01567
5
+ uri: https://api.datacite.org/prefixes/10.7554
6
6
  body:
7
7
  encoding: US-ASCII
8
8
  string: ''
@@ -16,31 +16,61 @@ http_interactions:
16
16
  code: 200
17
17
  message: ''
18
18
  headers:
19
- Server:
20
- - Apache-Coyote/1.1
21
- Crossref-Deployment-Name:
22
- - svc1-1
19
+ Access-Control-Allow-Credentials:
20
+ - 'true'
21
+ Access-Control-Allow-Headers:
22
+ - Content-Type,Accept,Accept-Encoding,Origin,User-Agent,Cache-Control,Keep-Alive
23
+ Access-Control-Allow-Methods:
24
+ - POST, GET, OPTIONS
25
+ Access-Control-Allow-Origin:
26
+ - "*"
27
+ Access-Control-Max-Age:
28
+ - '1728000'
29
+ Cache-Control:
30
+ - max-age=0, private, must-revalidate
23
31
  Content-Type:
24
- - application/json;charset=UTF-8
25
- Content-Language:
26
- - en-US
27
- Content-Length:
28
- - '57'
32
+ - application/vnd.api+json; charset=utf-8
29
33
  Date:
30
- - Wed, 22 Feb 2017 17:30:21 GMT
34
+ - Sun, 12 Mar 2017 09:08:47 GMT
35
+ Etag:
36
+ - W/"daf85afdb45f3c2713bc7e75916ba82a"
37
+ Server:
38
+ - openresty/1.11.2.2
39
+ Status:
40
+ - 200 OK
41
+ Vary:
42
+ - Accept-Encoding
43
+ Via:
44
+ - kong/0.10.0rc3
45
+ X-Content-Type-Options:
46
+ - nosniff
47
+ X-Frame-Options:
48
+ - SAMEORIGIN
49
+ X-Kong-Proxy-Latency:
50
+ - '1'
51
+ X-Kong-Upstream-Latency:
52
+ - '489'
53
+ X-Powered-By:
54
+ - Phusion Passenger 5.1.2
55
+ X-Ratelimit-Limit-Hour:
56
+ - '10000'
57
+ X-Ratelimit-Remaining-Hour:
58
+ - '9994'
59
+ X-Request-Id:
60
+ - 62732ae3-9068-4d9c-ade4-36f6523afc7e
61
+ X-Runtime:
62
+ - '0.487711'
63
+ X-Xss-Protection:
64
+ - 1; mode=block
65
+ Content-Length:
66
+ - '124'
31
67
  Connection:
32
- - close
68
+ - keep-alive
33
69
  body:
34
70
  encoding: UTF-8
35
- string: |-
36
- [
37
- {
38
- "DOI": "10.7554/elife.01567",
39
- "RA": "Crossref"
40
- }
41
- ]
71
+ string: '{"data":{"id":"10.7554","type":"prefixes","attributes":{"registration-agency":"Crossref","updated":"2016-09-21T21:07:27Z"}}}'
42
72
  http_version:
43
- recorded_at: Wed, 22 Feb 2017 17:30:22 GMT
73
+ recorded_at: Sun, 12 Mar 2017 09:08:48 GMT
44
74
  - request:
45
75
  method: get
46
76
  uri: https://doi.org/10.7554/elife.01567
@@ -64,20 +94,20 @@ http_interactions:
64
94
  Location:
65
95
  - http://data.crossref.org/10.7554%2Felife.01567
66
96
  Expires:
67
- - Wed, 22 Feb 2017 17:45:01 GMT
97
+ - Sun, 12 Mar 2017 09:59:19 GMT
68
98
  Content-Type:
69
99
  - text/html;charset=utf-8
70
100
  Content-Length:
71
101
  - '177'
72
102
  Date:
73
- - Wed, 22 Feb 2017 17:30:22 GMT
103
+ - Sun, 12 Mar 2017 09:08:55 GMT
74
104
  body:
75
105
  encoding: UTF-8
76
106
  string: |-
77
107
  <html><head><title>Handle Redirect</title></head>
78
108
  <body><a href="http://data.crossref.org/10.7554%2Felife.01567">http://data.crossref.org/10.7554%2Felife.01567</a></body></html>
79
109
  http_version:
80
- recorded_at: Wed, 22 Feb 2017 17:30:22 GMT
110
+ recorded_at: Sun, 12 Mar 2017 09:08:56 GMT
81
111
  - request:
82
112
  method: get
83
113
  uri: http://data.crossref.org/10.7554%2Felife.01567
@@ -113,7 +143,7 @@ http_interactions:
113
143
  Server:
114
144
  - http-kit
115
145
  Date:
116
- - Wed, 22 Feb 2017 17:30:22 GMT
146
+ - Sun, 12 Mar 2017 09:08:56 GMT
117
147
  Connection:
118
148
  - close
119
149
  body:
@@ -756,5 +786,5 @@ http_interactions:
756
786
  aWNsZT4NCiAgICAgIDwvam91cm5hbD4NCiAgICA8L2Nyb3NzcmVmPg0KICA8
757
787
  L2RvaV9yZWNvcmQ+DQo8L2RvaV9yZWNvcmRzPg==
758
788
  http_version:
759
- recorded_at: Wed, 22 Feb 2017 17:30:22 GMT
789
+ recorded_at: Sun, 12 Mar 2017 09:08:56 GMT
760
790
  recorded_with: VCR 3.0.3
@@ -2,7 +2,7 @@
2
2
  http_interactions:
3
3
  - request:
4
4
  method: get
5
- uri: https://doi.crossref.org/doiRA/10.7554/elife.01567
5
+ uri: https://api.datacite.org/prefixes/10.7554
6
6
  body:
7
7
  encoding: US-ASCII
8
8
  string: ''
@@ -16,31 +16,61 @@ http_interactions:
16
16
  code: 200
17
17
  message: ''
18
18
  headers:
19
- Server:
20
- - Apache-Coyote/1.1
21
- Crossref-Deployment-Name:
22
- - svc1-1
19
+ Access-Control-Allow-Credentials:
20
+ - 'true'
21
+ Access-Control-Allow-Headers:
22
+ - Content-Type,Accept,Accept-Encoding,Origin,User-Agent,Cache-Control,Keep-Alive
23
+ Access-Control-Allow-Methods:
24
+ - POST, GET, OPTIONS
25
+ Access-Control-Allow-Origin:
26
+ - "*"
27
+ Access-Control-Max-Age:
28
+ - '1728000'
29
+ Cache-Control:
30
+ - max-age=0, private, must-revalidate
23
31
  Content-Type:
24
- - application/json;charset=UTF-8
25
- Content-Language:
26
- - en-US
27
- Content-Length:
28
- - '57'
32
+ - application/vnd.api+json; charset=utf-8
29
33
  Date:
30
- - Wed, 22 Feb 2017 17:30:20 GMT
34
+ - Sun, 12 Mar 2017 09:09:16 GMT
35
+ Etag:
36
+ - W/"daf85afdb45f3c2713bc7e75916ba82a"
37
+ Server:
38
+ - openresty/1.11.2.2
39
+ Status:
40
+ - 200 OK
41
+ Vary:
42
+ - Accept-Encoding
43
+ Via:
44
+ - kong/0.10.0rc3
45
+ X-Content-Type-Options:
46
+ - nosniff
47
+ X-Frame-Options:
48
+ - SAMEORIGIN
49
+ X-Kong-Proxy-Latency:
50
+ - '26'
51
+ X-Kong-Upstream-Latency:
52
+ - '237'
53
+ X-Powered-By:
54
+ - Phusion Passenger 5.1.2
55
+ X-Ratelimit-Limit-Hour:
56
+ - '10000'
57
+ X-Ratelimit-Remaining-Hour:
58
+ - '9991'
59
+ X-Request-Id:
60
+ - 2ceda84e-d266-4ed3-9f8a-df8675fd0106
61
+ X-Runtime:
62
+ - '0.236229'
63
+ X-Xss-Protection:
64
+ - 1; mode=block
65
+ Content-Length:
66
+ - '124'
31
67
  Connection:
32
- - close
68
+ - keep-alive
33
69
  body:
34
70
  encoding: UTF-8
35
- string: |-
36
- [
37
- {
38
- "DOI": "10.7554/elife.01567",
39
- "RA": "Crossref"
40
- }
41
- ]
71
+ string: '{"data":{"id":"10.7554","type":"prefixes","attributes":{"registration-agency":"Crossref","updated":"2016-09-21T21:07:27Z"}}}'
42
72
  http_version:
43
- recorded_at: Wed, 22 Feb 2017 17:30:21 GMT
73
+ recorded_at: Sun, 12 Mar 2017 09:09:16 GMT
44
74
  - request:
45
75
  method: get
46
76
  uri: https://doi.org/10.7554/elife.01567
@@ -64,20 +94,20 @@ http_interactions:
64
94
  Location:
65
95
  - http://data.crossref.org/10.7554%2Felife.01567
66
96
  Expires:
67
- - Wed, 22 Feb 2017 17:45:01 GMT
97
+ - Sun, 12 Mar 2017 09:59:19 GMT
68
98
  Content-Type:
69
99
  - text/html;charset=utf-8
70
100
  Content-Length:
71
101
  - '177'
72
102
  Date:
73
- - Wed, 22 Feb 2017 17:30:20 GMT
103
+ - Sun, 12 Mar 2017 09:09:23 GMT
74
104
  body:
75
105
  encoding: UTF-8
76
106
  string: |-
77
107
  <html><head><title>Handle Redirect</title></head>
78
108
  <body><a href="http://data.crossref.org/10.7554%2Felife.01567">http://data.crossref.org/10.7554%2Felife.01567</a></body></html>
79
109
  http_version:
80
- recorded_at: Wed, 22 Feb 2017 17:30:21 GMT
110
+ recorded_at: Sun, 12 Mar 2017 09:09:24 GMT
81
111
  - request:
82
112
  method: get
83
113
  uri: http://data.crossref.org/10.7554%2Felife.01567
@@ -113,7 +143,7 @@ http_interactions:
113
143
  Server:
114
144
  - http-kit
115
145
  Date:
116
- - Wed, 22 Feb 2017 17:30:21 GMT
146
+ - Sun, 12 Mar 2017 09:09:24 GMT
117
147
  Connection:
118
148
  - close
119
149
  body:
@@ -756,5 +786,5 @@ http_interactions:
756
786
  aWNsZT4NCiAgICAgIDwvam91cm5hbD4NCiAgICA8L2Nyb3NzcmVmPg0KICA8
757
787
  L2RvaV9yZWNvcmQ+DQo8L2RvaV9yZWNvcmRzPg==
758
788
  http_version:
759
- recorded_at: Wed, 22 Feb 2017 17:30:21 GMT
789
+ recorded_at: Sun, 12 Mar 2017 09:09:25 GMT
760
790
  recorded_with: VCR 3.0.3