Closed mgrimace closed 6 months ago
Okay from what I can see the notification is successfully pushed to the NTFY-Server, however the NTFY-Server has trouble parsing the message.
As URL, did you send the root URI of your NTFY-Server? e.g. https://ntfy.sh/
(correct), and not to https://ntfy.sh/mytopic
(incorrect). (reference)
Additionally, can you check your NTFY-Server logs (reference), error 500 means that an internal error occured.
As URL, did you send the root URI of your NTFY-Server? e.g. https://ntfy.sh/ (correct), and not to https://ntfy.sh/mytopic (incorrect). (reference)
Gonna add code to set your own topic.
Hi, ok, I don't 100% remember what I ended up using but I'll try again with a few combinations.
I believe I did use the /manga
topic, and what I don't recall is whether I used basic auth, token, or webhook which is all-in the url AFAIK (e.g., https://ntfy.mydomain.com/manga/publish?auth=...
). NTFY has a few strange requirements for base64 and doublebase64 encoded user:pass authorization depending on the method. I'll report back if I can replicate.
From https://github.com/C9Glax/tranga/issues/186#issuecomment-2143609208
[{"notificationConnectorType":2,"endpoint":"https://ntfy.mydomain.com/manga"}]
It would seem that my suspicion on the base URI thing was correct as you had /manga
set as topic, which I failed to handle in my code correctly. For the json publish to work, you had to push to the base URI.
https://github.com/C9Glax/tranga/commit/ebe3012c694ea1006b2fae995007f90287e87c8c should fix that. If you set the topic via /manga
now, it should automatically set the topic correctly. (I now see another issue, gonna fix that real quick... don't update yet)
From #186 (comment)
[{"notificationConnectorType":2,"endpoint":"https://ntfy.mydomain.com/manga"}]
It would seem that my suspicion on the base URI thing was correct as you had/manga
set as topic, which I failed to handle in my code correctly. For the json publish to work, you had to push to the base URI.ebe3012 should fix that. If you set the topic via
/manga
now, it should automatically set the topic correctly. (I now see another issue, gonna fix that real quick... don't update yet)
Amazing, I'll test out the updates when they're ready and report back, no rush at all.
and I'm using Docker, what should I set the tags to (for tranga-api and tranga-website I'm currently on latest
)?
Okay it is building the image right now, you should be able to setup NTFY with
URL
containing your NTFY-Server URL in the format http(s)://ntfy.server.url/<optional topic, default is tranga>
and
Auth
containing the base64 authParam
.
authHeader = "Basic " + base64(username + ":" + password) // -> Basic dGVzdHVzZXI6ZmFrZXBhc3N3b3Jk
authParam = base64_raw(authHeader) // -> QmFzaWMgZEdWemRIVnpaWEk2Wm1GclpYQmhjM04zYjNKaw (no trailing =)
Which is quite clunky right now admit, will open a seperate issue, to make that easier...
I recommend using cuttingedge
as tag, as most issues are fixed on there.
Thanks again! As far as I can tell I broke the formatting through an accidental work-around by using the webhook url (which embeds the topic and auth). I hadn't gotten the right combination of no-topic and authparam authentication to get it working otherwise.
I tested it out with the no-topic (e.g., https://ntfy.mydomain.com
) and the correct authparam
authorization, and it's working as expected at /tranga. I'll test the custom topic once the image is up! Thanks also for making the login easier with #187 , it's difficult for a lay-person to understand the encoding (at least for me), and entering the user/pass should improve usability. Thanks so much for your work!
Image should be up for a few minutes already, so custom topic should also work 👍🏼
Image should be up for a few minutes already, so custom topic should also work 👍🏼
Confirmed working on my end at /manga!
As a final favor, can you restart you container to see if the notificationConnectors.json file is working?
What is broken?
Two issues with NTFY:
Log-output
Additional stuff
No response