Navigation X
ALERT
Click here to register with a few steps and explore all our cool stuff we have to offer!



   1467

NEED HELP WITH ANONFILES API

by Flos_Bitch - 22 January, 2022 - 09:51 AM
This post is by a banned member (Flos_Bitch) - Unhide
592
Posts
191
Threads
5 Years of service
#1
I'm making an automatic combo poster, and i want to you use the anonfiles api.

Ive used (https://pypi.org/project/anonfile/)
and states a 400 error, bad url, but i have a feeling it has to do with a token

 
Code:
 
def anonupload():
    from anonfile import AnonFile
    anon = AnonFile()
    # upload a file and enable progressbar terminal feedback
    upload = anon.upload('./output.txt', progressbar=True)
    print(upload.url.geturl())
"requests.exceptions.HTTPError: 400 Client Error: Bad Request for url: https://api.anonfiles.com/upload?token=undefine"
 CHEAP SIG SPOT AVAILABLE ?PROMOTE YOUR SERVICE FOR CHEAP
6K CREDITS FOR 1 MONTH

sig spot bought til 26/5/21
⭐️[b]Premium Refund Service⭐️  ⭐️Best 1 on 1 Refund Mentorship/Over 30 Students!⭐️  ⭐️HQ Threads Designs⭐️

 [Image: alxLAgo.gif][/b]

[Image: o4A2NWx.gif]
This post is by a banned member (Deaepunisher) - Unhide
649
Posts
240
Threads
4 Years of service
#2
Code:
import requests
req = requests.post("https://api.anonfiles.com/upload",files={"file":open(input("File Name: "),"rb")}).json()
if req["status"] == True:
    print("[+] File Uploaded Successfully")
    print(req)
elif req["status"] == False:
    print("[-] Found Error While Uploading The File")
    print(req["error"]["message"])

Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
or
Sign in
Already have an account? Sign in here.


Forum Jump:


Users browsing this thread: