# Delete hosts from Dynamic Inventory in AWX

**URL:** <https://forum.ansible.com/t/delete-hosts-from-dynamic-inventory-in-awx/29628>\
**Category:** AWX Project\
**Tags:** vmware, awx\
**Created:** [February 6, 2019, 11:51am UTC](https://forum.ansible.com/t/delete-hosts-from-dynamic-inventory-in-awx/29628 "2019-02-06T11:51:09Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Ankit2](https://avatars.discourse-cdn.com/v4/letter/a/ea5d25/32.png) [@Ankit2](https://forum.ansible.com/u/Ankit2)\
**Post date:** [February 6, 2019, 11:51am UTC](https://forum.ansible.com/t/delete-hosts-from-dynamic-inventory-in-awx/29628/1 "2019-02-06T11:51:09Z")

</div>

Can someone please suggest if there is a way to delete specific hosts after the Dynamic Inventory for VMWare completes updating the list of hosts?  
I want to create a separate job template where the playbook will target and delete specific hostnames from the VMWare Dynamic inventory in AWX.

---

<div class="post-metadata">

**Author:** ![matburt](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/matburt/32/3612_2.png) [@matburt](https://forum.ansible.com/u/matburt)\
**Post date:** [February 6, 2019, 3:00pm UTC](https://forum.ansible.com/t/delete-hosts-from-dynamic-inventory-in-awx/29628/2 "2019-02-06T15:00:29Z")

</div>

I think my question would be, why do you want to do this… but if you need to write a playbook to do this then just call DELETE on the host from the api: `/api/v2/hosts/<hostid>/`
