# Registry API bug

**URL:** <https://discourse.gbif.org/t/registry-api-bug/5425>\
**Category:** Miscellaneous\
**Created:** [October 18, 2024, 10:56am UTC](https://discourse.gbif.org/t/registry-api-bug/5425 "2024-10-18T10:56:31Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![s.modrak](https://avatars.discourse-cdn.com/v4/letter/s/b9bd4f/32.png) [@s.modrak](https://discourse.gbif.org/u/s.modrak)\
**Post date:** [October 18, 2024, 10:56am UTC](https://discourse.gbif.org/t/registry-api-bug/5425/1 "2024-10-18T10:56:32Z")

</div>

Hi!

I have noticed there is a bug in the Registry API endpoint `https://api.gbif.org/v1/dataset` (documented here [Registry API :: Technical Documentation](https://techdocs.gbif.org/en/openapi/v1/registry#/Datasets/listDatasets)). According to the documentation the parameter `modified` should support wildcards in the form of omitted values, for example `&modified=2024-09-10,` or `&modified=,2024-09-10`.

You can see that when comparing output for `https://api.gbif.org/v1/dataset?type=occurrence&modified=2024-09-10,2024-10-18`, which returns 1961 results, and `https://api.gbif.org/v1/dataset?type=occurrence&modified=2024-09-10,` which returns 20 results, we would expect it to return an equal or larger amount of results, as it has the open end of the range.

The form `https://api.gbif.org/v1/dataset?modified=,2024-10-18` does not work at all and returns status 400.

Additionally, the data parameter seems to be accepted as and expecting `year-moth-day` (throws an error if I try with `13` for `month`) but processed on the server when returning results as `year-day-month`. This could explain the issues above.

Thanks for your help!  
Stanley  
ICL

---

<div class="post-metadata">

**Author:** ![cecsve](https://sea1.discourse-cdn.com/gbif1/user_avatar/discourse.gbif.org/cecsve/32/770_2.png) [@cecsve](https://discourse.gbif.org/u/cecsve)\
**Post date:** [November 11, 2024, 1:37pm UTC](https://discourse.gbif.org/t/registry-api-bug/5425/2 "2024-11-11T13:37:07Z")

</div>

Thank you for reporting the issue! I have created an issue in the [registry repository on GitHub](https://github.com/gbif/registry/issues/639) so the Informatics team can investigate.

---

<div class="post-metadata">

**Author:** ![cecsve](https://sea1.discourse-cdn.com/gbif1/user_avatar/discourse.gbif.org/cecsve/32/770_2.png) [@cecsve](https://discourse.gbif.org/u/cecsve)\
**Post date:** [November 11, 2024, 2:31pm UTC](https://discourse.gbif.org/t/registry-api-bug/5425/3 "2024-11-11T14:31:25Z")

</div>

From [modified parametre bug · Issue #639 · gbif/registry · GitHub](https://github.com/gbif/registry/issues/639#issuecomment-2468233153:)

A `*` to mark the end of the range is required, unfortunately it has been converted to italic text in the documentation. This will be fixed in the next release.

20 results for [https://api.gbif.org/v1/dataset?type=occurrence&modified=2024-09-10](https://api.gbif.org/v1/dataset?type=occurrence&modified=2024-09-10) or [https://api.gbif.org/v1/dataset?type=occurrence&modified=2024-09-10%2C](https://api.gbif.org/v1/dataset?type=occurrence&modified=2024-09-10%2C) (trailing comma escaped so GitHub links correctly) are the ones modified on that day only.

[https://api.gbif.org/v1/dataset?type=occurrence&modified=2024-09-10%2C\*](https://api.gbif.org/v1/dataset?type=occurrence&modified=2024-09-10%2C%2A) (trailing `,*`) has 7909 results.

[https://api.gbif.org/v1/dataset?type=occurrence&modified=\*%2C2024-09-10](https://api.gbif.org/v1/dataset?type=occurrence&modified=%2A%2C2024-09-10) has 41929 results.

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/gbif1/original/1X/d2525d53d815eb0c992cc44730ed8a6a1be1dbb5.png) [@system](https://discourse.gbif.org/u/system)\
**Post date:** [December 12, 2024, 12:31am UTC](https://discourse.gbif.org/t/registry-api-bug/5425/4 "2024-12-12T00:31:48Z")

</div>

Closed on December 12, 2024, 12:31am UTC

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
