Add Note to Alert via IPA (403 ERROR )

Michael Smith July 17, 2020

Hi everyone.

I'm new to using API's. When I'm trying to add note to Alert via IPA I'm getting the error:

403 ERROR
The request could not be satisfied.

This distribution is not configured to allow the HTTP request method that was used for this request. The distribution supports only cachable requests.
We can't connect to the server for this app or website at this time. There might be too much traffic or a configuration error. Try again later, or contact the app or website owner.

If you provide content to customers through CloudFront, you can find steps to troubleshoot and help prevent this error by reviewing the CloudFront documentation.

Generated by cloudfront (CloudFront)
Request ID: IZRkiFS1DofLrBqVJENTXDABYBjiMA4FCoq19s6ag6QMV29Rv-i6iQ==

What I'm doing wrong?

Example from documentation:

curl -X POST https://api.opsgenie.com/v2/alerts/8418d193-2dab-4490-b331-8c02cdd196b7/notes?identifierType=id
-H "Authorization: GenieKey eb243592-faa2-4ba2-a551q-1afdf565c889"
-H "Content-Type: application/json"
-d
'{
"user":"Monitoring Script",
"source":"AWS Lambda",
"note":"Action executed via Alert API"
}'

My request:

curl -X POST https://mycompany.app.eu.opsgenie.com/v2/alerts/4d704a13-3ca3-4c57-a8ca-c8ab21211b5a-1594821021926/notes?identifierType=id
-H "Authorization: GenieKey xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
-H "Content-Type: application/json"
-d
'{
"user":"DB Manager",
"source":"Test",
"note":"Test Note"
}'


Documentation:
https://docs.opsgenie.com/docs/alert-api

Please help.

Regards,
Michael

1 answer

1 accepted

1 vote
Answer accepted
Michael Smith July 17, 2020

Ok, My bad. I need to use  https://api.eu.opsgenie.com instead of https://mycompany.app.eu.opsgenie.com. It wasn't obvious to me. I thought https://api.eu.opsgenie.com is an example.

DaveMenc December 7, 2022

Made the same mistake; you're my hero!

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events