Skip to main content
Version: 2.x (upcoming)

Reference type recipes

Three complete reference type configurations, from the fields to the source. The request, search rules, and mapping settings they use are described in Connecting to an external API. The researcher and license recipes use the codes researchers and licenses, which repositories read when a plan is published; see Reference types the repository reads.


ORCID researchers (JSON API source)​

A reference type for Researchers that uses the ORCID public API, which needs no authentication.

About this reference type​

FieldValue
NameResearchers
Coderesearchers

Fields​

LabelCodeData TypeRequired
First Namefirst_nameTextYes
Last Namelast_nameTextYes
ORCID iDorcid_idTextNo

Source​

Add a source with Search an API:

FieldValue
Shown to users asORCID Public API
Keyorcid

Request​

FieldValue
MethodGET
URLhttps://pub.orcid.org/v3.0/expanded-search/?q={like}&start={page}&rows={pageSize}
First page number0
Content-Typeapplication/json
Header ACCEPTapplication/json

Search rules​

SettingValue
Who filters the resultsThe API
Placeholderlike
Rule 1Condition is anything, value to send {like}
No rule matches: Send instead*

Test and map​

SettingValue
Response formatJSON
Results are in$.expanded-result
Total count is in$.num-found
FieldPath in the reply
Reference ID$.orcid-id
Name@{{given-names}} @{{family-names}}
Description(leave empty)
First Name$.given-names
Last Name$.family-names
ORCID iD$.orcid-id

Display​

SettingValue
Link URLhttps://orcid.org/{reference_id}

re3data repositories (XML API source)​

A reference type for Repositories that uses the re3data public API, which returns XML.

About this reference type​

FieldValue
NameRepository
Coderepository

Fields​

LabelCodeData TypeRequired
DOIdoiTextNo

Source and request​

FieldValue
Shown to users asre3data Repositories
Keyre3data
MethodGET
URLhttps://www.re3data.org/api/beta/repositories?query={like}
Content-Typeapplication/xml

Search rules​

SettingValue
Placeholderlike
Rule 1Condition is anything, value to send {like}
No rule matches: Send instead*

Test and map​

SettingValue
Response formatXML
Results are in//repository
FieldPath in the reply
Reference ID./id/text()
Name./name/text()
Description(leave empty)
DOI./doi/text()
tip

A sample re3data response. It has no namespace declarations, so plain XPath such as //repository works:

<list>
<repository>
<id>r3d100012890</id>
<doi>https://doi.org/10.17616/R3JZ3J</doi>
<name>World Ocean Atlas</name>
<link href="https://www.re3data.org/api/beta/repository/r3d100012890" rel="self" />
</repository>
...
</list>

Licenses (fixed list)​

A reference type for Licenses that uses a fixed list, with no external API connection.

About this reference type​

FieldValue
NameLicenses
Codelicenses

Fields​

No custom fields are needed. The built-in Reference ID, Name, and Description fields are sufficient for a simple license list.

Source​

Add a source with Fixed list:

FieldValue
Shown to users asStandard Licenses
Keystatic-licenses

Entries​

Reference IDNameDescription
cc-by-4.0CC BY 4.0Attribution
cc-by-sa-4.0CC BY-SA 4.0Attribution-ShareAlike
cc-by-nc-4.0CC BY-NC 4.0Attribution-NonCommercial
cc0-1.0CC0 1.0Public Domain Dedication
mitMIT LicensePermissive software license
apache-2.0Apache License 2.0Permissive software license with a patent grant

See also​