SDK observability
The current TypeScript, Python, Ruby, PHP, and Go releases emit OpenTelemetry spans for their internal request lifecycle. Java and C# support is implemented on each SDK's GitHub default branch and will enter their registries when Maven Central and NuGet publishing are configured. A trace can show which Inttegro resource operation ran, when its HTTP attempt started, whether a retry was scheduled, when a response arrived, and whether decoding succeeded.
The SDKs do not create an exporter, choose an observability vendor, or send telemetry to Inttegro. They use the tracer provider and context propagator configured by your application. Without an application-owned provider, the instrumentation is a no-op.
Connect your OpenTelemetry provider
Configure OpenTelemetry once at application startup, before constructing the Inttegro client. The SDK uses the global provider by default; languages that commonly use dependency injection also accept an explicit provider.
Connect application tracing
- TypeScript
- Python
- Ruby
- PHP
- Go
import { InttegroClient } from '@inttegro/inttegro-sdk'
const inttegro = new InttegroClient({
apiKey: process.env.INTTEGRO_API_KEY!,
})
import os
from inttegro import InttegroClient
# Configure opentelemetry.trace's global provider at application startup.
inttegro = InttegroClient(
api_key=os.environ["INTTEGRO_API_KEY"],
)
require "opentelemetry/sdk"
require "inttegro"
OpenTelemetry::SDK.configure
inttegro = Inttegro::Client.new(api_key: ENV.fetch("INTTEGRO_API_KEY"))
use Inttegro\Client;
// $tracerProvider and $propagator belong to your application.
$inttegro = new Client(
apiKey: getenv('INTTEGRO_API_KEY'),
tracerProvider: $tracerProvider,
propagator: $propagator,
);
package main
import (
"context"
"os"
inttegro "github.com/zebodotdev/inttegro-sdk-go/v4"
"go.opentelemetry.io/otel"
"go.opentelemetry.io/otel/propagation"
sdktrace "go.opentelemetry.io/otel/sdk/trace"
)
func main() {
tracerProvider := sdktrace.NewTracerProvider()
defer tracerProvider.Shutdown(context.Background())
otel.SetTracerProvider(tracerProvider)
otel.SetTextMapPropagator(propagation.TraceContext{})
client := inttegro.NewClient(os.Getenv("INTTEGRO_API_KEY"))
_ = client
}
Java accepts an application-owned OpenTelemetry instance on its GitHub default branch. C# exposes InttegroClient.ActivitySourceName for registration with the application's OpenTelemetry pipeline. These hooks will be added to the examples above when their Maven Central and NuGet releases are available.
Follow the OpenTelemetry library guidance to configure sampling, processors, and an exporter in your application. Inttegro instrumentation works with OTLP and vendor-specific exporters because it only depends on the OpenTelemetry API.
Read an Inttegro span
Each public SDK call creates one CLIENT span named inttegro.<resource>.<action>, such as inttegro.orders.create or inttegro.refunds.lookup. The span contains only bounded operational metadata:
| Attribute | Meaning |
|---|---|
inttegro.operation.name | Stable resource and action, such as orders.create |
inttegro.sdk.language | SDK runtime |
inttegro.sdk.version | Installed SDK version |
http.request.method | HTTP method |
http.response.status_code | Response status when available |
server.address | Destination host without a path or query |
url.template | Static Inttegro API route, never a resource URL |
inttegro.request.id | Safe request identifier returned by the API |
error.type | Low-cardinality failure category such as http_401, timeout, or decode_error |
Lifecycle detail is recorded as span events:
inttegro.request.preparedinttegro.http.attempt.startedinttegro.retry.scheduledwhen a built-in retry is scheduledinttegro.response.receivedinttegro.response.decodedinttegro.request.failed
HTTP attempts include http.request.resend_count, starting at 0. This preserves one logical SDK operation span while still showing retry behavior inside it. Your collector can derive request counts, duration, retry count, and error rate from these stable spans and events without a separate Inttegro-specific metrics backend.
Data safety
Inttegro SDK telemetry never records:
- API keys or authorization headers
- request or response bodies
- customer, payment, order, or other resource identifiers
- URL query strings or dynamic capability paths
- exception messages or stack traces
W3C trace context is propagated on outbound requests so an Inttegro operation remains connected to its parent application trace. Existing caller-supplied propagation headers are preserved.
To disable SDK instrumentation for a particular client, set telemetry.enabled: false in TypeScript, telemetry_enabled=False in Python, telemetry_enabled: false in Ruby, telemetryEnabled: false in PHP or .NET, WithTelemetryEnabled(false) in Go, or pass false to Java's fully configured constructor.