newrelic_accept_distributed_trace_payload_httpsafe

newrelic_accept_distributed_trace_payload_httpsafe(string $httpsafe_payload, string $transport_type)
Accepts a distributed trace payload that includes an HTTPSafe (Base64 encoded) JSON string.

Requirements

Requires PHP agent version 8.4 or higher.

Description

Distributed tracing allows you to see the path that a request takes as it travels through a distributed system. This is useful, for example, when individual transactions occur in multiple services, and you want to examine them as a complete transaction trace.

Use this API method to accept a distributed trace payload that includes an HTTPSafe (Base64 encoded) JSON string representation of the payload.

Parameters

Parameter Description

$httpsafe_payload

string

Required. An HTTPSafe (Base64 encoded) JSON string representation of the payload.

$transport_type

string

Optional. A string overriding the default transport type.

Default values:

  • HTTP for web traffic
  • Unknown for non-web traffic

Additional accepted values:

  • AMQP
  • HTTP
  • HTTPS
  • IronMQ
  • JMS
  • Kafka
  • Other
  • Queue

Return value(s)

Returns true to indicate success, or false if an error occurs.

Example(s)

For examples of how and when to use this API method, see the documentation to manually instrument applications and services.

For more help

Recommendations for learning more: