# Can the -i option of dynamic inventory accept a json directly instead of a executable file ?

**URL:** <https://forum.ansible.com/t/can-the-i-option-of-dynamic-inventory-accept-a-json-directly-instead-of-a-executable-file/18233>\
**Category:** Ansible Project\
**Tags:** ansible-project\
**Created:** [May 14, 2015, 7:15pm UTC](https://forum.ansible.com/t/can-the-i-option-of-dynamic-inventory-accept-a-json-directly-instead-of-a-executable-file/18233 "2015-05-14T19:15:18Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![Shaps](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/shaps/32/1356_2.png) [@Shaps](https://forum.ansible.com/u/Shaps)\
**Post date:** [May 14, 2015, 7:15pm UTC](https://forum.ansible.com/t/can-the-i-option-of-dynamic-inventory-accept-a-json-directly-instead-of-a-executable-file/18233/1 "2015-05-14T19:15:18Z")

</div>

Hi,

no unfortunatelyou cannot pass any variable to the dynamic inventory, it will be called automatically by ansible with the host or list argument.  
The only way you have is either setting env variables or having a config file.
