I am consistently receiving a 404 “Not Found” error when trying to make a POST request to the Inference API (e.g., for the gpt2 model).
Here is what I have already tried:
- Used the correct PowerShell command: Invoke-WebRequest -Uri “https://api-inference.huggingface.co/models/gpt2” -Method POST …
- Generated a new API token with “write” permissions.
- Tested the command on two completely different networks (my home Wi-Fi and my mobile data provider). The 404 error persists on both.
- To confirm my machine and network are working, I successfully made a POST request to https://httpbin.org/post. The test was successful (200 OK).
This indicates the issue is not with my local setup but is specific to the connection to the Hugging Face API from my location/account.`
Could you please help me investigate this?