Agents

Get Agent Sample Record

Changed on

Pull the latest record from the topic that matches topicPattern.

Useful as a concrete sample record for POST /agents/test-run. Returns 200 in every "no record" case (regex matches no topic, every matched topic is empty, deserialization fails), with the reason in the response body rather than an HTTP error.

Requires read:agents.

Per-tenant rate limit: 30 req/min -> 429 with Retry-After.

post/agents/sample-record

Request

Request body

topicPatternstring required

Regex pattern for input topics, e.g. '^(orders)$'

inputSerialization'AvroConfluent' | 'JsonConfluent' | 'Protobuf' | 'String' required

Input deserialization formats accepted by POST /agents/sample-record.

Wider than AgentSerializationEnum (the formats a deployed agent accepts): this endpoint also accepts the other formats a topic may carry, so a sample can be pulled from any topic regardless of how it is produced.

Response

Successful Response

recordobject nullable

The latest deserialized record, or null if none was found

sourceTopicstring nullable

Concrete topic name the record came from after regex resolution

errorMessagestring nullable

Set when a topic was found but its latest record could not be read or deserialized

Changes