The oaipmh module is a Python implementation of an "Open Archives$ Initiative Protocol for Metadata Harvesting"
Python
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
doc
src/oaipmh
.gitignore
.hgignore
.hgtags
CREDITS.txt
HISTORY.txt
INSTALL.txt
LICENSE.txt
MANIFEST.in
README.rst
TODO.txt
buildout.cfg
setup.py

README.rst

OAIPMH

The oaipmh module is a Python implementation of an "Open Archives Initiative Protocol for Metadata Harvesting" (version 2) client and server. The protocol is described here:

http://www.openarchives.org/OAI/openarchivesprotocol.html

Below is a simple implementation of an OAIPMH client:

>>> from oaipmh.client import Client
>>> from oaipmh.metadata import MetadataRegistry, oai_dc_reader
>>> URL = 'http://uni.edu/ir/oaipmh'
>>> registry = MetadataRegistry()
>>> registry.registerReader('oai_dc', oai_dc_reader)
>>> client = Client(URL, registry)
>>> for record in client.listRecords(metadataPrefix='oai_dc'):
>>>    print record

The pyoai package also contains a generic server implementation of the OAIPMH protocol, this is used as the foundation of the MOAI Server Platform