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,8 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <common:application-group-orcid
3
+ xmlns:common="http://www.orcid.org/ns/common" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4
+ xsi:schemaLocation="http://www.orcid.org/ns/common ../common-2.0_rc3.xsd ">
5
+ <common:uri>http://orcid.org/8888-8888-8888-8880</common:uri>
6
+ <common:path>8888-8888-8888-8880</common:path>
7
+ <common:host>orcid.org</common:host>
8
+ </common:application-group-orcid>
@@ -0,0 +1,32 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <xs:schema attributeFormDefault="unqualified" elementFormDefault="qualified"
3
+ targetNamespace="http://www.orcid.org/ns/notification" xmlns:notification="http://www.orcid.org/ns/notification"
4
+ xmlns:common="http://www.orcid.org/ns/common"
5
+ xmlns:xs="http://www.w3.org/2001/XMLSchema"
6
+ xmlns:vc="http://www.w3.org/2007/XMLSchema-versioning" vc:minVersion="1.1">
7
+ <xs:import namespace="http://www.orcid.org/ns/common" schemaLocation="../common_2.0_rc3/common-2.0_rc3.xsd" />
8
+ <xs:import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="../xml.xsd"/>
9
+ <xs:element name="notification">
10
+ <xs:complexType>
11
+ <xs:sequence>
12
+ <xs:element name="notification-type">
13
+ <xs:simpleType>
14
+ <xs:restriction base="xs:string">
15
+ <xs:enumeration value="custom"/>
16
+ </xs:restriction>
17
+ </xs:simpleType>
18
+ </xs:element>
19
+ <xs:element type="xs:string" name="subject"/>
20
+ <xs:element type="xs:string" name="body-text"/>
21
+ <xs:element type="xs:string" name="body-html"/>
22
+ <xs:element ref="common:created-date" minOccurs="0"/>
23
+ <xs:element ref="common:sent-date"/>
24
+ <xs:element ref="common:read-date" minOccurs="0"/>
25
+ <xs:element ref="common:archived-date" minOccurs="0"/>
26
+ <xs:element ref="common:source" minOccurs="0"/>
27
+ </xs:sequence>
28
+ <xs:attribute name="put-code" type="common:put-code" use="optional" />
29
+ <xs:attribute ref="xml:lang" use="optional" />
30
+ </xs:complexType>
31
+ </xs:element>
32
+ </xs:schema>
@@ -0,0 +1,128 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <xs:schema attributeFormDefault="unqualified"
3
+ elementFormDefault="qualified" targetNamespace="http://www.orcid.org/ns/notification"
4
+ xmlns:notification="http://www.orcid.org/ns/notification" xmlns:common="http://www.orcid.org/ns/common"
5
+ xmlns:activities="http://www.orcid.org/ns/activities" xmlns:xs="http://www.w3.org/2001/XMLSchema"
6
+ xmlns:vc="http://www.w3.org/2007/XMLSchema-versioning" vc:minVersion="1.1">
7
+ <xs:import namespace="http://www.orcid.org/ns/common"
8
+ schemaLocation="../common_2.0_rc3/common-2.0_rc3.xsd" />
9
+ <xs:import namespace="http://www.orcid.org/ns/activities"
10
+ schemaLocation="../record_2.0_rc3/activities-2.0_rc3.xsd" />
11
+
12
+ <xs:element name="notifications">
13
+ <xs:annotation>
14
+ <xs:documentation>Notification container</xs:documentation>
15
+ </xs:annotation>
16
+ <xs:complexType>
17
+ <xs:sequence>
18
+ <xs:element name="notification" type="notification:notification"
19
+ minOccurs="0" maxOccurs="unbounded" />
20
+ </xs:sequence>
21
+ </xs:complexType>
22
+ </xs:element>
23
+
24
+ <xs:element name="notification">
25
+ <xs:annotation>
26
+ <xs:documentation>Notification element
27
+ </xs:documentation>
28
+ </xs:annotation>
29
+ <xs:complexType>
30
+ <xs:complexContent>
31
+ <xs:extension base="notification:notification"></xs:extension>
32
+ </xs:complexContent>
33
+ </xs:complexType>
34
+ </xs:element>
35
+
36
+ <xs:complexType name="notification">
37
+ <xs:sequence>
38
+ <xs:element name="notification-type" type="notification:notification-type" />
39
+ <xs:element name="authorization-url" type="notification:authorization-url" />
40
+ <xs:element ref="notification:notification-subject" />
41
+ <xs:element ref="notification:notification-intro" />
42
+ <xs:element name="items" type="notification:items" />
43
+ <xs:element ref="common:created-date" minOccurs="0" />
44
+ <xs:element ref="common:sent-date" minOccurs="0" />
45
+ <xs:element ref="common:read-date" minOccurs="0" />
46
+ <xs:element name="actioned-date" type="notification:actioned-date"
47
+ minOccurs="0" />
48
+ <xs:element ref="common:archived-date" minOccurs="0" />
49
+ <xs:element ref="common:source" minOccurs="0" />
50
+ </xs:sequence>
51
+ <xs:attribute name="put-code" type="common:put-code"
52
+ use="optional" />
53
+ </xs:complexType>
54
+
55
+ <xs:simpleType name="notification-type">
56
+ <xs:restriction base="xs:string">
57
+ <xs:enumeration value="permission" />
58
+ </xs:restriction>
59
+ </xs:simpleType>
60
+
61
+ <xs:complexType name="authorization-url">
62
+ <xs:sequence>
63
+ <xs:choice>
64
+ <xs:sequence>
65
+ <xs:element name="uri" type="xs:anyURI" />
66
+ <xs:element name="path" type="xs:string" minOccurs="0" />
67
+ </xs:sequence>
68
+ <xs:element name="path" type="xs:string" />
69
+ </xs:choice>
70
+ <xs:element name="host" type="xs:string" minOccurs="0" />
71
+ </xs:sequence>
72
+ </xs:complexType>
73
+
74
+ <xs:element name="notification-subject">
75
+ <xs:annotation>
76
+ <xs:documentation>The subject line for the message (displayed to the
77
+ end user)
78
+ </xs:documentation>
79
+ </xs:annotation>
80
+ <xs:simpleType>
81
+ <xs:restriction base="xs:string" />
82
+ </xs:simpleType>
83
+ </xs:element>
84
+ <xs:element name="notification-intro">
85
+ <xs:annotation>
86
+ <xs:documentation>A text-only introductory message to be displayed to
87
+ the end user, and displayed before the example list of items.
88
+ </xs:documentation>
89
+ </xs:annotation>
90
+ <xs:simpleType>
91
+ <xs:restriction base="xs:string">
92
+ <xs:maxLength value="1000" />
93
+ </xs:restriction>
94
+ </xs:simpleType>
95
+ </xs:element>
96
+ <xs:complexType name="items">
97
+ <xs:sequence>
98
+ <xs:element name="item" type="notification:item"
99
+ maxOccurs="unbounded" />
100
+ </xs:sequence>
101
+ </xs:complexType>
102
+ <xs:complexType name="item">
103
+ <xs:sequence>
104
+ <xs:element name="item-type" type="notification:activity-type" />
105
+ <xs:element name="item-name" type="xs:string" />
106
+ <xs:element ref="common:external-id" minOccurs="0" />
107
+ </xs:sequence>
108
+ </xs:complexType>
109
+ <xs:simpleType name="activity-type">
110
+ <xs:restriction base="xs:string">
111
+ <xs:enumeration value="education"></xs:enumeration>
112
+ <xs:enumeration value="employment"></xs:enumeration>
113
+ <xs:enumeration value="funding"></xs:enumeration>
114
+ <xs:enumeration value="work"></xs:enumeration>
115
+ <xs:enumeration value="peer-review"></xs:enumeration>
116
+ </xs:restriction>
117
+ </xs:simpleType>
118
+ <xs:complexType name="actioned-date">
119
+ <xs:annotation>
120
+ <xs:documentation>The date time when the user took action on the
121
+ notification.
122
+ </xs:documentation>
123
+ </xs:annotation>
124
+ <xs:simpleContent>
125
+ <xs:extension base="xs:dateTime" />
126
+ </xs:simpleContent>
127
+ </xs:complexType>
128
+ </xs:schema>
@@ -0,0 +1,45 @@
1
+ <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
2
+ <!--
3
+
4
+ =============================================================================
5
+
6
+ ORCID (R) Open Source
7
+ http://orcid.org
8
+
9
+ Copyright (c) 2012-2014 ORCID, Inc.
10
+ Licensed under an MIT-Style License (MIT)
11
+ http://orcid.org/open-source-license
12
+
13
+ This copyright and license information (including a link to the full license)
14
+ shall be included in its entirety in all copies or substantial portion of
15
+ the software.
16
+
17
+ =============================================================================
18
+
19
+ -->
20
+ <notification:notification put-code="1"
21
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
22
+ xsi:schemaLocation="http://www.orcid.org/ns/notification ../notification-custom-2.0_rc3.xsd"
23
+ xmlns:notification="http://www.orcid.org/ns/notification"
24
+ xmlns:common="http://www.orcid.org/ns/common"
25
+ xml:lang="en-gb">
26
+ <notification:notification-type>custom</notification:notification-type>
27
+ <notification:subject>Important Notification from ORCID</notification:subject>
28
+ <notification:body-text>This is an email with important info.
29
+ </notification:body-text>
30
+ <notification:body-html><![CDATA[
31
+ <p>
32
+ This is an email with <em>important</em> info.
33
+ </p>]]>
34
+ </notification:body-html>
35
+ <common:created-date>2014-01-01T09:17:56</common:created-date>
36
+ <common:sent-date>2014-01-01T14:45:32</common:sent-date>
37
+ <common:source>
38
+ <common:source-orcid>
39
+ <common:uri>http://orcid.org/2111-1111-1111-1114</common:uri>
40
+ <common:path>2111-1111-1111-1114</common:path>
41
+ <common:host>orcid.org</common:host>
42
+ </common:source-orcid>
43
+ <common:source-name>Member 1</common:source-name>
44
+ </common:source>
45
+ </notification:notification>
@@ -0,0 +1,58 @@
1
+ <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
2
+ <!--
3
+
4
+ =============================================================================
5
+
6
+ ORCID (R) Open Source
7
+ http://orcid.org
8
+
9
+ Copyright (c) 2012-2014 ORCID, Inc.
10
+ Licensed under an MIT-Style License (MIT)
11
+ http://orcid.org/open-source-license
12
+
13
+ This copyright and license information (including a link to the full license)
14
+ shall be included in its entirety in all copies or substantial portion of
15
+ the software.
16
+
17
+ =============================================================================
18
+
19
+ -->
20
+ <notification:notification put-code="1" xsi:schemaLocation="http://www.orcid.org/ns/notification ../notification-permission-2.0_rc3.xsd" xmlns:common="http://www.orcid.org/ns/common" xmlns:notification="http://www.orcid.org/ns/notification" xmlns:activities="http://www.orcid.org/ns/activities" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
21
+ <notification:notification-type>permission</notification:notification-type>
22
+ <notification:authorization-url>
23
+ <!-- API user can specify just the path if they want, and leave out the uri element. -->
24
+ <notification:uri>https://orcid.org/oauth/authorize?client_id=APP-U4UKCNSSIM1OCVQY&amp;response_type=code&amp;scope=/orcid-works/create&amp;redirect_uri=http://somethirdparty.com</notification:uri>
25
+ <notification:path>/oauth/authorize?client_id=APP-U4UKCNSSIM1OCVQY&amp;response_type=code&amp;scope=/orcid-works/create&amp;redirect_uri=http://somethirdparty.com</notification:path>
26
+ <notification:host>orcid.org</notification:host>
27
+ </notification:authorization-url>
28
+ <notification:notification-subject>Subject</notification:notification-subject>
29
+ <notification:notification-intro>Intro</notification:notification-intro>
30
+ <notification:items>
31
+ <notification:item>
32
+ <notification:item-type>work</notification:item-type>
33
+ <notification:item-name>A Really Interesting Research Article</notification:item-name>
34
+ <common:external-id>
35
+ <common:external-id-type>doi</common:external-id-type>
36
+ <common:external-id-value>http://10.5555/12345ABCDE</common:external-id-value>
37
+ <common:external-id-relationship>self</common:external-id-relationship>
38
+ </common:external-id>
39
+ </notification:item>
40
+ <notification:item>
41
+ <notification:item-type>employment</notification:item-type>
42
+ <notification:item-name>Head of Research at NanoBiologica</notification:item-name>
43
+ </notification:item>
44
+ </notification:items>
45
+ <!-- Read only for API user -->
46
+ <common:created-date>2014-01-01T09:17:56</common:created-date>
47
+ <!-- Read only for API user -->
48
+ <common:sent-date>2014-01-01T14:45:32</common:sent-date>
49
+ <common:source>
50
+ <!-- Read only for API user - will only be able to see notifications for which they are the source -->
51
+ <common:source-client-id>
52
+ <common:uri>http://orcid.org/client/APP-U4UKCNSSIM1OCVQY</common:uri>
53
+ <common:path>APP-U4UKCNSSIM1OCVQY</common:path>
54
+ <common:host>orcid.org</common:host>
55
+ </common:source-client-id>
56
+ <common:source-name>Member 1</common:source-name>
57
+ </common:source>
58
+ </notification:notification>
@@ -0,0 +1,187 @@
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/activities"
5
+ xmlns:activities="http://www.orcid.org/ns/activities"
6
+ xmlns:common="http://www.orcid.org/ns/common"
7
+ xmlns:work="http://www.orcid.org/ns/work"
8
+ xmlns:funding="http://www.orcid.org/ns/funding"
9
+ xmlns:education="http://www.orcid.org/ns/education"
10
+ xmlns:employment="http://www.orcid.org/ns/employment"
11
+ xmlns:peer-review="http://www.orcid.org/ns/peer-review">
12
+ <xs:annotation>
13
+ <xs:documentation>
14
+ =============================================================================
15
+
16
+ ORCID (R) Open Source
17
+ http://orcid.org
18
+
19
+ Copyright (c) 2012-2014 ORCID,
20
+ Inc.
21
+ Licensed under an MIT-Style License (MIT)
22
+ http://orcid.org/open-source-license
23
+
24
+ This copyright and license
25
+ information (including a link to the full
26
+ license)
27
+ shall be included in
28
+ its entirety in all copies or substantial portion of
29
+ the software.
30
+
31
+ =============================================================================
32
+ The schema describes the message format used for ORCID API requests
33
+ and responses.
34
+ The top level element is orcid-message.
35
+ </xs:documentation>
36
+ <xs:appinfo>
37
+ <sch:title>Schematron validation</sch:title>
38
+ <sch:ns prefix="orcid" uri="http://www.orcid.org/ns/orcid" />
39
+ </xs:appinfo>
40
+ </xs:annotation>
41
+
42
+ <xs:import namespace="http://www.orcid.org/ns/common"
43
+ schemaLocation="../common_2.0_rc3/common-2.0_rc3.xsd" />
44
+ <xs:import namespace="http://www.orcid.org/ns/employment"
45
+ schemaLocation="employment-2.0_rc3.xsd" />
46
+ <xs:import namespace="http://www.orcid.org/ns/education"
47
+ schemaLocation="education-2.0_rc3.xsd" />
48
+ <xs:import namespace="http://www.orcid.org/ns/funding"
49
+ schemaLocation="funding-2.0_rc3.xsd" />
50
+ <xs:import namespace="http://www.orcid.org/ns/work"
51
+ schemaLocation="work-2.0_rc3.xsd" />
52
+ <xs:import namespace="http://www.orcid.org/ns/peer-review"
53
+ schemaLocation="peer-review-2.0_rc3.xsd" />
54
+
55
+ <xs:element name="activities-summary">
56
+ <xs:complexType>
57
+ <xs:sequence>
58
+ <xs:element ref="common:last-modified-date" minOccurs="0" maxOccurs="1" />
59
+
60
+ <xs:element name="educations" type="activities:educations" minOccurs="0" maxOccurs="1">
61
+ <xs:annotation>
62
+ <xs:documentation>Container for the list of educations associated
63
+ with the researcher or contributor
64
+ </xs:documentation>
65
+ </xs:annotation>
66
+ </xs:element>
67
+
68
+ <xs:element name="employments" type="activities:employments" minOccurs="0" maxOccurs="1">
69
+ <xs:annotation>
70
+ <xs:documentation>Container for the list of employments associated
71
+ with the researcher or contributor
72
+ </xs:documentation>
73
+ </xs:annotation>
74
+ </xs:element>
75
+
76
+ <xs:element name="fundings" minOccurs="0" maxOccurs="1">
77
+ <xs:annotation>
78
+ <xs:documentation>Container for the funding received by the
79
+ researcher or contributor
80
+ </xs:documentation>
81
+ </xs:annotation>
82
+ <xs:complexType>
83
+ <xs:sequence>
84
+ <xs:element ref="common:last-modified-date" minOccurs="0" maxOccurs="1" />
85
+ <xs:element maxOccurs="unbounded" minOccurs="0" name="group"
86
+ type="activities:funding-group" />
87
+ </xs:sequence>
88
+ </xs:complexType>
89
+ </xs:element>
90
+ <xs:element name="peer-reviews" minOccurs="0" maxOccurs="1">
91
+ <xs:annotation>
92
+ <xs:documentation>Container for the funding received by the
93
+ researcher or contributor
94
+ </xs:documentation>
95
+ </xs:annotation>
96
+ <xs:complexType>
97
+ <xs:sequence>
98
+ <xs:element ref="common:last-modified-date" minOccurs="0" maxOccurs="1" />
99
+ <xs:element maxOccurs="unbounded" minOccurs="0" name="group"
100
+ type="activities:peer-review-group" />
101
+ </xs:sequence>
102
+ </xs:complexType>
103
+ </xs:element>
104
+ <xs:element name="works" minOccurs="0" maxOccurs="1">
105
+ <xs:annotation>
106
+ <xs:documentation>Container for the Works published by the
107
+ researcher
108
+ or contributor.
109
+ </xs:documentation>
110
+ </xs:annotation>
111
+ <xs:complexType>
112
+ <xs:sequence>
113
+ <xs:element ref="common:last-modified-date" minOccurs="0" maxOccurs="1" />
114
+ <xs:element maxOccurs="unbounded" minOccurs="0" name="group"
115
+ type="activities:work-group" />
116
+ </xs:sequence>
117
+ </xs:complexType>
118
+ </xs:element>
119
+ </xs:sequence>
120
+ </xs:complexType>
121
+ </xs:element>
122
+
123
+ <xs:complexType name="educations">
124
+ <xs:sequence>
125
+ <xs:element ref="common:last-modified-date" minOccurs="0" maxOccurs="1" />
126
+ <xs:element maxOccurs="unbounded" minOccurs="0"
127
+ ref="education:education-summary" />
128
+ </xs:sequence>
129
+ </xs:complexType>
130
+
131
+ <xs:element name="educations">
132
+ <xs:complexType>
133
+ <xs:complexContent>
134
+ <xs:restriction base="activities:educations" />
135
+ </xs:complexContent>
136
+ </xs:complexType>
137
+ </xs:element>
138
+
139
+ <xs:complexType name="employments">
140
+ <xs:sequence>
141
+ <xs:element ref="common:last-modified-date" minOccurs="0" maxOccurs="1" />
142
+ <xs:element maxOccurs="unbounded" minOccurs="0"
143
+ ref="employment:employment-summary" />
144
+ </xs:sequence>
145
+ </xs:complexType>
146
+
147
+ <xs:element name="employments">
148
+ <xs:complexType>
149
+ <xs:complexContent>
150
+ <xs:restriction base="activities:employments" />
151
+ </xs:complexContent>
152
+ </xs:complexType>
153
+ </xs:element>
154
+
155
+ <xs:complexType name="work-group">
156
+ <xs:sequence>
157
+ <xs:element ref="common:last-modified-date" minOccurs="0" maxOccurs="1" />
158
+ <xs:element ref="common:external-ids"></xs:element>
159
+ <xs:sequence>
160
+ <xs:element maxOccurs="unbounded" minOccurs="0"
161
+ ref="work:work-summary" />
162
+ </xs:sequence>
163
+ </xs:sequence>
164
+ </xs:complexType>
165
+
166
+ <xs:complexType name="funding-group">
167
+ <xs:sequence>
168
+ <xs:element ref="common:last-modified-date" minOccurs="0" maxOccurs="1" />
169
+ <xs:element ref="common:external-ids"></xs:element>
170
+ <xs:sequence>
171
+ <xs:element maxOccurs="unbounded" minOccurs="0"
172
+ ref="funding:summary" />
173
+ </xs:sequence>
174
+ </xs:sequence>
175
+ </xs:complexType>
176
+
177
+ <xs:complexType name="peer-review-group">
178
+ <xs:sequence>
179
+ <xs:element ref="common:last-modified-date" minOccurs="0" maxOccurs="1" />
180
+ <xs:element ref="common:external-ids"></xs:element>
181
+ <xs:sequence>
182
+ <xs:element maxOccurs="unbounded" minOccurs="0"
183
+ ref="peer-review:summary" />
184
+ </xs:sequence>
185
+ </xs:sequence>
186
+ </xs:complexType>
187
+ </xs:schema>