National Library of Israel MCP Server ๐Ÿ‡ฎ๐Ÿ‡ฑ๐Ÿ“–๐Ÿ”

by rdoelman

139 downloads Not rated yet

About

# National Library of Israel MCP Server ๐Ÿ‡ฎ๐Ÿ‡ฑ๐Ÿ“–๐Ÿ” This package provides a Model Context Protocol (MCP) server that interfaces between large language models and the National Library of Israel's APIs. The MCP server allows AI assistants to search the NLI catalog, retrieve images, and access library resourcesโ€ฆ

Explore

Catalog Search: Query the NLI catalog by various criteria including general terms, title, creator, date range
IIIF Image Access: Retrieve, manipulate and get detailed information about digitized materials
Advanced Filtering: Control search by resource type (photographs, maps, books etc.), online availability, date range, and creator
Image Manipulation: Support for different regions, sizes, rotations, and quality parameters
* Large Image Support: Generate tiled image URLs for efficiently retrieving high-resolution images

Setting up with Highlight

This MCP is not yet compatible with Highlight’s one-click setup. However, you can still use it with Highlight by following these steps:

  1. Download and install Highlight from highlightai.com/download
  2. Navigate to the plugins tab and select "Add Custom Plugin"
  3. Configure the plugin with the settings below
    Plugin Name National Library of Israel MCP Server ๐Ÿ‡ฎ๐Ÿ‡ฑ๐Ÿ“–๐Ÿ”
    Command (node, npx, python, etc.)

    Please refer to the README for specific instructions on how to obtain API keys or other required environment variables.

  4. Enable "Start Automatically" if you want the plugin to start when Highlight launches

From the repository

Install dependencies (Python 3.10+, httpx, mcp >= 1.2.0, and uv recommended), then run uv sync from the source directory. For Claude Desktop integration, add a configuration entry to claude_desktop_config.json pointing to the serverโ€™s main.py file.

query

(string): The main search query

resource_type

(string, optional): Type of resource to search for (photograph, book, manuscript, etc.)

start_date

(string, optional): Start date in format YYYYMMDD

end_date

(string, optional): End date in format YYYYMMDD

creator

(string, optional): Creator/author name to search by

availability

(string, optional): Availability type (online_resources, all_items, etc.)

page_size

(integer, optional): Number of results to return (default: 10)

identifier

(string): Image identifier

region

(string, optional): Region parameter (default: "full")

size

(string, optional): Size parameter (default: "max")

rotation

(string, optional): Rotation parameter (default: "0")

quality

(string, optional): Image quality (default: "default")

image_format

(string, optional): Image format (default: "jpg")

tile_size

(integer, optional): Size of each tile in pixels (default: 256)

search_catalog
Search the NLI catalog with advanced filtering options
Inputs:
query (string): The main search query
resource_type (string, optional): Type of resource to search for (photograph, book, manuscript, etc.)
start_date (string, optional): Start date in format YYYYMMDD
end_date (string, optional): End date in format YYYYMMDD
creator (string, optional): Creator/author name to search by
availability (string, optional): Availability type (online_resources, all_items, etc.)
page_size (integer, optional): Number of results to return (default: 10)

get_image_info
Get information about an image using the IIIF Image Information API
Inputs:
identifier (string): Image identifier

get_image
Get an image using the IIIF Image API
Inputs:
identifier (string): Image identifier
region (string, optional): Region parameter (default: "full")
size (string, optional): Size parameter (default: "max")
rotation (string, optional): Rotation parameter (default: "0")
quality (string, optional): Image quality (default: "default")
image_format (string, optional): Image format (default: "jpg")

get_tiled_image_urls
Get URLs for retrieving a large image as tiles
Inputs:
identifier (string): Image identifier
tile_size (integer, optional): Size of each tile in pixels (default: 256)

Claude Desktop / Cursor

Paste into your MCP client config file to install this server.

{
    "mcpServers": {
        "national library of israel mcp server \ud83c\uddee\ud83c\uddf1\ud83d\udcd6\ud83d\udd0d": {
            "nli_mcp_server": {
                "command": "uv",
                "args": [
                    "sync"
                ]
            }
        }
    }
}

McpServers

{
    "nli_mcp_server": {
        "command": "uv",
        "args": [
            "sync"
        ]
    }
}

This package provides a Model Context Protocol (MCP) server that interfaces between large language models and the National Library of Israel's APIs. The MCP server allows AI assistants to search the NLI catalog, retrieve images, and access library resources programmatically.

> โš ๏ธ Important Note: This is an independent, external initiative and is not affiliated with or endorsed by the National Library of Israel. This project is developed by enthusiasts to enhance AI accessibility to public library resources.

## Features

Catalog Search: Query the NLI catalog by various criteria including general terms, title, creator, date range
IIIF Image Access: Retrieve, manipulate and get detailed information about digitized materials
Advanced Filtering: Control search by resource type (photographs, maps, books etc.), online availability, date range, and creator
Image Manipulation: Support for different regions, sizes, rotations, and quality parameters
Large Image Support: Generate tiled image URLs for efficiently retrieving high-resolution images

## Tools

search_catalog
Search the NLI catalog with advanced filtering options
Inputs:
query (string): The main search query
resource_type (string, optional): Type of resource to search for (photograph, book, manuscript, etc.)
start_date (string, optional): Start date in format YYYYMMDD
end_date (string, optional): End date in format YYYYMMDD
creator (string, optional): Creator/author name to search by
availability (string, optional): Availability type (online_resources, all_items, etc.)
page_size (integer, optional): Number of results to return (default: 10)

get_image_info
Get information about an image using the IIIF Image Information API
Inputs:
identifier (string): Image identifier

get_image
Get an image using the IIIF Image API
Inputs:
identifier (string): Image identifier
region (string, optional): Region parameter (default: "full")
size (string, optional): Size parameter (default: "max")
rotation (string, optional): Rotation parameter (default: "0")
quality (string, optional): Image quality (default: "default")
image_format (string, optional): Image format (default: "jpg")

get_tiled_image_urls
Get URLs for retrieving a large image as tiles
Inputs:
identifier (string): Image identifier
* tile_size (integer, optional): Size of each tile in pixels (default: 256)

## Installation

### Dependencies

- Python 3.10 or higher
- httpx
- mcp >= 1.2.0
- uv (recommended)

For installing uv, please follow the instructions at uv documentation.

To install this package from source, navigate to the project and run:

  uv sync
  

## Claude Desktop Integration

To use this MCP server with Claude Desktop, add the following configuration to your claude_desktop_config.json file:

  {
    "mcpServers": {
      "nli_mcp": {
        "command": "uv",
        "args": [
          "run",
          "--with",
          "mcp[cli]",
          "mcp",
          "run",
          "[PATH_TO_REPO]/nli_mcp_server/main.py"
        ]
      }
    }
  }
  

Replace [PATH_TO_REPO] with the actual path to your checked out git repository.

## Development

For development, use uv to run the server:

  # Start the server in development mode
  uv run mcp dev main.py
  

## License

MIT License

No reviews yet โ€” be the first

Sign in to leave a review

Use Google, GitHub, or an email account so ratings stay tied to real people.

Email sign in

No reviews posted yet.