Forum Discussion

jaread83's avatar
jaread83
Champion
8 years ago

How to get the current blog ID (of the post)

Hi all,

 

I need to get the ID of a blog article when I am on the page viewing the article in question. The URL contains this ID after /ba-p/{THE ID I WANT}.

 

What is the best way to obtain this ID in a custom component so I may plug this id into another API call for something else?

  • jaread83 -  You can use ${env.context.message.uniqueId}  context object to get  the current blog id.  Here is the reference.  

    Give kudos if you find my posts helpful or mark solution if it answers your query. 

  • jaread83 -  You can use ${env.context.message.uniqueId}  context object to get  the current blog id.  Here is the reference.  

    Give kudos if you find my posts helpful or mark solution if it answers your query.