curl \
-H "Authorization: Bearer API_KEY" \
-X GET "https://api.ayrshare.com/api/brand/search/linkedin?search=ayrshare"
curl \
-H "Authorization: Bearer API_KEY" \
-X GET "https://api.ayrshare.com/api/brand/search/linkedin?search=John%20Smith&personOnly=true"
const API_KEY = "API_KEY";
// 搜尋公司或人員
fetch("https://api.ayrshare.com/api/brand/search/linkedin?search=ayrshare", {
method: "GET",
headers: {
Authorization: `Bearer ${API_KEY}`
}
})
.then((res) => res.json())
.then((json) => console.log(json))
.catch(console.error);
// 只搜尋人員
fetch("https://api.ayrshare.com/api/brand/search/linkedin?search=John%20Smith&personOnly=true", {
method: "GET",
headers: {
Authorization: `Bearer ${API_KEY}`
}
})
.then((res) => res.json())
.then((json) => console.log(json))
.catch(console.error);
import requests
headers = {'Authorization': 'Bearer API_KEY'}
# 搜尋公司或人員
r = requests.get('https://api.ayrshare.com/api/brand/search/linkedin?search=ayrshare', headers=headers)
print(r.json())
# 只搜尋人員
r = requests.get('https://api.ayrshare.com/api/brand/search/linkedin?search=john&personOnly=true', headers=headers)
print(r.json())
{
"linkedin": [
{
"vanityName": "ayrshare",
"website": "https://www.ayrshare.com",
"groups": [],
"description": "Ayrshare's APIs provide the core infrastructure for social media posting, management, and analytics.\n\nThe Ayrshare API takes care of the social media infrastructure so you don't have to. Your team can focus on building your product instead of stitching together and maintaining multiple social media platforms.\n\nPost to Facebook, Twitter, Instagram, LinkedIn, Reddit, Telegram, TikTok, Google My Business, and YouTube.\n",
"defaultLocale": {
"country": "US",
"language": "en"
},
"organizationType": "PARTNERSHIP",
"alternativeNames": [],
"specialties": [
"social media",
"api",
"saas",
"social networks",
"tiktok",
"facebook",
"instagram"
],
"staffCountRange": "SIZE_10_TO_100",
"name": "Ayrshare",
"primaryOrganizationType": "NONE",
"locations": [
{
"description": {
"localized": {
"en_US": "Headquarters"
},
"preferredLocale": {
"country": "US",
"language": "en"
}
},
"locationType": "HEADQUARTERS",
"address": {
"geographicArea": "New York",
"country": "US",
"city": "New York",
"line1": "142 W 57th St",
"postalCode": "10019"
},
"localizedDescription": "Headquarters",
"streetAddressFieldState": "UNSET_OPT_OUT",
"geoLocation": "urn:li:geo:103963738"
}
],
"id": 66755333
}
]
}
{
"linkedin": [
{
"lastName": "Smith",
"firstName": "John",
"headline": "CTO at Ayrshare",
"id": "urn:li:person:WBwF1C23L"
}
]
}
{
"linkedin": {
"action": "request",
"status": "error",
"code": 101,
"message": "Missing or incorrect parameters. Please verify with the docs. https://www.ayrshare.com/docs/apis",
"details": "The search must be a string between 3 and 100 characters."
}
}
{
"linkedin": []
}
Search
搜尋 LinkedIn
搜尋 LinkedIn 公司或人員
GET
/
brand
/
search
/
linkedin
curl \
-H "Authorization: Bearer API_KEY" \
-X GET "https://api.ayrshare.com/api/brand/search/linkedin?search=ayrshare"
curl \
-H "Authorization: Bearer API_KEY" \
-X GET "https://api.ayrshare.com/api/brand/search/linkedin?search=John%20Smith&personOnly=true"
const API_KEY = "API_KEY";
// 搜尋公司或人員
fetch("https://api.ayrshare.com/api/brand/search/linkedin?search=ayrshare", {
method: "GET",
headers: {
Authorization: `Bearer ${API_KEY}`
}
})
.then((res) => res.json())
.then((json) => console.log(json))
.catch(console.error);
// 只搜尋人員
fetch("https://api.ayrshare.com/api/brand/search/linkedin?search=John%20Smith&personOnly=true", {
method: "GET",
headers: {
Authorization: `Bearer ${API_KEY}`
}
})
.then((res) => res.json())
.then((json) => console.log(json))
.catch(console.error);
import requests
headers = {'Authorization': 'Bearer API_KEY'}
# 搜尋公司或人員
r = requests.get('https://api.ayrshare.com/api/brand/search/linkedin?search=ayrshare', headers=headers)
print(r.json())
# 只搜尋人員
r = requests.get('https://api.ayrshare.com/api/brand/search/linkedin?search=john&personOnly=true', headers=headers)
print(r.json())
{
"linkedin": [
{
"vanityName": "ayrshare",
"website": "https://www.ayrshare.com",
"groups": [],
"description": "Ayrshare's APIs provide the core infrastructure for social media posting, management, and analytics.\n\nThe Ayrshare API takes care of the social media infrastructure so you don't have to. Your team can focus on building your product instead of stitching together and maintaining multiple social media platforms.\n\nPost to Facebook, Twitter, Instagram, LinkedIn, Reddit, Telegram, TikTok, Google My Business, and YouTube.\n",
"defaultLocale": {
"country": "US",
"language": "en"
},
"organizationType": "PARTNERSHIP",
"alternativeNames": [],
"specialties": [
"social media",
"api",
"saas",
"social networks",
"tiktok",
"facebook",
"instagram"
],
"staffCountRange": "SIZE_10_TO_100",
"name": "Ayrshare",
"primaryOrganizationType": "NONE",
"locations": [
{
"description": {
"localized": {
"en_US": "Headquarters"
},
"preferredLocale": {
"country": "US",
"language": "en"
}
},
"locationType": "HEADQUARTERS",
"address": {
"geographicArea": "New York",
"country": "US",
"city": "New York",
"line1": "142 W 57th St",
"postalCode": "10019"
},
"localizedDescription": "Headquarters",
"streetAddressFieldState": "UNSET_OPT_OUT",
"geoLocation": "urn:li:geo:103963738"
}
],
"id": 66755333
}
]
}
{
"linkedin": [
{
"lastName": "Smith",
"firstName": "John",
"headline": "CTO at Ayrshare",
"id": "urn:li:person:WBwF1C23L"
}
]
}
{
"linkedin": {
"action": "request",
"status": "error",
"code": 101,
"message": "Missing or incorrect parameters. Please verify with the docs. https://www.ayrshare.com/docs/apis",
"details": "The search must be a string between 3 and 100 characters."
}
}
{
"linkedin": []
}
依搜尋條件搜尋 LinkedIn 公司或人員。
此端點常用於社群媒體貼文中 @提及功能的輸入自動補全。
已連結的帳號必須是 LinkedIn 公司頁面才能搜尋。 個人 LinkedIn 帳號無法用於執行搜尋。
- 在貼文中提及:當實作 @提及功能時,請搭配輸入自動補全使用此端點。
- 公司搜尋:需要提供公司的完整專屬名稱 (vanity name)。
- 人員搜尋:至少輸入 3 個字元的姓名以取得最佳結果。
- 速率限制:此端點遵循標準的 API 速率限制。
搜尋限制
- 公司:您可以搜尋任何 LinkedIn 公司頁面
- 人員:您只能搜尋您 LinkedIn 帳號的追蹤者,而且 Ayrshare 已連結的帳號必須是 LinkedIn 公司頁面才能執行搜尋。若對方將 LinkedIn 隱私設定為不公開,他們就不會出現在搜尋結果中。
標頭參數
查詢參數
用以尋找 LinkedIn 公司或人員的搜尋條件。需求:
- 最短長度:人員 3 個字元,公司 1 個字元。
- 最長長度:人員與公司皆為 100 個字元。
- 公司搜尋:使用公司的專屬名稱 (vanity name),可從 LinkedIn URL 中取得。只會回傳專屬名稱完全相符的結果。
- 範例:對於
linkedin.com/company/ayrshare,請搜尋 “ayrshare”。 - 搜尋部分名稱(如 “ayrsh”)將不會傳回結果。
- 範例:對於
- 人員搜尋:使用名字與/或姓氏,支援部分名稱比對。
- 範例:“John Smith” 會找到名為 John Smith 的人。請務必將空格進行 URL 編碼。
- 部分比對如 “Joh” 或 “Smi” 也會回傳結果。
- 請記得:僅能找到您 LinkedIn 的追蹤者,且 Ayrshare 已連結的帳號必須是 LinkedIn 公司頁面才能執行搜尋
控制搜尋範圍:-
false(預設):先搜尋公司,若找不到公司則再搜尋人員。 - true:只搜尋人員(完全跳過公司搜尋)。範例
curl \
-H "Authorization: Bearer API_KEY" \
-X GET "https://api.ayrshare.com/api/brand/search/linkedin?search=ayrshare"
curl \
-H "Authorization: Bearer API_KEY" \
-X GET "https://api.ayrshare.com/api/brand/search/linkedin?search=John%20Smith&personOnly=true"
const API_KEY = "API_KEY";
// 搜尋公司或人員
fetch("https://api.ayrshare.com/api/brand/search/linkedin?search=ayrshare", {
method: "GET",
headers: {
Authorization: `Bearer ${API_KEY}`
}
})
.then((res) => res.json())
.then((json) => console.log(json))
.catch(console.error);
// 只搜尋人員
fetch("https://api.ayrshare.com/api/brand/search/linkedin?search=John%20Smith&personOnly=true", {
method: "GET",
headers: {
Authorization: `Bearer ${API_KEY}`
}
})
.then((res) => res.json())
.then((json) => console.log(json))
.catch(console.error);
import requests
headers = {'Authorization': 'Bearer API_KEY'}
# 搜尋公司或人員
r = requests.get('https://api.ayrshare.com/api/brand/search/linkedin?search=ayrshare', headers=headers)
print(r.json())
# 只搜尋人員
r = requests.get('https://api.ayrshare.com/api/brand/search/linkedin?search=john&personOnly=true', headers=headers)
print(r.json())
{
"linkedin": [
{
"vanityName": "ayrshare",
"website": "https://www.ayrshare.com",
"groups": [],
"description": "Ayrshare's APIs provide the core infrastructure for social media posting, management, and analytics.\n\nThe Ayrshare API takes care of the social media infrastructure so you don't have to. Your team can focus on building your product instead of stitching together and maintaining multiple social media platforms.\n\nPost to Facebook, Twitter, Instagram, LinkedIn, Reddit, Telegram, TikTok, Google My Business, and YouTube.\n",
"defaultLocale": {
"country": "US",
"language": "en"
},
"organizationType": "PARTNERSHIP",
"alternativeNames": [],
"specialties": [
"social media",
"api",
"saas",
"social networks",
"tiktok",
"facebook",
"instagram"
],
"staffCountRange": "SIZE_10_TO_100",
"name": "Ayrshare",
"primaryOrganizationType": "NONE",
"locations": [
{
"description": {
"localized": {
"en_US": "Headquarters"
},
"preferredLocale": {
"country": "US",
"language": "en"
}
},
"locationType": "HEADQUARTERS",
"address": {
"geographicArea": "New York",
"country": "US",
"city": "New York",
"line1": "142 W 57th St",
"postalCode": "10019"
},
"localizedDescription": "Headquarters",
"streetAddressFieldState": "UNSET_OPT_OUT",
"geoLocation": "urn:li:geo:103963738"
}
],
"id": 66755333
}
]
}
{
"linkedin": [
{
"lastName": "Smith",
"firstName": "John",
"headline": "CTO at Ayrshare",
"id": "urn:li:person:WBwF1C23L"
}
]
}
{
"linkedin": {
"action": "request",
"status": "error",
"code": 101,
"message": "Missing or incorrect parameters. Please verify with the docs. https://www.ayrshare.com/docs/apis",
"details": "The search must be a string between 3 and 100 characters."
}
}
{
"linkedin": []
}
⌘I
