Fix spacebin paste

This commit is contained in:
Yasir Aris M 2024-07-30 10:44:36 +07:00 committed by GitHub
parent a89a3cabcd
commit 6d855662a0
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -350,8 +350,8 @@ async def spacebinn(_, message):
uname = message.sender_chat.title
try:
siteurl = "https://spaceb.in/api/v1/documents/"
response = await fetch.post(siteurl, data={"content": data, "extension": "txt"})
siteurl = "https://spaceb.in/api/"
response = await fetch.post(siteurl, json={"content": data, "extension": "txt"})
response = response.json()
url = "https://spaceb.in/" + response["payload"]["id"]
except Exception as e: