<?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 Re: FMC - How to get multiple objects with the rest API? in Network Security</title>
    <link>https://community.cisco.com/t5/network-security/fmc-how-to-get-multiple-objects-with-the-rest-api/m-p/4754129#M1096711</link>
    <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;-&amp;nbsp;&amp;nbsp;Try to&amp;nbsp; use the bulk export feature to export multiple objects of the same type (e.g. networks, host objects, object groups) in one API call. The URL for bulk export is as follows:&lt;/P&gt;
&lt;P&gt;{{protocol}}://{{hostname}}/api/fmc_config/v1/domain/{{domain_id}}/object/{{object_type}}?expanded=true&amp;amp;limit={{limit}}&amp;amp;offset={{offset}}&lt;/P&gt;
&lt;P&gt;where:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;{{protocol}} is the protocol used to access the FMC (e.g. https)&lt;/LI&gt;
&lt;LI&gt;{{hostname}} is the hostname or IP address of the FMC&lt;/LI&gt;
&lt;LI&gt;{{domain_id}} is the ID of the domain to which the objects belong&lt;/LI&gt;
&lt;LI&gt;{{object_type}} is the type of objects to be exported (e.g. networks, hostobjects, objectgroups)&lt;/LI&gt;
&lt;LI&gt;{{limit}} is the number of objects to be exported per API call&lt;/LI&gt;
&lt;LI&gt;{{offset}} is the starting position of the objects to be exported&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;You can also filter the export by adding additional query parameters to the url.&lt;/P&gt;
&lt;P&gt;For example, you could use the following URL to export all network objects in the domain with ID "12345678-1234-1234-1234-123456789abc":&lt;/P&gt;
&lt;P&gt;{{protocol}}://{{hostname}}/api/fmc_config/v1/domain/12345678-1234-1234-1234-123456789abc/object/networks?expanded=true&lt;/P&gt;
&lt;P&gt;It's also possible to export multiple object types in one call. To do this, you would need to use the export endpoint with the object types separated by commas.&lt;/P&gt;
&lt;P&gt;For example:&lt;/P&gt;
&lt;P&gt;{{protocol}}://{{hostname}}/api/fmc_config/v1/domain/{{domain_id}}/object/networks,hostobjects,objectgroups&lt;/P&gt;
&lt;P&gt;&amp;nbsp;M.&lt;/P&gt;</description>
    <pubDate>Fri, 13 Jan 2023 07:07:10 GMT</pubDate>
    <dc:creator>Mark Elsen</dc:creator>
    <dc:date>2023-01-13T07:07:10Z</dc:date>
    <item>
      <title>FMC - How to get multiple objects with the rest API?</title>
      <link>https://community.cisco.com/t5/network-security/fmc-how-to-get-multiple-objects-with-the-rest-api/m-p/4753250#M1096668</link>
      <description>&lt;P&gt;Hi experts, I am wondering if I can GET multiple network objects in one API call to the FMC. I found the following URL for querying one network object (from the postman collection)&lt;/P&gt;&lt;LI-CODE lang="markup"&gt;{{protocol}}://{{hostname}}/api/fmc_config/v1/domain/{{domain_id}}/object/networks/{{network_id}}&lt;/LI-CODE&gt;&lt;P&gt;&lt;SPAN class=""&gt;&lt;SPAN&gt;I also have the same need for host objects and object groups and I hope the solution is the same for them.&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;&lt;SPAN&gt;Thanks!&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class=""&gt;&lt;SPAN&gt;Difan&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 11 Jan 2023 22:12:21 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-security/fmc-how-to-get-multiple-objects-with-the-rest-api/m-p/4753250#M1096668</guid>
      <dc:creator>Difan_Zhao</dc:creator>
      <dc:date>2023-01-11T22:12:21Z</dc:date>
    </item>
    <item>
      <title>Re: FMC - How to get multiple objects with the rest API?</title>
      <link>https://community.cisco.com/t5/network-security/fmc-how-to-get-multiple-objects-with-the-rest-api/m-p/4753519#M1096682</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;U&gt;&lt;EM&gt; &amp;nbsp;Check if these procedures could work for you (not tested myself)&amp;nbsp; , or else you may '&lt;STRONG&gt;take hints&lt;/STRONG&gt;' from these info's&lt;/EM&gt;&lt;/U&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;-&amp;nbsp;&lt;SPAN&gt;To get multiple objects with the REST API on Cisco FMC, you can use the &lt;/SPAN&gt;&lt;CODE&gt;GET&lt;/CODE&gt;&lt;SPAN&gt; method and specify the objects you want to retrieve in the URL. For example, to get all of the objects in the "object_group" resource, you can use the following URL:&lt;/SPAN&gt;&lt;BR /&gt;&amp;nbsp; &amp;nbsp;&lt;STRONG&gt;https://&amp;lt;FMC IP&amp;gt;/api/fmc_config/v1/domain/e276abec-e0f2-11e3-8169-6d9ed49b625f/object/objectgroups&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;You can also filter the objects you retrieve by specifying query parameters in the URL. For example, to get all objects in the "object_group" resource that have the name "TestGroup", you can use the following URL:&lt;BR /&gt;&lt;/SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;STRONG&gt; &amp;nbsp;https://&amp;lt;FMC IP&amp;gt;/api/fmc_config/v1/domain/e276abec-e0f2-11e3-8169-6d9ed49b625f/object/objectgroups?name=TestGroup&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;Make sure to replace the &lt;CODE&gt;&amp;lt;FMC IP&amp;gt;&lt;/CODE&gt; placeholder with the actual IP address or hostname of your Cisco FMC device, and &lt;CODE&gt;e276abec-e0f2-11e3-8169-6d9ed49b625f&lt;/CODE&gt; with your domain UUID. You should also include a valid &lt;CODE&gt;Authorization&lt;/CODE&gt; header in your &lt;CODE&gt;GET&lt;/CODE&gt; request, with a value of "Bearer &amp;lt;access_token&amp;gt;", where &lt;CODE&gt;&amp;lt;access_token&amp;gt;&lt;/CODE&gt; is a valid token obtained by authenticating to the Cisco FMC.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;M.&lt;/P&gt;</description>
      <pubDate>Thu, 12 Jan 2023 09:43:21 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-security/fmc-how-to-get-multiple-objects-with-the-rest-api/m-p/4753519#M1096682</guid>
      <dc:creator>Mark Elsen</dc:creator>
      <dc:date>2023-01-12T09:43:21Z</dc:date>
    </item>
    <item>
      <title>Re: FMC - How to get multiple objects with the rest API?</title>
      <link>https://community.cisco.com/t5/network-security/fmc-how-to-get-multiple-objects-with-the-rest-api/m-p/4753866#M1096706</link>
      <description>&lt;P&gt;Thanks, Marce for your response. I apologize that I might not make my question clear... I know how to query for a specific object or all objects. However, is it possible to query for several objects with their object IDs?&lt;/P&gt;</description>
      <pubDate>Thu, 12 Jan 2023 17:53:47 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-security/fmc-how-to-get-multiple-objects-with-the-rest-api/m-p/4753866#M1096706</guid>
      <dc:creator>Difan_Zhao</dc:creator>
      <dc:date>2023-01-12T17:53:47Z</dc:date>
    </item>
    <item>
      <title>Re: FMC - How to get multiple objects with the rest API?</title>
      <link>https://community.cisco.com/t5/network-security/fmc-how-to-get-multiple-objects-with-the-rest-api/m-p/4754129#M1096711</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;-&amp;nbsp;&amp;nbsp;Try to&amp;nbsp; use the bulk export feature to export multiple objects of the same type (e.g. networks, host objects, object groups) in one API call. The URL for bulk export is as follows:&lt;/P&gt;
&lt;P&gt;{{protocol}}://{{hostname}}/api/fmc_config/v1/domain/{{domain_id}}/object/{{object_type}}?expanded=true&amp;amp;limit={{limit}}&amp;amp;offset={{offset}}&lt;/P&gt;
&lt;P&gt;where:&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;{{protocol}} is the protocol used to access the FMC (e.g. https)&lt;/LI&gt;
&lt;LI&gt;{{hostname}} is the hostname or IP address of the FMC&lt;/LI&gt;
&lt;LI&gt;{{domain_id}} is the ID of the domain to which the objects belong&lt;/LI&gt;
&lt;LI&gt;{{object_type}} is the type of objects to be exported (e.g. networks, hostobjects, objectgroups)&lt;/LI&gt;
&lt;LI&gt;{{limit}} is the number of objects to be exported per API call&lt;/LI&gt;
&lt;LI&gt;{{offset}} is the starting position of the objects to be exported&lt;/LI&gt;
&lt;/UL&gt;
&lt;P&gt;You can also filter the export by adding additional query parameters to the url.&lt;/P&gt;
&lt;P&gt;For example, you could use the following URL to export all network objects in the domain with ID "12345678-1234-1234-1234-123456789abc":&lt;/P&gt;
&lt;P&gt;{{protocol}}://{{hostname}}/api/fmc_config/v1/domain/12345678-1234-1234-1234-123456789abc/object/networks?expanded=true&lt;/P&gt;
&lt;P&gt;It's also possible to export multiple object types in one call. To do this, you would need to use the export endpoint with the object types separated by commas.&lt;/P&gt;
&lt;P&gt;For example:&lt;/P&gt;
&lt;P&gt;{{protocol}}://{{hostname}}/api/fmc_config/v1/domain/{{domain_id}}/object/networks,hostobjects,objectgroups&lt;/P&gt;
&lt;P&gt;&amp;nbsp;M.&lt;/P&gt;</description>
      <pubDate>Fri, 13 Jan 2023 07:07:10 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-security/fmc-how-to-get-multiple-objects-with-the-rest-api/m-p/4754129#M1096711</guid>
      <dc:creator>Mark Elsen</dc:creator>
      <dc:date>2023-01-13T07:07:10Z</dc:date>
    </item>
    <item>
      <title>Re: FMC - How to get multiple objects with the rest API?</title>
      <link>https://community.cisco.com/t5/network-security/fmc-how-to-get-multiple-objects-with-the-rest-api/m-p/4754324#M1096738</link>
      <description>&lt;P&gt;I do not believe it is possible to GET multiple network objects based on their ID in one GET call, I don't think the API in FMC supports this...yet.&lt;/P&gt;</description>
      <pubDate>Fri, 13 Jan 2023 14:36:50 GMT</pubDate>
      <guid>https://community.cisco.com/t5/network-security/fmc-how-to-get-multiple-objects-with-the-rest-api/m-p/4754324#M1096738</guid>
      <dc:creator>Marius Gunnerud</dc:creator>
      <dc:date>2023-01-13T14:36:50Z</dc:date>
    </item>
  </channel>
</rss>

