Configuration and exmaple endpoints

Here are the configuration and example endpoints. The response type provides the XML schema name for the format of the responses provided by the endpoint.

Introduction to the configuration endpoints

The configs endpoint provides information on the URL parameters, and the searchable fields and sortable fields available for a specific endpoint.

For example, the configuration for the projects endpoint can be obtained by issuing a GET request to https://gtr.ukri.org/gtr/api/configs/projects. The following is an example of the response to the requested, with some items in the various lists truncated to save space.

<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<resourceConfig xmlns="http://gtr.ukri.org/gtr/api">
    <parameters>
        <parameter>
            <value>q</value>
            <description>Query term, q=search_term</description>
        </parameter>
        <parameter>
            <value>p</value>
            <description>Page of result set, starting at 1, p=1</description>
        </parameter>
        <parameter>
            <value>s</value>
            <description>Size of page between 10 and 100, defaulted to s=20</description>
        </parameter>
        <parameter>
            <value>f</value>
            <description>Search fields - see fields section for field codes, f=pro.t&f=pro.orcidId</description>
        </parameter>
        <parameter>
            <value>sf</value>
            <description>Sort field - see fields section for field codes, sf=score</description>
        </parameter>
        <parameter>
            <value>so</value>
            <description>Sort order A (ascending) or D (descending), so=A</description>
        </parameter>
    </parameters>
    <fields>
        <field>
            <code>pro.gr</code>
            <description>Project Reference</description>
            <searchable>true</searchable>
            <sortable>false</sortable>
            <searchedByDefault>true</searchedByDefault>
        </field>
        <field>
            <code>pro.t</code>
            <description>Project Title</description>
            <searchable>true</searchable>
            <sortable>false</sortable>
            <searchedByDefault>true</searchedByDefault>
        </field>
        <field>
            <code>pro.a</code>
            <description>Project Abstract</description>
            <searchable>true</searchable>
            <sortable>false</sortable>
            <searchedByDefault>true</searchedByDefault>
        </field>
        <!-- ... -->
    </fields>
</resourceConfig>

Example endpoint

Example endpoint Description

Retrieves examples of all endpoints

Example endpoint URL

https://gtr.ukri.org/gtr/api/examples

Example endpoint Response type

gtr:endpointConfig

Configuration endpoint

Configuration endpoint Description

Retrieves information about the parameters for a resource endpoint, where <resource> should be replaced with the name of a GtR resource, for example funds, projects, persons, keyfindings etc.

Configuration endpoint URL

https://gtr.ukri.org/gtr/api/configs/<resource>

Configuration endpoint Response type

gtr:endpointConfig