Map a Crossref record to a Zotero item payload
ztCrossref.RdThe returned payload is cleaned with ztCleanPayload() and can be placed in
a create plan. The default fetcher contacts the public Crossref API; inject a
compatible function for reproducible or offline work.
Examples
Message <- function(doi) list(
title = list("A reproducible record"),
author = list(list(given = "Ada", family = "Lovelace")),
`container-title` = list("Example Journal"),
issued = list(`date-parts` = list(list(2026L)))
)
ztCrossref("10.1000/example", getJson = Message)
#> $itemType
#> [1] "journalArticle"
#>
#> $title
#> [1] "A reproducible record"
#>
#> $creators
#> $creators[[1]]
#> $creators[[1]]$creatorType
#> [1] "author"
#>
#> $creators[[1]]$firstName
#> [1] "Ada"
#>
#> $creators[[1]]$lastName
#> [1] "Lovelace"
#>
#>
#>
#> $DOI
#> [1] "10.1000/example"
#>
#> $publicationTitle
#> [1] "Example Journal"
#>
#> $date
#> [1] "2026"
#>