织梦CMS - 轻松建站从此开始!

欧博ABG官网-欧博官方网址-会员登入

欧博How to get share URN of a linkedin post?

时间:2025-09-15 15:29来源: 作者:admin 点击: 0 次
A LinkedIn Share URN (Uniform Resource Name) is a unique identifier that points to a specific post or share on the LinkedIn platform. It's essentially

A LinkedIn Share URN (Uniform Resource Name) is a unique identifier that points to a specific post or share on the LinkedIn platform. It's essentially a digital address that helps locate and reference that particular content.Note that it is written as "Share" URN and not "shar".

Typically, LinkedIn Share URN's follow this format:

urn:li:share:<share_id>

urn:li:share: This is a fixed prefix that indicates it's a LinkedIn share. <share_id>: This is a unique numerical identifier assigned to the specific share.

For instance:

urn:li:share:1234567890

Thus the Share URN can be gained from a visual inspection of the post URL or programmatically from parsing the URL. Share URN's help in content strategy and can indeed be manipulated using the LinkedIn API. The LinkedIn API provides endpoints that allow you to retrieve information about posts, including their Share URNs. You can use the GET posts endpoint to fetch a list of posts and then extract the Share URNs from the response.

First, you must obtain an access token. Next, you need to make an API call. Please use the GET POSTS endpoint to retrieve a list of posts. Finally, parse the JSON response to get the Share URN.

One confusion is the term "activity URN". Actually the accurate term is Share URN. LinkedIn uses Activity to refer to generally what the user is upto on the platform in general (likes, comments, shares). This is technically called an activity stream.

In programmatically fetching the Share URN you might use the LinkedIn library in a python script like such:

import linkedin # Replace 'YOUR_ACCESS_TOKEN' with your actual access token access_token = 'YOUR_ACCESS_TOKEN' # Create a LinkedIn client client = linkedin.LinkedInClient(access_token) # Get a list of posts posts = client.get_posts() # Extract share URNs for post in posts: share_urn = post['id'] print(share_urn)

Do note that as you mentioned last: The UGC Post API (User-Generated Content Post API) is a LinkedIn API endpoint that allows you to create, update, and delete user-generated content posts on the platform. This includes posts that you or your users create, such as text posts, images, or videos.

When working with the UGC Post API, you'll often use Share URNs to uniquely identify and reference specific posts. A Share URN is a unique identifier that points to a particular post or share on LinkedIn.

Here's how Share URNs are typically used in conjunction with the UGC Post API:

In creating a post, when you do so using the UGC Post API, the API will return the newly created post's share URN. You can then use this share URN to reference and interact with the post in subsequent API calls.

While updating posts, an existing post, you'll need to provide the post's share URN as a parameter to the API endpoint. This allows the API to correctly identify the post you want to modify.

In deletion of a post, similar to updating a post, you'll need to provide the post's Share URN to delete it using the UGC Post API.

Basically, Share URNs serve as a bridge between your application and the specific LinkedIn posts you're working with. You use Share URNs to manage and interact with user-generated content on LinkedIn through the API, just as I showed your kind self above, sounds good?

(责任编辑:)
------分隔线----------------------------
发表评论
请自觉遵守互联网相关的政策法规,严禁发布色情、暴力、反动的言论。
评价:
表情:
用户名: 验证码:
发布者资料
查看详细资料 发送留言 加为好友 用户等级: 注册时间:2025-09-15 19:09 最后登录:2025-09-15 19:09
栏目列表
推荐内容