yeah it works
I will review cors (maybe that is the error)
And you said you tried using the LAN IP of your machine?
And are you disabling the SSL verification?
yeah I tried to use the lan ip also
no i didn't i will review in axios docs
Did you test localhost using axios?
yeah, but localhost points to the container itself
And it was https without any extra SSL bypass?
yeah
That's kind of surprising....
What OS do you have?
now the error says "self-signed certificate"
windows 11 and WSL ubuntu 20.04
Try to set up ignore SSL verification
So that API you have...is that running in a docker container?
No, the api is running in windows, and I'm trying to call it from an appwrite function (container)
sorry i didn't explain it well
It is working now, I disabled SSL verification from axios using: httpsAgent: new https.Agent({ rejectUnauthorized: false, }),
But It only works with the LAN ip
It doesnt work with the bridge 172.17.0.1
Yes that makes sense because WSL is like a virtual machine inside windows
That bridge would be a bridge to WSL, not windows
Yes, I tried to call the endpoint with curl from WSL, it only works with lan ip not localhost
[SOLVED] call api from a function
Thank you so much @Steven
Recommended threads
- THE COLUMNS STUCK ON PROCESSING HOW DO I...
I HAVE SELF HOSTED THE APPWRITE ON VPS
- Impossible to create project via CLI?
Is it possible to create a new project via the appwrite CLI ? I need to create a few projects for something I'm working on and because i don't want to do it man...
- Understanding S3 setup with appwrite
Hey, i'm planning to change the storage from local to S3, tho i have some questions to see before starting the migration. 1. Does all the `/storage/<storage_ty...