Hello,
I'm using the manage API of Statuspage.
Currently I'm trying to create incidents programmatically. To be able to identify incidents when accessing them in the future, I'm trying to save an ID in the "metadata" key of the incident. However, when I try to do that, I get the following response:
{
"error":[
"Metadata Metadata must be namespaced"
]
}
My request entity, the incident, looks like this:
{
"incident": {
"name": "Incident title",
"body": "Something is not working.",
"status": "investigating",
"component_ids": [ "abc123def456" ],
"metadata": {
"my_id": "123456789_test:hello"
}
}
}
Does anybody know what this response means? Can't I use the metadata field?
Edit: This page of the API documentation suggests that there is a metadata field.
As it turns out, I had to wrap"my_id" inside another object, which represents the namespace:
{
"incident": {
"name": "Incident title",
"body": "Something is not working.",
"status": "investigating",
"component_ids": [ "abc123def456" ],
"metadata": {
"my_namespace: {
"my_id": "123456789_test:hello"
}
}
}
}
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.