Genesys Cloud - Main

 View Only

Sign Up

  Thread closed by the administrator, not accepting new replies.
  • 1.  Update the text to CRM

    Posted 02-11-2023 06:37
    No replies, thread closed.

    Hello,

    In my mailflow, I want to update the fields to CRM
    I receive the mail with multiple fields one of them is a literal text contain lignes break.

    What's kind of value i ccould attribut to a variable to update the text to the CRM? 
    it's like Add a tag at the begin and end of text , in order to read only what is between.

    Best Regards


    #ArchitectureandDesign

    ------------------------------
    Pasco Bendo
    Inetum SA
    ------------------------------


  • 2.  RE: Update the text to CRM

    Posted 02-11-2023 15:13
    No replies, thread closed.

    Hi Pasco,

    Assuming this comes from a form or similar where you know what fields you'll get, you could split each line and until you see the next field name you know it belongs to the previous one.
    I have one where I expect several lines of information that I split using \r\n.



    ------------------------------
    Jan Heinonen
    Contact Center Specialist
    GlobalConnect AB
    ------------------------------



  • 3.  RE: Update the text to CRM

    Posted 02-13-2023 14:09
    Edited by Max Gill 02-13-2023 14:09
    No replies, thread closed.

    I'm assuming you have a webform with a text area like "Message" that may have line breaks. You should look out for these characters "/n" and "/t". 

    BUT, I should add that it's possible for people to type in HTML and other text that may confuse the parser unless you encode the textarea content. You should try copy-pasting in code-like text as well to make sure you don't get weird exceptions.

    On another note, we have clients that use our ServiceJourney Advanced Email for Genesys Premium App to handle the more complex use-cases. Could be worth the try.



    ------------------------------
    Maksim Gill
    Eccentex (Customer Service Platform)
    https://www.eccentex.com/genesys
    ------------------------------



  • 4.  RE: Update the text to CRM

    Posted 02-15-2023 06:49
    Edited by Pasco Bendo 02-15-2023 06:55
    No replies, thread closed.

    Thank you for your answer,

    The first condition to add all fields is :

    split(Flow.array_customer_email_body_split[Flow.int_customer_body_split_counter],":" )

    and count(Flow.array_cust_line_split) > 1

    and then I declare the keys

    Current key : trim(Replace(Replace(Replace(Flow.array_cust_line_split[0],"(",""),")",""),"*",""))

    and Current value : trim(Replace(Replace(Flow.array_cust_line_split[1]," "," "),"*",""))

    it's working if only the text began after  ":" but it doesn't working when it began after a new line.

    I think that I have to separate the cases and find a new current value for this failure case, but i can't.

    Do u have an idea?

    Thx 



    ------------------------------
    Pasco Bendo
    Inetum SA
    ------------------------------



  • 5.  RE: Update the text to CRM

    Posted 02-15-2023 07:05
    No replies, thread closed.

    Hi Pasco,

    If the e-mail comes from a form adding a tag on "data end" would make it easier.

    Without knowing what the e-mail looks like I would still probably split the e-mail in lines, and then check if the line contains key and value, or just a continuation of value for the previous key.



    ------------------------------
    Jan Heinonen
    Contact Center Specialist
    GlobalConnect AB
    ------------------------------



  • 6.  RE: Update the text to CRM

    Posted 02-15-2023 09:19
    No replies, thread closed.

    Thx,

    I think that i have to add the tag on "data end"

    the emails looks like ( the 1st and second line working, but the third is down)

    Machine 1*: Downgraded 

    Engine 2*: Electrical/Automation 

    Oil & activities done*: 

    This is the text to update

    and it

    and 

    and



    ------------------------------
    Pasco Bendo
    Inetum SA
    ------------------------------



  • 7.  RE: Update the text to CRM
    Best Answer

    Posted 02-15-2023 09:58
    No replies, thread closed.

    Hello,

    If the e-mail always is structured the same way, then you could just grab every line after the third key assuming there's no "garbage" that can be added at the bottom.

    Otherwise a tag declaring end of data will help.



    ------------------------------
    Jan Heinonen
    Contact Center Specialist
    GlobalConnect AB
    ------------------------------