{{ _("Fetch your maDMPs:") }}
{{ _("Endpoint:") }} GET /api/invenio_damap/damap/dmp
{{ _("Token Required:") }} {% trans trimmed token_link = token_link %} Yes — generate one here. {% endtrans %}
cURL:
{#- ################# PREFORMATTED AREA TEXT BEGIN ################# #}
curl "{{ config.SITE_API_URL }}/invenio_damap/damap/dmp" \
-H "Authorization: Bearer {your-access-token}"
{#- ################## PREFORMATTED AREA TEXT END ################## -#}
Python (requests):
{#- ################# PREFORMATTED AREA TEXT BEGIN ################# #}
import requests
url = "{{ config.SITE_API_URL }}/invenio_damap/damap/dmp"
headers = {
"Authorization": "Bearer {your-access-token}",
}
response = requests.post(url, headers=headers)
print(response.json())
{#- ################## PREFORMATTED AREA TEXT END ################## -#}
{{ _("Example Response") }} (HTTP 200 - OK):
{#- ################# PREFORMATTED AREA TEXT BEGIN ################# #}
{
"hits": {
"hits": [
{
"id": 4002,
"created": "2025-02-10T11:28:03.472Z",
"project": {
"id": 4002,
"description": "A very important chemistry project.",
"title": "Advanced Chemical Reactions Study"
},
"datasets": [],
"links": {}
},
{
"id": 4001,
"created": "2025-01-10T14:07:26.234Z",
"project": {
"id": 4001,
"description": "A very important climate project.",
"title": "Global Climate Change Analysis"
},
"datasets": [],
"links": {}
}
],
"total": 10
},
"links": {
"self": "{{ config.SITE_API_URL }}/invenio_damap/damap/dmp?facets=%7B%7D"
}
}
{#- ################## PREFORMATTED AREA TEXT END ################## -#}
{{ _("Link your selected InvenioRDM record to the target maDMP:") }}
{{ _("Endpoint:") }} POST /api/invenio_damap/damap/dmp/{dmp_id}/dataset/{record_id}
{{ _("Token Required:") }} {% trans trimmed token_link = token_link %} Yes — generate one here. {% endtrans %}
cURL:
{#- ################# PREFORMATTED AREA TEXT BEGIN ################# #}
curl -X POST "{{ config.SITE_API_URL }}/invenio_damap/dmp/1337/dataset/abcde-12345" \
-H "Authorization: Bearer {your-access-token}"
{#- ################## PREFORMATTED AREA TEXT END ################## -#}
Python (requests):
{#- ################# PREFORMATTED AREA TEXT BEGIN ################# #}
import requests
url = "{{ config.SITE_API_URL }}/invenio_damap/dmp/1337/dataset/abcde-12345"
headers = {
"Authorization": "Bearer {your-access-token}",
}
response = requests.post(url, headers=headers)
print(response.json())
{#- ################## PREFORMATTED AREA TEXT END ################## -#}
{{ _("Example Response") }} (HTTP 201 - CREATED):
{#- ################# PREFORMATTED AREA TEXT BEGIN ################# #}
{
"id": "abcde-12345",
"metadata": {
"title": "New Dataset Title",
"creators": [{"name": "Doe, Jane"}],
"publication_date": "2025-01-09",
"resource_type": {"id": "dataset"}
},
"links": {
"self": "{{ config.SITE_API_URL }}/records/abcde-12345",
"files": "{{ config.SITE_API_URL }}/records/abcde-12345/files"
}
}
{#- ################## PREFORMATTED AREA TEXT END ################## -#}