✅ Help with http request
Hey guys, i'm having a wierd issue, i made a trial request to my mysql service provider via postman and it works fine, but when i try to do it via c# code, it returns with a 401, what's wierd is i used same auth ticket for both:
8 Replies
example usage:
and i checked, the
UserSecretsService
returns the token, not null or empty string seems wrong to me. You are serializing the HTTP method and putting that as your... content?
you dont include your actual request payload anywhere
Your code seems a fair bit overcomplicated, if you ask me.
I'm assuming you want to POST to that endpoint, seeing how GET doesn't support body
(a very useful website btw)
Though it uses
StringContent
, whereas it would probably be best to just use JsonContent
so you don't need to set the content-type manuallyUnknown User•7d ago
Message Not Public
Sign In & Join Server To View
its not a web app, all i need the api for is database storage, coz i plan on making both a mobile and windows app, so that i can add records via both
Unknown User•6d ago
Message Not Public
Sign In & Join Server To View
If you have no further questions, please use /close to mark the forum thread as answered