No project description provided
Project description
Omeka S Tools
Install
pip install omeka-s-tools2
How to use
See the documentation for full details of the Omeka API Client.
from omeka_s_tools2.api import *
omeka = OmekaAPIClient('http://timsherratt.org/collections/api')
items = omeka.get_resources('items')
items['total_results']
140
items['results'][0]
{'@context': 'http://timsherratt.org/collections/api-context',
'@id': 'http://timsherratt.org/collections/api/items/677',
'@type': ['o:Item', 'schema:Newspaper'],
'o:id': 677,
'o:is_public': True,
'o:owner': {'@id': 'http://timsherratt.org/collections/api/users/1',
'o:id': 1},
'o:resource_class': {'@id': 'http://timsherratt.org/collections/api/resource_classes/161',
'o:id': 161},
'o:resource_template': {'@id': 'http://timsherratt.org/collections/api/resource_templates/5',
'o:id': 5},
'o:thumbnail': None,
'o:title': 'Manilla Express (NSW : 1899 - 1954)',
'thumbnail_display_urls': {'large': 'http://timsherratt.org/collections/files/large/aa1fb4063116fc889418ce6dc20af3cb7e7bd0db.jpg',
'medium': 'http://timsherratt.org/collections/files/medium/aa1fb4063116fc889418ce6dc20af3cb7e7bd0db.jpg',
'square': 'http://timsherratt.org/collections/files/square/aa1fb4063116fc889418ce6dc20af3cb7e7bd0db.jpg'},
'o:created': {'@value': '2022-01-20T06:37:50+00:00',
'@type': 'http://www.w3.org/2001/XMLSchema#dateTime'},
'o:modified': {'@value': '2022-01-20T06:37:50+00:00',
'@type': 'http://www.w3.org/2001/XMLSchema#dateTime'},
'o:media': [{'@id': 'http://timsherratt.org/collections/api/media/882',
'o:id': 882},
{'@id': 'http://timsherratt.org/collections/api/media/897', 'o:id': 897},
{'@id': 'http://timsherratt.org/collections/api/media/929', 'o:id': 929},
{'@id': 'http://timsherratt.org/collections/api/media/994', 'o:id': 994},
{'@id': 'http://timsherratt.org/collections/api/media/995', 'o:id': 995},
{'@id': 'http://timsherratt.org/collections/api/media/996', 'o:id': 996},
{'@id': 'http://timsherratt.org/collections/api/media/997', 'o:id': 997}],
'o:item_set': [],
'o:site': [],
'schema:name': [{'type': 'literal',
'property_id': 1116,
'property_label': 'name',
'is_public': True,
'@value': 'Manilla Express (NSW : 1899 - 1954)'}],
'schema:url': [{'type': 'uri',
'property_id': 393,
'property_label': 'url',
'is_public': True,
'@id': 'http://nla.gov.au/nla.news-title1006'}],
'schema:identifier': [{'type': 'literal',
'property_id': 190,
'property_label': 'identifier',
'is_public': True,
'@value': '1006'}],
'@reverse': []}
See the documentation for more examples.
Created by Tim Sherratt
(@wragge) for the GLAM
Workbench.
Created by @satoru196.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
omeka_s_tools2-0.0.4.tar.gz
(16.0 kB
view hashes)
Built Distribution
Close
Hashes for omeka_s_tools2-0.0.4-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e526318e18e5572206ea127bec0342d4faa09d80f4969236d10a628445f131d2 |
|
MD5 | 2d971ecb3669df6631e9ec0756e64b88 |
|
BLAKE2b-256 | 2211996457c8225d18bb9341e717bc1bebbe107809d6494024b3d82c4e594a1b |