INSPIRE-HEP upstream quirks
Behavior of the live INSPIRE-HEP API that the client accounts for or that callers should know.
Search and paging
- INSPIRE allows 15 requests per 5 seconds per IP, and a request blocked by
the limiter also counts against the window. After a 429, wait at least 5
seconds; the client's default pace of 2 requests per second stays inside
the limit, and the core retry waits for the response's
Retry-Afterheader when the API sends one. sizecaps at 1000; a larger value answers HTTP 400Maximum search page size of '1000' results exceeded.The client clampspage_sizeto 1000 before sending.- A search cannot reach past record 10000: a window that passes that point
answers HTTP 400
SearchPaginationRESTError: Maximum number of 10000 results have been reached.The client raisesConfigurationErrorbefore sending when the offset would exceed 9999. Split a broad query into narrower ones to reach further. links.nextin a search answer is the URL of the next page; the client instead pages withpageandsize, which the API supports directly.- An invalid
sortvalue is ignored, and the results come back unsorted. Documented orders:mostrecentandmostcitedfor literature,mostrecentanddeadlinefor jobs,dateascanddatedescfor conferences and seminars. - The SPIRES-style query
a E.Witten.1answered 0 results when probed, although the official documentation uses it as an example. Field-path queries (abstracts.source:Springer,recid:4328,control_number:1011247) work. - An invalid
qexpression answers HTTP 200 with an empty result, not an error. - Facet filters beyond
qare not enumerated in the API documentation; the seminars collection acceptsstart_date=upcoming. Pass others as a plainfiltersmapping; the API ignores unknown parameters. fields=(the client'sselect=) trimsmetadatato the named fields and only works on searches, not on single-record routes.
Records
- Search hits carry
created,updated,id(the recid as a string),links, andmetadata; single records adduuidandrevision_id. metadataholds more fields than the schemas document, and INSPIRE states that undocumented fields can change at any time. The client models type the documented fields and keep the rest accessible throughextra="allow".- Dates inside
metadataare partial as often as not (1984-10for a month,1993for a year), so the models type them as strings. Only the envelopecreatedandupdatedtimestamps are typed as datetimes. - The same field sometimes changes type between records: a series
numberarrives as an integer on one record and as a string on another. /literature/{id}/citationswraps its records inmetadatainstead of thehitsenvelope, reports no total in the usual place, and carries the citing total asmetadata.citation_count.
Content
- Most metadata is published under a CC0 license, but restrictions apply to some fields, and bulk collection of email addresses is not allowed. The API hides author email addresses unless the caller authenticates; this client offers no helper for harvesting them.
- Alternative citation formats (
bibtex,latex-eu,latex-us,cv,json-expanded) are only rendered for literature records. Thecvformat answers HTML, andjson-expandedinlines linked ROR and ORCID identifiers. - The bibliography generator (
POST /api/bibliography-generator) is a write-shaped POST route and is not wrapped.