AI framework

Jobo for LangChain

Live job data for the agents you write yourself.

langchain-jobo is a LangChain integration package for the Jobo API. It gives an agent a structured job search tool with every search filter as a typed argument, a tool that reads one listing as prose, and a company lookup; outside an agent, a retriever turns a query into job Documents and a loader streams the bulk feed into your own index. It depends on langchain-core, httpx and pydantic only, and needs Python 3.10 or later.

Get an API key PyPI — coming soon
LangChain logoLangChainGive an agent the tools
python
import os

from langchain.agents import create_agent
from langchain_jobo import get_jobo_tools

agent = create_agent(
    model=os.environ["AGENT_MODEL"],
    tools=get_jobo_tools(max_page_size=10),
    system_prompt="Search with jobo_job_search and cite each job's listing URL.",
)

What can you do with the LangChain integration?

Tools, a retriever and a feed loader that give a LangChain agent live job search with a capped per-call cost.

01

Filters as typed arguments

Location, work model, employment type, experience level, skills, industries, companies, salary and dates are arguments on the tool's schema, each with its exclude twin where the API has one. An unknown enum value is rejected before any request is made.

02

A spend cap on every call

Search bills per job returned, so the search tool asks for five jobs by default and never requests more than max_page_size, whatever the model asks for.

03

Results an agent can cite

The model sees compact text with each job's id, title, company, location, salary when stated and listing URL. The raw job objects travel alongside as the tool artifact for your own code.

04

A retriever for RAG

JoboRetriever turns a query into Documents whose page content is self-contained prose and whose metadata carries the id, URL, company, location, salary and dates.

05

A feed loader that cannot run away

JoboFeedLoader streams the bulk feed as Documents and will not start without an explicit max_jobs. It exposes the cursor so a scan can resume where it stopped.

How do you connect LangChain to Jobo?

One-time setup. After this, the data keeps itself current.

  1. 1

    Install the package

    The package installs from PyPI once it is published there.

    bash
    pip install -U langchain-jobo
  2. 2

    Set your API key

    Create a key under Developers → API Keys in the Jobo dashboard and export it. Every component reads JOBO_API_KEY, or takes api_key directly. A sandbox key returns fictional jobs for free and works with the search tool, the details tool and the retriever.

    bash
    export JOBO_API_KEY="jbe_live_..."
  3. 3

    Call the search tool

    The tool takes the same filters as the search API. Enum filters use the API's lowercase values.

    python
    from langchain_jobo import JoboSearchTool
    
    tool = JoboSearchTool()
    
    print(
        tool.invoke(
            {
                "query": "backend engineer",
                "location": "Berlin, Germany",
                "work_model": ["remote", "hybrid"],
                "experience_level": ["senior"],
                "page_size": 3,
            }
        )
    )
  4. 4

    Hand the tools to an agent

    get_jobo_tools returns the search, job details and company lookup tools. Pass them to any LangChain agent, with the chat model you already use.

    python
    import os
    
    from langchain.agents import create_agent
    from langchain_jobo import get_jobo_tools
    
    agent = create_agent(
        model=os.environ["AGENT_MODEL"],
        tools=get_jobo_tools(max_page_size=10, handle_tool_error=True),
        system_prompt=(
            "You help people find jobs. Search with jobo_job_search, read a posting with "
            "jobo_job_details before describing it, and cite each job's listing URL."
        ),
    )

What goes wrong with LangChain, and how do you fix it?

The things people actually hit when running Jobo in LangChain.

The agent run stops with a ToolException
By default an API error (a rate limit, an empty wallet) raises and ends the run, so a model cannot retry a failure that will not succeed. Pass handle_tool_error=True to hand the error back to the model as the tool's answer instead.
A company filter matches nothing, or too much
The companies filter matches a company name whole. Use the company lookup tool to turn a name or domain into company ids, which match exactly.
JoboFeedLoader fails with a sandbox key
The feed is not available to sandbox keys. The loader needs a live key; the search tool, details tool and retriever work with either.
The loader returned slightly fewer jobs than max_jobs
max_jobs is an upper bound. The loader reads whole, equal batches that fit under it, so it never requests, or bills, more than you allowed.

How do you get the most out of LangChain?

  • Keep max_page_size low and tell the agent in its prompt when to stop searching. An agent that searches in a loop spends per job returned on every call.
  • Use the retriever or the search tool to answer a question, and the loader to copy jobs into your own index.
  • Persist loader.last_cursor after each run so a long scan resumes instead of starting again.
  • Have the agent read a posting with the details tool before describing it. Reading one listing is free.

Start pulling live jobs into LangChain

One API key covers every integration, and the same job index sits behind all of them.