-
Notifications
You must be signed in to change notification settings - Fork 188
cant create event #75
Comments
You're missing the authorization token. Here's an example of my curl command that I use in my DEV environment: curl --insecure -H "Content-type: application/json" -H "Authorization: token thisismysecret" -X POST -d '{"service_key":"b893c504c51c26c720056ed94ec53049b9b9d0a4","event_type":"trigger","description":"test","incident_key":"1234567","details":"Details here"}' http://192.168.0.92:9080/api/create_event Note, the service_key is the API Key from the service that I want to send the alert to in OpenDuty. I only mention that in case you hadn't replaced your service key with the text you included. Also, the token "thisismysecret" is the secret token defined within the settings.py. |
found out yesterday, reading your case :) thanks a lot can we create a service using api ? |
Not yet, but that feature will come eventually. Check this for continously added features: github.com/openduty/openduty |
We are facing the same problem here:
Any hint on what might be wrong. Everything is setup. Service key, Sekret key, users, service... etc |
Have you created an escalation policy? I got the same problem when there was no escalation policy connected to the service |
and also "Authorization: password_from_settings.py" |
Everything is setup correctly. Escalation policy is assigned to the service. But no luck. I am clueless. |
You have used the API key created in the service as service_key ? |
Hmm. This is the curl I'm using and it works. curl --insecure -H "Content-type: application/json" -H "Authorization: <<secret<<" -X POST -d '{"service_key":"<<apikey<<","event_type":"trigger","description":"test","incident_key":"123425","details":"Details here"}' http://172.16.200.160:8000/api/create_event |
Ok I found the cause. Shame on me :(
Thanks @kjetilmjos |
That's good news! |
The Twilio Notification works fine for me. I receive SMS. |
So you didn't have to do any code changes to the notification part? What OS are you running on? |
doing
get
The text was updated successfully, but these errors were encountered: