I'm planning to bring the Kafka as a Service. I would need any client or command-line tools to add a cluster. Right now, I'm able to add from Cloudera Manager, but I would want to do it from the CLI. Do we have any API or any leads to get this done?
You can use the Cloudera Manager API call something like following to start/stop Kafka Service (or any desired service)
In order to stop "kafka" service:
# curl -iLv -u admin:admin -X POST --header 'Accept: application/json' 'ttp://dc-1.example.com:7180/api/v40/clusters/TestCluster/services/kafka/commands/stop'
In order to start "kafka" Service
# curl -iLv -u admin:admin -X POST --header 'Accept: application/json' 'ttp://dc-1.example.com:7180/api/v40/clusters/TestCluster/services/kafka/commands/start'
Please also take a look at the Cloudera Manager Swagger APIs.
Cloudera Manager(CM) 6.0 introduces new Python API client cm_client based on Swagger. This new API client supports all CM API versions.
Here please replace the CM credentials and cluster name in CM host port in the above mentioned API calls.