Welcome to ALeRCE Python Client’s documentation!

ALeRCE client is a Python library to interact with ALeRCE services and databases.

Installing ALeRCE Client

The ALeRCE client can be installed through pip with

pip install git+https://git@github.com/alercebroker/alerce_client_new#egg=alerce

Or clone the repository and install from there

git clone https://github.com/alercebroker/alerce_client_new.git
cd alerce_client_new
python setup.py install


from alerce.core import Alerce
alerce = Alerce()

dataframe = alerce.query_objects(

detections = alerce.query_detections("ObjectID", format="pandas", sort="mjd")

magstats = alerce.query_magstats("ObjectID")


By default the Alerce object should be ready to use without any external configuration, but in case you need to adjust any parameters then you can configure the Alerce object in different ways.

At the client object initialization

You can pass parameters to the Alerce class constructor to set the parameters for API connection.

alerce = Alerce(ZTF_API_URL="https://ztf.alerce.online")

From a dictionary object

You can pass parameters to the Alerce class from a dictionary object.

my_config = {
    "ZTF_API_URL": "https://ztf.alerce.online"
alerce = Alerce()

Indices and tables