Hi,
I'm trying to access a user property that I created as described here , but with no success.
I've found a way to access a user property added through REST API, but as the article above says - those are different properties (and also those are stored as JSON, and I just need a plain text).
Can You point me to how to use User Properties (added via GUI, not REST API) in i.e Automation scripts using Smart Values?
I've tried something like this, but with no success:
{{reporter.properties.someCustomProperty}}
Best Regards,
Maciek
@Maciek Palicki, there isn't a way to access these values through the automation smart values. There is a disconnect between the values stored in the API and the values defined in the UI.
Thanks for fast reply.
This seems weird, because those values are basically useless then.
So I'll ask a slightly different question - is there a way to put just a string, not a json as a user property using REST API?
i.e I'd like to store discordID, and in automation just access {{reporter.properties.discordID}} which will return discordID, not a json?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Maciek Palicki, sorry about the late response.
Yes, it is possible to do that.
You'll need to use this rest API to set the property. My URL looked like this:
https://yourdomain.atlassian.net/rest/api/3/user/properties/<propertyName>?accountId=<accountID of account>.
You can find accountID's by performing a user search like follows:
https://yourdomain.atlassian.net/rest/api/3/user/search?query=<email address of user>
In the body, I just put "123".
The property name you define in the URL is how you will access the property in your automation rule.
This is what my comment looked like.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
For posterity's sake, for non-Cloud (i.e. Datacenter or Server) users... there is a way to access those UI properties through automation smart values. Specifically:
{{issue.reporter.legacyProperties."jira.meta.someCustomProperty"}}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.