Skip to contents

Dryad issues OAuth2 bearer tokens from account settings. Unlike Figshare, Dataverse, Zenodo, and OSF, a token is REQUIRED to download file bytes even from a fully public dataset (verified live 2026-08-16: both the per-file and whole-dataset download endpoints answer 401 with no token, though dataset metadata and file listings are readable without one). Without a token, dryad_file_download() can list what a dataset contains but cannot fetch any of it.

Usage

dryad_pat(pat = NULL)

Arguments

pat

the token to set, or NULL to get the current token

Value

the current token (character; "" when none is set)

Details

This token expires after 10 hours and must be regenerated by hand from Dryad's account settings – for a long corpus run, dryad_auth() avoids this by exchanging a client id/secret for a token automatically, with no manual re-entry. When client credentials are set via dryad_auth(), they take priority over this token.

Store it as the DRYAD_PAT environment variable so it is read every time R starts.

Examples

dryad_pat() # returns "" unless a token is set
#> [1] ""