import requests ### # Registres de l'Église def get_member_list(unit_number, cookie): r = requests.get('https://lcr.churchofjesuschrist.org/services/umlu/report/member-list', params={'lang': "fra", 'unitNumber': unit_number}, headers={'Accept': "application/json", 'Cookie': cookie}) r.raise_for_status() return r.json() def get_member_profile(member_id, cookie): r = requests.get(f'https://lcr.churchofjesuschrist.org/records/member-profile/service/{member_id}', params={'lang': "fra"}, headers={'Accept': "application/json", 'Cookie': cookie, 'Referer': f"https://lcr.churchofjesuschrist.org/records/member-profile/{member_id}?lang=fra"}) r.raise_for_status() return r.json()