<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
</head>
<body>
<p>Actually, even the "pipeline" can be removed, by embedding the
action right into the "search" element:</p>
<p><font face="monospace">{<br>
"@ns" :
<a class="moz-txt-link-rfc2396E" href="http://midpoint.evolveum.com/xml/ns/public/model/scripting-3">"http://midpoint.evolveum.com/xml/ns/public/model/scripting-3"</a>,<br>
"search" : {<br>
"type": "UserType",<br>
"searchFilter": {<br>
"@ns" :
<a class="moz-txt-link-rfc2396E" href="http://prism.evolveum.com/xml/ns/public/query-3">"http://prism.evolveum.com/xml/ns/public/query-3"</a>,<br>
"inOid": {<br>
"value": [<br>
"00000000-0000-0000-0000-000000000002"<br>
]<br>
}<br>
},<br>
"assign": {<br>
"targetRef": {<br>
"oid":"00000000-0000-0000-0000-000000000008",<br>
"type":"RoleType"<br>
}<br>
}<br>
}<br>
}</font><br>
</p>
<p>For more scripting examples, please see <a
moz-do-not-send="true"
href="https://github.com/Evolveum/midpoint/tree/master/model/model-intest/src/test/resources/scripting"
class="moz-txt-link-freetext">https://github.com/Evolveum/midpoint/tree/master/model/model-intest/src/test/resources/scripting</a>
directory.<br>
</p>
<pre class="moz-signature" cols="72">--
Pavol Mederly
Software developer
evolveum.com</pre>
<div class="moz-cite-prefix">On 21/06/2022 13:16, Pavol Mederly via
midPoint wrote:<br>
</div>
<blockquote type="cite"
cite="mid:ff897a8f-4964-ff92-e315-60ca07686da7@evolveum.com">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<p>Hello Alexander,</p>
<p>actually, there was a couple of problems in your JSON code,
mainly related to namespace.</p>
<p>This one is parseable:</p>
<p><font face="monospace">{<br>
"@ns" : "<font color="#0000ff"><a
class="moz-txt-link-freetext"
href="http://midpoint.evolveum.com/xml/ns/public/model/scripting-3"
moz-do-not-send="true">http://midpoint.evolveum.com/xml/ns/public/model/scripting-3</a></font>",<br>
"pipeline": [<br>
{<br>
"@element": "search",<br>
"type": "c:UserType",<br>
"searchFilter": {<br>
<font color="#0000ff">"@ns" : <a
class="moz-txt-link-rfc2396E"
href="http://prism.evolveum.com/xml/ns/public/query-3"
moz-do-not-send="true">"http://prism.evolveum.com/xml/ns/public/query-3"</a>,</font><br>
"inOid": {<br>
"value": [<br>
"c38dc04a-e780-4475-ad51-f42dd054f622",<br>
"cd244459-81fe-4208-a51c-111cae039185",<br>
"12d665c0-7114-4b49-97ba-94c4cd154f8a"<br>
]<br>
}<br>
}<br>
},<br>
{<br>
"@element": "sequence",<br>
"@value": [<br>
{<br>
"@element": "action",<br>
"type": "assign",<br>
"parameter": {<br>
<font color="#0000ff">"name"</font>:
"role",<br>
"<font color="#0000ff"><a
class="moz-txt-link-freetext"
href="http://midpoint.evolveum.com/xml/ns/public/common/common-3#value"
moz-do-not-send="true">http://midpoint.evolveum.com/xml/ns/public/common/common-3#value</a></font>":
{<br>
<font color="#0000ff">"@type":
"string",</font><br>
<font color="#0000ff">"@value": </font>"a6afcd50-5f33-4250-8b93-62cb72e1a39a"<br>
}<br>
}<br>
}<br>
]<br>
}<br>
]<br>
}</font></p>
<p>(the changes are highlighted)</p>
<p>Note that since 4.2 it's possible to write the actions in more
compact, statically-typed way. See <a moz-do-not-send="true"
href="https://docs.evolveum.com/midpoint/reference/misc/bulk/actions/"
class="moz-txt-link-freetext">https://docs.evolveum.com/midpoint/reference/misc/bulk/actions/</a>
or <a moz-do-not-send="true"
href="https://github.com/Evolveum/midpoint/blob/30e5a166e566a99517dedb48680622a8c651c1ea/model/model-intest/src/test/resources/scripting/assign-pirate-manager-to-will.xml"
class="moz-txt-link-freetext">https://github.com/Evolveum/midpoint/blob/30e5a166e566a99517dedb48680622a8c651c1ea/model/model-intest/src/test/resources/scripting/assign-pirate-manager-to-will.xml</a>
for an XML sample.<br>
</p>
<p>Like this (I have also removed "sequence" as it superfluous
here):</p>
<p><font face="monospace">{<br>
"@ns" : <a class="moz-txt-link-rfc2396E"
href="http://midpoint.evolveum.com/xml/ns/public/model/scripting-3"
moz-do-not-send="true">"http://midpoint.evolveum.com/xml/ns/public/model/scripting-3"</a>,<br>
"pipeline": [<br>
{<br>
"@element": "search",<br>
"type": "UserType",<br>
"searchFilter": {<br>
"@ns" : <a class="moz-txt-link-rfc2396E"
href="http://prism.evolveum.com/xml/ns/public/query-3"
moz-do-not-send="true">"http://prism.evolveum.com/xml/ns/public/query-3"</a>,<br>
"inOid": {<br>
"value": [<br>
"00000000-0000-0000-0000-000000000002"<br>
]<br>
}<br>
}<br>
},<br>
{<br>
"@element": "assign",<br>
"targetRef": {<br>
"oid": "00000000-0000-0000-0000-000000000008",<br>
"type": "RoleType"<br>
}<br>
}<br>
]<br>
}</font><br>
</p>
<p>Best regards,<br>
</p>
<pre class="moz-signature" cols="72">--
Pavol Mederly
Software developer
evolveum.com</pre>
<div class="moz-cite-prefix">On 21/06/2022 12:12, Alexander
Bruckner via midPoint wrote:<br>
</div>
<blockquote type="cite"
cite="mid:VI1PR05MB3439D1A4E9F19B6FDD63E8CEF2B39@VI1PR05MB3439.eurprd05.prod.outlook.com">
<meta http-equiv="Content-Type" content="text/html;
charset=UTF-8">
<meta name="Generator" content="Microsoft Word 15 (filtered
medium)">
<style>@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}@font-face
{font-family:Verdana;
panose-1:2 11 6 4 3 5 4 4 2 4;}p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
font-size:11.0pt;
font-family:"Calibri",sans-serif;
mso-fareast-language:EN-US;}a:link, span.MsoHyperlink
{mso-style-priority:99;
color:#0563C1;
text-decoration:underline;}span.E-MailFormatvorlage20
{mso-style-type:personal-reply;
font-family:"Calibri",sans-serif;
color:windowtext;}.MsoChpDefault
{mso-style-type:export-only;
font-size:10.0pt;}div.WordSection1
{page:WordSection1;}</style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
<div class="WordSection1">
<p class="MsoNormal">Hello,<o:p></o:p></p>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal"><span lang="EN-US">thank you for your
suggestions! <o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">I am not sure if the
pipeline itself is the problem since the request seems to
work as an XML request, only when attempting to send it in
JSON format the mentioned error happened. <o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">Kind regards,<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US">Alexander<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="EN-US"><o:p> </o:p></span></p>
<div>
<div style="border:none;border-top:solid #E1E1E1
1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span
style="mso-fareast-language:DE-AT" lang="DE">Von:</span></b><span
style="mso-fareast-language:DE-AT" lang="DE"> Emil
Militzer <a class="moz-txt-link-rfc2396E"
href="mailto:emil.militzer@posteo.de"
moz-do-not-send="true"><emil.militzer@posteo.de></a>
<br>
<b>Gesendet:</b> Mittwoch, 15. Juni 2022 17:46<br>
<b>An:</b> midPoint General Discussion <a
class="moz-txt-link-rfc2396E"
href="mailto:midpoint@lists.evolveum.com"
moz-do-not-send="true"><midpoint@lists.evolveum.com></a><br>
<b>Cc:</b> Alexander Bruckner <a
class="moz-txt-link-rfc2396E"
href="mailto:alexander.bruckner@ventum.com"
moz-do-not-send="true"><alexander.bruckner@ventum.com></a><br>
<b>Betreff:</b> Re: [midPoint] Bulk Assignment of
Roles to Users via JSON API Request<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<div>
<p class="MsoNormal">Hi,<span
style="mso-fareast-language:DE-AT"><o:p></o:p></span></p>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal">I think this will not work because the
pipeline is not working correctly:<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><b><span
style="font-size:13.5pt;font-family:"Verdana",sans-serif;color:#014391"><br>
<br>
</span></b><o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><a
href="https://jira.evolveum.com/browse/MID-7965?orderby=updated+DESC%2C+priority+DESC"
moz-do-not-send="true" class="moz-txt-link-freetext">https://jira.evolveum.com/browse/MID-7965?orderby=updated+DESC%2C+priority+DESC</a><o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
<div>
<p class="MsoNormal">Kind regards<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal">Emil<o:p></o:p></p>
</div>
<div>
<p class="MsoNormal"><br>
<br>
<o:p></o:p></p>
<blockquote style="margin-top:5.0pt;margin-bottom:5.0pt">
<p class="MsoNormal" style="margin-bottom:12.0pt">Am
15.06.2022 um 15:08 schrieb Alexander Bruckner via
midPoint <<a
href="mailto:midpoint@lists.evolveum.com"
moz-do-not-send="true" class="moz-txt-link-freetext">midpoint@lists.evolveum.com</a>>:<o:p></o:p></p>
</blockquote>
</div>
<blockquote style="margin-top:5.0pt;margin-bottom:5.0pt">
<div>
<p class="MsoNormal"> <span
style="mso-fareast-language:DE-AT"><o:p></o:p></span></p>
<p class="MsoNormal">Hello everyone,<o:p></o:p></p>
<p class="MsoNormal"> <o:p></o:p></p>
<p class="MsoNormal"> <o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">we are currently
trying to assign one role to multiple users via a JSON
API request. We’ve already managed to do this over XML
with this request body:</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal"
style="line-height:13.5pt;background:#FFFFFE"><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"><</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">s:pipeline</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US"> </span><span
style="font-size:9.0pt;font-family:"Courier
New";color:red;mso-fareast-language:DE-AT"
lang="EN-US">xmlns:s</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US">=</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"><a
href="http://midpoint.evolveum.com/xml/ns/public/model/scripting-3"
moz-do-not-send="true"><span lang="EN-US">http://midpoint.evolveum.com/xml/ns/public/model/scripting-3</span></a></span><o:p></o:p></p>
<p class="MsoNormal"
style="line-height:13.5pt;background:#FFFFFE"><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US"> </span><span
style="font-size:9.0pt;font-family:"Courier
New";color:red;mso-fareast-language:DE-AT"
lang="EN-US">xmlns:c</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US">=</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"><a
href="http://midpoint.evolveum.com/xml/ns/public/common/common-3"
moz-do-not-send="true"><span lang="EN-US">http://midpoint.evolveum.com/xml/ns/public/common/common-3</span></a></span><o:p></o:p></p>
<p class="MsoNormal"
style="line-height:13.5pt;background:#FFFFFE"><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US"> </span><span
style="font-size:9.0pt;font-family:"Courier
New";color:red;mso-fareast-language:DE-AT"
lang="EN-US">xmlns:xsi</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US">=</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"><a
href="http://www.w3.org/2001/XMLSchema-instance"
moz-do-not-send="true"><span lang="EN-US">http://www.w3.org/2001/XMLSchema-instance</span></a></span><o:p></o:p></p>
<p class="MsoNormal"
style="line-height:13.5pt;background:#FFFFFE"><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US"> </span><span
style="font-size:9.0pt;font-family:"Courier
New";color:red;mso-fareast-language:DE-AT"
lang="EN-US">xmlns:xsd</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US">=</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"><a
href="http://www.w3.org/2001/XMLSchema"
moz-do-not-send="true"><span lang="EN-US">http://www.w3.org/2001/XMLSchema</span></a></span><o:p></o:p></p>
<p class="MsoNormal"
style="line-height:13.5pt;background:#FFFFFE"><span
style="font-size:9.0pt;font-family:"Courier
New";color:red;mso-fareast-language:DE-AT"
lang="EN-US">xmlns:q</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US">=</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"><a
href="http://prism.evolveum.com/xml/ns/public/query-3"
moz-do-not-send="true"><span lang="EN-US">http://prism.evolveum.com/xml/ns/public/query-3</span></a></span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><o:p></o:p></p>
<p class="MsoNormal"
style="line-height:13.5pt;background:#FFFFFE"><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"><</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">s:search</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US"> </span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><o:p></o:p></p>
<p class="MsoNormal"
style="line-height:13.5pt;background:#FFFFFE"><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US"> </span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"><</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">s:type</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US">c:UserType</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"></</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">s:type</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><o:p></o:p></p>
<p class="MsoNormal"
style="line-height:13.5pt;background:#FFFFFE"><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US"> </span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"><</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">s:searchFilter</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><o:p></o:p></p>
<p class="MsoNormal"
style="line-height:13.5pt;background:#FFFFFE"><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US"> </span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"><</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">q:inOid</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><o:p></o:p></p>
<p class="MsoNormal"
style="line-height:13.5pt;background:#FFFFFE"><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US"> </span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"><</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">q:value</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US">c38dc04a-e780-4475-ad51-f42dd054f622</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"></</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">q:value</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><o:p></o:p></p>
<p class="MsoNormal"
style="line-height:13.5pt;background:#FFFFFE"><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US"> </span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"><</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">q:value</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US">cd244459-81fe-4208-a51c-111cae039185</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"></</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">q:value</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><o:p></o:p></p>
<p class="MsoNormal"
style="line-height:13.5pt;background:#FFFFFE"><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US"> </span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"><</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">q:value</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US">12d665c0-7114-4b49-97ba-94c4cd154f8a</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"></</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">q:value</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><o:p></o:p></p>
<p class="MsoNormal"
style="line-height:13.5pt;background:#FFFFFE"><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US"> </span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"></</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">q:inOid</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><o:p></o:p></p>
<p class="MsoNormal"
style="line-height:13.5pt;background:#FFFFFE"><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US"> </span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"></</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">s:searchFilter</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><o:p></o:p></p>
<p class="MsoNormal"
style="line-height:13.5pt;background:#FFFFFE"><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"></</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">s:search</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><o:p></o:p></p>
<p class="MsoNormal"
style="line-height:13.5pt;background:#FFFFFE"><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"><</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">s:sequence</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><o:p></o:p></p>
<p class="MsoNormal"
style="line-height:13.5pt;background:#FFFFFE"><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"><</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">s:action</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><o:p></o:p></p>
<p class="MsoNormal"
style="line-height:13.5pt;background:#FFFFFE"><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US"> </span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"><</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">s:type</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US">assign</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"></</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">s:type</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><o:p></o:p></p>
<p class="MsoNormal"
style="line-height:13.5pt;background:#FFFFFE"><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US"> </span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"><</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">s:parameter</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><o:p></o:p></p>
<p class="MsoNormal"
style="line-height:13.5pt;background:#FFFFFE"><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US"> </span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"><</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">s:name</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US">role</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"></</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">s:name</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><o:p></o:p></p>
<p class="MsoNormal"
style="line-height:13.5pt;background:#FFFFFE"><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US"> </span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"><</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">c:value</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US"> </span><span
style="font-size:9.0pt;font-family:"Courier
New";color:red;mso-fareast-language:DE-AT"
lang="EN-US">xsi:type</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US">=</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">"xsd:string"></span><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US">a6afcd50-5f33-4250-8b93-62cb72e1a39a</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"></</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">c:value</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><o:p></o:p></p>
<p class="MsoNormal"
style="line-height:13.5pt;background:#FFFFFE"><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US"> </span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"></</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">s:parameter</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><o:p></o:p></p>
<p class="MsoNormal"
style="line-height:13.5pt;background:#FFFFFE"><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US"> </span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"></</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">s:action</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><o:p></o:p></p>
<p class="MsoNormal"
style="line-height:13.5pt;background:#FFFFFE"><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US"> </span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"></</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">s:sequence</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><o:p></o:p></p>
<p class="MsoNormal"
style="line-height:13.5pt;background:#FFFFFE"><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US"> </span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"></</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT">s:pipeline</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT">></span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">But similar
approaches do not seem to work for JSON. We attempted
the recommended method via heterogenous lists as
outlined in <a
href="https://docs.evolveum.com/midpoint/devel/design/xml-json-yaml-vs-xnode-vs-internal-data/heterogeneous-lists/"
moz-do-not-send="true" class="moz-txt-link-freetext">
https://docs.evolveum.com/midpoint/devel/design/xml-json-yaml-vs-xnode-vs-internal-data/heterogeneous-lists/</a>:</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">{</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US"> "@ns" : <a
href="http://midpoint.evolveum.com/xml/ns/public/model/scripting/extension-3"
moz-do-not-send="true" class="moz-txt-link-freetext">
http://midpoint.evolveum.com/xml/ns/public/model/scripting/extension-3</a>,</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US"> "pipeline": [</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US"> {</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">
"@element": "search",</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">
"type": "c:UserType",</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">
"searchFilter": {</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">
"inOid": {</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">
"value": [</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">
"c38dc04a-e780-4475-ad51-f42dd054f622",</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">
"cd244459-81fe-4208-a51c-111cae039185",</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">
"12d665c0-7114-4b49-97ba-94c4cd154f8a"</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">
]</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US"> }</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US"> }</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US"> },</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US"> {</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">
"@element": "sequence",</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">
"@value": [</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US"> {</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">
"@element": "action",</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">
"type": "assign",</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">
"parameter": {</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">
"type": "role",</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">
"value": "a6afcd50-5f33-4250-8b93-62cb72e1a39a"</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">
}</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US"> }</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US"> ]</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US"> }</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US"> ]</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">}</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">But received the
error message:</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal"
style="line-height:13.5pt;background:#FFFFFE"><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"><</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">message</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US">Wrong input value for ExecuteScriptType: RawType: (raw): XNode(list:2 elements))</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"></</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">message</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><o:p></o:p></p>
<p class="MsoNormal"
style="line-height:13.5pt;background:#FFFFFE"><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US"> </span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US"><</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:maroon;mso-fareast-language:DE-AT"
lang="EN-US">details</span><span
style="font-size:9.0pt;font-family:"Courier
New";color:blue;mso-fareast-language:DE-AT"
lang="EN-US">></span><span
style="font-size:9.0pt;font-family:"Courier
New";color:black;mso-fareast-language:DE-AT"
lang="EN-US">java.lang.IllegalArgumentException: Wrong input value for ExecuteScriptType: RawType: (raw): XNode(list:2 elements))</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">It seems like
Pipeline is not expecting a list of objects.</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">Is there some
error in our current JSON or is there a different way
of writing the query?</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">If anyone of you
has some advice regarding this, it would be greatly
appreciated!</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US"> </span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">Thank you and best
regards,</span><o:p></o:p></p>
<p class="MsoNormal"><span lang="EN-US">Alexander Bruckner</span><o:p></o:p></p>
<p class="MsoNormal"> <o:p></o:p></p>
<p class="MsoNormal"><span
style="mso-fareast-language:DE-AT">_______________________________________________<br>
midPoint mailing list<br>
<a href="mailto:midPoint@lists.evolveum.com"
moz-do-not-send="true" class="moz-txt-link-freetext">midPoint@lists.evolveum.com</a><br>
<a
href="https://lists.evolveum.com/mailman/listinfo/midpoint"
moz-do-not-send="true" class="moz-txt-link-freetext">https://lists.evolveum.com/mailman/listinfo/midpoint</a><o:p></o:p></span></p>
</div>
</blockquote>
</div>
<br>
<fieldset class="moz-mime-attachment-header"></fieldset>
<pre class="moz-quote-pre" wrap="">_______________________________________________
midPoint mailing list
<a class="moz-txt-link-abbreviated moz-txt-link-freetext" href="mailto:midPoint@lists.evolveum.com" moz-do-not-send="true">midPoint@lists.evolveum.com</a>
<a class="moz-txt-link-freetext" href="https://lists.evolveum.com/mailman/listinfo/midpoint" moz-do-not-send="true">https://lists.evolveum.com/mailman/listinfo/midpoint</a>
</pre>
</blockquote>
<br>
<fieldset class="moz-mime-attachment-header"></fieldset>
<pre class="moz-quote-pre" wrap="">_______________________________________________
midPoint mailing list
<a class="moz-txt-link-abbreviated" href="mailto:midPoint@lists.evolveum.com">midPoint@lists.evolveum.com</a>
<a class="moz-txt-link-freetext" href="https://lists.evolveum.com/mailman/listinfo/midpoint">https://lists.evolveum.com/mailman/listinfo/midpoint</a>
</pre>
</blockquote>
</body>
</html>