How can I get the version ID from a web panel on the version page?

I’ve added a web panel with location This displays on a page about a specific version and I’d like to retrieve information about the version using the version ID.

I tried to use the context parameter, but when I specify the query parameter ?versionId=${} in the URL for the web panel in the app descriptor, it’s not populated.

How can I access get the version ID from this location?

(Note, this was also asked in the general community)


Hi @MichaelBelton,
This looks like a bug so I’ve created [JSWCLOUD-19011] The {} context parameter is not populated - Create and track feature requests for Atlassian products.. Unfortunately, I don’t know of a workaround.

1 Like

Hi @dmorrow, thanks for the reply! :crossed_fingers: it will be resolved soon

No problems - good to see you’re watching the ticket. :slight_smile:

@dmorrow @MichaelBelton I have a workaround. Add the following javascript inside your iframe

		var versionId = location.match(/\/versions\/(.+?)\//)[1]

Seems very dirty, but it’s better than nothing.

Hi @MartinCassidy very dirty :slight_smile: but it works! Thanks!

@dmorrow are there any plans for fixing that issue?

Best Valentin

Hi @ValentinPravtchev ,

Much of the development team’s effort is focussed on Forge so this issue is likely to remain outstanding for some time.


1 Like

Hi @dmorrow thanks for the quick response !

Good luck for the team!

Best Valentin