orcid_client 0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (110) hide show
  1. checksums.yaml +7 -0
  2. data/.env.example +10 -0
  3. data/.gitignore +42 -0
  4. data/.travis.yml +17 -0
  5. data/CHANGELOG.md +0 -0
  6. data/Gemfile +4 -0
  7. data/Gemfile.lock +115 -0
  8. data/LICENSE.md +21 -0
  9. data/README.md +45 -0
  10. data/Rakefile +5 -0
  11. data/lib/orcid_client.rb +3 -0
  12. data/lib/orcid_client/api.rb +75 -0
  13. data/lib/orcid_client/author.rb +56 -0
  14. data/lib/orcid_client/base.rb +21 -0
  15. data/lib/orcid_client/date.rb +61 -0
  16. data/lib/orcid_client/metadata.rb +128 -0
  17. data/lib/orcid_client/notification.rb +125 -0
  18. data/lib/orcid_client/version.rb +3 -0
  19. data/lib/orcid_client/work.rb +200 -0
  20. data/lib/orcid_client/work_type.rb +68 -0
  21. data/orcid_client.gemspec +37 -0
  22. data/resources/common_2.0_rc3/common-2.0_rc3.xsd +1624 -0
  23. data/resources/common_2.0_rc3/samples/common-2.0_rc3.xml +8 -0
  24. data/resources/notification_2.0_rc3/notification-custom-2.0_rc3.xsd +32 -0
  25. data/resources/notification_2.0_rc3/notification-permission-2.0_rc3.xsd +128 -0
  26. data/resources/notification_2.0_rc3/samples/notification-custom-2.0_rc3.xml +45 -0
  27. data/resources/notification_2.0_rc3/samples/notification-permission-2.0_rc3.xml +58 -0
  28. data/resources/record_2.0_rc3/activities-2.0_rc3.xsd +187 -0
  29. data/resources/record_2.0_rc3/address-2.0_rc3.xsd +73 -0
  30. data/resources/record_2.0_rc3/bulk-2.0_rc3.xsd +57 -0
  31. data/resources/record_2.0_rc3/deprecated-2.0_rc3.xsd +80 -0
  32. data/resources/record_2.0_rc3/education-2.0_rc3.xsd +96 -0
  33. data/resources/record_2.0_rc3/email-2.0_rc3.xsd +74 -0
  34. data/resources/record_2.0_rc3/employment-2.0_rc3.xsd +96 -0
  35. data/resources/record_2.0_rc3/error-2.0_rc3.xsd +84 -0
  36. data/resources/record_2.0_rc3/funding-2.0_rc3.xsd +257 -0
  37. data/resources/record_2.0_rc3/history-2.0_rc3.xsd +203 -0
  38. data/resources/record_2.0_rc3/internal-2.0_rc3.xsd +199 -0
  39. data/resources/record_2.0_rc3/keyword-2.0_rc3.xsd +72 -0
  40. data/resources/record_2.0_rc3/other-name-2.0_rc3.xsd +88 -0
  41. data/resources/record_2.0_rc3/peer-review-2.0_rc3.xsd +246 -0
  42. data/resources/record_2.0_rc3/person-2.0_rc3.xsd +98 -0
  43. data/resources/record_2.0_rc3/person-external-identifier-2.0_rc3.xsd +63 -0
  44. data/resources/record_2.0_rc3/personal-details-2.0_rc3.xsd +186 -0
  45. data/resources/record_2.0_rc3/preferences-2.0_rc3.xsd +50 -0
  46. data/resources/record_2.0_rc3/record-2.0_rc3.xsd +105 -0
  47. data/resources/record_2.0_rc3/researcher-url-2.0_rc3.xsd +90 -0
  48. data/resources/record_2.0_rc3/samples/activities-2.0_rc3.xml +236 -0
  49. data/resources/record_2.0_rc3/samples/address-2.0_rc3.xml +16 -0
  50. data/resources/record_2.0_rc3/samples/addresses-2.0_rc3.xml +32 -0
  51. data/resources/record_2.0_rc3/samples/biography-2.0_rc3.xml +10 -0
  52. data/resources/record_2.0_rc3/samples/bulk-work-2.0_rc3.json +56 -0
  53. data/resources/record_2.0_rc3/samples/bulk-work-2.0_rc3.xml +62 -0
  54. data/resources/record_2.0_rc3/samples/credit-name-2.0_rc3.xml +5 -0
  55. data/resources/record_2.0_rc3/samples/deprecated-2.0_rc3.xml +13 -0
  56. data/resources/record_2.0_rc3/samples/education-2.0_rc3.xml +30 -0
  57. data/resources/record_2.0_rc3/samples/education-full-2.0_rc3.xml +40 -0
  58. data/resources/record_2.0_rc3/samples/email-2.0_rc3.xml +16 -0
  59. data/resources/record_2.0_rc3/samples/emails-2.0_rc3.xml +31 -0
  60. data/resources/record_2.0_rc3/samples/employment-2.0_rc3.xml +30 -0
  61. data/resources/record_2.0_rc3/samples/employment-full-2.0_rc3.xml +40 -0
  62. data/resources/record_2.0_rc3/samples/error-2.0_rc3.xml +8 -0
  63. data/resources/record_2.0_rc3/samples/external-identifier-2.0_rc3.xml +20 -0
  64. data/resources/record_2.0_rc3/samples/external-identifiers-2.0_rc3.xml +36 -0
  65. data/resources/record_2.0_rc3/samples/funding-2.0_rc3.xml +65 -0
  66. data/resources/record_2.0_rc3/samples/funding-full-2.0_rc3.xml +75 -0
  67. data/resources/record_2.0_rc3/samples/history-2.0_rc3.xml +22 -0
  68. data/resources/record_2.0_rc3/samples/keyword-2.0_rc3.xml +18 -0
  69. data/resources/record_2.0_rc3/samples/keywords-2.0_rc3.xml +34 -0
  70. data/resources/record_2.0_rc3/samples/name-2.0_rc3.xml +12 -0
  71. data/resources/record_2.0_rc3/samples/other-name-2.0_rc3.xml +16 -0
  72. data/resources/record_2.0_rc3/samples/other-names-2.0_rc3.xml +31 -0
  73. data/resources/record_2.0_rc3/samples/peer-review-2.0_rc3.xml +49 -0
  74. data/resources/record_2.0_rc3/samples/peer-review-full-2.0_rc3.xml +59 -0
  75. data/resources/record_2.0_rc3/samples/person-2.0_rc3.xml +122 -0
  76. data/resources/record_2.0_rc3/samples/personal-details-2.0_rc3.xml +47 -0
  77. data/resources/record_2.0_rc3/samples/preferences-2.0_rc3.xml +4 -0
  78. data/resources/record_2.0_rc3/samples/record-2.0_rc3.xml +420 -0
  79. data/resources/record_2.0_rc3/samples/researcher-url-2.0_rc3.xml +19 -0
  80. data/resources/record_2.0_rc3/samples/researcher-urls-2.0_rc3.xml +21 -0
  81. data/resources/record_2.0_rc3/samples/search-2.0_rc3.xml +368 -0
  82. data/resources/record_2.0_rc3/samples/work-2.0_rc3.xml +49 -0
  83. data/resources/record_2.0_rc3/samples/work-full-2.0_rc3.xml +59 -0
  84. data/resources/record_2.0_rc3/search-2.0_rc3.xsd +82 -0
  85. data/resources/record_2.0_rc3/work-2.0_rc3.xsd +445 -0
  86. data/spec/api_spec.rb +59 -0
  87. data/spec/fixtures/vcr_cassettes/OrcidClient/get/should_get_works.yml +646 -0
  88. data/spec/fixtures/vcr_cassettes/OrcidClient/notifications/post/should_create_notification.yml +104 -0
  89. data/spec/fixtures/vcr_cassettes/OrcidClient/works/delete/should_delete_work.yml +38 -0
  90. data/spec/fixtures/vcr_cassettes/OrcidClient/works/get/should_get_works.yml +646 -0
  91. data/spec/fixtures/vcr_cassettes/OrcidClient/works/post/should_create_work.yml +116 -0
  92. data/spec/fixtures/vcr_cassettes/OrcidClient/works/put/should_update_work.yml +155 -0
  93. data/spec/fixtures/vcr_cassettes/OrcidClient_Notification/data.yml +44 -0
  94. data/spec/fixtures/vcr_cassettes/OrcidClient_Notification/schema/validates_data.yml +44 -0
  95. data/spec/fixtures/vcr_cassettes/OrcidClient_Notification/schema/validates_item_type_work.yml +41 -0
  96. data/spec/fixtures/vcr_cassettes/OrcidClient_Work/citation.yml +50 -0
  97. data/spec/fixtures/vcr_cassettes/OrcidClient_Work/contributors/literal.yml +47 -0
  98. data/spec/fixtures/vcr_cassettes/OrcidClient_Work/contributors/multiple_titles.yml +47 -0
  99. data/spec/fixtures/vcr_cassettes/OrcidClient_Work/contributors/valid.yml +50 -0
  100. data/spec/fixtures/vcr_cassettes/OrcidClient_Work/contributors/with_ORCID_IDs.yml +157 -0
  101. data/spec/fixtures/vcr_cassettes/OrcidClient_Work/data.yml +50 -0
  102. data/spec/fixtures/vcr_cassettes/OrcidClient_Work/publication_date.yml +50 -0
  103. data/spec/fixtures/vcr_cassettes/OrcidClient_Work/schema/validates_ORCID_IDs_for_contributors.yml +157 -0
  104. data/spec/fixtures/vcr_cassettes/OrcidClient_Work/schema/validates_data.yml +50 -0
  105. data/spec/fixtures/vcr_cassettes/OrcidClient_Work/schema/validates_work_type_data-set.yml +47 -0
  106. data/spec/fixtures/work.xml +33 -0
  107. data/spec/notification_spec.rb +42 -0
  108. data/spec/spec_helper.rb +32 -0
  109. data/spec/work_spec.rb +100 -0
  110. metadata +392 -0
@@ -0,0 +1,84 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
3
+ xmlns:sch="http://purl.oclc.org/dsdl/schematron" elementFormDefault="qualified"
4
+ targetNamespace="http://www.orcid.org/ns/error" xmlns:error="http://www.orcid.org/ns/error"
5
+ xmlns:common="http://www.orcid.org/ns/common">
6
+ <xs:annotation>
7
+ <xs:documentation>
8
+ =============================================================================
9
+
10
+ ORCID (R) Open Source
11
+ http://orcid.org
12
+
13
+ Copyright (c) 2012-2014 ORCID,
14
+ Inc.
15
+ Licensed under an MIT-Style License (MIT)
16
+ http://orcid.org/open-source-license
17
+
18
+ This copyright and license
19
+ information (including a link to the full
20
+ license)
21
+ shall be included in
22
+ its entirety in all copies or substantial portion of
23
+ the software.
24
+
25
+ =============================================================================
26
+ The schema describes the message format used for ORCID API requests
27
+ and responses.
28
+ The top level element is orcid-message.
29
+ </xs:documentation>
30
+ <xs:appinfo>
31
+ <sch:title>Schematron validation</sch:title>
32
+ <sch:ns prefix="error" uri="http://www.orcid.org/ns/error" />
33
+ </xs:appinfo>
34
+ </xs:annotation>
35
+
36
+ <xs:element name="error">
37
+ <xs:complexType>
38
+ <xs:sequence>
39
+ <xs:element name="response-code" type="xs:int">
40
+ <xs:annotation>
41
+ <xs:documentation>
42
+ The HTTP response code that was also used in the response header.
43
+ </xs:documentation>
44
+ </xs:annotation>
45
+ </xs:element>
46
+ <xs:element name="developer-message" type="xs:string">
47
+ <xs:annotation>
48
+ <xs:documentation>
49
+ Debugging information for the API client developer, e.g. schema validation
50
+ error message.
51
+ </xs:documentation>
52
+ </xs:annotation>
53
+ </xs:element>
54
+ <xs:element name="user-message" type="xs:string"
55
+ minOccurs="0">
56
+ <xs:annotation>
57
+ <xs:documentation>
58
+ An error message that would be suitable to display to the user in
59
+ the application using the ORCID API.
60
+ If possible, this will be in the language of the locale specified
61
+ by the user in ORCID.
62
+ </xs:documentation>
63
+ </xs:annotation>
64
+ </xs:element>
65
+ <xs:element name="error-code" type="xs:integer" minOccurs="0">
66
+ <xs:annotation>
67
+ <xs:documentation>
68
+ The ORCID error code that defines the specific type of error. A full
69
+ list of codes can be found at
70
+ http://support.orcid.org/knowledgebase/articles/....
71
+ </xs:documentation>
72
+ </xs:annotation>
73
+ </xs:element>
74
+ <xs:element name="more-info" type="xs:anyURI" minOccurs="0">
75
+ <xs:annotation>
76
+ <xs:documentation>
77
+ A URL of a page giving more info about the error.
78
+ </xs:documentation>
79
+ </xs:annotation>
80
+ </xs:element>
81
+ </xs:sequence>
82
+ </xs:complexType>
83
+ </xs:element>
84
+ </xs:schema>
@@ -0,0 +1,257 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
3
+ xmlns:sch="http://purl.oclc.org/dsdl/schematron" elementFormDefault="qualified"
4
+ targetNamespace="http://www.orcid.org/ns/funding" xmlns:funding="http://www.orcid.org/ns/funding"
5
+ xmlns:common="http://www.orcid.org/ns/common">
6
+ <xs:annotation>
7
+ <xs:documentation>
8
+ =============================================================================
9
+
10
+ ORCID (R) Open Source
11
+ http://orcid.org
12
+
13
+ Copyright (c) 2012-2014 ORCID,
14
+ Inc.
15
+ Licensed under an MIT-Style License (MIT)
16
+ http://orcid.org/open-source-license
17
+
18
+ This copyright and license
19
+ information (including a link to the full
20
+ license)
21
+ shall be included in
22
+ its entirety in all copies or substantial portion of
23
+ the software.
24
+
25
+ =============================================================================
26
+ The schema describes the message format used for ORCID API requests
27
+ and responses.
28
+ The top level element is orcid-message.
29
+ </xs:documentation>
30
+ <xs:appinfo>
31
+ <sch:title>Schematron validation</sch:title>
32
+ <sch:ns prefix="orcid" uri="http://www.orcid.org/ns/orcid" />
33
+ </xs:appinfo>
34
+ </xs:annotation>
35
+
36
+ <xs:import namespace="http://www.orcid.org/ns/common"
37
+ schemaLocation="../common_2.0_rc3/common-2.0_rc3.xsd" />
38
+
39
+ <xs:element name="funding">
40
+ <xs:annotation>
41
+ <xs:documentation>Funding received by the researcher or contributor.
42
+ * REQUIRED FIELDS: Funding-type, Funding-title, Funding Agency
43
+ (organization)
44
+ * The visibility attribute (private, limited or
45
+ public) can be set at
46
+ record creation, and indicates who can see this
47
+ section of
48
+ information.
49
+ * The put-code attribute is used only when
50
+ reading this element. When
51
+ updating the item, the put-code attribute
52
+ must be included to
53
+ indicate the specific record to be updated.
54
+ </xs:documentation>
55
+ </xs:annotation>
56
+ <xs:complexType>
57
+ <xs:complexContent>
58
+ <xs:extension base="common:element-summary">
59
+ <xs:sequence>
60
+ <xs:element name="type" type="funding:funding-type"
61
+ minOccurs="1" maxOccurs="1" />
62
+ <xs:element name="organization-defined-type" type="common:organization-defined-type"
63
+ minOccurs="0" maxOccurs="1" />
64
+ <xs:element name="title" type="funding:funding-title"
65
+ minOccurs="0" />
66
+ <xs:element name="short-description" type="common:short-description"
67
+ minOccurs="0" />
68
+ <xs:element name="amount" type="common:amount"
69
+ minOccurs="0" maxOccurs="1" />
70
+ <xs:element name="url" type="common:url" minOccurs="0"
71
+ maxOccurs="1" />
72
+ <xs:element ref="common:start-date" minOccurs="0"
73
+ maxOccurs="1">
74
+ <xs:annotation>
75
+ <xs:documentation>Start date for the funding.</xs:documentation>
76
+ </xs:annotation>
77
+ </xs:element>
78
+ <xs:element ref="common:end-date" minOccurs="0"
79
+ maxOccurs="1">
80
+ <xs:annotation>
81
+ <xs:documentation>End date for the funding.</xs:documentation>
82
+ </xs:annotation>
83
+ </xs:element>
84
+ <xs:element ref="common:external-ids"
85
+ minOccurs="0" />
86
+ <xs:element name="contributors" type="funding:contributors"
87
+ minOccurs="0" />
88
+ <xs:element name="organization" type="common:organization"
89
+ minOccurs="1" maxOccurs="1" />
90
+ </xs:sequence>
91
+ </xs:extension>
92
+ </xs:complexContent>
93
+ </xs:complexType>
94
+ </xs:element>
95
+
96
+ <xs:element name="summary">
97
+ <xs:complexType>
98
+ <xs:complexContent>
99
+ <xs:extension base="common:element-summary">
100
+ <xs:sequence>
101
+ <xs:element name="title" type="funding:funding-title"
102
+ minOccurs="1" />
103
+ <xs:element ref="common:external-ids"
104
+ minOccurs="0" />
105
+ <xs:element name="type" type="funding:funding-type"
106
+ minOccurs="1" maxOccurs="1" />
107
+ <xs:element ref="common:start-date" minOccurs="0"
108
+ maxOccurs="1">
109
+ <xs:annotation>
110
+ <xs:documentation>Start date for the funding.</xs:documentation>
111
+ </xs:annotation>
112
+ </xs:element>
113
+ <xs:element ref="common:end-date" minOccurs="0"
114
+ maxOccurs="1">
115
+ <xs:annotation>
116
+ <xs:documentation>End date for the funding.</xs:documentation>
117
+ </xs:annotation>
118
+ </xs:element>
119
+ </xs:sequence>
120
+ </xs:extension>
121
+ </xs:complexContent>
122
+ </xs:complexType>
123
+ </xs:element>
124
+
125
+ <xs:complexType name="funding-title">
126
+ <xs:annotation>
127
+ <xs:documentation>Container for titles of the funding.
128
+ </xs:documentation>
129
+ </xs:annotation>
130
+ <xs:sequence>
131
+ <xs:element ref="common:title">
132
+ <xs:annotation>
133
+ <xs:documentation>The main name or title of the funding.
134
+ </xs:documentation>
135
+ </xs:annotation>
136
+ </xs:element>
137
+ <xs:element ref="common:translated-title" minOccurs="0" />
138
+ </xs:sequence>
139
+ </xs:complexType>
140
+
141
+ <xs:simpleType name="funding-type">
142
+ <xs:annotation>
143
+ <xs:documentation>The type of funding, it could be grant, contract,
144
+ award or salary-award.
145
+ </xs:documentation>
146
+ </xs:annotation>
147
+
148
+ <xs:restriction base="xs:string">
149
+ <xs:enumeration value="grant" />
150
+ <xs:enumeration value="contract" />
151
+ <xs:enumeration value="award" />
152
+ <xs:enumeration value="salary-award" />
153
+ </xs:restriction>
154
+ </xs:simpleType>
155
+ <!--
156
+ <xs:complexType name="external-identifiers">
157
+ <xs:annotation>
158
+ <xs:documentation>Container for storing the external references to
159
+ the funding.
160
+ </xs:documentation>
161
+ </xs:annotation>
162
+ <xs:sequence>
163
+ <xs:element maxOccurs="unbounded" minOccurs="0"
164
+ name="externalIdentifier" type="funding:external-identifier" />
165
+ </xs:sequence>
166
+ </xs:complexType>
167
+
168
+ <xs:complexType name="external-identifier">
169
+ <xs:annotation>
170
+ <xs:documentation>An external identifier that uniquely represents the
171
+ funding. Includes an identifier type and value as well as a URL for
172
+ a link to more information about the funding.
173
+ </xs:documentation>
174
+ </xs:annotation>
175
+ <xs:complexContent>
176
+ <xs:extension base="common:external-identifier">
177
+ <xs:sequence>
178
+ <xs:element name="external-identifier-type" type="funding:external-identifier-type"
179
+ minOccurs="1" maxOccurs="1" />
180
+ <xs:element name="external-identifier-value" type="common:string-2084"
181
+ minOccurs="0" maxOccurs="1">
182
+ <xs:annotation>
183
+ <xs:documentation>Value of the external identifier.</xs:documentation>
184
+ </xs:annotation>
185
+ </xs:element>
186
+ </xs:sequence>
187
+ </xs:extension>
188
+ </xs:complexContent>
189
+ </xs:complexType>
190
+
191
+ <xs:simpleType name="external-identifier-type">
192
+ <xs:annotation>
193
+ <xs:documentation>The type of the funding external identifier.
194
+ Currently only grant number is supported.
195
+ </xs:documentation>
196
+ </xs:annotation>
197
+ <xs:restriction base="xs:string">
198
+ <xs:enumeration value="grant_number" />
199
+ </xs:restriction>
200
+ </xs:simpleType>
201
+ -->
202
+ <xs:complexType name="contributors">
203
+ <xs:annotation>
204
+ <xs:documentation>Container for the contributors of a funding.
205
+ </xs:documentation>
206
+ </xs:annotation>
207
+ <xs:sequence>
208
+ <xs:element maxOccurs="unbounded" minOccurs="0" name="contributor"
209
+ type="funding:contributor" />
210
+ </xs:sequence>
211
+ </xs:complexType>
212
+
213
+ <xs:complexType name="contributor">
214
+ <xs:annotation>
215
+ <xs:documentation>A collaborator or other contributor to a work or
216
+ other orcid-activity
217
+ </xs:documentation>
218
+ </xs:annotation>
219
+ <xs:sequence>
220
+ <xs:element ref="common:contributor-orcid" minOccurs="0"
221
+ maxOccurs="1" />
222
+ <xs:element name="credit-name" type="common:credit-name"
223
+ minOccurs="0" maxOccurs="1" />
224
+ <xs:element name="contributor-email" type="common:contributor-email"
225
+ minOccurs="0" maxOccurs="1" />
226
+ <xs:element name="contributor-attributes" type="funding:contributor-attributes"
227
+ minOccurs="0" maxOccurs="1" />
228
+ </xs:sequence>
229
+ </xs:complexType>
230
+
231
+ <xs:complexType name="contributor-attributes">
232
+ <xs:annotation>
233
+ <xs:documentation>Provides detail of the nature of the contribution
234
+ by the collaborator or other contirbutor.
235
+ </xs:documentation>
236
+ </xs:annotation>
237
+ <xs:sequence>
238
+ <xs:element name="contributor-role" type="funding:contributor-role"
239
+ minOccurs="0" />
240
+ </xs:sequence>
241
+ </xs:complexType>
242
+
243
+ <xs:simpleType name="contributor-role">
244
+ <xs:annotation>
245
+ <xs:documentation>The role performed by the collaborator or other
246
+ contributor.
247
+ </xs:documentation>
248
+ </xs:annotation>
249
+ <xs:restriction base="xs:string">
250
+ <xs:enumeration value="lead" />
251
+ <xs:enumeration value="co-lead" />
252
+ <xs:enumeration value="supported-by" />
253
+ <xs:enumeration value="other-contribution" />
254
+ </xs:restriction>
255
+ </xs:simpleType>
256
+
257
+ </xs:schema>
@@ -0,0 +1,203 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
3
+ xmlns:sch="http://purl.oclc.org/dsdl/schematron" elementFormDefault="qualified"
4
+ targetNamespace="http://www.orcid.org/ns/history" xmlns:history="http://www.orcid.org/ns/history"
5
+ xmlns:common="http://www.orcid.org/ns/common">
6
+ <xs:annotation>
7
+ <xs:documentation>
8
+ =============================================================================
9
+
10
+ ORCID (R) Open Source
11
+ http://orcid.org
12
+
13
+ Copyright (c) 2012-2014 ORCID,
14
+ Inc.
15
+ Licensed under an MIT-Style License (MIT)
16
+ http://orcid.org/open-source-license
17
+
18
+ This copyright and license
19
+ information (including a link to the full
20
+ license)
21
+ shall be included in
22
+ its entirety in all copies or substantial portion of
23
+ the software.
24
+
25
+ =============================================================================
26
+ The schema describes the message format used for ORCID API requests
27
+ and responses.
28
+ The top level element is orcid-message.
29
+ </xs:documentation>
30
+ <xs:appinfo>
31
+ <sch:title>Schematron validation</sch:title>
32
+ <sch:ns prefix="orcid" uri="http://www.orcid.org/ns/orcid" />
33
+ </xs:appinfo>
34
+ </xs:annotation>
35
+
36
+ <xs:import namespace="http://www.orcid.org/ns/common"
37
+ schemaLocation="../common_2.0_rc3/common-2.0_rc3.xsd" />
38
+
39
+ <xs:element name="history">
40
+ <xs:complexType>
41
+ <xs:annotation>
42
+ <xs:documentation>A simple history of the researcher or
43
+ contributor's
44
+ ORCID Record. The visibility attribute (private, limited or public)
45
+ can be set at record creation, and indicates who can see this
46
+ section of information.
47
+ </xs:documentation>
48
+ </xs:annotation>
49
+ <xs:sequence>
50
+ <xs:element name="creation-method" type="history:creation-method"
51
+ minOccurs="0" maxOccurs="1">
52
+ <xs:annotation>
53
+ <xs:documentation>The method used to create the ORCID Record
54
+ * API
55
+ method - Institution created the record on behalf of the
56
+ individual
57
+ * Direct method - Individual registered directly at
58
+ orcid.org
59
+ * Member-referrred method - Individual registered as
60
+ part
61
+ of a workflow such as submitting a manuscript or applying
62
+ for a
63
+ grant
64
+ </xs:documentation>
65
+ </xs:annotation>
66
+ </xs:element>
67
+ <xs:element name="completion-date" type="history:completion-date"
68
+ minOccurs="0" maxOccurs="1" />
69
+ <xs:element name="submission-date" type="history:submission-date"
70
+ minOccurs="0" maxOccurs="1" />
71
+ <xs:element ref="common:last-modified-date"
72
+ minOccurs="0" maxOccurs="1" />
73
+ <xs:element name="claimed" type="history:claimed" minOccurs="0"
74
+ maxOccurs="1" />
75
+ <xs:element ref="common:source" minOccurs="0" maxOccurs="1" />
76
+ <xs:element name="deactivation-date" type="history:deactivation-date"
77
+ minOccurs="0" maxOccurs="1" />
78
+ <xs:element name="verified-email" type="xs:boolean"
79
+ minOccurs="1" maxOccurs="1">
80
+ <xs:annotation>
81
+ <xs:documentation>True if the user has a verified email
82
+ </xs:documentation>
83
+ </xs:annotation>
84
+ </xs:element>
85
+ <xs:element name="verified-primary-email" type="xs:boolean"
86
+ minOccurs="1" maxOccurs="1">
87
+ <xs:annotation>
88
+ <xs:documentation>True if the user's current primary email is
89
+ verified
90
+ </xs:documentation>
91
+ </xs:annotation>
92
+ </xs:element>
93
+ </xs:sequence>
94
+ <xs:attribute name="visibility" type="common:visibility" />
95
+ </xs:complexType>
96
+ </xs:element>
97
+
98
+ <xs:complexType name="completion-date">
99
+ <xs:annotation>
100
+ <xs:documentation>The date and time when the ORCID Record set up was
101
+ completed.
102
+ </xs:documentation>
103
+ </xs:annotation>
104
+ <xs:simpleContent>
105
+ <xs:extension base="xs:dateTime" />
106
+ </xs:simpleContent>
107
+ </xs:complexType>
108
+
109
+ <xs:complexType name="submission-date">
110
+ <xs:annotation>
111
+ <xs:documentation>The date time when the ORCID Record and iD was
112
+ first created.
113
+ </xs:documentation>
114
+ </xs:annotation>
115
+ <xs:simpleContent>
116
+ <xs:extension base="xs:dateTime" />
117
+ </xs:simpleContent>
118
+ </xs:complexType>
119
+
120
+ <xs:complexType name="claimed">
121
+ <xs:annotation>
122
+ <xs:documentation>True if the researcher or contributor has added a
123
+ password
124
+ to assume ownership of their ORCID Record after bulk
125
+ creation
126
+ by their institution.
127
+ </xs:documentation>
128
+ </xs:annotation>
129
+ <xs:simpleContent>
130
+ <xs:extension base="xs:boolean" />
131
+ </xs:simpleContent>
132
+ </xs:complexType>
133
+
134
+ <xs:complexType name="deactivation-date">
135
+ <xs:annotation>
136
+ <xs:documentation>The date and time when the ORCID Record was
137
+ deactivated. (If the account is active, this field will be NULL.)
138
+ </xs:documentation>
139
+ </xs:annotation>
140
+ <xs:simpleContent>
141
+ <xs:extension base="xs:dateTime" />
142
+ </xs:simpleContent>
143
+ </xs:complexType>
144
+
145
+ <xs:complexType mixed="true" name="source-reference">
146
+ <xs:annotation>
147
+ <xs:documentation>(UNUSED) The identifier or other reference
148
+ information for the researcher or contributor in the source client
149
+ application (Member Organization's) system.
150
+ </xs:documentation>
151
+ </xs:annotation>
152
+ </xs:complexType>
153
+
154
+ <xs:complexType name="source-date">
155
+ <xs:annotation>
156
+ <xs:documentation>The date time that the source client application
157
+ (Member organization system) or individual user created/attempted to
158
+ create the item.
159
+ </xs:documentation>
160
+ </xs:annotation>
161
+ <xs:simpleContent>
162
+ <xs:extension base="xs:dateTime" />
163
+ </xs:simpleContent>
164
+ </xs:complexType>
165
+
166
+ <xs:simpleType name="creation-method">
167
+ <xs:annotation>
168
+ <xs:documentation>Indicates how the ORCID record and iD were created.
169
+ </xs:documentation>
170
+ </xs:annotation>
171
+ <xs:restriction base="common:non-empty-string">
172
+ <xs:enumeration value="API">
173
+ <xs:annotation>
174
+ <xs:documentation>The ORCID Record was created using the ORCID
175
+ Member API.
176
+ </xs:documentation>
177
+ </xs:annotation>
178
+ </xs:enumeration>
179
+ <xs:enumeration value="Direct">
180
+ <xs:annotation>
181
+ <xs:documentation>The user registered on the /register page.
182
+ </xs:documentation>
183
+ </xs:annotation>
184
+ </xs:enumeration>
185
+ <xs:enumeration value="Member-referred">
186
+ <xs:annotation>
187
+ <xs:documentation>The registered on the /oauth/signin.
188
+ </xs:documentation>
189
+ </xs:annotation>
190
+ </xs:enumeration>
191
+ <xs:enumeration value="website">
192
+ <xs:annotation>
193
+ <xs:documentation>DEPRECATED use Direct or Member-referred
194
+ instead.
195
+ The method used to create the ORCID Record (Website or
196
+ API).
197
+ </xs:documentation>
198
+ </xs:annotation>
199
+ </xs:enumeration>
200
+ </xs:restriction>
201
+ </xs:simpleType>
202
+
203
+ </xs:schema>