Closed jordanroskelley closed 1 year ago
I had issues getting this working because the directory.churchofjesuschrist.org uses a slightly different way of handling auth. I did however find a way to get this to work, I exposed the whole mobile-sync data endpoint in a new method which gives you all the data that member tools gets on a sync, and you can get the info will all unit numbers in your stake by running the following example:
api.get_mobile_sync_data()['units']
First, I don't work with GitHub much, so I'm not sure what the normal way to to a Fork/PR here is, if this is wrong, I'm sorry. Let me know how to change it and I will.
It currently isn't working for me. When I call: api.get_units(parentUnitNumber)
It gives me an error: Error from server: 401 - b'' for endpoint https://directory.churchofjesuschrist.org/api/v4/units/MY_STAKE_UNIT_NUMBER