Payload Command Examples for Custom Metrics
Below is an example how to send the necessary objects for Faros custom metrics attached to teams. Reach out to Faros to help determine your own specific API Payload.
mutation{
insert_faros_MetricDefinition(
objects:[
{
origin: "api"
name: "Lunch Expenses"
uid: "lunch-expenses"
description: "Weekly lunch expenses for a team"
}
]
){
affected_rows
}
}
mutation {
insert_faros_MetricValue(objects:[
{
origin: "api"
uid: "Jul27TeamA"
value: "250",
computedAt: "2023-07-27T20:31:35.147+00:00"
definitionId: "1515bff7c21be2e1eb4fa9ee500e549770d5ed1f"
}
]){
returning{
id
}
}
}
mutation {
insert_org_TeamMetric(objects:[
{
origin: "api"
valueId: "26df5b03d5855caad95ac191727e11aaba1ba041"
teamId: "4c8afdc6b963d36f757d108d90f39462afc21c55"
}
]){
affected_rows
}
}
Updated 12 months ago