Changing the reporter field with a smart value and keep getting an error
Asked by David B:

We currently have a Jira Service management project set up that gets emails from another system and it generates issues. Currently every issue is listing the email address we configured on the other system as the reporter. In the description we have the actual customer's email and I am able to pull it from the description and populate it in a custom email field. The problem I am running into is when I try to make an automation rule that will take the email field and put its value in the reporter field. Currently I am getting the error in the audit logs for the automation rule:

(Specify a valid value for reporter (reporter))

Here is how I currently have the automation rule setup:

![Image 14.jpg](https://community.atlassian.com/t5/image/serverpage/image-id/144148i36586519868DCFC6/image-size/large?v=v2&px=999 "Image 14.jpg")

Any ideas or insight into this would be great. Thanks.


Answers:
author: Simmo
body: Hi [@David B](/t5/user/viewprofilepage/user-id/437711),

I think you need to use the Add Customer Action to add the email address as a customer, then try what you're doing.

Let me know how that goes.

Cheers,

Simeon.

comments: author: David B
body: Thanks for the response Simeon but that does not resolve the issue, it adds the customer but when I try to assign it to the reporter I am still getting the same error.

![Image 15.jpg](https://community.atlassian.com/t5/image/serverpage/image-id/144207i442BC73602B8AAB6/image-size/large?v=v2&px=999 "Image 15.jpg")![Image 16.jpg](https://community.atlassian.com/t5/image/serverpage/image-id/144208i648496B6F9734684/image-size/large?v=v2&px=999 "Image 16.jpg")


author: Simmo
body: Hi [@David B](/t5/user/viewprofilepage/user-id/437711)

My apologies, I forgot to add the other important step. You cannot reference a user by email address. However, when we add a customer they are accessible via the smart value customer.

You can use this to get the account ID which will be accepted:

```
{{customer.accountId}}
```

![create.png](https://community.atlassian.com/t5/image/serverpage/image-id/144281i5410DDC2EEE10BC0/image-size/large?v=v2&px=999 "create.png")

I have just tested that and got it to work. Hopefully that should sort you out!

Cheers,

Simeon


author: David B
body: Simeon -

You are amazing thank you. That seems to be working. Not sure if I need all of the re-fetch data calls but it gets me to where I need to go. I appreciate the help.

![Capture.JPG](https://community.atlassian.com/t5/image/serverpage/image-id/144284i3CB7BCE77E65066E/image-size/large?v=v2&px=999 "Capture.JPG")


author: Simmo
body: Awesome mate, glad to hear that you got there!

Try it without them, I don't think you'll need them and all it is doing is putting unnecessary load on Jira!


author: Team GoCredible
body: I've been trying the same. When I manually trigger the flow it does work but when I trigger it with the creation of an issue it doesnt work. Could you help?

![Schermafbeelding 2023-11-27 173152.png](https://community.atlassian.com/t5/image/serverpage/image-id/293872i9586007117CDAF94/image-size/large?v=v2&px=999 "Schermafbeelding 2023-11-27 173152.png")![Schermafbeelding 2023-11-27 173222.png](https://community.atlassian.com/t5/image/serverpage/image-id/293873i36D7C2641597992F/image-size/large?v=v2&px=999 "Schermafbeelding 2023-11-27 173222.png")


author: Bill Sheboy
body: Hi [@Team GoCredible](/t5/user/viewprofilepage/user-id/5373581) -- Welcome to the Atlassian Community!

As this is quite an old thread, I recommend creating a new question and linking back to this one. That will ensure the most number of people see it to offer ideas.

When you create you question, please post an image of your complete automation rule, images of any relevant actions / conditions / branches, an image of the audit log details showing the rule execution, and explain what is not working as expected. Those will provide context for the community to offer ideas. Thanks!

Kind regards,  
Bill


author: Matt Adorjan
body: [@David B](/t5/user/viewprofilepage/user-id/437711) - this is similar to a problem we are trying to solve and looks like Simeon's solution could work for us too! Do you min sharing how you are pulling the customer's information from the "Description" and putting it into a custom field? I assume that is happening in your "Then: Edit issue fields" step with some regex?

Thanks!  
Matt

comments: author: David B
body: [@Matt Adorjan](/t5/user/viewprofilepage/user-id/3689926) -

I use a smart value to pull the string from the description field and set email to it's value:

![Screenshot 2021-05-24 101611.png](https://community.atlassian.com/t5/image/serverpage/image-id/144560iA77AE20A45559F08/image-size/large?v=v2&px=999 "Screenshot 2021-05-24 101611.png")

{{issue.description.substringBetween("email ", " ")}} is what I used, your mileage may vary.

<https://support.atlassian.com/jira-software-cloud/docs/smart-values-text-fields/> is what I found invaluable for a reference to get what I wanted.


author: Omer Joffe (MG)
body: Hi [@David B](/t5/user/viewprofilepage/user-id/437711) \& [@Simmo](/t5/user/viewprofilepage/user-id/3608665)  
I'm dealing with kinda the same issue as mentioned above, trying to "add a new customer" based off a custom field, and then set this customer as a reporter.   
I didn't fully understand what should be configured within the last condition "edit issue filed reporter". [@David B](/t5/user/viewprofilepage/user-id/437711) could you please share the workflow that worked for you? I see that [@Simmo](/t5/user/viewprofilepage/user-id/3608665) suggested the action {{customer.accountId}}, but it doesn't seem to work for me.

thanks!!!


author: Simmo
body: Hi [@Omer Joffe (MG)](/t5/user/viewprofilepage/user-id/4138549) ,

Could you share a screenshot of your rule setup and where you're stuck?


author: Omer Joffe (MG)
body: thanks for the quick reply [@Simmo](/t5/user/viewprofilepage/user-id/3608665) !  

sure, please find it below.  
quick overview -

* the issues are being created in JIra by Splunk
* fields description -
  * {{issue.fields.customfield_10084}} = account email address
  * {{issue.fields.customfield_10083}} = account name

The first condition adds a new member (if doesn't exist) -

![jira1.png](https://community.atlassian.com/t5/image/serverpage/image-id/150922i8A5DDD71169FB534/image-size/large?v=v2&px=999 "jira1.png")

The second condition is supposed to assign the customer from the first condition as a reporter instead of Splunk.

![jira2.png](https://community.atlassian.com/t5/image/serverpage/image-id/150923iF45999C8A808151D/image-size/large?v=v2&px=999 "jira2.png")

Audit log - "specify a valid value for reporter".

![jira3.png](https://community.atlassian.com/t5/image/serverpage/image-id/150924i62F2DEB932CEF9D5/image-size/large?v=v2&px=999 "jira3.png")

what am I missing? my goal is to assign the reporter based on either account name/email address.

thanks a lot.

Omer Joffe


author: Simmo
body: Hi [@Omer Joffe (MG)](/t5/user/viewprofilepage/user-id/4138549)

In this case, the error is happening with the add customer action. A customer already exists with that email address, so we don't create one so the smart value doesn't work. Looks like you're testing this so try it with made up emails.

Cheers,

Simeon.


author: Omer Joffe (MG)
body: Hey [@Simmo](/t5/user/viewprofilepage/user-id/3608665)  
yeah, I know this customer already exists, but that's not the case, I've tried this rule many times with different emails and names, but still failing to assign a new reporter.  
here is another test from this morning- a new customer was successfully created, but the reporter value doesn't seem to work (I'm using - {{customer.accountId}} as the new reporter value).

<br />

![jira4.png](https://community.atlassian.com/t5/image/serverpage/image-id/151150iB778B2FE82DA749A/image-size/large?v=v2&px=999 "jira4.png")


author: Simmo
body: Hey [@Omer Joffe (MG)](/t5/user/viewprofilepage/user-id/4138549)

Can you raise a support ticket for this? You're doing the exact same thing that I am able to do successfully so I am not sure what is going on here. We'll need to dig into the problem to find out.

Cheers,

Simeon.


author: Omer Joffe (MG)
body: Hi [@Simmo](/t5/user/viewprofilepage/user-id/3608665) ,

I created a ticket last week and it was already fixed by a Jira service management engineer. Thanks for your quick reply.


author: Mathias HD
body: What was the Issue?   
I have the same Error when i try to put in a email from an Interal user but it works for external Emails.