Skip to content
alienbrett edited this page Mar 28, 2020 · 1 revision

The package includes functions that can query the Ally servers on some basic functions, like

Market Clock

This shows information regarding the current state of the US Exchanges:

>>a.market_clock()
{
    "status": {
        "current": "close",
        "next": "pre",
        "change_at": "08:00:00"
    },
    "message": "Market is open Monday through Friday 9:30AM to 4:00PM EST"
}

Api Status

Get an error message about the server, or "Success" if everything is good:

>>a.api_status()
{
    "time": "Sat, 28 Mar 2020 15:16:49 GMT",
    "error": "Success"
}

Member information

Get information about the owner of the account:

>>a.get_member()
{
    "login_id": "XXX",
    "primaryFirstName": "XXX",
    "primaryLastName": "XXX",
    "primaryMiddleInitial": "X",
    "primaryNameSuffix": "XX",
    "account": "XXX",
    "fundtrading": "true",
    "ira": "false",
    "margintrading": "true",
    "nickname": "individual",
    "optionlevel": "X",
    "shared": "false",
    "stocktrading": "true"
}