How to associate hosts to group with the new 'awx' Command Line Interface

‘tower-cli’ is the legacy command line tool for Ansible Tower.

‘tower-cli host’ can associate/disassociate a group to/from a host

https://tower-cli.readthedocs.io/en/latest/api_ref/resources/host.html

But now tower-cli is no longer under active development. This tool is being phased out in favor of the new official AWX CLI.

awx is the new official command-line client for AWX and Red Hat Ansible Tower

https://docs.ansible.com/ansible-tower/latest/html/towercli/index.html

the problem is that I have nowhere found an awx option allowing, like tower-cli, to associate a host with a group.

An issue that addresses this exact problem has been filed here https://github.com/ansible/awx/issues/6056, so please keep an eye on it re: progress/solutions as we’re aware of this and it’s on the AWX “to-do list”!