Join fellow LogicMonitor users at the Elevate Community Conference and get hands-on with our latest product innovations.

Register Now

Resources

Explore our blogs, guides, case studies, eBooks, and more actionable insights to enhance your IT monitoring and observability.

View Resources

About us

Get to know LogicMonitor and our team.

About us

Documentation

Read through our documentation, check out our latest release notes, or submit a ticket to our world-class customer service team.

View Resources

OpenAI Monitoring

Last updated on 07 May, 2025

LogicMonitor’s monitoring package for OpenAI provides REST API-based visibility into API usage and cost metrics for OpenAI services. The package enables you to track consumption across core OpenAI features—such as text and audio completions, image generation, and daily billing—using an administrative API key.

The monitoring suite collects detailed usage data including input/output tokens, cached token reuse, and model-specific statistics. It also tracks cost metrics associated with daily OpenAI API consumption, helping you stay within project budgets and enabling the configuration of alerts.

This package supports scalable, structured monitoring and is ideal for teams looking to optimize their OpenAI API usage within the LogicMonitor platform.

Requirements for OpenAI Monitoring

  • AnOpenAI admin-level API key with access to organization-wide usage and billing endpoints.
  • Outbound HTTPS access (TCP port 443) from the LogicMonitor Collector to https://api.openai.com.

Note: Personal or project-level API keys are not sufficient. The key must have organization-level visibility.

  • The following device property must be set on the resource in LogicMonitor:
PropertyDescription
OpenAI.admin.keyAdmin-level OpenAI API key required for authentication with the REST API.

This key is used to retrieve usage and cost data for the organization. The property must be added manually under the resource’s Info tab.

Adding Resources into Monitoring

Add your OpenAI resource into monitoring. For more information on adding resources into monitoring, see Adding Resources.

Note: Ensure the resource is internet-accessible and that the LogicMonitor Collector can reach https://api.openai.com over HTTPS (port 443).

Assigning Properties to Resources

The following property is required to enable module application:

PropertyDescription
OpenAI.admin.keyAdmin-level API key used for all REST API requests in this suite.

No additional properties are required. Once set, the LogicModules will apply automatically.

Import LogicModules

From the LogicMonitor Exchange, import all OpenAI LogicModules included in the package. For more information, see LogicModules in Package.

If you have previously imported these modules, ensure they are updated to the latest version to benefit from latest improvements or fixes.

Troubleshooting

  • Admin Key Requirements—This package requires an OpenAI admin-level API key with access to usage and billing data. Personal or project-scoped keys are not supported.
  • Key Management—Admin keys grant broad access. Store them securely, rotate them periodically, and monitor usage through OpenAI’s audit features.
  • No Support for Proxies or Limited Scope Tokens—The package is designed for direct access to OpenAI’s API endpoints. It does not support API proxies or restricted-scope keys.
  • No Data Appearing in LogicMonitor—Ensure the OpenAI.admin.key is present on the resource and has the necessary permissions.
  • Authentication Errors (401/403)—These indicate that the API key is invalid or expired. Verify the value and key scope in OpenAI’s dashboard.
  • Rate Limiting (HTTP 429)—OpenAI may limit request volume. If this occurs, reduce polling frequency or stagger requests across collectors.
  • Collector Connectivity Issues—Ensure the LogicMonitor Collector has outbound HTTPS access to https://api.openai.com on TCP port 443.

LogicModules in Package

LogicMonitor’s package for OpenAI consists of the following LogicModules. For full coverage, import the following LogicModules into your platform:

Display NameTypeDescription
OpenAI ImagesDataSourceCollects image generation activity grouped by model.
OpenAI CostsDataSourceCaptures and reports daily cost metrics across the organization.
OpenAI CompletionsDataSourceTracks text and audio completion usage, including token input/output stats.

When setting static datapoint thresholds on the various metrics tracked by this package’s DataSources, LogicMonitor follows the technology owner’s best practice KPI recommendations.

Recommendation: If necessary, adjust these predefined thresholds to meet the unique needs of your environment. For more information on tuning datapoint thresholds, see Alert Threshold Overview.

In This Article

Start Your Trial

Full access to the LogicMonitor platform.
Comprehensive monitoring and alerting for unlimited devices.