Skip to main content
Glama

search_jobs

Find job opportunities on LinkedIn by entering specific search terms to match career interests and requirements.

Instructions

Search for jobs on LinkedIn using a search term.

Args: search_term (str): Search term to use for the job search.

Returns: List[Dict[str, Any]]: List of job search results

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
search_termYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Implementation Reference

  • The primary handler function for the 'search_jobs' MCP tool. It uses linkedin_scraper.JobSearch to find jobs matching the input search_term, converts Job objects to dictionaries, and handles exceptions with error formatting.
    @mcp.tool()
    async def search_jobs(search_term: str) -> List[Dict[str, Any]]:
        """
        Search for jobs on LinkedIn using a search term.
    
        Args:
            search_term (str): Search term to use for the job search.
    
        Returns:
            List[Dict[str, Any]]: List of job search results
        """
        try:
            driver = safe_get_driver()
    
            logger.info(f"Searching jobs: {search_term}")
            job_search = JobSearch(driver=driver, close_on_complete=False, scrape=False)
            jobs = job_search.search(search_term)
    
            # Convert job objects to dictionaries
            return [job.to_dict() for job in jobs]
        except Exception as e:
            return handle_tool_error_list(e, "search_jobs")
  • Invocation of register_job_tools during MCP server creation, which registers the search_jobs tool (and other job tools) via decorators.
    register_job_tools(mcp)
  • The register_job_tools function defines and registers all job-related tools including search_jobs using @mcp.tool() decorators.
    def register_job_tools(mcp: FastMCP) -> None:
        """
        Register all job-related tools with the MCP server.
    
        Args:
            mcp (FastMCP): The MCP server instance
        """
    
        @mcp.tool()
        async def get_job_details(job_id: str) -> Dict[str, Any]:
            """
            Get job details for a specific job posting on LinkedIn
    
            Args:
                job_id (str): LinkedIn job ID (e.g., "4252026496", "3856789012")
    
            Returns:
                Dict[str, Any]: Structured job data including title, company, location, posting date,
                              application count, and job description (may be empty if content is protected)
            """
            try:
                # Construct clean LinkedIn URL from job ID
                job_url = f"https://www.linkedin.com/jobs/view/{job_id}/"
    
                driver = safe_get_driver()
    
                logger.info(f"Scraping job: {job_url}")
                job = Job(job_url, driver=driver, close_on_complete=False)
    
                # Convert job object to a dictionary
                return job.to_dict()
            except Exception as e:
                return handle_tool_error(e, "get_job_details")
    
        @mcp.tool()
        async def search_jobs(search_term: str) -> List[Dict[str, Any]]:
            """
            Search for jobs on LinkedIn using a search term.
    
            Args:
                search_term (str): Search term to use for the job search.
    
            Returns:
                List[Dict[str, Any]]: List of job search results
            """
            try:
                driver = safe_get_driver()
    
                logger.info(f"Searching jobs: {search_term}")
                job_search = JobSearch(driver=driver, close_on_complete=False, scrape=False)
                jobs = job_search.search(search_term)
    
                # Convert job objects to dictionaries
                return [job.to_dict() for job in jobs]
            except Exception as e:
                return handle_tool_error_list(e, "search_jobs")
    
        @mcp.tool()
        async def get_recommended_jobs() -> List[Dict[str, Any]]:
            """
            Get your personalized recommended jobs from LinkedIn
    
            Returns:
                List[Dict[str, Any]]: List of recommended jobs
            """
            try:
                driver = safe_get_driver()
    
                logger.info("Getting recommended jobs")
                job_search = JobSearch(
                    driver=driver,
                    close_on_complete=False,
                    scrape=True,  # Enable scraping to get recommended jobs
                    scrape_recommended_jobs=True,
                )
    
                if hasattr(job_search, "recommended_jobs") and job_search.recommended_jobs:
                    return [job.to_dict() for job in job_search.recommended_jobs]
                else:
                    return []
            except Exception as e:
                return handle_tool_error_list(e, "get_recommended_jobs")
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden of behavioral disclosure. It states the basic action ('search') but lacks details on permissions, rate limits, pagination, or what happens if no jobs are found. For a search tool with zero annotation coverage, this is a significant gap in transparency.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is well-structured and appropriately sized, with a clear purpose statement followed by separate 'Args' and 'Returns' sections. It's front-loaded and avoids unnecessary fluff, though the 'Returns' section could be more concise given the output schema exists.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's moderate complexity (search operation), lack of annotations, and presence of an output schema, the description is minimally adequate. It covers the basic purpose and parameters but misses behavioral details and usage guidelines, leaving room for improvement in completeness.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The description includes an 'Args' section that documents the single parameter 'search_term' as a string, adding meaning beyond the input schema (which has 0% description coverage). However, it doesn't provide examples, constraints, or formatting details, so it only partially compensates for the schema's lack of descriptions.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool's purpose: 'Search for jobs on LinkedIn using a search term.' It specifies the verb ('search'), resource ('jobs'), and platform ('LinkedIn'), making it easy to understand what the tool does. However, it doesn't explicitly differentiate from sibling tools like 'get_recommended_jobs' or 'get_job_details', which prevents a perfect score.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives. It doesn't mention when to prefer this over 'get_recommended_jobs' or 'get_job_details', nor does it specify any prerequisites or exclusions. This leaves the agent without context for tool selection.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Logos-Parthenos-AI/linkedin-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server