<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Retrieving a value from Cluster, and assign it to a variable in Playbook in Software Development Kit (SDK) and API Discussions</title>
    <link>https://community.netapp.com/t5/Software-Development-Kit-SDK-and-API-Discussions/Retrieving-a-value-from-Cluster-and-assign-it-to-a-variable-in-Playbook/m-p/157907#M3069</link>
    <description>&lt;P&gt;How can I retrieve the corresponding export policy name based on a known volume name, then assign it to a variable in Playbook. The goal is to use the NA module to create a rule based on the policy name.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I don't know if Playbook can do that. Thank you!&lt;/P&gt;</description>
    <pubDate>Wed, 04 Jun 2025 11:00:23 GMT</pubDate>
    <dc:creator>netappmagic</dc:creator>
    <dc:date>2025-06-04T11:00:23Z</dc:date>
    <item>
      <title>Retrieving a value from Cluster, and assign it to a variable in Playbook</title>
      <link>https://community.netapp.com/t5/Software-Development-Kit-SDK-and-API-Discussions/Retrieving-a-value-from-Cluster-and-assign-it-to-a-variable-in-Playbook/m-p/157907#M3069</link>
      <description>&lt;P&gt;How can I retrieve the corresponding export policy name based on a known volume name, then assign it to a variable in Playbook. The goal is to use the NA module to create a rule based on the policy name.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I don't know if Playbook can do that. Thank you!&lt;/P&gt;</description>
      <pubDate>Wed, 04 Jun 2025 11:00:23 GMT</pubDate>
      <guid>https://community.netapp.com/t5/Software-Development-Kit-SDK-and-API-Discussions/Retrieving-a-value-from-Cluster-and-assign-it-to-a-variable-in-Playbook/m-p/157907#M3069</guid>
      <dc:creator>netappmagic</dc:creator>
      <dc:date>2025-06-04T11:00:23Z</dc:date>
    </item>
    <item>
      <title>Re: Retrieving a value from Cluster, and assign it to a variable in Playbook</title>
      <link>https://community.netapp.com/t5/Software-Development-Kit-SDK-and-API-Discussions/Retrieving-a-value-from-Cluster-and-assign-it-to-a-variable-in-Playbook/m-p/158549#M3074</link>
      <description>&lt;P&gt;Not sure if this is the best way to do it you can make an API call to the OnTap system to get the export policy name.&lt;/P&gt;
&lt;P&gt;---&lt;BR /&gt;- hosts: localhost&lt;BR /&gt;tasks:&lt;BR /&gt;- name: Get NetApp UUID of Volume&lt;BR /&gt;uri:&lt;BR /&gt;url: https://cluster_name/api/storage/volumes?name=volume_name&amp;amp;fields=nas.export_policy.name&amp;amp;return_records=true&amp;amp;return_timeout=15&lt;BR /&gt;url_username: username&lt;BR /&gt;url_password: password&lt;BR /&gt;method: GET&lt;BR /&gt;force_basic_auth: yes&lt;BR /&gt;validate_certs: no&lt;BR /&gt;register: vol_export_policy&lt;BR /&gt;- name: Set export policy fact&lt;BR /&gt;set_fact:&lt;BR /&gt;export_policy: "{{ vol_export_policy.json.records[0].nas.export_policy.name }}"&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 12 Aug 2020 09:29:53 GMT</pubDate>
      <guid>https://community.netapp.com/t5/Software-Development-Kit-SDK-and-API-Discussions/Retrieving-a-value-from-Cluster-and-assign-it-to-a-variable-in-Playbook/m-p/158549#M3074</guid>
      <dc:creator>Trubida</dc:creator>
      <dc:date>2020-08-12T09:29:53Z</dc:date>
    </item>
  </channel>
</rss>

