Sync Phone Numbers via Automation + Rovo Agent

Sync Phone Numbers via Automation + Rovo Agent

 

This guide shows how to automatically convert free-text phone numbers into the structured format that the ACF Validated Phone field requires. It uses a Rovo Agent for parsing and a Jira Automation rule to write the result. No coding required, setup takes about 15 minutes.

image-20260320-202344.png

 

Content

Problem

Phone numbers arrive in Jira as free-text, either through JSM portal forms, CSV imports, or plain text custom fields. The ACF Validated Phone field expects a structured JSON format with an internationally formatted number and a country code. Manually reformatting every phone number is not practical at scale.

Typical inputs that need to be handled:

  • 0171 1234567 (local format, no country code)

  • +49 (0)30 / 123 456 (mixed formatting)

  • 00 44 20 7946 0958 (international with 00 prefix)

  • 0171-9876543 (mobile) (with label hint)

The ACF Validated Phone field expects:

{"numbers":[{"number":"+49 171 1234567","country":"DE"}]}

Solution overview

Use a Rovo Agent to parse the free-text phone number into the correct ACF format, then write the result into the ACF field via a Jira Automation rule.

The flow:

  1. User enters a phone number in a plain text field (e.g. "Phone (Jira)")

  2. Jira Automation triggers on field change

  3. The automation sends the text value to the Rovo Phone Agent

  4. The agent returns the structured JSON

  5. The automation writes the JSON into the ACF Validated Phone field

Step 1: Create the Rovo Agent

image-20260320-201734.png

 

Go to Rovo > Agents > Create agent and configure it with the following system prompt:

You are a phone number formatting agent for Awesome Custom Fields (ACF). Your only job: take raw phone number input and return it in the exact JSON format that the ACF Validated Phone field expects. Nothing else. No explanations, no conversation, no markdown formatting. Only valid JSON output. ## Output format Always return this exact JSON structure: {"numbers":[{"number":"+49 123 4567890","country":"DE"}]} Rules: - "number" must be in international format with spaces (e.g. "+49 123 4567890", "+1 415 555 0132") - "country" must be the ISO 3166-1 alpha-2 country code (e.g. "DE", "US", "GB") - If the input contains a label hint like "mobile", "work", "home", or "fax", add a "label" field: {"number":"+49 123 4567890","country":"DE","label":"mobile"} - If no label is mentioned, omit the "label" field entirely ## Parsing rules - Accept any common phone number format: "0123/456789", "(0049) 123-456789", "+49123456789", "00 49 123 456 789", "123 456789" - Strip all non-numeric characters except the leading "+" - If the number starts with "00", replace "00" with "+" - If the number starts with "0" (single zero, no country code), assume the default country (see below) and prepend the country calling code - Detect the country from the number prefix (e.g. +49 = DE, +1 = US, +44 = GB, +33 = FR, +43 = AT, +41 = CH) - Format the output number with international spacing according to the country's convention ## Default country If the number has no country prefix (e.g. "0123 456789"), assume Germany (DE, +49) unless the user specifies otherwise. If the user says something like "US number: 415-555-0132", use that country. ## Multiple numbers If the input contains multiple phone numbers (separated by commas, newlines, or "and"), return all of them in the "numbers" array: {"numbers":[{"number":"+49 123 4567890","country":"DE"},{"number":"+1 415 555 0132","country":"US"}]} ## Invalid input If the input cannot be parsed as a phone number at all, return a short plain-text error message. No JSON, no formatting.

Adjust the default country in the prompt if your users primarily enter numbers from a different region.

Step 2: Test the agent

Before setting up automation, test the agent manually in the Rovo chat. Try these inputs and verify the output:

Input

Expected output

Input

Expected output

0171 1234567

{"numbers":[{"number":"+49 171 1234567","country":"DE"}]}

+1 (415) 555-0132

{"numbers":[{"number":"+1 415 5550132","country":"US"}]}

030/123456, mobile

{"numbers":[{"number":"+49 30 123456","country":"DE","label":"mobile"}]}

hello world

Not a valid phone number.

You may use the recently introduced “Evaluation“ function. Use this CSV to test it

image-20260320-201452.png

 

Step 3: Create the Jira Automation rule

image-20260320-201953.png

 

Rovo was not able to create the automation rule reliably via prompt. Create it manually:

Trigger

  • When: Field value changed

  • Field: Phone (Jira) (your plain text source field)

Condition

  • If: Phone (Jira) is not empty

Action 1: Send Rovo Agent request

  • Action type: Send request to Rovo Agent

  • Agent: (select the phone formatting agent you created in Step 1)

  • Prompt: {{issue.Phone (Jira)}} (use the smart value for your source field)

Action 2: Edit issue

The ACF Validated Phone field is not available in the standard field dropdown. You need to use Additional fields (raw JSON).

  • Action type: Edit issue

  • Additional fields:

{ "fields": { "customfield_XXXXX": {{agentResponse}} } }

Replace customfield_XXXXX with the actual custom field ID of your ACF Validated Phone field. You can find the field ID in Jira Settings > Issues > Custom fields, or by inspecting the field in the REST API.

The {{agentResponse}} smart value contains the raw JSON output from the Rovo agent, which is already in the correct ACF format.

Rule name

Sync Phone (Jira) → Phone (ACF)

Step 4: Find your custom field ID

If you do not know the custom field ID:

  1. Go to Jira Settings > Issues > Custom fields

  2. Search for your ACF Validated Phone field

  3. Click on it and check the URL, it will contain something like customFieldId=10673

  4. The field ID for the automation JSON is customfield_10673

Troubleshooting

Agent returns markdown or explanations instead of pure JSON:
Adjust the system prompt. Make sure the first line clearly states "Only valid JSON output. No explanations, no conversation, no markdown formatting."

Automation fails with "field not found":
Double-check the custom field ID. The field name (e.g. "Phone (ACF)") does not work in the Additional fields JSON, you must use the customfield_XXXXX format.

Phone number is not parsed correctly:
Test the input directly in the Rovo Agent chat. If the agent output is wrong, adjust the parsing rules or default country in the system prompt.

Automation does not trigger:
Verify the trigger field name matches exactly. If the source field is a custom field, it may also require the customfield_XXXXX format in the trigger configuration.