mkt.databases.alphafold.AlphaFoldStructure
- class mkt.databases.alphafold.AlphaFoldStructure(uniprot_id: str, url: str = 'https://alphafold.ebi.ac.uk/api', headers: str = "{'Accept': 'application/json'}", _json: dict | None = None, _cif: str | None = None)[source]
Bases:
AlphaFoldPredictionClass to download the mmCIF file from the AlphaFold EBI server.
Inherits from AlphaFoldPrediction and uses the cifUrl from the prediction JSON to download and store the CIF content.
Parameters:
- uniprot_idstr
UniProt accession (e.g. “P00533”).
- __init__(*args: Any, **kwargs: Any) None
Methods
__eq__(other)Return self==value.
__post_init__()Download the mmCIF file from the cifUrl in the prediction JSON.
_stamp_from_response(res)Record query datetime + cache provenance from a requests-cache response.
_stamp_now()Record current UTC datetime; cache provenance unknown.
check_response(res)Check the response status code for errors.
query_api()Query the AlphaFold prediction endpoint and populate _json.
Attributes
__dataclass_fields____dataclass_params____match_args____pydantic_config___cifmmCIF file content downloaded from AlphaFold.
_jsonJSON response from the AlphaFold API.
from_cacheWhether the most recent response was served from requests-cache.
headersHeader for the API request.
query_datetimeUTC datetime the underlying network query was made (cache creation time if served from cache).
urlBase URL for the AlphaFold EBI API.
uniprot_idUniProt accession to query.