Topics

GET /topics/{topicname}

Changed on

Retrieves the metadata about a given topic.

Request

  • The document declares no server URL.
  • Auth
    none declared

Response

Topic metadata.

namestring

Name of the topic.

configsobject

Per-topic configuration overrides.

Example response

{
  "name": "topic",
  "offset": 2,
  "configs": {
    "cleanup.policy": "compact"
  },
  "partitions": [
    {
      "partition": 1,
      "leader": 1,
      "replicas": [
        {
          "broker": 1,
          "leader": true,
          "in_sync": true
        },
        {
          "broker": 2,
          "leader": false,
          "in_sync": true
        }
      ]
    },
    {
      "partition": 2,
      "leader": 2,
      "replicas": [
        {
          "broker": 1,
          "leader": false,
          "in_sync": true
        },
        {
          "broker": 2,
          "leader": true,
          "in_sync": true
        }
      ]
    }
  ]
}

Changes