Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Uniprot API change #24

Closed
yaccos opened this issue Jun 29, 2023 · 1 comment
Closed

Uniprot API change #24

yaccos opened this issue Jun 29, 2023 · 1 comment

Comments

@yaccos
Copy link
Contributor

yaccos commented Jun 29, 2023

From my understanding, Uniprot's web API has changed from the time autoPACMEN was created and I used it. For this reason the Uniprot ID -> Protein mass mapping no longer works (https://github.com/klamt-lab/autopacmen/blob/cb828391d4cbb17e50ba9752cc974d78775d836d/autopacmen/submodules/get_protein_mass_mapping.py#L116C8-L116C105). However, I one of my group members have come up with a suggested solution; this is: Replace

uniprot_query_url = f"https://www.uniprot.org/uniprot/?query={query}&format=tab&columns=id,mass"

with

uniprot_query_url = f"https://rest.uniprot.org/uniprotkb/search?query=accession:{query}&format=tsv&fields=accession,mass"

I have tested both approaches in the web browser and can confirm that the old query string does no longer work, whereas the newly suggested one does.

@Paulocracy
Copy link
Member

Fixed thanks to @yaccos as per #25 :-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants