Ranter
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Comments
-
Awlex182756yI just made a request with apirequest.io -> works
Copy the curl command generated.
-> Doesn't work
This is fucking bullshit. -
Awlex182756y@bahua what I forgot to mention is that when I used curl or the 2nd library I just got a 500.
Adding -k unfortunately didn't help -
Without seeing code it's hard to help.
But... As some server admins and / or devs are fucktards: Maybe changing the User Agent and / or enabling cookies helps... -
Awlex182756y@IntrusionCM there's not much code to see
Tried with elixir and python
<HTTPLibrary>.get(<url>)
or
curl -v -i <url>
If you wanna try for yourself:
https://capi-v2.sankakucomplex.com/...
Yes, it's nsfw api -
@Awlex: Exactly what I thought.
curl --verbose --user-agent 'Mozilla/5.0 (X11; Linux x86_64; rv:65.0) Gecko/20100101 Firefox/65.0' https://capi-v2.sankakucomplex.com/...
Works.
If I just use curl --verbose URL it generates a 500.
Set a user agent. -
Awlex182756y@IntrusionCM Thanks dude. I honestly didn't think an API would require me to send a user-agent. Probably because they never mentioned it. 🤷♂️
-
@Awlex Yes... Reason I used the term fucktards. It's a booby trap mostly used to prevent ddos attacks from bots - pretty useless, yes.
Another thing I noticed... You should be careful of the UTF 8 characters inside. I don't know what you try to implement, but in some cases like MySQL, there are still caveats (utf8mb4 vs utf8 for example).
Happy to help. :) I know the frustration.... XD -
Awlex182756yHad me totally bamboozled XD
No worries about the moonrules, I don't store than and even then, my database should be set up for utf8 ;)
The world must truly hate me.
I refactored my code a lot in order to easily integrate different APIs endpoints but then I can't use the one I specifically did this for, because of TLS errors.
My browsers all agree that it's fine, but curl and the 2 http libraries I tested can't fetxh any data.
END ME!
rant