DEV Community

Frederik Van Lierde
Frederik Van Lierde

Posted on • Edited on

1

How to get the AuthorID (and Type) to use with the API and poost on LinkedIn Pages

The following code explains how to post on your LinkedIn Business Page (Company pages and Showcase Pages) and how you can find the author id for your page

Many people are confused with the AuthorID in the API
When you create your access code, you do this with your personal account. But posting on LinkedIn pages doesn't use the personal ID. The API needs the Page ID and Page Type

The following code lets you find how you can find it the correct ID.

Prerequisites

Online Tool

I have created an online tool to make it easier:
Online Tool

The Code

use CodeHelper.API.LinkedIn;

LinkedInHelper _helper = new() { AccessToken = "AQWJ0..." };
List<Organisation> _orgs = await 
                _helper.GetUserOrganizationAccessControl();
foreach(var _org in _orgs)
{
   Console.WriteLine(_org.OrganizationalID + " " + 
                              _org.Localized.LocalizedName);
}
Enter fullscreen mode Exit fullscreen mode

The Author ID's

OrganizationalID return the urn:li:TYPE:ID

Image of Timescale

🚀 pgai Vectorizer: SQLAlchemy and LiteLLM Make Vector Search Simple

We built pgai Vectorizer to simplify embedding management for AI applications—without needing a separate database or complex infrastructure. Since launch, developers have created over 3,000 vectorizers on Timescale Cloud, with many more self-hosted.

Read full post →

Top comments (0)

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more