diagnose_institutional_access
Diagnose why institutional fulltext access fails or succeeds for an article by probing direct fetch, EZproxy, and OpenURL paths and reporting each outcome.
Instructions
Diagnose why institutional fulltext access succeeds or fails for an article.
Runs up to three probes and reports each path's outcome:
Direct fetch (Phase 1, IP-aware) — follows
https://doi.org/<doi>and classifies whether the publisher served fulltext, a paywall, or a login page. Works automatically when your network IP is on the publisher's institutional allow-list (campus / VPN).EZproxy fetch (Phase 2, BYO-cookie) — rewrites the publisher hostname to your library's EZproxy host and replays your exported browser session cookie. Configured via env vars:
EZPROXY_HOST(e.g.ezproxy.lib.ntu.edu.tw)EZPROXY_COOKIE_FILE(path to browser-exported cookies.json)EZPROXY_ENABLED=1
OpenURL handoff — generated for you to open manually in a browser when the automated paths fail.
Usage: diagnose_institutional_access( source={"kind": "doi", "value": "10.1097/ALN.0000000000003599"} )
diagnose_institutional_access(
source={"kind": "pmid", "value": "38353755"},
try_ezproxy=False
)Args: source: Exactly one PMID or DOI. A PMID is resolved to a DOI when possible so direct and EZproxy probes can run. try_direct: Run the Phase 1 direct probe (default True). try_ezproxy: Run the Phase 2 EZproxy probe (default True).
Returns: Markdown report listing every probe's status, classification, and advice on the next action to take.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| source | Yes | ||
| try_direct | No | ||
| try_ezproxy | No |