# Boto(ec2) documentation confusing, ec2\_vpc\_net\_facts

**URL:** <https://forum.ansible.com/t/boto-ec2-documentation-confusing-ec2-vpc-net-facts/20751>\
**Category:** Ansible Project\
**Tags:** aws\
**Created:** [March 2, 2016, 4:37pm UTC](https://forum.ansible.com/t/boto-ec2-documentation-confusing-ec2-vpc-net-facts/20751 "2016-03-02T16:37:57Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![viper233](https://sea1.discourse-cdn.com/ansible/user_avatar/forum.ansible.com/viper233/32/2060_2.png) [@viper233](https://forum.ansible.com/u/viper233)\
**Post date:** [March 2, 2016, 4:37pm UTC](https://forum.ansible.com/t/boto-ec2-documentation-confusing-ec2-vpc-net-facts/20751/1 "2016-03-02T16:37:57Z")

</div>

I spent some time trying to use this module and had trouble finding documentation for the filters to pass in. E.g isDefault is actually is\_default, vpc\_id, id is actually vpc-d, and even though most of the documentation points to is\_default being a boolean I had to pass it in as a string e.g.

# Get the vpc id

- name: Get the VPC net details  
ec2\_vpc\_net\_facts:  
aws\_access\_key: “{{ aws\_access\_key }}”  
aws\_secret\_key: “{{ aws\_secret\_key }}”  
region: “{{ aws\_region }}”  
filters:  
is\_default: “true”  
register: returned\_vpc

- name: The VPC id  
debug:  
var: returned\_vpc.vpcs[0].id

[http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API\_DescribeVpcs.html](http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeVpcs.html)  
[http://docs.aws.amazon.com/AWSEC2/latest/CommandLineReference/ApiReference-cmd-DescribeVpcs.html](http://docs.aws.amazon.com/AWSEC2/latest/CommandLineReference/ApiReference-cmd-DescribeVpcs.html)

[http://boto.cloudhackers.com/en/latest/ref/vpc.html#boto.vpc.VPCConnection.get\_all\_vpcs](http://boto.cloudhackers.com/en/latest/ref/vpc.html#boto.vpc.VPCConnection.get_all_vpcs)

There seems to be conflicting variable names and types used through out.

Is there something I’m missing in regards what filters to pass? how variables are set? their types? It all seems pretty confusing and inconsistent, what (documentation/reference) am I missing?

Thanks!

---

<div class="post-metadata">

**Author:** ![Joaquin\_Menchaca](https://avatars.discourse-cdn.com/v4/letter/j/d2c977/32.png) [@Joaquin\_Menchaca](https://forum.ansible.com/u/Joaquin_Menchaca)\
**Post date:** [April 9, 2018, 12:37am UTC](https://forum.ansible.com/t/boto-ec2-documentation-confusing-ec2-vpc-net-facts/20751/2 "2018-04-09T00:37:11Z")

</div>

**filters:**  
**isDefault: “true”**

As per [https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API\_DescribeVpcs.html](https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_DescribeVpcs.html)

is\_default is not correct.
