How to save a contact's WhatsApp number March 21, 2024 12:13 Updated Índice: Introduction Creating the Script Storing the number in the Contact Introduction Getting and keeping your contact information up to date can be very important for any business. The WhatsApp channel already brings some information by default saved in the bot contacts: Name and Phone. However, the phone number is saved in the form of a User Identifier, which can cause some confusion. If you do not want to have to ask for your phone number through the conversational flow, but instead take advantage of the information already sent by the channel, you will need to follow some steps: Create a Script and Store the data in the Contact. Creating the Script This is a script that will receive the user's identifier and collect only the user's phone number. This number will be stored in a variable called Telephone, which will later be stored in the contact's information. To start, create a script (it can be in the first block of the bot) and put the variable contact.identity, which is the variable that contains the user identifier, in the input variables of the Script. It is in the following format: ############@wa.gw.msging.net Then copy and paste, replacing the script with the one below: function run (identifier) { user phone var = identifier.split ("@") [0]; return phoneUser; } Notice that the script receives an identifier and returns a user phone. Remember to save the return in a variable (phoneUser, for example), because it is with it that we will save the phone in the contact information. Storing the number in the Contact Now, with the phone number saved in the userPhone variable from the step above, we will create a Define Contact action. Click here if you need to know more details about this action and its settings. Below the Run Script Action, create a Define Contact action. In the action, define in the Telephone field the value of the variable telephoneUser, inside the braces ({{telephoneUser}}) At the end, we will have the saved WhatsApp number contact. ATTENTION: Customer telephone numbers in international format must follow the following pattern: "+ DDI PHONE DDD". Therefore, it is mandatory to add the "+" (plus) sign before the DDI. For more information, visit the discussion on the subject in our community or the videos on our channel. ?. Related articles How to Save Contact Information Sending WhatsApp Active Messages on Blip Desk Builder variables Saving contact name from WhatsApp Broadcast Creating interactive messages in WhatsApp