Add get_relationship method to api

This commit is contained in:
Daniel Schwarz 2023-02-03 21:28:18 -05:00 committed by Ivan Habunek
parent a633f757b5
commit 95473fcd6e
No known key found for this signature in database
GPG Key ID: F5F0623FF5EBCB3D
1 changed files with 5 additions and 0 deletions

View File

@ -369,6 +369,11 @@ def vote(app, user, poll_id, choices: List[int]):
return http.post(app, user, url, json=json).json()
def get_relationship(app, user, account):
params = {"id[]": account}
return http.get(app, user, '/api/v1/accounts/relationships', params).json()[0]
def mute(app, user, account):
return _account_action(app, user, account, 'mute')