Skip to main content
Glama
mcp-libraryofcongress

mcp-libraryofcongress

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
LOC_LOG_LEVELNosilent, error, info or debug. Logs go to stderr.error
LOC_TIMEOUT_MSNoPer-request deadline for the catalogue, the records and the collections. Accepted between 1000 and 120000.30000
LOC_USER_AGENTNoIdentify your own client. The project's identifier is appended, so the Library can reach a human.
LOC_MAX_RETRIESNoRetries on rate limiting and transient errors, up to 8.3
LOC_CACHE_TTL_MSNoIn-memory cache lifetime. 0 turns it off.900000
LOC_MIN_INTERVAL_MSNoMinimum gap between requests. Values below 3000 ms are refused, as are values above 60000.6000
LOC_CACHE_MAX_ENTRIESNoIn-memory cache size, up to 5000.200
LOC_NEWSPAPER_TIMEOUT_MSNoPer-request deadline for search_newspapers, which reads the text of millions of pages and answers in tens of seconds. Accepted between 1000 and 300000.90000

Instructions

Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.

This server publishes no instructions, or was last inspected before Glama recorded them.

Capabilities

Features and capabilities supported by this server

Protocol revision2025-11-25

CapabilityDetails
tools
{
  "listChanged": true
}

Tools

Functions exposed to the LLM to take actions

NameDescription
search_newspapersA

Search the text inside digitised American newspaper pages held by the Library of Congress. This reads what optical recognition took off the scanned pages, so it finds a phrase that appears nowhere in a title or a catalogue record. Double quotes change how the Library matches the words, and it decides what they mean: a page can come back carrying the words apart or in another order rather than the phrase as written. What the quotes do to the number of matching pages varies from one query to the next, so run the search both ways rather than expecting either form to return more. 'total' counts the pages that match, and they page: ask for page 2, 3 and so on to see beyond the first answer. It is not a count of how many times the words occur. Each match names the newspaper, the date, the leaf of the issue and the state it was published in, and 'source_url' opens that leaf with the query applied. 'location' keeps to papers published in one state, 'publication' to a single paper, and 'year_from' with 'year_to' to a span of years. A filter matching nothing is dropped and the answer says so. Every match carries 'excerpt_kind', and the excerpts are labelled with it in the text. A 'passage' is the text around the words that matched. A 'page_opening' is the start of the page, sent because the text the Library returned with the row stops before those words appear, so it does not carry the match and quoting it quotes something else. Use search_items instead when looking for a work by its title, creator or subject.

search_itemsA

Search the Library of Congress catalogue: books, photographs, maps, recordings, films, manuscripts, sheet music and newspaper titles. 'media_type' is required, because the Library keeps a separate catalogue for each kind of thing. This matches titles, creators and catalogue descriptions. It does not read the text inside a scan; use search_newspapers for a phrase printed on a newspaper page. Filters take the words the Library itself uses: 'subject' and 'location' as the rows here spell them, 'language' written in English, 'collection' as list_collections reports it under 'collection_filter'. A filter matching nothing is set aside and the search asked again without it; the answer names what was dropped, and the count it reports is then the unfiltered search's. By default only material with a digitised copy is returned; set 'online_only' to false to take in records the Library holds on a shelf alone. A row carries an 'identifier' get_item takes when it names a record. A row that is a collection the Library gathered names no record: 'is_collection' is true there, 'identifier' is null, and 'source_url' opens the collection.

get_itemA

Read one Library of Congress record by its identifier, as returned by search_items or search_newspapers. An identifier can carry slashes: a single newspaper issue is named by its paper, its date and its edition together. Sections are opt-in: 'basic' is the default and covers what a description needs. 'date' carries only the precision the record's own words support, and 'date_stated' repeats those words, which can be a span of years the record was filed at the opening of. Where the Library has established no date it files the record under a cataloguing code, which 'date_code' carries while 'date' and 'year' stay null. 'citations' returns the ready-made citations the Library publishes for the record. 'resources' lists the served copies, such as page images and downloadable files. 'full_metadata' returns every field the Library publishes for the record, which is large and rarely needed. A long description paginates: when 'next_offset' is not null, call again with 'offset' set to it.

list_collectionsA

List the digital collections of the Library of Congress: bodies of material a curator chose, described and published together. Use it to see what is there before searching, since a collection names a corpus that a query would have to guess at. 'collection_filter' on each row is the wording search_items takes as its 'collection' argument, and 'searchable_media_types' names the catalogues that filter can be sent to. A collection whose 'searchable_media_types' is empty gathers a kind of thing the catalogue search is not divided into, such as web archives; set 'searchable_only' to leave those out. 'item_count' is how many records the collection gathers, which is the size of the corpus rather than the number of rows here.

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

TDQS

A4.5/5.0

Scored across 4 tools

Disambiguation5/5

Each tool has a clearly distinct target: full-text OCR search of newspaper pages, catalogue metadata search, single-record retrieval by identifier, and enumeration of digital collections. The descriptions actively steer between the two search tools ('Use search_items instead when looking for a work by its title...' / 'use search_newspapers for a phrase printed on a newspaper page'), leaving no realistic misselection risk.

Naming Consistency5/5

All four names follow a strict verb_noun snake_case pattern: search_newspapers, search_items, get_item, list_collections. The two search_* tools differ only by their noun, which mirrors the actual distinction in behaviour.

Tool Count4/5

Four tools map cleanly onto the essential operations (search two corpora, fetch a record, discover collections) with no filler. It is on the lean side — there is no dedicated enumeration or browse surface — but every tool present earns its place.

Completeness4/5

The core lifecycle is covered: discover collections, search catalogue records, search newspaper page text, then resolve an identifier into a full record with sections for citations and resources. Minor gaps exist (no newspaper-title or issue-level enumeration, subjects/facets only usable as filters), but agents can work around them via search and paging.

Maintenance

ActivityActive
ResponsivenessLimited data