Datadog · Arazzo Workflow

Datadog Create a Log-based Metric

Version 1.0.0

Create a log-based metric from a query then read it back.

1 workflow 2 source APIs 1 provider
View Spec View on GitHub AnalyticsDashboardsMonitoringPlatformT1VisualizationsArazzoWorkflows

Provider

datadog

Workflows

create-log-metric
Create a log-based metric then get it by id.
Creates a count log-based metric over the supplied query, then retrieves the metric by id to confirm its filter and compute settings persisted.
2 steps inputs: metricId, query outputs: compute, metricId
1
createMetric
Create a new log-based metric that counts log events matching the supplied query.
2
getMetric
Retrieve the newly created log-based metric by its id to confirm it was stored with the expected filter and compute configuration.

Source API Descriptions

Arazzo Workflow Specification

Raw ↑
arazzo: 1.0.1
info:
  title: Datadog Create a Log-based Metric
  summary: Create a log-based metric from a query then read it back.
  description: >-
    Defines a new Datadog log-based metric that counts the log events matching
    a search query, then retrieves the created metric by its identifier to
    confirm it was stored with the expected filter and compute configuration.
    Every step spells out its request inline so the flow can be read and
    executed without opening the underlying OpenAPI description.
  version: 1.0.0
sourceDescriptions:
- name: createApi
  url: ../openapi/datadog-create-api-openapi.yml
  type: openapi
- name: getApi
  url: ../openapi/datadog-get-api-openapi.yml
  type: openapi
workflows:
- workflowId: create-log-metric
  summary: Create a log-based metric then get it by id.
  description: >-
    Creates a count log-based metric over the supplied query, then retrieves
    the metric by id to confirm its filter and compute settings persisted.
  inputs:
    type: object
    required:
    - metricId
    - query
    properties:
      metricId:
        type: string
        description: The unique name/id for the new log-based metric.
      query:
        type: string
        description: The log search query that selects which logs feed the metric.
  steps:
  - stepId: createMetric
    description: >-
      Create a new log-based metric that counts log events matching the
      supplied query.
    operationId: CreateLogsMetric
    requestBody:
      contentType: application/json
      payload:
        data:
          type: logs_metrics
          id: $inputs.metricId
          attributes:
            filter:
              query: $inputs.query
            compute:
              aggregation_type: count
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      metricId: $response.body#/data/id
      filter: $response.body#/data/attributes/filter
  - stepId: getMetric
    description: >-
      Retrieve the newly created log-based metric by its id to confirm it was
      stored with the expected filter and compute configuration.
    operationId: GetLogsMetric
    parameters:
    - name: metric_id
      in: path
      value: $steps.createMetric.outputs.metricId
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      metricId: $response.body#/data/id
      compute: $response.body#/data/attributes/compute
  outputs:
    metricId: $steps.createMetric.outputs.metricId
    compute: $steps.getMetric.outputs.compute

Work with this as data

Every workflow here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for arazzo workflows

4 MCP tools reach this
  • find_arazzoBrowse and filter every workflow in the catalog.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This workflow
curl "https://apis.io/api/v1/arazzo/datadog-create-log-metric-workflow"
All arazzo workflows
curl "https://apis.io/api/v1/arazzo?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.