<?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: How to securely access all sub folder of parent folder using REST API in ArcGIS REST APIs and Services Questions</title>
    <link>https://community.esri.com/t5/arcgis-rest-apis-and-services-questions/how-to-securely-access-all-sub-folder-of-parent/m-p/1017751#M3697</link>
    <description>&lt;P&gt;&amp;nbsp;Hi All,&lt;/P&gt;&lt;P&gt;I am able to access the secure folder through browser by manually entering the credentials. But when I try to access it through REST API, I get Invalid Token error.&lt;/P&gt;&lt;P&gt;I am doing the below steps&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;Generating the token using https://xxxxx/arcgis/tokens/generateToken&amp;nbsp;API&lt;/LI&gt;&lt;LI&gt;Then calling&amp;nbsp;&lt;A href="https://xxxxx/arcgis/rest/services/OSvC/?f=json" target="_blank"&gt;https://xxxxx/arcgis/rest/services/OSvC/?f=json&lt;/A&gt;&amp;nbsp;REST API by passing generated token to access subfolder. But I am getting 'Invalid Token'&lt;/LI&gt;&lt;/OL&gt;</description>
    <pubDate>Mon, 18 Jan 2021 20:24:36 GMT</pubDate>
    <dc:creator>anuragmittal</dc:creator>
    <dc:date>2021-01-18T20:24:36Z</dc:date>
    <item>
      <title>How to securely access all sub folder of parent folder using REST API</title>
      <link>https://community.esri.com/t5/arcgis-rest-apis-and-services-questions/how-to-securely-access-all-sub-folder-of-parent/m-p/1017415#M3692</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I want to access all properties of parent folder using Rest API. Its a secured and I am trying to access it though token but not getting any success.&lt;/P&gt;&lt;P&gt;I am following this:&amp;nbsp;&lt;A href="https://developers.arcgis.com/rest/enterprise-administration/server/folder.htm" target="_blank"&gt;https://developers.arcgis.com/rest/enterprise-administration/server/folder.htm&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 15 Jan 2021 22:45:11 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-rest-apis-and-services-questions/how-to-securely-access-all-sub-folder-of-parent/m-p/1017415#M3692</guid>
      <dc:creator>anuragmittal</dc:creator>
      <dc:date>2021-01-15T22:45:11Z</dc:date>
    </item>
    <item>
      <title>Re: How to securely access all sub folder of parent folder using REST API</title>
      <link>https://community.esri.com/t5/arcgis-rest-apis-and-services-questions/how-to-securely-access-all-sub-folder-of-parent/m-p/1017469#M3693</link>
      <description>&lt;P&gt;More info on your API call and error messages would help.&lt;/P&gt;</description>
      <pubDate>Sat, 16 Jan 2021 15:43:16 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-rest-apis-and-services-questions/how-to-securely-access-all-sub-folder-of-parent/m-p/1017469#M3693</guid>
      <dc:creator>DavidPike</dc:creator>
      <dc:date>2021-01-16T15:43:16Z</dc:date>
    </item>
    <item>
      <title>Re: How to securely access all sub folder of parent folder using REST API</title>
      <link>https://community.esri.com/t5/arcgis-rest-apis-and-services-questions/how-to-securely-access-all-sub-folder-of-parent/m-p/1017591#M3694</link>
      <description>&lt;P&gt;Hi David,&lt;/P&gt;&lt;P&gt;I am using PHP curl to access the API. Below is the code. I am getting accessed denied error. Before reaching out to client, I want to know if this is the right approach ?&lt;/P&gt;&lt;LI-CODE lang="php"&gt;				if ( !function_exists( "\curl_init" ) )
				{
					\load_curl();
				}
				$curl = curl_init();
				curl_setopt_array($curl, array(
					CURLOPT_URL =&amp;gt; "https://xxxxx/arcgis/rest/services/OSvC/OSvC_LandUse_Areas/MapServer?f=json",
					CURLOPT_RETURNTRANSFER =&amp;gt; true,
					CURLOPT_ENCODING =&amp;gt; "",
					CURLOPT_MAXREDIRS =&amp;gt; 10,
					CURLOPT_TIMEOUT =&amp;gt; 0,
					CURLOPT_FOLLOWLOCATION =&amp;gt; true,
					CURLOPT_SSL_VERIFYPEER =&amp;gt; 1,
					CURLOPT_SSL_VERIFYHOST =&amp;gt; 2,
					CURLOPT_CAINFO =&amp;gt; '/cgi-bin/' . cfg_get((120)) . '.db/certs/ca.pem',  
					
					CURLOPT_HTTP_VERSION =&amp;gt; CURL_HTTP_VERSION_1_1,
					CURLOPT_CUSTOMREQUEST =&amp;gt; "GET",
					CURLOPT_HTTPHEADER =&amp;gt; array(
						"Authorization: Bearer ".$token,
						"Content-Type: application/json"
					)
				));	
				
				$response = curl_exec($curl);
				$error = curl_error( $curl );
				$code = curl_getinfo($curl, CURLINFO_HTTP_CODE);			
				curl_close($curl);&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 18 Jan 2021 06:19:34 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-rest-apis-and-services-questions/how-to-securely-access-all-sub-folder-of-parent/m-p/1017591#M3694</guid>
      <dc:creator>anuragmittal</dc:creator>
      <dc:date>2021-01-18T06:19:34Z</dc:date>
    </item>
    <item>
      <title>Re: How to securely access all sub folder of parent folder using REST API</title>
      <link>https://community.esri.com/t5/arcgis-rest-apis-and-services-questions/how-to-securely-access-all-sub-folder-of-parent/m-p/1017593#M3695</link>
      <description>&lt;P&gt;Hi David,&lt;/P&gt;&lt;P&gt;My ultimate goal is to get all features layer that are in one particular folder. Let me know if there any other way to doing this.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 18 Jan 2021 06:31:20 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-rest-apis-and-services-questions/how-to-securely-access-all-sub-folder-of-parent/m-p/1017593#M3695</guid>
      <dc:creator>anuragmittal</dc:creator>
      <dc:date>2021-01-18T06:31:20Z</dc:date>
    </item>
    <item>
      <title>Re: How to securely access all sub folder of parent folder using REST API</title>
      <link>https://community.esri.com/t5/arcgis-rest-apis-and-services-questions/how-to-securely-access-all-sub-folder-of-parent/m-p/1017751#M3697</link>
      <description>&lt;P&gt;&amp;nbsp;Hi All,&lt;/P&gt;&lt;P&gt;I am able to access the secure folder through browser by manually entering the credentials. But when I try to access it through REST API, I get Invalid Token error.&lt;/P&gt;&lt;P&gt;I am doing the below steps&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;Generating the token using https://xxxxx/arcgis/tokens/generateToken&amp;nbsp;API&lt;/LI&gt;&lt;LI&gt;Then calling&amp;nbsp;&lt;A href="https://xxxxx/arcgis/rest/services/OSvC/?f=json" target="_blank"&gt;https://xxxxx/arcgis/rest/services/OSvC/?f=json&lt;/A&gt;&amp;nbsp;REST API by passing generated token to access subfolder. But I am getting 'Invalid Token'&lt;/LI&gt;&lt;/OL&gt;</description>
      <pubDate>Mon, 18 Jan 2021 20:24:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-rest-apis-and-services-questions/how-to-securely-access-all-sub-folder-of-parent/m-p/1017751#M3697</guid>
      <dc:creator>anuragmittal</dc:creator>
      <dc:date>2021-01-18T20:24:36Z</dc:date>
    </item>
    <item>
      <title>Re: How to securely access all sub folder of parent folder using REST API</title>
      <link>https://community.esri.com/t5/arcgis-rest-apis-and-services-questions/how-to-securely-access-all-sub-folder-of-parent/m-p/1019534#M3705</link>
      <description>&lt;P&gt;Hi,I am not sure how u are passing the token but you can try the following&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;A href="https://xxxxx/arcgis/rest/services/OSvC/?f=json" target="_blank" rel="nofollow noopener noreferrer"&gt;https://xxxxx/arcgis/rest/services/OSvC/?f=json&amp;amp;token=fdnfdasfdsajffsdfa&lt;/A&gt;&lt;/P&gt;</description>
      <pubDate>Mon, 25 Jan 2021 05:45:24 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-rest-apis-and-services-questions/how-to-securely-access-all-sub-folder-of-parent/m-p/1019534#M3705</guid>
      <dc:creator>VictorTey</dc:creator>
      <dc:date>2021-01-25T05:45:24Z</dc:date>
    </item>
  </channel>
</rss>

