DEV Community

Cover image for Ultimate Guide To Linkedin Company API, With Full Python Code Samples
Proxycurl
Proxycurl

Posted on

Ultimate Guide To Linkedin Company API, With Full Python Code Samples

Ever felt like you're navigating a complex maze when working with the LinkedIn Company API? Trust me, I've been there. As a battle-hardened developer, I've wrestled with API limitations, rate limits, and data restrictions more times than I can count. But guess what? Those frustrations led to some pretty cool discoveries I'm about to share with you.

Whether you're a developer building the next big thing in HR tech, a data scientist with an insatiable appetite for corporate data extraction, or a startup founder aiming to disrupt the B2B landscape, you've just stumbled upon your treasure map to the LinkedIn data goldmine.

In this no-BS guide, we're going to:

  • Demystify the LinkedIn Company API (because who doesn't love a good mystery?)
  • Show you how to squeeze every last drop of value from this world's largest B2B platform
  • Introduce you to a game-changing alternative (Proxycurl Company API) that'll make you question everything you thought you knew about LinkedIn data access (spoiler alert: it's good)

But hey, why tell when we can show? Let's kick things off with a taste of what's possible. Imagine pulling comprehensive company data with just a few lines of code:

curl \
    -G \
    -H "Authorization: Bearer demo-bearer-token" \
    'https://nubela.co/proxycurl/api/linkedin/company' \
    --data-urlencode 'url=https://www.linkedin.com/company/google/' \
    --data-urlencode 'categories=include' \
    --data-urlencode 'funding_data=include' \
    --data-urlencode 'exit_data=include' \
    --data-urlencode 'acquisitions=include' \
    --data-urlencode 'extra=include' \
    --data-urlencode 'use_cache=if-present' \
    --data-urlencode 'fallback_to_cache=on-error'
Enter fullscreen mode Exit fullscreen mode

Impressed? That's just the appetizer. This snippet showcases the power of a third-party LinkedIn API solution (in this case, our very own Proxycurl API). But don't worry. In this guide, we'll dive into both official and alternative solutions.

Whether you're dealing with API rate limits, wrestling with data restrictions, or simply looking for more efficient ways to access corporate insights, you’re in the right place. We'll explore both the official LinkedIn Company API and 3rd-party APIs like Proxycurl Company API and make you, the developer, the API hero your company deserves! Let’s get started!

Why trust our expertise?

When it comes to navigating the labyrinth of data about people and companies, you want a guide who's been in the trenches. That's us. At Proxycurl, we've spent years wrangling with APIs, decoding data structures, and pushing the boundaries of what's possible with LinkedIn data. We're talking about a platform that boasts 900+ million users and 58.4+ million companies - that's the scale of data we're dealing with. Here's why you can trust us:

  • Battle-tested experience and continuous innovation: We didn't stop at understanding LinkedIn's API. When we hit roadblocks, we innovated. Our team has developed cutting-edge solutions to extract, process, and analyze LinkedIn data at scale. This drive for innovation led to the creation of our own Proxycurl API products, which now serves as a powerful alternative to LinkedIn's official offerings.
  • Deep understanding of business needs: Our expertise isn't limited to the technical side. We've worked closely with businesses across various industries – from nimble startups to Fortune 500 giants. This has given us unique insights into how LinkedIn company data can drive real business value, whether it's for lead generation, market analysis, or HR tech solutions.

But don't just take my word for it. Here's a quick success story:

  • A game-changer in the HR tech domain: An HR tech startup struggled with LinkedIn's API limitations for their AI-driven recruitment platform. After switching to Proxycurl's API, they got:
    • Access to rich company profiles, including detailed information on company size, industry, and recent hires
    • 40% increase in successful placements
    • 60% reduction in data acquisition costs
    • Significantly more accurate candidate-company matches

By the way, our success stories aren't just impressive numbers on a spreadsheet - they're real-world game-changers, my friend! We're talking about businesses that were up against the wall with several limitations and came out swinging. From turbocharging HR tech to revolutionizing market intelligence, from supercharging B2B sales to... well, you get the picture. The possibilities are so vast, I'd need a novel to list them all (and, nobody wants that).

So, as we dive deeper into the world of LinkedIn Company APIs, remember: you're not just getting information - you're tapping into years of hands-on experience and proven results. We've been in the trenches, fought the API battles with scars (success stories) to prove it, and we're here to guide you to victory.

Two types of LinkedIn Company APIs

Before we dive in, let's set the scene. In the realm of LinkedIn Company APIs, there are two distinct territories:

  1. The Official LinkedIn Company API: The gated community, where only the chosen few (LinkedIn Partners) get to play.
  2. 3rd-party LinkedIn Company APIs: The wild west, where alternative solutions like Proxycurl roam free for those locked out of the official party. Want to cut to the chase and skip to the good part? Click here to jump to the Proxycurl's LinkedIn Company API section.

The official LinkedIn Company API

Alright, fellow data enthusiasts, it's time to pull back the curtain on the official LinkedIn Company API. Think of it as your backstage pass to the world's largest professional network. Let's break down what this API is all about, what it can do, and who can benefit from it. Buckle up!

What is the official LinkedIn Company API?

In simple terms, the official LinkedIn Company API is a set of programmatic interfaces that allow developers to access and retrieve data about companies listed on LinkedIn. It's like having a direct line to LinkedIn's vast database of corporate information, but with some rules and limitations (we'll get to those later, don't worry).

Five key features of the LinkedIn Company API

Now, what can you actually do with this API? Let's break it down:

  1. Company profile retrieval:
  2. Basic company information (name, website, industry, etc.)
  3. Company size and employee count
  4. Headquarters location and other office locations
  5. Founded year and company type
  6. Follower statistics:
  7. Total follower count
  8. Follower demographics (limited)
  9. Updates and content:
  10. Recent company updates
  11. Shared content statistics
  12. Job postings:
  13. Current job openings (with limitations)
  14. Insights (for select partners):
  15. Page analytics
  16. Follower gains

It's worth noting that while this list might seem extensive, the actual data you can access is often more limited than you might expect. LinkedIn keeps a tight leash on its data, rightly so because the vast data on their platform is indeed extremely valuable, and which is why alternatives like Proxycurl have become so popular (but we're getting ahead of ourselves).

Who can benefit and how? Six quick use cases

User Group Use Cases
Developers and software engineers - Building company research tools
- Integrating LinkedIn data into existing applications
- Creating custom dashboards for business intelligence
Data scientists - Analyzing company growth trends
- Performing industry-wide comparisons
- Building predictive models for business performance
HR and recruitment professionals - Enhancing applicant tracking systems with company data
- Researching potential employers for candidates
- Identifying companies with recent growth for targeted recruiting
Sales and marketing teams - Enriching CRM data with up-to-date company information
- Identifying potential leads based on company characteristics
- Creating targeted marketing campaigns based on company insights
Business strategists and consultants - Conducting competitive analysis
- Identifying potential partners or acquisition targets
- Tracking industry trends and company movements
Entrepreneurs and startup founders - Researching potential competitors or partners
- Understanding industry landscapes
- Identifying gaps in the market based on company data

For a real-world example, let's say you're a developer, and your company is building a B2B sales intelligence platform. With the LinkedIn Company API, you could:

  1. Pull basic company profiles for your leads
  2. Track follower growth as a proxy for company popularity or market position
  3. Monitor job postings to identify companies in growth phases
  4. Analyze recent updates to gauge company activity and focus areas

Sounds great, right? But here's where it gets tricky. While the LinkedIn Company API offers these capabilities in theory, accessing and using this data comes with its own set of challenges. Rate limits, data restrictions, and stringent application processes can turn your data dreams into an API nightmare faster than you can say "HTTP 429 Too Many Requests."

But don't worry! We'll dive into how to actually get your hands on this data, the nitty-gritty of making API calls, and yes, we'll tackle those pesky limitations head-on. And if you find yourself thinking, "There's got to be a better way," well... stay tuned. We might just have a solution that'll make you forget all about those API blues.

Four things to know before getting access to the official LinkedIn Company API

Alright, let's talk more about the elephant in the room - actually getting access to the official LinkedIn API. It's like the coolest club in town, but getting past the bouncer? That's where things get very tricky:

  1. Access Restrictions: This isn't your average "open to all" API. Nope, it's exclusive to LinkedIn Partners. Think of it as the API world's VIP lounge.
  2. Approval Process: Remember that time you waited in line for hours to get into the hottest club? Yeah, trust me, this makes that look like a cakewalk. We're talking weeks of administrative hurdles and scrutiny.
  3. Competitive Clause: Here's the kicker - LinkedIn won't let you in if you're building something that could steal their thunder. Competing with LinkedIn products? Sorry, you're not on the list.
  4. Pricing and Cost Consideration: LinkedIn keeps its pricing cards close to the chest. Brace yourself, there are whispers of five-figure monthly fees for the privilege of API access. That's right; we're potentially talking about tens of thousands per month. But anyway, expect to negotiate based on your usage and needs. And remember those whispers of five-figure monthly fees? Yeah, that's the ballpark we're playing in.

So, you still want in?

1. First, apply to become a LinkedIn Partner

Alright, you brave soul, here are the 3 steps on how to get that coveted LinkedIn Partner status to get access to the LinkedIn Company API:

Step 1: Determining your category

  • Talent Solutions: For the HR tech wizards out there that integrate with LinkedIn’s hiring and talent acquisition tools.
  • Marketing Solutions: Marketing automation gurus, this one's for you. I mean marketing automation platforms or tools that integrate LinkedIn Ads or company page analytics.
  • Sales Navigator Application Development: Sales tech innovators, step right up. Companies building on top of LinkedIn’s sales and business development tools (Sales Navigator).
  • LinkedIn Learning Integration: E-learning enthusiasts and professional development platforms that might integrate with LinkedIn Learning, come on down!

Step 2: Preparing your application

Time to put on your best suit and practice your elevator pitch:

  • Be crystal clear about how you'll use LinkedIn's data. Vague ideas won't cut it here.
  • Show how you're adding to LinkedIn's ecosystem, not trying to outshine it.
  • Prepare to dazzle them with the value you'll bring to the LinkedIn universe.

Step 3: Submitting your application

Now, it’s time to head over to the LinkedIn Partner Program page and lay it all out:

LinkedIn’s Partner Program page showing the partner categories for a new application
LinkedIn’s Partner Program page showing the partner categories for a new application

  • Choose your category (remember Step 1?)
  • Spill the beans about you, your company and your products
  • Fill out the application form in detail (remember to paint a vivid picture of your partnership use case)

Now, the waiting game begins. And by game, I mean weeks of nail-biting anticipation. Stay on your toes - LinkedIn might come back asking for more info.

But wait, there's more…

2. While waiting, get access to the "Lite" version

While you're twiddling your thumbs waiting weeks (or months) for that coveted LinkedIn Partner status, there's a "lite" version you can start exploring. Spoiler alert: it's basic and still also requires approval, but it might just scratch that API itch in the meantime.

Here are it's 5 steps:

Step 1: Creating a LinkedIn Developer account

Step 2: Creating your LinkedIn application

  • After signing in, on the page, click "Create app":

Start creating your app here
Start creating your app here

  • Fill in the blanks about your app (make it good!)

Pro Tip: Be specific about your use case. LinkedIn likes to know exactly how you'll be using their data. It's like telling your partner why you have been out for 5 nights in a row - the more details, the better!

Step 3: Verifying your app

  • After submitting your use case, you need to verify that the app is truly associated with the selected company (your company)
  • Navigate to the "Settings" tab and click on the "Verify" button

Verifying your app
Verifying your app

  • Follow the instructions that come afterward. It's like proving you're really you but for your app!

Step 4: Requesting API access

  • After the verification, you can now proceed with requesting API access
  • Navigate to the "Products" tab
  • Read through the API Terms of Use (yes, actually read it - we know, it's boring, but important!)
  • Finally, select the "Request access" button.

Here you can request to get access to the API
Here you can request to get access to the API

  • Fingers crossed!

Step 5: Getting your API credentials

  • Once approved, in the dashboard, you'll get your Client ID and Client Secret:

Finally, you gotten access to the keys
Finally, you gotten access to the keys

  • Guard these with everything you’ve got (or at least don't post them on GitHub). You’ll use them in your code (which we shall discuss next) to get the access token.

Remember, my friend, while this guide is comprehensive, the official LinkedIn API world is as changeable as a chameleon on a disco floor. Always double-check the official LinkedIn docs for the latest info. It's like checking the weather before a picnic - better safe than sorry!

3. Finally approved, start using the official LinkedIn Company API with Python!

Congratulations! If you're reading this, you've somehow managed to scale the fortress walls of accessing a LinkedIn's developer account. You've survived the scrutiny of use-case evaluation and emerged victorious with your basic API access in hand. Now, it's time to claim your prize and dive into the data that awaits. Let’s turn that hard-earned access into pure data gold!

The technical landscape

Before we dive into the code, let's get our hands dirty with some technical details. After all, knowing is half the battle!

  1. Company Search API: This is your go-to for finding companies using keywords, industry, location, and other criteria. Think of it as LinkedIn's corporate search engine on steroids:
    • Returns a collection of matching companies
    • Each entry can contain an entity field represented by an organization URN (Uniform Resource Name)
    • Supports filters similar to LinkedIn's Search results page
  2. OAuth 2.0 authentication: LinkedIn's bouncer at the door. Before you can party with the data, you need to get past this guy:
    • Required for member (user) authorization and API authentication
    • Essential for fetching data or accessing member information
    • Most permissions require explicit approval from LinkedIn
  3. Permissions and partner programs:
    • Open Permissions: The public library of LinkedIn APIs - available to all developers without special approval
    • Restricted Permissions: The special collections - require LinkedIn's explicit nod

Now that we've got the lay of the land, let's roll up our sleeves and dive into the code!

Step 1: Getting your access token function

In the API world, access tokens are like VIP passes to an exclusive club. LinkedIn’s Company API uses the Client Credential Flow (2-legged OAuth) to grant this backstage pass (access token). Remember our Client ID and Secret we saved earlier? It’s time to trade them for an access token:

import requests

# Your LinkedIn App's Client ID and Client Secret
LINKEDIN_CLIENT_ID = 'your_client_id'
LINKEDIN_CLIENT_SECRET = 'your_client_secret'

def get_access_token():
    """
    Exchanges LinkedIn app's client credentials for an access token.
    """
    token_url = 'https://www.linkedin.com/oauth/v2/accessToken'

    params = {
        'grant_type': 'client_credentials',
        'client_id': LINKEDIN_CLIENT_ID,
        'client_secret': LINKEDIN_CLIENT_SECRET,
    }

    headers = {
        'Content-Type': 'application/x-www-form-urlencoded'
    }

    response = requests.post(token_url, headers=headers, data=params)

    if response.status_code == 200:
        access_token = response.json().get('access_token')
        if access_token:
            print(f"Access Token acquired: {access_token}")
            return access_token
        else:
            print("Access token not found in the response.")
            return None
    else:
        print(f"Error {response.status_code}: {response.text}")
        return None

# Get the access token
access_token = get_access_token()
Enter fullscreen mode Exit fullscreen mode

Pro Tip: In my experience, it's crucial to treat your access token like your secret recipe for success. Store it securely and reuse it until it expires (typically after 30 minutes). After that, simply request a new one. Remember, sharing is caring, but not when it comes to access tokens!

Step 2: Making your API call function

Now that we have our VIP pass (access token), let's fetch some company data! We'll use the Company Search API and its keyword search feature to find some cool companies:

def search_companies(access_token, search_query='LinkedIn Corporation', filters=None):
    """
    Search for companies on LinkedIn using the provided access token, query, and optional filters.
    """
    base_url = 'https://api.linkedin.com/v2/companySearch'
    params = {
        'q': 'search',
        'query': search_query,
        'projection': '(elements*(entity~(id,name,localizedName,vanityName,logoV2,locations)),paging)'
    }

    # Add filters if provided
    if filters:
        for key, value in filters.items():
            if isinstance(value, list):
                for i, v in enumerate(value):
                    params[f'filter.{key}[{i}]'] = v
            else:
                params[f'filter.{key}'] = value

    headers = {
        'Authorization': f'Bearer {access_token}',
        'X-Restli-Protocol-Version': '2.0.0'
    }

    url = f"{base_url}?{urlencode(params)}"
    response = requests.get(url, headers=headers)

    if response.status_code == 200:
        print("Data successfully retrieved!")
        return response.json()
    else:
        print(f"Error {response.status_code}: {response.text}")
        return None
Enter fullscreen mode Exit fullscreen mode

This search_companies function will allow us to zoom in on the corporate landscape. Here's what makes it tick:

  • Query power: The search_query parameter defines the search term. It's like whispering a company name or industry keyword into the API's ear.
  • Filter finesse: The filters parameter lets us refine our search. Want only tech giants? Or perhaps cozy startups? These filters are our corporate matchmakers.
  • Data projection: We're asking for specific company details like name, vanity name, logo, and locations. It's like customizing our corporate baseball cards.
  • Error handling: We've built in some safeguards. If something goes wrong, the function will let us know, rather than leaving us in the dark.
  • Flexibility: We can easily modify the search query or filters to suit our various needs.

Step 3: Putting it all together

Now that we have our access token function and our API call function, let's combine them into a main function that will orchestrate our LinkedIn company search:

def search_companies(access_token, search_query='LinkedIn Corporation', filters=None):
    """
    Search for companies on LinkedIn using the provided access token, query, and optional filters.
    """
    base_url = 'https://api.linkedin.com/v2/companySearch'
    params = {
        'q': 'search',
        'query': search_query,
        'projection': '(elements*(entity~(id,name,localizedName,vanityName,logoV2,locations)),paging)'
    }

    # Add filters if provided
    if filters:
        for key, value in filters.items():
            if isinstance(value, list):
                for i, v in enumerate(value):
                    params[f'filter.{key}[{i}]'] = v
            else:
                params[f'filter.{key}'] = value

    headers = {
        'Authorization': f'Bearer {access_token}',
        'X-Restli-Protocol-Version': '2.0.0'
    }

    url = f"{base_url}?{urlencode(params)}"
    response = requests.get(url, headers=headers)

    if response.status_code == 200:
        print("Data successfully retrieved!")
        return response.json()
    else:
        print(f"Error {response.status_code}: {response.text}")
        return None
Enter fullscreen mode Exit fullscreen mode

Here, we use the query parameter to search for companies by keyword. In this case, we're searching for "LinkedIn Corporation", but feel free to replace it with any company name or industry keyword that piques your interest. Remember, you can adjust your search query, add or remove filters, and experiment with different parameters to refine your results. Don't be afraid to tweak the code and see what kind of company data you can uncover.

Remember, when using this API:

  • All input is case-insensitive
  • Wildcards and Boolean logic are not supported
  • You should search for only a single company at a time (be aware of LinkedIn's API usage limits and respect them in your code)

For the output, the actual fields returned may vary based on the company and the level of access your application has. Some fields might be missing or have different values. It's like a box of chocolates - you never know exactly what you're gonna get!

And there you have it! You've just made your first call to the LinkedIn Company API. Feel that rush? That's the power of data at your fingertips!

But wait, there's a plot twist...

Limitations of this LinkedIn Company API

If you’re using this official LinkedIn Company API and it's working flawlessly, congratulations! You're one of the chosen few. But for many of us mere mortals, we might hit a few roadblocks. Don't worry, what you're facing is common, and LinkedIn is notorious with the limitations they placed.

Limitation #1: Rate limits

  1. Daily limits:
    • LinkedIn typically caps API calls at around 100,000 per day.
    • Sounds like a lot? Not when you're dealing with big data or building a scalable application.
  2. Endpoint-specific limits:
    • Some endpoints are more restricted than others.
    • For example, company lookups might be limited to a mere 100 calls per day per company.
  3. Unpredictable throttling:
    • LinkedIn may decide to throttle your requests if they think you're being too eager.
    • It's like playing data roulette – you never know when you'll hit the "too many requests" jackpot.

Imagine you're building a sales intelligence tool. You want to enrich your CRM with fresh LinkedIn corporate data daily. With these rate limits, you might be able to update a few hundred records a day. At that rate, by the time you finish updating your database, the first entries are already outdated!

Limitation #2: Data restriction

  1. Limited company information:
    • Basic company profiles? Sure.
    • Detailed employee information or comprehensive company updates? Not so fast.
  2. Historical data constraints:
    • Want to analyze a company's growth over the past year? Good luck to you and yours.
    • LinkedIn often restricts access to historical data, leaving you with a snapshot rather than a movie.
    • But here's some good news: We recently launched a historical data feature at Proxycurl. Check out our article on historical employee growth to see how you can get that movie after all!
  3. Follower insights:
    • You can see follower counts, but detailed follower demographics? That's behind a velvet rope.

Let's say you're a market researcher trying to understand industry trends. You want to analyze how companies in a specific sector have evolved over the past five years. With these data restrictions, you're left with gaps in your analysis that could skew your entire report.

Limitation #3: When LinkedIn says "No"

Picture this: You've got a brilliant idea for an app that will revolutionize how people find jobs. You're pumped, you're coding away, and then... LinkedIn's terms of service bring your dreams crashing down.

  1. Competitive features:
    • If your application competes with LinkedIn's core offerings, you might be shown the door.
    • Building a recruiting platform? LinkedIn might view you as a competition and restrict your API access.
  2. Data usage restrictions:
    • LinkedIn is very particular about how you can use their data.
    • Want to combine LinkedIn data with other sources for a comprehensive business intelligence tool? You might be walking on thin ice.
  3. Display guidelines:
    • There are strict rules about how you can display LinkedIn data in your application.
    • It's like being told exactly how to arrange furniture in a house you thought you owned.

Imagine you've built an AI-powered career advisory tool that uses LinkedIn’s corporate data to suggest optimal career paths. You're ready to launch, but LinkedIn decides your app is too similar to their own career insight features. Suddenly, your API access is revoked, and months of work go down the drain.

Wait a minute. Don't get me wrong - the official LinkedIn Company API is powerful. But it's like a temperamental sports car: high-performance but high-maintenance, too.

The plot thickens...

Now, imagine accessing comprehensive LinkedIn company data without rate limits breathing down your neck or extensive approval processes. Picture pulling historical data that lets you analyze trends over time. Envision building that revolutionary app without fear of suddenly losing API access. Sounds too good to be true, right?

Enter Proxycurl: a game-changing alternative to the official LinkedIn Company API

Alright, folks, it's time to introduce you to the superhero of our entire story. Remember all those official LinkedIn Company API headaches we just talked about? Well, imagine if there was a magic wand that could make them disappear faster than you can say "rate limit."

Ladies and gentlemen, I welcome you to Proxycurl – your new best friend in the world of LinkedIn data.

Why Proxycurl Company API? Four key features and advantages

Let's break down why Proxycurl is the Robin Hood of LinkedIn data, democratizing access for developers and associated companies everywhere:

  1. Generous rate limits:
    • Say goodbye to those pesky "Too Many Requests" errors
    • Proxycurl offers plans with credits with up to millions of API calls per month
    • It's like going from a garden hose to a fire hydrant of data
  2. Comprehensive data access:
    • Full company profiles, including employee counts, funding info, and more
    • Historical data that lets you analyze trends over time
    • It's not just a snapshot; it's the whole movie of a company's LinkedIn presence
  3. Flexible use cases:
    • Build that revolutionary app without fear of suddenly losing access
    • Combine LinkedIn data with other sources for powerful business intelligence
    • Your imagination is the limit, not some restrictive terms of service
  4. Simple integration:
    • RESTful API that plays nice with most programming languages
    • Clear documentation that doesn't require a PhD to understand
    • It's so easy, you'll wonder why you ever wrestled with LinkedIn's API

But don't just take my word for it. Let's see the Proxycurl Company API in action!

Seamless transition from the official LinkedIn Company API to Proxycurl Company API

Remember that company search through the official LinkedIn Company API we wrestled with earlier? Well, prepare to have your mind blown. Here's how easy it is with Proxycurl Company API:

import requests

def fetch_company_data(api_key, company_url, use_cache='if-present', fallback_to_cache='on-error'):
    """
    Fetch company data using Proxycurl API with cache control
    """
    api_endpoint = 'https://nubela.co/proxycurl/api/linkedin/company'
    headers = {'Authorization': f'Bearer {api_key}'}
    params = {
        'url': company_url,
        'categories': 'include',
        'funding_data': 'include',
        'exit_data': 'include',
        'acquisitions': 'include',
        'extra': 'include',
        'use_cache': use_cache,
        'fallback_to_cache': fallback_to_cache
    }

    response = requests.get(api_endpoint, params=params, headers=headers, timeout=10)

    if response.status_code == 200:
        return response.json()
    else:
        print(f"Oops! Something went wrong. Status code: {response.status_code}")
        return None

# Example usage
if __name__ == "__main__":
    api_key = 'YOUR_API_KEY'
    company_url = 'https://www.linkedin.com/company/google/'

    # Fetch data with default cache settings
    company_data = fetch_company_data(api_key, company_url)

    # Or, fetch only recent data
    # company_data = fetch_company_data(api_key, company_url, use_cache='if-recent')

    # Or, never fallback to cache
    # company_data = fetch_company_data(api_key, company_url, fallback_to_cache='never')

    if company_data:
        print(f"Company Name: {company_data.get('name', 'N/A')}")
        print(f"Industry: {company_data.get('industry', 'N/A')}")
        print(f"Company Size: {company_data.get('company_size', 'N/A')}")
        print(f"Follower Count: {company_data.get('follower_count', 'N/A')}")
        print("And lots more corporate secrets!")
Enter fullscreen mode Exit fullscreen mode

Look at that! Clean, simple, and powerful. Here's what makes our function shine:

  • API key magic: Your API key is the magic wand that grants you access to Proxycurl's treasure trove of data.
  • Flexible fetching: By tweaking the params dictionary, we can adjust what kind of corporate intel we're after. Want funding data? Acquisitions? It's all at your fingertips!
  • Error handling: If something goes awry in our data-summoning ritual, the function will let us know. No silent failures here!

Thought we were done? Nah…

Cache-control

With the use_cache parameter, you're now the master of time (well, data freshness, at least):

  • if-present (default): "Give me what you've got, old or new!"
  • if-recent: "I want the fresh stuff, no older than 29 days please!"

Fallback strategy

The fallback_to_cache parameter lets you decide what to do if fetching fresh data hits a snag:

  • on-error (default): "If something goes wrong, let's see what's in the cache."
  • never: "I'd rather have no data than old data!"

By the way, we're just scratching the surface in this example – there's so much more to explore! But before you start coding away, let's take a step back and dive into some important details about Proxycurl API.

Getting started with Proxycurl API: 7 things to note

I know you’re ready to dive into the world of Proxycurl API and unleash the full potential of LinkedIn data, but before you jump in, let's cover some essential points to ensure you hit the ground running.

  1. Sign Up and get your API key:
  2. Head over to Proxycurl's registration page.
  3. Fill in your details and create an account.
  4. Once logged in, navigate to the API section in your dashboard.
  5. There, you'll find your randomly generated secret key. Guard this with everything you’ve got!

  6. Authentication:

  7. Proxycurl API uses bearer tokens for authentication.

  8. Simply include your API key in the Authorization header, as we did in the code above.

  9. Rate limits: Hold onto your hats because this is where things get exciting:

  10. Up to 300 requests per minute

  11. Burst up to 1500 requests every 5 minutes

Pro Tip: Handle 429 errors (rate limit) with exponential backoff. It's like doing a polite knock on the API's door instead of banging on it repeatedly.

  1. Credits:
  2. Each successful request (even a 404) consumes at least 1 credit.
  3. No charge for errors (except 404s, which aren't really errors).

  4. API Response Time:

  5. The average response time is about 2 seconds. Faster than you can say "professional networking"!

Pro Tip: Make concurrent requests to maximize throughput. It's like opening multiple checkout lines at a supermarket.

  1. Errors:
  2. Proxycurl API provides clear error codes and messages. No more cryptic errors that make you question your entire career choice!

  3. Backward compatibility:

  4. We promise not to pull the rug out from under you. We won't remove or change existing functionality without giving you a heads-up. Take that as a promise from us to you and yours!

Proxycurl Company API: 6 powerful endpoints to supercharge your data game

Ladies and gentlemen, we've seen a basic code snippet of what the Proxycurl Company API can do, but that's just the tip of the iceberg. Remember that simple company lookup we did? Well, hang onto your keyboards because Proxycurl isn't just an API - it's your all-access pass to the corporate data universe.

Let's dive into 6 endpoints of the Proxycurl Company API that'll make you feel like a data wizard.

Endpoint #1: Company Profile Endpoint

Think of the Company Profile Endpoint as your one-stop shop for all things company-related. With just 1 credit per successful request, you get a treasure trove of structured data about a company profile. It's like having a corporate crystal ball at your fingertips!

Pro Tip: This endpoint is perfect for enriching your CRM data or building detailed company databases. It's like turning a business card into a comprehensive company biography!

Endpoint #2: Employee Listing Endpoint

Want to know who's who in a company? The Employee Listing Endpoint has got you covered. At 3 credits per employee returned, you get access to a goldmine of employee data. It's powered by LinkDB, Proxycurl's comprehensive dataset of close to 500 million people and company profiles.

Pro Tip: Use this for competitive analysis or to identify key decision-makers in target companies. It's like having an org chart on steroids!

Endpoint #3: Employee Count Endpoint

Sometimes, size does matter – especially when it comes to company data. This Employee Count Endpoint gives you the total employee count from various sources, all for just 1 credit per successful request. It's like having a corporate headcount clicker, but way more accurate!

Pro Tip: Great for market segmentation or identifying companies in specific growth stages. Watch those numbers grow!

Endpoint #4: Company Profile Picture Endpoint

They say a picture is worth a thousand words. Well, the Company Profile Picture Endpoint gives you that picture for free (after your first top-up)! It's a quick and easy way to add visual flair to your company data displays.

Pro Tip: Use this to enhance the UI of your company directories or business intelligence dashboards. Make your data look as good as it performs!

Endpoint #5: Company Lookup Endpoint

Playing detective with company data? The Company Lookup Endpoint is your magnifying glass. For 2 credits per successful request, you can resolve a company's LinkedIn profile from just a name, domain, or location. It's like turning a business card into a full LinkedIn profile!

Pro Tip: Perfect for verifying company information or enriching lead data in your sales processes. Sherlock Holmes, eat your heart out!

Endpoint #6: Employee Search Endpoint

Last but not least, this employee search endpoint is your corporate talent scout. For 10 credits per successful request plus 6 per employee returned, you can search employees by job title. It's like having X-ray vision into a company's org chart!

Pro Tip: Ideal for recruitment firms looking for specific talent or sales teams targeting particular roles. Finding a needle in a corporate haystack has never been easier!

Putting it all together: The Proxycurl Company API advantage

Now, I know what you're thinking: "This sounds great, but what sets these endpoints apart from the official LinkedIn Company API?" Well, my friend, here's the secret sauce. Imagine you're building a competitive intelligence tool. With these Proxycurl Company API’s endpoints, you could:

  1. Lead generation on steroids: Use the Company Profile Endpoint to get detailed info on target companies. You'll have a trawling net for leads in your target industry!
  2. Competitor analysis made easy: Leverage the Employee Listing Endpoint to understand team structures and keep tabs on your rivals. It's like having a spy in their boardroom, but totally legal!
  3. Growth tracking in real-time: Use the Employee Count Endpoint to track company growth over time. Spot emerging players and industry trends before they hit the mainstream!
  4. Visual appeal for your data: Spice up your UI with the Company Profile Picture Endpoint. Because who said data can't be pretty?
  5. Data enrichment on demand: Use the Company Lookup Endpoint to enrich your existing data. Turn business cards into comprehensive company profiles!
  6. Talent scouting reinvented: Harness the Employee Search Endpoint to identify key players in specific roles. HR folks, it's like having a heat-seeking missile for your dream team!

And the best part? You get all this with flexible pricing, no stringent rate limits, and data that could be fresher than your morning coffee! Because with Proxycurl, the sky's not the limit - it's just the beginning!

So, whether you're a startup founder looking to disrupt the market, a data scientist hungry for insights, or a developer building the next big thing for your company, Proxycurl's Company API has got your back. It's time to stop wrestling with API limitations and start unleashing the full power of LinkedIn data.

LinkedIn Company API vs. Proxycurl Company API: 9 key differences

Now, it's time for the main event! In the red corner, we have the reigning champion, the official LinkedIn Company API. And in the blue corner, the challenger, Proxycurl's Company API. Let's break down this matchup and see who comes out on top.

Feature LinkedIn API Proxycurl API
Rate Limits Strict (e.g., 100,000/day) Flexible credit system
Data Completeness Limited fields Comprehensive data fields
Historical Data Limited access Extensive historical data
Use Case Flexibility Restricted by LinkedIn's TOS Flexible for various applications
Integration Complexity Complex OAuth process Simple API key authentication
Pricing Model Opaque, negotiation-based Transparent, credit-based system
Support Limited, often automated Dedicated human support
Data Compliance Strict usage guidelines Ethical collection, flexible usage

While the official LinkedIn API has been the go-to or top-of-mind solution for many, the industry has since shifted to favour such data enrichment API solutions such as our own Proxycurl API products. Judging from the intense matchup laid out in the table above, it's pretty clear who emerged the champion (ahem it's Proxycurl).

But what about legality and data compliance?

Now, I know what you might be thinking: "This all sounds great, but is it actually legal?" It's a fair question and one that deserves a thorough answer.

Proxycurl takes data compliance and ethical collection very seriously. We've gone to great lengths to ensure our practices are above board. Still worried? Don't just take my word for it.

Here are some resources that dive deep into the legal aspects:

These articles provide in-depth analyses of the legal landscape surrounding LinkedIn data collection and data usage generally. They're not just reassuring - they're educational!

Beyond Company API: 6 other Proxycurl’s API solutions

Before we wrap up, let's take a quick look at some other powerful tools in the Proxycurl arsenal. These products work seamlessly with the Company API to provide a comprehensive B2B data solution.

Product Use Cases
People API Talent sourcing, sales lead generation
Search API Market research, competitor analysis
Contact API Direct outreach, email marketing
School API Education sector analysis, alumni networking
Jobs API Job market trends, recruitment strategies
Customer API Customer insights, retention strategies

Thought we were done? There's more! Proxycurl offers even more solutions to supercharge your B2B data game:

  1. LinkDB: An enterprise-level comprehensive data set with over 472 million public LinkedIn\ profiles (and growing). Perfect for building lead lists, identifying talent, or discovering investment opportunities. It's like having the entire professional world at your fingertips!
  2. Sapiengraph: A user-friendly no-code tool for B2B enrichment. It's a 5-minute growth tool designed for anyone. If you can't get productive with it in 5 minutes, we offer a no-questions-asked refund. Talk about confidence in our product!

Each of these tools can be integrated with Proxycurl’s Company API to create powerful, comprehensive B2B data solutions. Whether you're in sales, recruitment, market analysis, or any other field that relies on professional data, trust me, we definitely have a tool to supercharge your workflow.

Oh, and if you're hungry for more data-driven insights, check out our deep dive into CRM data enrichment. It's juicier than a gossip magazine and way more useful!

Supercharge your applications with LinkedIn Company API

Whew, what a day! We've journeyed through the landscape of LinkedIn data, from the challenges of the official LinkedIn Company API to the liberating possibilities of Proxycurl. As we wrap up, let's recap the most important points.

Key Takeaways: 5 Things to Remember

  1. LinkedIn's official API is like a strict librarian - lots of rules, limited access, and a tendency to shush your enthusiasm.
  2. Proxycurl, on the other hand, is the cool librarian who legally sneaks you the restricted books and teaches you how to speed read.
  3. With Proxycurl's Company API, you're not just getting company profiles; you're getting the corporate equivalent of a tell-all memoir.
  4. Ethical data collection isn't just good karma; it's good business. Always keep it clean, folks!
  5. Proxycurl isn't a one-trick pony - from People API to LinkDB to others, we offer a suite of complementary products beyond the Company API.

So there you have it, my friend! We've demystified the process of accessing LinkedIn company data without the need for a secret handshake or sacrificing your firstborn to the API gods.

Remember, in the world of B2B data, knowledge truly is power. With Proxycurl, you're not just accessing data – you're unlocking insights that can drive your business forward, fuel innovation, and give you a competitive edge in your industry.

Whether you're a startup founder plotting world domination, a developer coding the next big thing in the B2B ecosystem, or a data scientist with an insatiable appetite for corporate data insights, Proxycurl is your key to unlocking the full potential of LinkedIn's vast data ecosystem.

Sign up for a Proxycurl account today and unlock the full potential of B2B data at your fingertips. You get 100 free credits if you register with a work email, 10 free credits if you use a personal email.

Whatever your next step, remember that we’re always here at hello@nubela.co to support you on your data journey.

Now, if you'll excuse me, I have some APIs to wrangle and data to conquer. So go forth, code fearlessly, and may your databases be ever full and your API calls always successful.

Top comments (0)