Hi @PeterQuinn!
It looks like the phone numbers are line items, which is why the Formatter step isn’t working as you’d expect.
It’s easy enough to extract the first phone number, getting the others into the comments field will depend on what other actions you need in the Zap.
Here’s how I would do it:
- Add a Formatter > Utilities step to convert the line items into text. Add the number field as the input for the action. This will convert the line items into comma separated text, which wont look different when you’re adding the field in the steps of your Zap, but if you look at the output of the Formatter step, you’ll see that it’s something like “(415) 123456, (415) 234567, (415) 345678”
- Add another Formatter action, this time choosing Text and then Split Text as the transform. This will break the text into chunks based on the character you choose, and it uses a comma by default, so your numbers field is already good to go.
- The next part depends on what information you get from the webhook each time, specifically if there will always be the same number of phone numbers each time, or if sometimes someone might add one and another they will add three. I’m going to assume that there could be different numbers of phone numbers as that’s the most common use case.
- In the Split text step, for the Segment Index field, choose First. This will pull the first piece of information before a comma, ie the first phone number on the list. Tada! You now have the first number as a separate field.
- Add another Formatter > Text step to the Zap but this time choose the transform Replace. The aim of this step is to get the rest of the phone numbers in the list, without the first one. To do that, put the output of the line item to text step in the input field - that’s the full list of phone numbers from point 1 above. In the Find field, add the output of the Split text step (ie the first phone number) and then type a comma. Leave the Replace field blank and the action will delete the found text.
- The output of that step will then be a list of the other phone numbers, separated by commas that you can add to the comments.
That’s a lot of Formatter steps, so let me know if you have any questions about them! There may also be a way to do this using a single code step, but that’s beyond my knowledge
Let us know if that works for you :)