Pass more than one event parameter in PostEvent() | Community
Skip to main content
February 26, 2025
Solved

Pass more than one event parameter in PostEvent()

  • February 26, 2025
  • 1 reply
  • 586 views

Hi,

 

I am looking for the way to pass more than one variable into PostEvent() function. My current approach works with one variable:

 

I send POST request from Postman, the body looks like below:

 

<?xml version="1.0" encoding="utf-8"?> <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns0="urn:xtk:workflow"> <SOAP-ENV:Header /> <SOAP-ENV:Body> <PostEvent> <sessiontoken></sessiontoken> <strWorkflowId>WKF2137</strWorkflowId> <strActivity>signal</strActivity> <strTransition></strTransition> <parameters> <variables email="email1@domain.com"/> </parameters> <complete></complete> </PostEvent> </SOAP-ENV:Body> </SOAP-ENV:Envelope>

 

I tried the following versions, but for all of them I get SOP-330007 Error while reading parameters of method 'PostEvent' of service 'xtk:workflow' error: 

(1)

<?xml version="1.0" encoding="utf-8"?> <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns0="urn:xtk:workflow"> <SOAP-ENV:Header /> <SOAP-ENV:Body> <PostEvent> <sessiontoken></sessiontoken> <strWorkflowId>WKF2137</strWorkflowId> <strActivity>signal</strActivity> <strTransition></strTransition> <parameters> <variables email="email1@domain.com" email2="email2@domain.com"/> </parameters> <complete></complete> </PostEvent> </SOAP-ENV:Body> </SOAP-ENV:Envelope>

(2)

<?xml version="1.0" encoding="utf-8"?> <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns0="urn:xtk:workflow"> <SOAP-ENV:Header /> <SOAP-ENV:Body> <PostEvent> <sessiontoken></sessiontoken> <strWorkflowId>WKF2137</strWorkflowId> <strActivity>signal</strActivity> <strTransition></strTransition> <parameters> <variables> <email>email@domain.com</email> <email2>email2@domain.com</email2> </variables> </parameters> <complete></complete> </PostEvent> </SOAP-ENV:Body> </SOAP-ENV:Envelope>

 

Best answer by ParthaSarathy

Hi @curiousdijkstra ,

You can try the below,

<PostEvent> <sessiontoken></sessiontoken> <strWorkflowId>WKF2137</strWorkflowId> <strActivity>signal</strActivity> <strTransition></strTransition> <elemParameters> <variables email="email1@domain.com" email2="email2@domain.com" > <ctx> <email>email1@domain.com</email> <email2>email2@domain.com</email2> </ctx> </variables> </elemParameters> <complete></complete> </PostEvent>

1 reply

ParthaSarathy
Community Advisor
ParthaSarathyCommunity AdvisorAccepted solution
Community Advisor
February 26, 2025

Hi @curiousdijkstra ,

You can try the below,

<PostEvent> <sessiontoken></sessiontoken> <strWorkflowId>WKF2137</strWorkflowId> <strActivity>signal</strActivity> <strTransition></strTransition> <elemParameters> <variables email="email1@domain.com" email2="email2@domain.com" > <ctx> <email>email1@domain.com</email> <email2>email2@domain.com</email2> </ctx> </variables> </elemParameters> <complete></complete> </PostEvent>
~  ParthaSarathy S~  Click here to join ADOBE CAMPAIGN USER GROUP for Quarterly In-person | Hybrid | Virtual Meetups
February 26, 2025

Hey @parthasarathy,

 

Unfortunately, it's not working and returns the same error.

February 27, 2025

Disregard my previous comment, the code works as expected. Thanks @parthasarathy.