<?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 Qlik replicate AEM API returning SYS,UNRECOGNIZED_REQUEST_PATTERN,GET,/v1/servers in Integration, Extension &amp; APIs</title>
    <link>https://community.qlik.com/t5/Integration-Extension-APIs/Qlik-replicate-AEM-API-returning-SYS-UNRECOGNIZED-REQUEST/m-p/2432072#M20224</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;I'm following AEM API documentation here&lt;/P&gt;
&lt;P&gt;&lt;A href="https://help.qlik.com/en-US/enterprise-manager/May2021/Content/EnterpriseManager/EnterpriseManager_APIGuide/CurlAPI/api_login.htm" target="_blank"&gt;https://help.qlik.com/en-US/enterprise-manager/May2021/Content/EnterpriseManager/EnterpriseManager_APIGuide/CurlAPI/api_login.htm&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;and able to login and getting APISessionID, but when APISessionID returned is passed to other APIs such as&amp;nbsp;&lt;/P&gt;
&lt;P&gt;/api/v1/servers it's returning application-status as 500 and error as "&lt;SPAN&gt;SYS-E-UNRECREQ, Unrecognized request pattern 'GET: /v1/servers'."&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Can someone help me, what's missing?&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 18 Mar 2024 20:57:48 GMT</pubDate>
    <dc:creator>wama</dc:creator>
    <dc:date>2024-03-18T20:57:48Z</dc:date>
    <item>
      <title>Qlik replicate AEM API returning SYS,UNRECOGNIZED_REQUEST_PATTERN,GET,/v1/servers</title>
      <link>https://community.qlik.com/t5/Integration-Extension-APIs/Qlik-replicate-AEM-API-returning-SYS-UNRECOGNIZED-REQUEST/m-p/2432072#M20224</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;I'm following AEM API documentation here&lt;/P&gt;
&lt;P&gt;&lt;A href="https://help.qlik.com/en-US/enterprise-manager/May2021/Content/EnterpriseManager/EnterpriseManager_APIGuide/CurlAPI/api_login.htm" target="_blank"&gt;https://help.qlik.com/en-US/enterprise-manager/May2021/Content/EnterpriseManager/EnterpriseManager_APIGuide/CurlAPI/api_login.htm&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;and able to login and getting APISessionID, but when APISessionID returned is passed to other APIs such as&amp;nbsp;&lt;/P&gt;
&lt;P&gt;/api/v1/servers it's returning application-status as 500 and error as "&lt;SPAN&gt;SYS-E-UNRECREQ, Unrecognized request pattern 'GET: /v1/servers'."&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Can someone help me, what's missing?&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 18 Mar 2024 20:57:48 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Integration-Extension-APIs/Qlik-replicate-AEM-API-returning-SYS-UNRECOGNIZED-REQUEST/m-p/2432072#M20224</guid>
      <dc:creator>wama</dc:creator>
      <dc:date>2024-03-18T20:57:48Z</dc:date>
    </item>
    <item>
      <title>Re: Qlik replicate AEM API returning SYS,UNRECOGNIZED_REQUEST_PATTERN,GET,/v1/servers</title>
      <link>https://community.qlik.com/t5/Integration-Extension-APIs/Qlik-replicate-AEM-API-returning-SYS-UNRECOGNIZED-REQUEST/m-p/2509306#M21902</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I had the same error in powershell script that should stop task.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Problem is with codding url parameters.&lt;BR /&gt;&lt;BR /&gt;below my full working script:&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;
&lt;DIV&gt;# Configuration&lt;/DIV&gt;
&lt;DIV&gt;$qlik_ent_man_url = "&lt;A href="https://XXX.XXX.XXX.XXX" target="_blank"&gt;https://XXX.XXX.XXX.XXX&lt;/A&gt;"&lt;/DIV&gt;
&lt;DIV&gt;$credentials_login = 'my_login_name'&lt;/DIV&gt;
&lt;DIV&gt;$credentials_password = 'my_login_password'&lt;/DIV&gt;
&lt;DIV&gt;$credentials_domain = 'my_hostname_or_domain'&lt;/DIV&gt;
&lt;DIV&gt;$server_name = "my_Qlik_Replicate_name_in_QEM"&amp;nbsp;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;$task_name = "my_task_name"&amp;nbsp;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;$stop_timeout = 600&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;# Login - Retrieve apisessionid&lt;/DIV&gt;
&lt;DIV&gt;$credentials_enc = [Convert]::ToBase64String([Text.Encoding]::UTF8.GetBytes("${credentials_domain}\${credentials_login}:${credentials_password}"))&lt;/DIV&gt;
&lt;DIV&gt;$session = new-object microsoft.powershell.commands.webrequestsession&lt;/DIV&gt;
&lt;DIV&gt;$response = Invoke-WebRequest -Uri "$qlik_ent_man_url/attunityenterprisemanager/api/v1/login" -Headers @{ "Authorization" = "Basic $credentials_enc" } -WebSession $Session -Method POST -SkipCertificateCheck&lt;/DIV&gt;
&lt;DIV&gt;$session_id = $response.Headers["EnterpriseManager.APISessionID"]&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;# Check if session ID was retrieved successfully&lt;/DIV&gt;
&lt;DIV&gt;if (-not $session_id) {&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; Write-Host "Login failed! Could not retrieve 'apisessionid'." -ForegroundColor Red&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; exit 1&lt;/DIV&gt;
&lt;DIV&gt;}&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;Write-Host "Successfully logged in. Stopping task..." -ForegroundColor Green&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;# Stop task&lt;/DIV&gt;
&lt;DIV&gt;$headers = @{&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; "EnterpriseManager.APISessionID" = "$session_id"&lt;/DIV&gt;
&lt;DIV&gt;}&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;# function quote_param to encode URL params&lt;/DIV&gt;
&lt;DIV&gt;function Quote-Param {&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; param([string]$param)&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; return [System.Net.WebUtility]::UrlEncode($param)&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; }&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;$task_url = "$qlik_ent_man_url/attunityenterprisemanager/api/v1/servers/" + (Quote-Param $server_name) + "/tasks/" + (Quote-Param $task_name) + "?action=stop&amp;amp;timeout=" + (Quote-Param $stop_timeout) + ""&lt;/DIV&gt;
&lt;DIV&gt;try {&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt; $task_stop = Invoke-WebRequest&amp;nbsp; -Uri $task_url -Headers $headers -WebSession $Session -Method POST -SkipCertificateCheck&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; }&lt;/DIV&gt;
&lt;DIV&gt;catch {&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp; &amp;nbsp; Write-Host "Server responsed with error: $_"&amp;nbsp; -ForegroundColor RED&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt; exit 1&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;}&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;$task_info = $task_stop.Content | ConvertFrom-Json&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;Write-Host "[ Task Stopping:&amp;nbsp; $($task_info.state) ($($task_info.error_message)) ]"&amp;nbsp; -ForegroundColor GREEN&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;# Logout session&lt;/DIV&gt;
&lt;DIV&gt;$logout_details = Invoke-WebRequest -Uri "$qlik_ent_man_url/attunityenterprisemanager/api/v1/logout" -Headers @{ "EnterpriseManager.APISessionID" = "$session_id" } -Method POST -SkipCertificateCheck&lt;/DIV&gt;
&lt;DIV&gt;Write-Host "Logged out successfully." -ForegroundColor Green&lt;/DIV&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 11 Mar 2025 15:48:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Integration-Extension-APIs/Qlik-replicate-AEM-API-returning-SYS-UNRECOGNIZED-REQUEST/m-p/2509306#M21902</guid>
      <dc:creator>TomaszRomanowski</dc:creator>
      <dc:date>2025-03-11T15:48:58Z</dc:date>
    </item>
  </channel>
</rss>

