{
  "id": "kafkactl",
  "name": "kafkactl",
  "homepage": "https://github.com/deviceinsight/kafkactl",
  "description": "A command-line interface for interaction with Apache Kafka.",
  "executables": [
    "kafkactl"
  ],
  "dotfiles": {
    "paths": [
      "[configHome]/kafkactl/config.yml",
      "~/.kafkactl/config.yml"
    ],
    "exclude": [
      "[configHome]/kafkactl/current-context.yml",
      "~/.kafkactl/current-context.yml"
    ],
    "secret": [],
    "side_effect": false,
    "secret_paths": [
      {
        "file": [
          "[configHome]/kafkactl/config.yml",
          "~/.kafkactl/config.yml"
        ],
        "match": {
          "key_path": [
            "contexts.*.sasl.password",
            "contexts.*.tls.certKeyPassphrase",
            "contexts.*.schemaRegistry.password",
            "contexts.*.schemaRegistry.tls.certKeyPassphrase"
          ]
        }
      }
    ]
  },
  "commands": {
    "format": 1,
    "label": "kafkactl",
    "description": "Consume and produce messages and list topics. Protobuf, Avro and admin commands are left out.",
    "quality": "ai-draft",
    "base": "fig:kafkactl",
    "parser": {
      "end_of_options": "--",
      "interleave": "permute",
      "long_equals": true,
      "short_attached": true,
      "short_bundles": false
    },
    "source": [
      {
        "id": "fig",
        "kind": "completion",
        "url": "https://github.com/withfig/autocomplete/blob/master/src/kafkactl.ts",
        "license": "MIT"
      }
    ],
    "subcommand": [
      {
        "path": [
          "consume"
        ],
        "label": "Consume messages",
        "source": [
          {
            "id": "fig",
            "kind": "completion",
            "url": "https://github.com/withfig/autocomplete/blob/master/src/kafkactl.ts",
            "license": "MIT"
          }
        ],
        "field": [
          {
            "id": "topic",
            "label": "Topic",
            "type": "string",
            "position": 0,
            "sources": [
              "fig"
            ]
          },
          {
            "id": "from_beginning",
            "label": "From beginning",
            "type": "boolean",
            "option": [
              "--from-beginning",
              "-b"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "exit",
            "label": "Stop at latest offset",
            "type": "boolean",
            "option": [
              "--exit",
              "-e"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "group",
            "label": "Consumer group",
            "type": "string",
            "option": [
              "--group",
              "-g"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "max_messages",
            "label": "Max messages",
            "type": "integer",
            "option": [
              "--max-messages"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "tail",
            "label": "Last N messages",
            "type": "integer",
            "option": [
              "--tail"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "print_keys",
            "label": "Print keys",
            "type": "boolean",
            "option": [
              "--print-keys",
              "-k"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "print_timestamps",
            "label": "Print timestamps",
            "type": "boolean",
            "option": [
              "--print-timestamps",
              "-t"
            ],
            "sources": [
              "fig"
            ]
          }
        ],
        "task": [
          {
            "id": "peek",
            "label": "Read existing messages",
            "set": {
              "from_beginning": [
                true
              ],
              "exit": [
                true
              ]
            },
            "fields": [
              "topic",
              "from_beginning",
              "exit",
              "max_messages"
            ],
            "required": [
              "topic"
            ]
          }
        ],
        "group": [
          {
            "id": "basic",
            "label": "Basic",
            "fields": [
              "topic",
              "from_beginning",
              "exit",
              "group",
              "max_messages",
              "tail",
              "print_keys",
              "print_timestamps"
            ]
          }
        ]
      },
      {
        "path": [
          "produce"
        ],
        "label": "Produce a message",
        "source": [
          {
            "id": "fig",
            "kind": "completion",
            "url": "https://github.com/withfig/autocomplete/blob/master/src/kafkactl.ts",
            "license": "MIT"
          }
        ],
        "field": [
          {
            "id": "topic",
            "label": "Topic",
            "type": "string",
            "position": 0,
            "sources": [
              "fig"
            ]
          },
          {
            "id": "value",
            "label": "Value",
            "type": "string",
            "option": [
              "--value",
              "-v"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "key",
            "label": "Key",
            "type": "string",
            "option": [
              "--key",
              "-k"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "file",
            "label": "Read from file",
            "type": "path",
            "option": [
              "--file",
              "-f"
            ],
            "path": {
              "kind": "file",
              "role": "input"
            },
            "sources": [
              "fig"
            ]
          },
          {
            "id": "partition",
            "label": "Partition",
            "type": "integer",
            "option": [
              "--partition",
              "-p"
            ],
            "sources": [
              "fig"
            ]
          },
          {
            "id": "header",
            "label": "Headers (key:value)",
            "type": "string",
            "option": [
              "--header",
              "-H"
            ],
            "multiple": true,
            "sources": [
              "fig"
            ]
          }
        ],
        "task": [
          {
            "id": "one",
            "label": "Send one message",
            "fields": [
              "topic",
              "value",
              "key"
            ],
            "required": [
              "topic",
              "value"
            ]
          }
        ],
        "group": [
          {
            "id": "basic",
            "label": "Basic",
            "fields": [
              "topic",
              "value",
              "key",
              "file",
              "partition",
              "header"
            ]
          }
        ]
      },
      {
        "path": [
          "list",
          "topics"
        ],
        "label": "List topics",
        "source": [
          {
            "id": "fig",
            "kind": "completion",
            "url": "https://github.com/withfig/autocomplete/blob/master/src/kafkactl.ts",
            "license": "MIT"
          }
        ],
        "field": [
          {
            "id": "output",
            "label": "Output format",
            "type": "enum",
            "option": [
              "--output",
              "-o"
            ],
            "choices": [
              {
                "value": "json",
                "label": "JSON"
              },
              {
                "value": "yaml",
                "label": "YAML"
              },
              {
                "value": "wide",
                "label": "Wide"
              },
              {
                "value": "compact",
                "label": "Compact"
              }
            ],
            "sources": [
              "fig"
            ]
          }
        ],
        "group": [
          {
            "id": "basic",
            "label": "Basic",
            "fields": [
              "output"
            ]
          }
        ]
      }
    ]
  }
}
