This commit is contained in:
@ -28,7 +28,7 @@ response = get(api_url)
|
|||||||
if response.reason == "OK":
|
if response.reason == "OK":
|
||||||
dog_fact = DefaultMunch.fromDict(loads(response.text)['data'][0])
|
dog_fact = DefaultMunch.fromDict(loads(response.text)['data'][0])
|
||||||
print(dog_fact)
|
print(dog_fact)
|
||||||
payload = {"status": f"didja know: \n {dog_fact.attributes.body}\n#RandomDogFacts", "visibility": "mutuals_only"}
|
payload = {"status": f"didja know: \n {dog_fact.attributes.body}\n#RandomDogFacts", "visibility": "unlisted"}
|
||||||
response = post(post_endpoint, headers=headers, json=payload)
|
response = post(post_endpoint, headers=headers, json=payload)
|
||||||
if response.reason == "OK":
|
if response.reason == "OK":
|
||||||
notify(-1, loads(response.text)['uri'])
|
notify(-1, loads(response.text)['uri'])
|
||||||
|
Reference in New Issue
Block a user