<?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>Contact CenterのトピックRe: NonGadgetPythonSample</title>
    <link>https://community.cisco.com/t5/contact-center/nongadgetpythonsample/m-p/4871939#M13910</link>
    <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.cisco.com/t5/user/viewprofilepage/user-id/121926"&gt;@Keith Abbott&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;For calling the API endpoint /finesse/api/User/myUser, the credentials(loginid &amp;amp; pwd) used should be of the user 'myUser' itself, or the administrator. For security reasons, one user's data cannot be accessed by another user's credentials. The error clearly says that the user ID in the URL and in the authentication header are different.&lt;/P&gt;
&lt;P&gt;This holds good for PUT requests too(here additionally the supervisor can change state). Looks like the login ID and password that you set are not of 'myUser'&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Update: Edited. Supervisor of the user cannot access the User object of another user. Only the user or the administrator can access the User details.&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Renjith Alexander&lt;/P&gt;</description>
    <pubDate>Wed, 12 Jul 2023 19:49:19 GMT</pubDate>
    <dc:creator>realexan</dc:creator>
    <dc:date>2023-07-12T19:49:19Z</dc:date>
    <item>
      <title>NonGadgetPythonSample</title>
      <link>https://community.cisco.com/t5/contact-center/nongadgetpythonsample/m-p/4871929#M13909</link>
      <description>&lt;P&gt;Good Day,&lt;/P&gt;&lt;P&gt;Im playing around a little with the sample python code created by dekwan ( &lt;A href="https://github.com/CiscoDevNet/finesse-sample-code/tree/master/NonGadgetPythonSample" target="_blank" rel="noopener"&gt;https://github.com/CiscoDevNet/finesse-sample-code/tree/master/NonGadgetPythonSample&lt;/A&gt; )&lt;/P&gt;&lt;P&gt;using REST APIs and python to see/change agent states, with the end game of checking for agents in 50002 state and change them back to their previous state.&lt;/P&gt;&lt;P&gt;Long before there at step 1, Im just trying to get the sample code running. We're running Finesse 11.6&lt;/P&gt;&lt;P&gt;Im starting with dekwan's code with no changes except updating the&lt;/P&gt;&lt;P&gt;URL / domain / finesse user login id&amp;nbsp; and pw / scheme (http or https) and port&lt;/P&gt;&lt;P&gt;For the latter 2 Im using https and port 8445 (Ive tried other ports and http with other ports) &amp;nbsp; -&amp;nbsp;&amp;nbsp;&amp;nbsp; for user id and pw Im using a finesse agent login that I am able to successfully log in with interactively.&amp;nbsp;&amp;nbsp;&amp;nbsp; -&amp;nbsp;&amp;nbsp;&amp;nbsp; for the URL Im using the host and domain portion of the same url Id use to log into finesse interactively.&lt;/P&gt;&lt;P&gt;however on&amp;nbsp; 'Executing GET '&lt;A href="https://finesseSvr.ourCompany.com:8445/finesse/api/User/myUser" target="_blank" rel="noopener"&gt;https://finesseSvr.ourCompany.com:8445/finesse/api/User/myUser&lt;/A&gt;' I get a string of various errors similar to this:&lt;BR /&gt;&lt;FONT color="#339966"&gt;GET User - ID: myUser&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#339966"&gt;REST API URL is: '&lt;A href="https://finesseSvr.ourCompany.com:8445/finesse/api/User/myUser" target="_blank" rel="noopener"&gt;https://finesseSvr.ourCompany.com:8445/finesse/api/User/myUser&lt;/A&gt;'&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#339966"&gt;Executing GET '&lt;A href="https://finesseSvr.ourCompany.coms.com:8445/finesse/api/User/myUser" target="_blank" rel="noopener"&gt;https://finesseSvr.ourCompany.coms.com:8445/finesse/api/User/myUser&lt;/A&gt;'&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#FF0000"&gt;C:\Program Files (x86)\Python38-32\lib\site-packages\urllib3\connectionpool.py:979: InsecureRequestWarning: Unverified HTTPS request is being made to host 'myUser.com'. Adding certificate verification is strongly advised. See: &lt;A href="https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings" target="_blank" rel="noopener"&gt;https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings&lt;/A&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#339966"&gt;warnings.warn(&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#339966"&gt;GET() - Status: 401&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#339966"&gt;GET() - Text: &amp;lt;ApiErrors&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#339966"&gt;&amp;lt;ApiError&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#339966"&gt;&amp;lt;ErrorType&amp;gt;Invalid Authorization User Specified&amp;lt;/ErrorType&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#339966"&gt;&amp;lt;ErrorData&amp;gt;myuser&amp;lt;/ErrorData&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#339966"&gt;&amp;lt;ErrorMessage&amp;gt;The user specified in the authentication credentials and the uri don&amp;amp;apos;t match&amp;lt;/ErrorMessage&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#339966"&gt;&amp;lt;/ApiError&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#339966"&gt;&amp;lt;/ApiErrors&amp;gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;I DO, subsequently, get a successful connection to XMPP&amp;nbsp;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#339966"&gt;"Connecting to the Finesse Notification Service.&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#339966"&gt;Waiting 2 seconds to establish a connection.&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#339966"&gt;The XMPP connection is successful."&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;but on the subsequent puts, etc I continue to get the 401s (along with the &lt;FONT color="#339966"&gt;'&amp;lt;ErrorType&amp;gt;User does not belong to Supervisor's Teams&amp;lt;/ErrorType&amp;gt;' &lt;FONT color="#000000"&gt;Errors.&amp;nbsp;&amp;nbsp; (BTW 'myUser' is a supervisor of all teams as well as an agent)&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#339966"&gt;&lt;FONT color="#000000"&gt;Ive read a couple of other threads in places where it seemed the problem was usually the agent id/pw but Ive double and triple checked that unless Im misunderstanding and should be using some other credentials.&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#339966"&gt;&lt;FONT color="#000000"&gt;Does anyone have any suggestions on how I can move forward?&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT color="#339966"&gt;&lt;FONT color="#000000"&gt;thanks&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 11 Jul 2023 18:30:07 GMT</pubDate>
      <guid>https://community.cisco.com/t5/contact-center/nongadgetpythonsample/m-p/4871929#M13909</guid>
      <dc:creator>Keith Abbott</dc:creator>
      <dc:date>2023-07-11T18:30:07Z</dc:date>
    </item>
    <item>
      <title>Re: NonGadgetPythonSample</title>
      <link>https://community.cisco.com/t5/contact-center/nongadgetpythonsample/m-p/4871939#M13910</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.cisco.com/t5/user/viewprofilepage/user-id/121926"&gt;@Keith Abbott&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;For calling the API endpoint /finesse/api/User/myUser, the credentials(loginid &amp;amp; pwd) used should be of the user 'myUser' itself, or the administrator. For security reasons, one user's data cannot be accessed by another user's credentials. The error clearly says that the user ID in the URL and in the authentication header are different.&lt;/P&gt;
&lt;P&gt;This holds good for PUT requests too(here additionally the supervisor can change state). Looks like the login ID and password that you set are not of 'myUser'&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Update: Edited. Supervisor of the user cannot access the User object of another user. Only the user or the administrator can access the User details.&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Renjith Alexander&lt;/P&gt;</description>
      <pubDate>Wed, 12 Jul 2023 19:49:19 GMT</pubDate>
      <guid>https://community.cisco.com/t5/contact-center/nongadgetpythonsample/m-p/4871939#M13910</guid>
      <dc:creator>realexan</dc:creator>
      <dc:date>2023-07-12T19:49:19Z</dc:date>
    </item>
    <item>
      <title>Re: NonGadgetPythonSample</title>
      <link>https://community.cisco.com/t5/contact-center/nongadgetpythonsample/m-p/4871947#M13913</link>
      <description>&lt;P&gt;Thanks for the reply realexan,&lt;/P&gt;&lt;P&gt;Let me see if I can review the code and see where its falling down&lt;/P&gt;</description>
      <pubDate>Tue, 11 Jul 2023 19:21:19 GMT</pubDate>
      <guid>https://community.cisco.com/t5/contact-center/nongadgetpythonsample/m-p/4871947#M13913</guid>
      <dc:creator>Keith Abbott</dc:creator>
      <dc:date>2023-07-11T19:21:19Z</dc:date>
    </item>
    <item>
      <title>Re: NonGadgetPythonSample</title>
      <link>https://community.cisco.com/t5/contact-center/nongadgetpythonsample/m-p/4872716#M13918</link>
      <description>&lt;P&gt;Hi realexan,&lt;/P&gt;&lt;P&gt;I hate to be a slow-coach but Im still not finding the problem.&lt;/P&gt;&lt;P&gt;I added a buncha print statements in each sub, to see where things were going and what was being passed, and it all looked good minus the part where it fails.&lt;/P&gt;&lt;P&gt;The first thing (non-setup) it hits is sub __init__, which code is:&lt;/P&gt;&lt;P class="lia-indent-padding-left-30px"&gt;&lt;FONT size="2"&gt;def __init__(self, username, password, scheme, fqdn, port, domain):&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;# Get the information from the config file&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;print("INsub __init__")&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;print ("UN '%s'\n" % username)&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;print ("PW '%s'\n" % password)&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;print ("scheme '%s'\n" % scheme)&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;print ("fqdn'%s'\n" % fqdn)&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;print ("port '%s'\n" % port)&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;print ("domain '%s'\n" % domain)&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;self.scheme = scheme&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;self.fqdn = fqdn&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;self.port = port&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;self.domain = domain&lt;/FONT&gt;&lt;/P&gt;&lt;P class="lia-indent-padding-left-30px"&gt;&lt;FONT size="2"&gt;self.username = username&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;self.password = password&lt;/FONT&gt;&lt;/P&gt;&lt;P class="lia-indent-padding-left-30px"&gt;&lt;FONT size="2"&gt;# Call the GET user API (and store the XML response)&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;self.getUser(id=self.username)&lt;/FONT&gt;&lt;/P&gt;&lt;P class="lia-indent-padding-left-30px"&gt;&lt;FONT size="2"&gt;# Establish a connection to the Finesse Notification Service&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;self.xmppConnection = Jabber(self.username, password, self.domain)&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;self.xmppConnection['feature_mechanisms'].unencrypted_plain = True&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;print("Connecting to the Finesse Notification Service.")&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;if self.xmppConnection.connect(address=(self.fqdn, 5222), use_tls=False, use_ssl=False):&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;print("Waiting 2 seconds to establish a connection.")&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;self.xmppConnection.process(block=False)&lt;/FONT&gt;&lt;/P&gt;&lt;P class="lia-indent-padding-left-30px"&gt;&lt;FONT size="2"&gt;# Need to wait a couple of seconds before calling a REST API&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;self.waitForNotification()&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;print("The XMPP connection is successful.")&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;else:&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;print("Failed to connect to XMPP.")&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;sys.exit(0)&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;print("OUT __init__")&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;This code results in output/error(each sub call is bounded by an INsub/OUTsub print statement pair:&lt;/P&gt;&lt;P&gt;&lt;FONT size="2"&gt;INsub __init__&lt;/FONT&gt;&lt;/P&gt;&lt;P class="lia-indent-padding-left-30px"&gt;&lt;FONT size="2"&gt;UN 'myUser'&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;PW '12345abc'&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;scheme 'https'&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;fqdn'finesseSVR.ourCompany.com'&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;port '8445'&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;domain 'ourCompany.com'&lt;/FONT&gt;&lt;/P&gt;&lt;P class="lia-indent-padding-left-30px"&gt;&lt;FONT size="2"&gt;INsub getUser&lt;/FONT&gt;&lt;/P&gt;&lt;P class="lia-indent-padding-left-60px"&gt;&lt;FONT size="2"&gt;GET User - ID: myUser&lt;/FONT&gt;&lt;/P&gt;&lt;P class="lia-indent-padding-left-60px"&gt;&lt;FONT size="2"&gt;INsub getURLPrefix&lt;/FONT&gt;&lt;/P&gt;&lt;P class="lia-indent-padding-left-90px"&gt;&lt;FONT size="2"&gt;REST API URL is: '&lt;A href="https://finesseSVR.ourCompany.com:8445/finesse/api/User/myUser" target="_blank"&gt;https://finesseSVR.ourCompany.com:8445/finesse/api/User/myUser&lt;/A&gt;'&lt;/FONT&gt;&lt;/P&gt;&lt;P class="lia-indent-padding-left-60px"&gt;&lt;FONT size="2"&gt;OUTsub getURLPrefix&lt;/FONT&gt;&lt;/P&gt;&lt;P class="lia-indent-padding-left-60px"&gt;&lt;FONT size="2"&gt;Executing subGET '&lt;A href="https://finesseSVR.ourCompany.com:8445/finesse/api/User/myUser" target="_blank"&gt;https://finesseSVR.ourCompany.com:8445/finesse/api/User/myUser&lt;/A&gt;'&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;UN'myUser'&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;PW'12345abc'&lt;/FONT&gt;&lt;/P&gt;&lt;P class="lia-indent-padding-left-60px"&gt;&lt;FONT size="2"&gt;C:\Program Files (x86)\Python38-32\lib\site-packages\urllib3\connectionpool.py:979: InsecureRequestWarning: Unverified HTTPS request is being made to host 'finesseSVR.ourCompany.com'. Adding certificate verification is strongly advised. See: &lt;A href="https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings" target="_blank"&gt;https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings&lt;/A&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;warnings.warn(&lt;/FONT&gt;&lt;/P&gt;&lt;P class="lia-indent-padding-left-60px"&gt;&lt;FONT size="2"&gt;Insub printRESTAPIResponse&lt;/FONT&gt;&lt;/P&gt;&lt;P class="lia-indent-padding-left-90px"&gt;&lt;FONT size="2"&gt;GET() - Status: 401&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;GET() - Text: &amp;lt;ApiErrors&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;ApiError&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;ErrorType&amp;gt;Invalid Authorization User Specified&amp;lt;/ErrorType&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;ErrorData&amp;gt;myUser&amp;lt;/ErrorData&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;ErrorMessage&amp;gt;The user specified in the authentication credentials and the uri don&amp;amp;apos;t match&amp;lt;/ErrorMessage&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;/ApiError&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;/ApiErrors&amp;gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P class="lia-indent-padding-left-60px"&gt;&lt;FONT size="2"&gt;OUTsub printRESTAPIResponse&lt;/FONT&gt;&lt;/P&gt;&lt;P class="lia-indent-padding-left-30px"&gt;&lt;FONT size="2"&gt;OUTsub getUser&lt;/FONT&gt;&lt;/P&gt;&lt;P class="lia-indent-padding-left-30px"&gt;&lt;FONT size="2"&gt;IN CLASS Jabber&lt;/FONT&gt;&lt;/P&gt;&lt;P class="lia-indent-padding-left-60px"&gt;&lt;FONT size="2"&gt;self'&amp;lt;__main__.Jabber object at 0x02EEACA0&amp;gt;'&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;UN 'myUser'&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;PW '12345abc'&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;domain '%s'&amp;lt;blank&amp;gt;'%s'&lt;/FONT&gt;&lt;/P&gt;&lt;P class="lia-indent-padding-left-30px"&gt;&lt;FONT size="2"&gt;OUT CLASS Jabber&lt;/FONT&gt;&lt;/P&gt;&lt;P class="lia-indent-padding-left-30px"&gt;&lt;FONT size="2"&gt;Connecting to the Finesse Notification Service.&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;Waiting 2 seconds to establish a connection.&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;The XMPP connection is successful.&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="2"&gt;OUT __init__&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="4"&gt;As you can see (or at least as it appears to me) Im passing the same creds each time. Those creds are for my agent which is a member of a team on which Im a supervisor, so covered both ways. It appears to die at sub '&lt;FONT size="2"&gt;printRESTAPIResponse&lt;/FONT&gt;' which code is this:&lt;/FONT&gt;&lt;/P&gt;&lt;P class="lia-indent-padding-left-30px"&gt;&lt;FONT size="4"&gt;&lt;BR /&gt;&lt;FONT size="3"&gt;def printRESTAPIResponse(prefix='printRESTAPIResponse()', response=''):&lt;/FONT&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P class="lia-indent-padding-left-60px"&gt;&lt;FONT size="3"&gt;"""&lt;BR /&gt;Print the REST API response with the HTTP Request status code&lt;BR /&gt;and the Response body text&lt;BR /&gt;"""&lt;BR /&gt;print("Insub printRESTAPIResponse")&lt;BR /&gt;print (prefix + " - Status: ", response.status_code) # This is the http request status&lt;BR /&gt;print (prefix + " - Text: ", response.text)&lt;BR /&gt;print ("\n")&lt;BR /&gt;print("OUTsub printRESTAPIResponse")&lt;BR /&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="3"&gt;Any thoughts/pointings on where to go from here?&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;Thx&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 12 Jul 2023 18:02:53 GMT</pubDate>
      <guid>https://community.cisco.com/t5/contact-center/nongadgetpythonsample/m-p/4872716#M13918</guid>
      <dc:creator>Keith Abbott</dc:creator>
      <dc:date>2023-07-12T18:02:53Z</dc:date>
    </item>
    <item>
      <title>Re: NonGadgetPythonSample</title>
      <link>https://community.cisco.com/t5/contact-center/nongadgetpythonsample/m-p/4872803#M13919</link>
      <description>&lt;P&gt;Wait! I Got it thanks to a tip in another post by dekwan&lt;/P&gt;&lt;P&gt;"Scenario 1 should work as far as agents being able to access their own information. For &lt;STRONG&gt;UCCE, you must use the agentId&lt;/STRONG&gt; rather than the agent login name. So in your case, it should be /finesse/User/&lt;SPAN&gt;47483650"&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;at &lt;A href="https://community.cisco.com/t5/contact-center/how-to-get-once-the-stanza-from-the-xmpp-connection/m-p/3584744#M7748" target="_blank"&gt;https://community.cisco.com/t5/contact-center/how-to-get-once-the-stanza-from-the-xmpp-connection/m-p/3584744#M7748&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;Thanks for your help!&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 12 Jul 2023 20:14:07 GMT</pubDate>
      <guid>https://community.cisco.com/t5/contact-center/nongadgetpythonsample/m-p/4872803#M13919</guid>
      <dc:creator>Keith Abbott</dc:creator>
      <dc:date>2023-07-12T20:14:07Z</dc:date>
    </item>
    <item>
      <title>Re: NonGadgetPythonSample</title>
      <link>https://community.cisco.com/t5/contact-center/nongadgetpythonsample/m-p/4872838#M13920</link>
      <description>&lt;P&gt;Great.... I thought 'myUser' was a placeholder for the actual user ID, as you didn't want to expose agent IDs here. &lt;LI-EMOJI id="lia_slightly-smiling-face" title=":slightly_smiling_face:"&gt;&lt;/LI-EMOJI&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 12 Jul 2023 21:32:35 GMT</pubDate>
      <guid>https://community.cisco.com/t5/contact-center/nongadgetpythonsample/m-p/4872838#M13920</guid>
      <dc:creator>realexan</dc:creator>
      <dc:date>2023-07-12T21:32:35Z</dc:date>
    </item>
    <item>
      <title>Re: NonGadgetPythonSample</title>
      <link>https://community.cisco.com/t5/contact-center/nongadgetpythonsample/m-p/4873526#M13924</link>
      <description>&lt;P&gt;That was indeed true, but it did mask a user login rather than a userID.&lt;/P&gt;&lt;P&gt;Now just trying to figure out why&lt;/P&gt;&lt;P&gt;&lt;FONT size="2"&gt;PUT() data: &lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;User&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;state&amp;gt;NOT_READY&amp;lt;/state&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;/User&amp;gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;Gives error&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;PUT() - Status: 400&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;PUT() - Text: &amp;lt;ApiErrors&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;ApiError&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;ErrorType&amp;gt;Parameter Missing&amp;lt;/ErrorType&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;ErrorData&amp;gt;finesse.api.reasoncode.require_reasoncode&amp;lt;/ErrorData&amp;gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;ErrorMessage&amp;gt;The state change requires a valid reason code.&amp;lt;/ErrorMessage&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;/ApiError&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;/ApiErrors&amp;gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="4"&gt;I assume (as it says) that a reason code is required when changing states. But Ive tried using both the ReasonCodeID, and ReasonCode (5004 and 1008) as strings and both produce this (with appropriate number)&lt;BR /&gt;&lt;BR /&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="4"&gt;&lt;FONT size="2"&gt;PUT() data: &lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;User&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;state&amp;gt;NOT_READY&amp;lt;/state&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;reasonCodeId&amp;gt;5004&amp;lt;/reasonCodeId&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;/User&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="4"&gt;&lt;FONT size="2"&gt;PUT() - Status: 400&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;PUT() - Text: &amp;lt;ApiErrors&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;ApiError&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;ErrorType&amp;gt;Invalid Input&amp;lt;/ErrorType&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;ErrorData&amp;gt;finesse.api.reasoncode.not_valid&amp;lt;/ErrorData&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;ErrorMessage&amp;gt;The Reason Code specified in the request does not exist&amp;lt;/ErrorMessage&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;/ApiError&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;/ApiErrors&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT size="4"&gt;Interestingly, 1008 gives a slightly different error:&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="2"&gt;404 and ReasonCode does not exist, codeId=1008&amp;lt;/ErrorMessage&amp;gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&lt;FONT size="4"&gt;Is ReasonCodeID the correct code to use (vs ReasonCode)?&lt;BR /&gt;Any thoughts on why the correct one is saying it doesnt exist?&amp;nbsp; I have verified the 1008/5004 code is a reason code available for my team.&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;FONT size="4"&gt;thanks&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 13 Jul 2023 12:57:48 GMT</pubDate>
      <guid>https://community.cisco.com/t5/contact-center/nongadgetpythonsample/m-p/4873526#M13924</guid>
      <dc:creator>Keith Abbott</dc:creator>
      <dc:date>2023-07-13T12:57:48Z</dc:date>
    </item>
    <item>
      <title>Re: NonGadgetPythonSample</title>
      <link>https://community.cisco.com/t5/contact-center/nongadgetpythonsample/m-p/4873696#M13927</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.cisco.com/t5/user/viewprofilepage/user-id/121926"&gt;@Keith Abbott&lt;/a&gt;&amp;nbsp;,&lt;/P&gt;
&lt;P&gt;The unique reason code IDs are system generated and not exposed to the users directly. What you have passed might be the numeric reason code that you created.&lt;/P&gt;
&lt;P&gt;For retrieving the reason code IDs belonging to the reason codes associated with a particular agent's team, you can issue a GET request on the resource /finesse/api/User/&amp;lt;user-id&amp;gt;/ReasonCodes?category=&amp;lt;NOT_READY|LOGOUT|ALL&amp;gt;.&lt;/P&gt;
&lt;P&gt;Please refer to&amp;nbsp;&lt;A href="https://developer.cisco.com/docs/finesse/#!user%e2%80%94get-reason-code-list/userget-reason-code-list" target="_blank"&gt;https://developer.cisco.com/docs/finesse/#!user%e2%80%94get-reason-code-list/userget-reason-code-list&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;Here is a sample response:&lt;/P&gt;
&lt;P&gt;#&amp;gt; curl -k &lt;A href="https://finesse-primary-node:8445/finesse/api/User/1001050/ReasonCodes?category=NOT_READY" target="_blank"&gt;https://finesse-primary-node:8445/finesse/api/User/1001050/ReasonCodes?category=NOT_READY&lt;/A&gt; -u '1001050:pwdfor50'&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;&amp;lt;?xml version="1.0" encoding="UTF-8" standalone="yes"?&amp;gt;&lt;BR /&gt;&amp;lt;ReasonCodes category="NOT_READY"&amp;gt;&lt;BR /&gt;&amp;lt;ReasonCode&amp;gt;&lt;BR /&gt;&amp;lt;uri&amp;gt;/finesse/api/ReasonCode/7618&amp;lt;/uri&amp;gt;&lt;BR /&gt;&lt;STRONG&gt;&amp;lt;id&amp;gt;7618&amp;lt;/id&amp;gt;&lt;/STRONG&gt;&lt;BR /&gt;&amp;lt;category&amp;gt;NOT_READY&amp;lt;/category&amp;gt;&lt;BR /&gt;&amp;lt;code&amp;gt;25137&amp;lt;/code&amp;gt;&lt;BR /&gt;&amp;lt;label&amp;gt;Tea break&amp;lt;/label&amp;gt;&lt;BR /&gt;&amp;lt;forAll&amp;gt;true&amp;lt;/forAll&amp;gt;&lt;BR /&gt;&amp;lt;systemCode&amp;gt;false&amp;lt;/systemCode&amp;gt;&lt;BR /&gt;&amp;lt;/ReasonCode&amp;gt;&lt;BR /&gt;&amp;lt;ReasonCode&amp;gt;&lt;BR /&gt;&amp;lt;uri&amp;gt;/finesse/api/ReasonCode/7619&amp;lt;/uri&amp;gt;&lt;BR /&gt;&lt;STRONG&gt;&amp;lt;id&amp;gt;7619&amp;lt;/id&amp;gt;&lt;/STRONG&gt;&lt;BR /&gt;&amp;lt;category&amp;gt;NOT_READY&amp;lt;/category&amp;gt;&lt;BR /&gt;&amp;lt;code&amp;gt;26960&amp;lt;/code&amp;gt;&lt;BR /&gt;&amp;lt;label&amp;gt;Lunch Break&amp;lt;/label&amp;gt;&lt;BR /&gt;&amp;lt;forAll&amp;gt;true&amp;lt;/forAll&amp;gt;&lt;BR /&gt;&amp;lt;systemCode&amp;gt;false&amp;lt;/systemCode&amp;gt;&lt;BR /&gt;&amp;lt;/ReasonCode&amp;gt;&lt;BR /&gt;&amp;lt;ReasonCode&amp;gt;&lt;BR /&gt;&amp;lt;uri&amp;gt;/finesse/api/ReasonCode/7622&amp;lt;/uri&amp;gt;&lt;BR /&gt;&lt;STRONG&gt;&amp;lt;id&amp;gt;7622&amp;lt;/id&amp;gt;&lt;/STRONG&gt;&lt;BR /&gt;&amp;lt;category&amp;gt;NOT_READY&amp;lt;/category&amp;gt;&lt;BR /&gt;&amp;lt;code&amp;gt;48673&amp;lt;/code&amp;gt;&lt;BR /&gt;&amp;lt;label&amp;gt;Other&amp;lt;/label&amp;gt;&lt;BR /&gt;&amp;lt;forAll&amp;gt;true&amp;lt;/forAll&amp;gt;&lt;BR /&gt;&amp;lt;systemCode&amp;gt;false&amp;lt;/systemCode&amp;gt;&lt;BR /&gt;&amp;lt;/ReasonCode&amp;gt;&lt;BR /&gt;&amp;lt;/ReasonCodes&amp;gt;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Renjith Alexander&lt;/P&gt;</description>
      <pubDate>Thu, 13 Jul 2023 16:03:44 GMT</pubDate>
      <guid>https://community.cisco.com/t5/contact-center/nongadgetpythonsample/m-p/4873696#M13927</guid>
      <dc:creator>realexan</dc:creator>
      <dc:date>2023-07-13T16:03:44Z</dc:date>
    </item>
    <item>
      <title>Re: NonGadgetPythonSample</title>
      <link>https://community.cisco.com/t5/contact-center/nongadgetpythonsample/m-p/4873729#M13928</link>
      <description>&lt;P&gt;Perfect!&lt;/P&gt;&lt;P&gt;Thanks Realexan.&lt;/P&gt;&lt;P&gt;My ver came up a little different than your sample response but I used the URI code and it worked like a charm:&lt;/P&gt;&lt;P class="lia-indent-padding-left-30px"&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;ReasonCodes category="NOT_READY"&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;ReasonCode&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;uri&amp;gt;/finesse/api/ReasonCode/&lt;FONT color="#339966"&gt;&lt;STRONG&gt;33&lt;/STRONG&gt;&lt;/FONT&gt;&amp;lt;/uri&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;category&amp;gt;NOT_READY&amp;lt;/category&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;code&amp;gt;1008&amp;lt;/code&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;label&amp;gt;IS Problem&amp;lt;/label&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;forAll&amp;gt;false&amp;lt;/forAll&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;systemCode&amp;gt;false&amp;lt;/systemCode&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;/ReasonCode&amp;gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT size="2"&gt;&amp;lt;ReasonCode&amp;gt;&lt;/FONT&gt;&lt;/P&gt;&lt;P&gt;Hopefully with the tools you provided I can move forward!&lt;/P&gt;</description>
      <pubDate>Thu, 13 Jul 2023 16:34:01 GMT</pubDate>
      <guid>https://community.cisco.com/t5/contact-center/nongadgetpythonsample/m-p/4873729#M13928</guid>
      <dc:creator>Keith Abbott</dc:creator>
      <dc:date>2023-07-13T16:34:01Z</dc:date>
    </item>
    <item>
      <title>Re: NonGadgetPythonSample</title>
      <link>https://community.cisco.com/t5/contact-center/nongadgetpythonsample/m-p/4873738#M13929</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.cisco.com/t5/user/viewprofilepage/user-id/121926"&gt;@Keith Abbott&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Glad to hear that it helped.&lt;/P&gt;
&lt;P&gt;You must be using an older release of Finesse. The more recent versions have the ID as part of the URL as well as within a separate tag.&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;Renjith Alexander&lt;/P&gt;</description>
      <pubDate>Thu, 13 Jul 2023 16:43:42 GMT</pubDate>
      <guid>https://community.cisco.com/t5/contact-center/nongadgetpythonsample/m-p/4873738#M13929</guid>
      <dc:creator>realexan</dc:creator>
      <dc:date>2023-07-13T16:43:42Z</dc:date>
    </item>
  </channel>
</rss>

