Why the API is not working?

Whenever I’m trying to use the API, I get this error: mp_api.client.core.client.MPRestError: REST query returned with error status code 403 on URL https://api.materialsproject.org/materials/core/mp-804/?_limit=1&_fields=structure with message:

Response {“error”: “You are using deprecated API endpoints. Please read our documentation (https://docs.materialsproject.org) and upgrade to the latest version of the mp-api client (mp-api · PyPI).”, “version”: “blocked”}

As the error message says, please check which version of mp-api you’re using and make sure it’s the latest one.