POST DETAILS API

Any Post URL to Structured JSON

Send a post URL and get the full text, the author, media, links, the exact publish time and engagement counts with a breakdown by reaction type. Reposts come with the original post attached.

POST/api/v1/post

{
  "post_text": "We're growing the Product team!...",
  "posted_at": "2024-07-17T20:14:41.000Z",
  "social_count": {
    "num_likes": 124,
    "num_comments": 11,
    "num_shares": 13
  }
}

What is the Datamagnet Post Details API?

The Datamagnet Post Details API turns a single post URL into structured JSON. It returns the full post text, the author with headline and profile link, links and media in the post, the exact publish time, and engagement counts for likes, comments and shares with a breakdown by reaction type. On a repost it also returns the original post and who reshared it.

Input
Post URL
Cost
1 credit per post
Freshness
Live at request time

One request

Authenticate with your API key as a bearer token and send a JSON body. This is the request behind the sample response.

  • POST /api/v1/post
  • Input: Post URL
  • Cost: 1 credit per post
POST /api/v1/post
curl -X POST \
  "https://api.datamagnet.co/api/v1/post" \
  -H "Authorization: Bearer {token}" \
  -H "Content-Type: application/json" \
  -d '{"url": "https://www.linkedin.com/feed/update/urn:li:activity:7219434359085252608"}'

→ 200 OK · 1 credit

{  "message": {    "post_text": "We're growing the Product team! ...",    "posted_at": "2024-07-17T20:14:41.000Z",    "actor": { "actor_name": "John Smith", "actor_description": "VP of Product at ExampleCo", ... },    "is_repost": true,    "social_count": {      "num_likes": 124,      "num_comments": 11,      "num_shares": 13,      "reaction_type_counts": [{ "count": 108, "reaction_type": "LIKE" }, ...]    },    "urn": "urn:li:activity:7219434359085252608"  },  "credit_used": 1}

What you get

The main fields in the response. The Post Details reference documents every field.

FieldTypeDescription
post_textstringFull text of the post.
post_linkstringDirect link to the post.
posted_atstringISO 8601 publish time. The field to sort and filter on.
actorobjectThe author: name, headline, picture, profile link, URN and numeric id.
social_countobjectnum_likes, num_comments, num_shares and reaction_type_counts.
links_in_postarrayURLs found in the post text.
mentionsarrayPeople and companies tagged in the post, with name and URN.
image_component_all_dimentionsarrayMedia attached to the post, in every size served.
top_commentsarrayThe first comments shown under the post, at no extra cost. Often empty.
is_repostbooleanWhether the post reshares another post.
header, reshared_postobject | nullOn a repost: who reshared it, and the original post.
urnstringUnique identifier of the post.

Use cases

Measure a post

Read likes, comments, shares and the reaction mix of any post from its URL, for campaign reporting or creator and partner programs.

Give an agent the full post

Hand an AI agent or a summariser the complete text, the links in it and the exact publish time instead of a truncated preview.

Untangle reposts

On a repost, actor is the original author and header is the account that reshared it, with the original post under reshared_post.

Frequently asked questions

1 credit per successful request, and each request returns one post.

The /posts/ share URL with an activity or ugcPost id, and the /feed/update/urn:li:activity: URL. The API reads the post id from any of them.

No. top_comments holds the first comments shown under the post, returned at no extra cost and often empty. For the full, paginated list of comments use the Post Comments endpoint.

No. /api/v1/posts (plural) is a deprecated legacy alias that returns a different, less reliable shape. Use /api/v1/post (singular), which returns engagement under social_count and the publish time as posted_at.

Read your first posts with 10 free credits

No credit card required. Get an API key and turn ten post URLs into JSON in a few minutes.

  • 1 credit per post
  • Charged only on success
  • Exact publish time and reaction breakdown

Interactive Demo

~15 minutes

1

Get your API key

1 min
2

POST a post URL

1 min
3

Use the JSON

Instant