且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

Linkedin API-从网址获取公司ID

更新时间:2023-11-27 20:25:16

2019更新

任意页面

以前提供的解决方案已过时.以下不是***解决方案,但会在某些情况下起作用.不幸的是,它不需要. (我知道这不能回答OP的问题,但是它应该会帮助到达这里的其他人,因为这是Google的最高成绩)

2019 update

Arbitrary Pages

The solutions provided previously are outdated. The following is not the best solution, but it will work in a pinch. It does require "crawling", unfortunately. (I know this doesn't answer OP's question, but it should help others who arrive here since this is the top Google result)

查看您要查找其ID的公司主页"的HTML源.搜索字符串https://www.linkedin.com/company/.该字符串在页面上的第一个实例之后是公司ID.

View the HTML source for the "home page" of the company whose ID you are trying to discover. Search for the string, https://www.linkedin.com/company/. The first instance of this string on the page is followed immediately by the company ID.

您可以通过访问整个链接(包括公司ID)来验证您拥有正确的公司ID,例如https://www.linkedin.com/company/123456.

You can verify that you have the right company ID by visiting the entire link (including the Company ID), e.g. https://www.linkedin.com/company/123456.

如果这种方法在某个时候停止工作,请在下面发表评论,我将更新此答案.

If this approach stops working at some point, please comment below and I'll update this answer.

更新:我今天(2019/2/7)使用该策略,并且由于LinkedIn进行了一些更改,我发现最后一个实例目前更可靠.最终,总体策略仍然是正确的.查看源并找到一些可重复的方式来搜索公司ID.寻找可靠的方法可能需要做一些实验.

UPDATE: I'm using the strategy today (7/2/2019) and am finding that the last instance is currently more reliable due to some changes made by LinkedIn. Ultimately, the overall strategy remains sound. View the source and find some repeatable way to search for the company ID. It may take some experimentation to find a reliable approach.

如果您具有该页面的管理员权限,则查找公司ID并不重要.登录后,访问您的公司页面.在网址中直接使用公司ID.

If you have admin rights to the Page, finding the Company ID is trivial. While signed in, visit your Company Page. The Company ID is used right within the URL.

例如:

公司页面的管理员URL:https://www.linkedin.com/company/123123123/admin/

Admin URL for Company Page: https://www.linkedin.com/company/123123123/admin/

公司ID:123123123

或者,您当然可以使用该API查找您作为管理员的任何公司页面的公司ID.

Or, you can of course use the API to find the Company ID for any Company Page of which you are an admin.