Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

JSON API call to /notify/key fails #124

Closed
npodbielski opened this issue Jul 13, 2023 · 1 comment
Closed

JSON API call to /notify/key fails #124

npodbielski opened this issue Jul 13, 2023 · 1 comment
Labels
bug Something isn't working

Comments

@npodbielski
Copy link

npodbielski commented Jul 13, 2023

🪲 Describe the bug
Calling API with JSON does not work at all.
According to examples it should work:

POST https://apprise.example.com/notify/key
Content-Type: application/json

{
  "body": "test",
  "tag":"some tag"
}

This is really strange because much more complex Content-Type application/x-www-form-urlencoded works from curl, Python but does not work from .NET.
The same is for multipart/form-data; works from curl but does not from .NET.
Json content type does not work at all. And this is why I am creating this bug since I am bashing my head with this for whole day.

💡 Screenshots and Logs
Returns:
Response code: 424 (Failed Dependency); Time: 16ms (16 ms); Content length: 56 bytes (56 B)

Logs:

apprise  | 2023-07-13 05:11:52,680 [INFO] apprise: Loaded 1 entries from memory://
apprise  | 2023-07-13 05:11:52,682 [WARNING] django.request: Failed Dependency: /notify/key

💻 Your System Details:

  • running Apprise from docker image caronc/apprise:latest at the time of writing this [v0.9.3]

🔮 Additional context
In an essence I want to connect shinobi motion detection notification to my matrix server via Apprise, but since Apprise does not allow webhooks - and Shinoby allows only those - I need to make a proxy. Thought about dotnet since I have it already set up, but no matter how I create a request it fails.
There is not much in logs why this is happening - the only other way beside creating a bug here would be to debug apprise to find out what is happening.

@npodbielski npodbielski added the bug Something isn't working label Jul 13, 2023
@npodbielski
Copy link
Author

Ok I did found the problem. I forgot to hit save on config page and tag I was using did not exists. So typical case of PEBKAC. Still I would expect API to throw 400 or 404 Tag do not exists. Instead of 424 that is defined for WebDav specifically I believe.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant