nerdexam
Cisco

350-901 · Question #82

Complete the Ansible task below to enable VLAN support on a Meraki MX device. Drag the correct options into the designated slots. Not all options may be used.

This Ansible task configures VLAN support on a Meraki MX device using the uri module. The draggable options were: delegate_to: localhost loop: "{{ result.results }}" method: PUT when: "{{ result.results }}" method: PATCH body: application/json Based on the 'Answer Area' and…

Network Automation

Question

Complete the Ansible task below to enable VLAN support on a Meraki MX device. Drag the correct options into the designated slots. Not all options may be used.

Exhibit

350-901 question #82 exhibit

Explanation

This Ansible task configures VLAN support on a Meraki MX device using the uri module. The draggable options were:

  • delegate_to: localhost
  • loop: "{{ result.results }}"
  • method: PUT
  • when: "{{ result.results }}" method: PATCH
  • body: application/json

Based on the 'Answer Area' and 'Explanation' on page 3, the correct placements for completing the uri task are:

- name: Enable VLAN support on MX
  uri:
    url: "https://api.meraki.com/api/v0/networks/{{ item.data.id }}/vlansEnabledState"
    return_content: yes
    headers:
      X-Cisco-Meraki-API-Key: "{{ meraki_api_key }}"
      body:
        enabled: true
    follow_redirects: all
    status_code: 200
    body_format: json
  delegate_to: localhost
  loop: "{{ result.results }}"
  method: PUT

The options when: "{{ result.results }}" method: PATCH and body: application/json are not used. The explanation specifically notes that 'It should be PUT and loop. Note: There is no PATCH operation for Meraki devices.'

Topics

#Ansible#Meraki API#Network Automation#VLANs

Community Discussion

No community discussion yet for this question.

Full 350-901 Practice