So I spoke with a Linkedin Technical Support member and it appears there is an error in their documentation.
The correct call requires a PUT
request.
Additionally, the URL for the request is: https://api.linkedin.com/v2/organizationAcls/(organization:urn%3Ali%3Aorganization%3AXXXXXXX,role:DIRECT_SPONSORED_CONTENT_POSTER,roleAssignee:urn%3Ali%3Aperson%3AXXXXXXX). Where the ‘XXXXXXX’ needs to be the associated organization id and the associated person id.
Lastly, as part of the request, a request body needs to be passed in. The request body is a JsonObject
that contains the following properties.
state
role
roleAssignee
organization
For state
, the only possible value is REQUESTED
.
For role
, the only possible value is DIRECT_SPONSORED_CONTENT_POSTER
.
For role assignee
, it is "urn:li:person:" + roleAssignee
, the id of the user you wish to use add to the below organization.
Lastly, for the organization
, it is "urn:li:organization:" + organization
, the id of organization you wish to add the above user to.
CLICK HERE to find out more related problems solutions.