openapi: 3.0.3 info: title: Jaeger Collector API (api_v2) CollectorService SamplingManager API version: '2.0' description: 'Jaeger Collector ingest API. The Collector accepts span batches over gRPC on port 14250 (`jaeger.api_v2.CollectorService`) and over the HTTP gateway at `/api/v2/spans`. Jaeger v2 (since November 2024) also accepts OTLP natively on ports 4317 (gRPC) and 4318 (HTTP) and Zipkin on 9411; this spec documents the native legacy api_v2 surface.' license: name: Apache 2.0 url: https://www.apache.org/licenses/LICENSE-2.0 servers: - url: http://localhost:14268 description: Jaeger Collector legacy HTTP endpoint tags: - name: SamplingManager paths: /api/v2/samplingStrategy: post: summary: Get Sampling Strategy description: 'Retrieve the sampling strategy for the named service. The gRPC equivalent is `jaeger.api_v2.SamplingManager/GetSamplingStrategy`.' operationId: getSamplingStrategy tags: - SamplingManager requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/SamplingStrategyParameters' responses: '200': description: Sampling strategy for the requested service. content: application/json: schema: $ref: '#/components/schemas/SamplingStrategyResponse' /sampling: get: summary: Get Sampling Strategy (Legacy) description: 'Legacy HTTP form used by older Jaeger SDKs. The Collector / agent returns the same SamplingStrategyResponse JSON; service name is given via the `service` query parameter.' operationId: getSamplingStrategyLegacy tags: - SamplingManager parameters: - name: service in: query required: true schema: type: string description: Service name to look up. responses: '200': description: Sampling strategy for the requested service. content: application/json: schema: $ref: '#/components/schemas/SamplingStrategyResponse' components: schemas: SamplingStrategyResponse: type: object description: 'Union-style response — exactly one of `probabilisticSampling`, `rateLimitingSampling`, or `operationSampling` will be populated.' properties: strategyType: type: string enum: - PROBABILISTIC - RATE_LIMITING probabilisticSampling: $ref: '#/components/schemas/ProbabilisticSamplingStrategy' rateLimitingSampling: $ref: '#/components/schemas/RateLimitingSamplingStrategy' operationSampling: $ref: '#/components/schemas/PerOperationSamplingStrategies' SamplingStrategyParameters: type: object required: - serviceName properties: serviceName: type: string description: Required service identifier. RateLimitingSamplingStrategy: type: object properties: maxTracesPerSecond: type: integer format: int32 description: Maximum number of traces sampled per second per service instance. PerOperationSamplingStrategies: type: object properties: defaultSamplingProbability: type: number format: double defaultLowerBoundTracesPerSecond: type: number format: double defaultUpperBoundTracesPerSecond: type: number format: double perOperationStrategies: type: array items: $ref: '#/components/schemas/OperationSamplingStrategy' ProbabilisticSamplingStrategy: type: object properties: samplingRate: type: number format: double minimum: 0 maximum: 1 description: Sampling probability in the range [0.0, 1.0]. OperationSamplingStrategy: type: object properties: operation: type: string probabilisticSampling: $ref: '#/components/schemas/ProbabilisticSamplingStrategy'