- Joined
- Mar 24, 2022
- Messages
- 16
- Reaction score
- 1
Hi All,
I'm having issues with seeing certain variables in the POST to our API since upgrading to V18.
I am aware that V18 does not support [Contact: XXXXXX] variables anymore, and therefore we need to use EntityID. So I've updated the XML to use EntityID instead, in both the Variables and outputs, however in the POST sent to our API the EntityID variable is just an empty string. Is there something I'm missing in order for this to pull through?
However, when I use the Test CRM Integration functionality the EntityID field is populated with the customerID that I'm hoping to receive in our API. So i'm not sure what I'm missing for the POST to populate it in the same way.
Any help would be greatly appreciated
I'm having issues with seeing certain variables in the POST to our API since upgrading to V18.
I am aware that V18 does not support [Contact: XXXXXX] variables anymore, and therefore we need to use EntityID. So I've updated the XML to use EntityID instead, in both the Variables and outputs, however in the POST sent to our API the EntityID variable is just an empty string. Is there something I'm missing in order for this to pull through?
XML:
<Variables>
<Variable Name="EntityId" Path="customer.Details.ID">
<Filter />
</Variable>
<Variable Name="FirstName" Path="customer.Details.Name">
<Filter />
</Variable>
<Variable Name="LastName" Path="customer.Details.Surname">
<Filter />
</Variable>
<Variable Name="Email" Path="customer.Details.Email">
<Filter />
</Variable>
<Variable Name="PhoneMobile" Path="customer.Telephone">
<Filter />
</Variable>
XML:
<Outputs AllowEmpty="false">
<Output Type="FirstName" Passes="0" Value="[FirstName]" />
<Output Type="LastName" Passes="0" Value="[LastName]" />
<Output Type="Email" Passes="0" Value="[Email]" />
<Output Type="PhoneMobile" Passes="0" Value="[PhoneMobile]" />
<Output Type="ContactUrl" Passes="0" Value="https://xxxxxx.co.uk/crm/customer/[EntityId]" />
<Output Type="EntityId" Passes="0" Value="[EntityId]" />
</Outputs>
XML:
<Outputs AllowEmpty="false">
<Output Type="EntityId" Passes="0" Value="[EntityId]" />
<Output Type="FirstName" Passes="0" Value="[FirstName]" />
<Output Type="LastName" Passes="0" Value="[LastName]" />
<Output Type="Email" Passes="0" Value="[Email]" />
<Output Type="PhoneMobile" Passes="0" Value="[PhoneMobile]" />
<Output Type="ContactUrl" Passes="0" Value="https://xxxxxx.co.uk/crm/customer/[EntityId]" />
</Outputs>
</Scenario>
<Scenario Id="ReportCall" Type="REST">
<Request SkipIf="[ReportCallEnabled]!=True||[CallType]!=Inbound" Url="https://xxxxxx.co.uk/api/events/new-event/?type=5" MessagePasses="0" RequestContentType="application/json" RequestEncoding="Json" RequestType="Post" ResponseType="Json">
<PostValues Key="">
<Value Key="duration" Passes="1" Type="String">[Duration]</Value>
<Value Key="phone" Passes="1" Type="String">[Number]</Value>
<Value Key="agent" Passes="1" Type="String">[Agent]</Value>
<Value Key="callType" Passes="1" Type="String">[CallType]</Value>
<Value Key="DateTime" Passes="1" Type="String">[DateTime]</Value>
<Value Key="CustomerID" Passes="1" Type="String">[EntityId]</Value>
<Value Key="EntityId" Passes="1" Type="String">[EntityId]</Value>
<Value Key="CallStart" Passes="1" Type="String">[CallStartTimeUTC]</Value>
<Value Key="CallEnd" Passes="1" Type="String">[CallEndTimeUTC]</Value>
</PostValues>
</Request>
However, when I use the Test CRM Integration functionality the EntityID field is populated with the customerID that I'm hoping to receive in our API. So i'm not sure what I'm missing for the POST to populate it in the same way.
JSON:
{"duration":"06:24","phone":"***********","agent":"1217","callType":"Inbound","DateTime":"24/03/2022 09:39","CustomerID":"","EntityId":"","CallStart":"24/03/2022 09:39:56","CallEnd":"24/03/2022 09:46:21"}
Any help would be greatly appreciated