v1
latestOpenAPI 3.1.0BSD-32026-07-2471176175.5 KBevents
Post an event
When something happens in one of your engineering systems that may have an impact on your cloud costs, submit an Event to the CloudZero API to correlate the Event with your ongoing cloud costs. For example, you can send us an Event every time you do a deployment. CloudZero will then correlate those deployment Events with changing cloud costs to help you understand what is driving said costs in any given period of time.
post/events/v1/events
Headers
Authorizationstring required
Your CloudZero API Key. Note: This is not a bearer token, and should appear in the header as Authorization: <cloudzero-api-key>
Request body
Example request
{
"title": "production-feature-deployed",
"source": "jenkins",
"timestamp": "2020-03-03T15:32:44.474670+00:00",
"filters": {
"accounts": [
"012093365392",
"055595555385"
],
"resource_ids": [
"arn:aws:lambda:us-east-1:055595555385:function:my-lambda-function"
],
"services": [
"AWSLambda",
"AmazonAthena",
"AmazonEC2"
],
"tags": {
"feature": "my-feature",
"team": "my-team"
},
"usage_families": [
"DataTransfer-Out-Bytes",
"Request"
]
},
"link": "http://jenkins.com/builds/production-feature",
"metadata": {
"user": "sasha@company.com",
"git_sha": "923dd0037a455576561b89c2321ffc36473578c7"
}
}Response
Event created
Example response
{
"event": {
"title": "production-feature-deployed",
"source": "jenkins",
"timestamp": "2020-03-03T15:32:44.474670+00:00",
"filters": {
"accounts": [
"012093365392",
"055595555385"
],
"resource_ids": [
"arn:aws:lambda:us-east-1:055595555385:function:my-lambda-function"
],
"services": [
"AWSLambda",
"AmazonAthena",
"AmazonEC2"
],
"tags": {
"feature": "my-feature",
"team": "my-team"
},
"usage_families": [
"DataTransfer-Out-Bytes",
"Request"
]
},
"link": "http://jenkins.com/builds/production-feature",
"metadata": {
"user": "sasha@company.com",
"git_sha": "923dd0037a455576561b89c2321ffc36473578c7"
},
"event_id": "8ddc2bga-8e8g-499c-a5ee-cgfc4d333b22"
}
}