Can you query the RCSB PDB API with a ligand and return the IDs of all entries in which it appears as a free ligand?
I'm not sure about the RCSB, but you can get such a list from the PDBe REST API, as documented in the compounds section:

http://www.ebi.ac.uk/pdbe/api/pdb/compound/in_pdb/ADN

Alternatively, from an older service:

http://www.ebi.ac.uk/pdbe-srv/pdbechem/PDBEntry/download/ADN