Skip to content

fcakyon/claude-codex-settings / plugins/openobserve-skills/skills/openobserve-api

openobserve-api

Unverified

This skill should be used when user asks to "query OpenObserve", "create OpenObserve dashboard", "edit OpenObserve panel", "fetch OpenObserve logs", "run OpenObserve search", "list OpenObserve streams", "ingest into OpenObserve", or works with OpenObserve Cloud / self-hosted via REST API. Covers auth, search/SQL, streams, dashboards (CRUD + per-panel ops), the v8 panel JSON schema, and known pitfalls (re-aggregation, hash concurrency, microsecond timestamps).

FileKindSize
SKILL.mdskill md16.1 KB
references/around.mdmarkdown2.5 KB
references/bulk.mdmarkdown7.0 KB
references/delete.mdmarkdown10.8 KB
references/index.mdmarkdown1.7 KB
references/json.mdmarkdown6.8 KB
references/list.mdmarkdown2.7 KB
references/loki.mdmarkdown2.8 KB
references/multi.mdmarkdown5.2 KB
references/otlp.mdmarkdown4.4 KB
references/recipes/build-dashboard.shexecutablescript1.5 KB
references/recipes/search-logs.shexecutablescript683 B
references/recipes/update-panel.shexecutablescript884 B
references/schema.mdmarkdown2.6 KB
references/search.mdmarkdown13.3 KB
references/setting.mdmarkdown5.8 KB
references/value.mdmarkdown1.9 KB

references/otlp.md

View on GitHub
---
title: Otlp
description: Ingest logs via OpenTelemetry Protocol (OTLP) at POST /api/{org}/v1/logs. Supports OTLP JSON and Protobuf formats with resource attributes and log records.
---

# Logs Ingestion - OTLP

Endpoint: `POST /api/{organization}/v1/logs`

OpenObserve supports the OpenTelemetry Protocol (OTLP) for log ingestion. You can send logs from any OpenTelemetry-compatible collector or SDK by pointing it at OpenObserve.

> we use custom http header `stream-name` for speciafic stream name, default will push into `default` stream.

## Request

e.g. `POST /api/myorg/v1/logs`

Content-Type: `application/json` (JSON) or `application/x-protobuf` (Protobuf)

```json
{
  "resourceLogs": [
    {
      "resource": {
        "attributes": [
          {
            "key": "service.name",
            "value": { "stringValue": "my-service" }
          },
          {
            "key": "service.version",
            "value": { "stringValue": "1.2.3" }
          },
          {
            "key": "host.name",
            "value": { "stringValue": "ip-10-2-50-35.us-east-2.compute.internal" }
          }
        ]
      },
      "scopeLogs": [
        {
          "scope": {
            "name": "my-logger",
            "version": "1.0.0"
          },
          "logRecords": [
            {
              "timeUnixNano": "1672149599212000000",
              "observedTimeUnixNano": "1672149599212000000",
              "severityNumber": 9,
              "severityText": "INFO",
              "body": {
                "stringValue": "Request processed successfully"
              },
              "attributes": [
                {
                  "key": "http.method",
                  "value": { "stringValue": "GET" }
                },
                {
                  "key": "http.status_code",
                  "value": { "intValue": "200" }
                },
                {
                  "key": "trace_id",
                  "value": { "stringValue": "4bf92f3577b34da6a3ce929d0e0e4736" }
                }
              ],
              "traceId": "4bf92f3577b34da6a3ce929d0e0e4736",
              "spanId": "00f067aa0ba902b7"
            }
          ]
        }
      ]
    }
  ]
}
```

### Fields

| Field | Type | Description |
|-------|------|-------------|
| `resourceLogs` | array | List of resource log groups. |
| `resourceLogs[].resource` | object | Resource describing the entity producing the logs (e.g. service, host). |
| `resourceLogs[].resource.attributes` | array | Key-value pairs for resource-level metadata. |
| `resourceLogs[].scopeLogs` | array | List of instrumentation scope log groups. |
| `scopeLogs[].scope` | object | Instrumentation scope (library name and version). |
| `scopeLogs[].logRecords` | array | List of individual log records. |
| `logRecords[].timeUnixNano` | string | Log timestamp in **nanoseconds** since Unix epoch. |
| `logRecords[].observedTimeUnixNano` | string | Time the log was observed by the collector, in nanoseconds. |
| `logRecords[].severityNumber` | integer | Numeric severity level (1–24). See [OTLP severity levels](https://opentelemetry.io/docs/specs/otel/logs/data-model/#field-severitynumber). |
| `logRecords[].severityText` | string | Human-readable severity string (e.g. `INFO`, `WARN`, `ERROR`). |
| `logRecords[].body` | object | Log message body. Typically a `stringValue`. |
| `logRecords[].attributes` | array | Key-value pairs for log-level metadata. |
| `logRecords[].traceId` | string | Trace ID associated with this log record (hex string). |
| `logRecords[].spanId` | string | Span ID associated with this log record (hex string). |

## Response

```json
{
  "partialSuccess": {}
}
```

HTTP status `200 OK` with an empty `partialSuccess` object indicates all records were accepted, matching the standard OTLP HTTP response format.

## Authentication

Pass your credentials using HTTP Basic Auth or via the `Authorization` header:

```
Authorization: Basic <base64(user:password)>
```

## Configuring OpenTelemetry Collector

Configure the OTLP exporter in your OpenTelemetry Collector `config.yaml` to forward logs to OpenObserve:

```yaml
exporters:
  otlphttp/openobserve:
    endpoint: https://<openobserve-host>/api/<organization>
    headers:
      Authorization: "Basic <base64(user:password)>"
      stream-name: "custom_stream"

service:
  pipelines:
    logs:
      receivers: [...]
      processors: [...]
      exporters: [otlphttp/openobserve]
```
deprecation-and-migrationaddyosmani/agent-skillsManages deprecation and migration. Use when removing old systems, APIs, or features. Use when migrating users from one implementation to another. Use when migrating a database schema in production, such as renaming or dropping a column without downtime (expand/contract). Use when deciding whether to maintain or sunset existing code.Stars: 119kUpdated Claude CodeCodexVerifiedInstall
performance-optimizationaddyosmani/agent-skillsOptimizes application performance across frontend, backend, queries, and databases. Use when performance requirements exist, when you suspect performance regressions, when Core Web Vitals or load times need improvement, when N+1 query patterns need fixing, or when profiling reveals bottlenecks.Stars: 119kUpdated Claude CodeCodexVerifiedInstall
agent-cost-reportthedotmack/claude-memBelievable agent cost report for any period, default the last 7 full days PT, not counting today. Measured tokens from Claude Code transcripts priced at OpenRouter list prices (ESTIMATED), measured provider spend when a sanctioned source exists, note-taker cost separate, Timing-style HTML/PDF plus report.json, line-items.csv, evidence.json.Stars: 118kUpdated Claude CodeCodexVerifiedInstall
agent-cost-reportthedotmack/claude-memBelievable agent cost report for any period, default the last 7 full days PT, not counting today. Measured tokens from Claude Code transcripts priced at OpenRouter list prices (ESTIMATED), measured provider spend when a sanctioned source exists, note-taker cost separate, Timing-style HTML/PDF plus report.json, line-items.csv, evidence.json.Stars: 118kUpdated Claude CodeCodexVerifiedInstall