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

Extra attribute on payload #215

Open
JoaoPedroMDP opened this issue Dec 19, 2024 · 1 comment
Open

Extra attribute on payload #215

JoaoPedroMDP opened this issue Dec 19, 2024 · 1 comment
Labels
question Further information is requested

Comments

@JoaoPedroMDP
Copy link

Hi!!! First of all, thanks for creating this amazing solution!!

I wrote a custom notification that creates tickets on Otobo. The problem is that, in order to create the ticket, i need some data that my external system would send in JSON format. Currently i am doing a 'json.encode()' an just shoving it as the last part of the url. The problem is: dates. In my country, we write dates as 'dd/mm/yyyy' and i need to pass it like this. But it bugs with the '/' probably.

Now i just tested converting it to base64 but no success (altough i did not confirm how 'unsuccessful' it was and if there is an workaround). But then i asked myself: "couldn't i just send another key, sibling to 'urls', 'title' and 'body', and retrieve it inside my custom notification plugin?

Reading the docs i couldn't find anything. So, is there any way to do this?

@JoaoPedroMDP JoaoPedroMDP added the question Further information is requested label Dec 19, 2024
@JoaoPedroMDP
Copy link
Author

JoaoPedroMDP commented Dec 19, 2024

Oh, and by the way, the problem i had with the base64 encoded url
apprise | 2024-12-19 06:47:57,207 [WARNING] django: NOTIFY - 127.0.0.1 - Invalid FORM Payload provided

This is the payload

{'body': 'Host: TESTE-HOST\nService: PING\nState: CRITICAL\nDate: 19/12/2024 10:02:20\nLast Change: 0:09:08\n', 'title': 'Host: TESTE-HOST Service: PING Status: CRITICAL', 'urls': ['tckt://otobo/eyJBcnRpY2xlIjp7IkJvZHkiOiJIb3N0OiBURVNURS1IT1NUXG5TZXJ2aWNlOiBQSU5HXG5TdGF0ZTogQ1JJVElDQUxcbkRhdGU6IDE5LzEyLzIwMjQgMTA6MDI6MjBcbkxhc3QgQ2hhbmdlOiAwOjA5OjA4XG4iLCJTdWJqZWN0IjoiUElORyBET1dOIiwiQXV0b1Jlc3BvbnNlVHlwZS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versation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

1 participant