Application Programing Interfaces (API's) are one of the standard ways for interacting with data and software services on the internet. Learning how to use them with your programming is one of the fundamental steps in becoming a fluent developer. Here we will explore one API in particular, the one for the Digital Public Library of America (DPLA). But, first, what exactly is an API?

Imagine the following scenario: you have just accomplished a big task in putting the entire run of your university's literary journal online. People can explore the full text of each issue, and they can also download the images for your texts. Hooray! As we just learned in the lesson on web scraping, an interested digital humanist could use just this information to pull down your materials. They might scrape each page for the full texts, titles, and dates of your journal run, and put together their own little corpus for analysis. But that's a lot of work. Web scraping seems fun and all at first, but the novelty quickly wears off. We wouldn't want to scrape every resource from the web. Surely there must be a better way, and there is! What if we were to package all that data up in a more usable way for our users to consume with their programs? That's where API's come in.

API's are a way for exchanging information and services from one piece of software to another. In this case, we're theorizing an API that would provide data. When a user comes to our journal site, we might imagine them saying, "hey - could you give me all the journals published in the 1950's?" And then our fledgling API would respond with something like the following:

[{"ArticleID":[42901,42902,42903,42904,42905,42906,42907,42908,42909,42910,42911,42912],"ID":1524,"Issue":1,"IssueLabel":"1","Season":"Spring","Volume":1,"Year":1950,"YearLabel":"1950"},{"ArticleID":[42913,42914,42915,42916,42917,42918,42919,42920,42921,42922],"ID":1525,"Issue":2,"IssueLabel":"2","Season":"Summer","Volume":1,"Year":1950,"YearLabel":"1950"},{"ArticleID":[42923,42924,42925,42926,42927,42928,42929,42930,42931,42932],"ID":1526,"Issue":3,"IssueLabel":"3","Season":"Winter","Volume":1,"Year":1950,"YearLabel":"1950"},……]

As we've discussed all along, computers are pretty bad at inferring things, so our API neatly structures a way for your programming to interface with an application that we've made (API - get it?) more easily. The results give us a list of all the articles in each issue, as well as relevant metadata for the issue. In this case, we learn the year, data, season, and issue number. With this information, we could make several other API requests for particular articles. But data isn't the only thing you can get from API's - they can also do things for us as well! Have you ever used a social media account to log in to a different website - say using Facebook to log into the New York Times website? Behind the scenes, the NY Times is using the Facebook API to authenticate you and prove that you're a user. API's let you do an awful lot, and they let you build on the work that others have done.

But this isn't a lesson about how to build API's - we're going to talk about how to use them. There are a couple different ways in which we can do this: from scratch or with a wrapper. In the former, we go through all the different steps of putting together a request for information from the DPLA API. In the latter, we use someone else's code to do the heavy lifting for us. First, we'll do things the easy way by working with DPyLA, a Python wrapper for the DPLA API. Let's pull in the relevant Python pieces. Notice the $, which indicates that we're working in command line and not Python. We'll need to install first.

$ pip install DPLA

We've got the DPLA wrapper installed, now we'll import it into our Python script. Remember, the "from X.Y import Z" will enable us to keep from writing X.Y.Z every time. In this case, it keeps us from writing dpla.api.DPLA when we would rather just write DPLA.

In [1]:
from dpla.api import DPLA

API's generally require you to prove that you are an authentic user (not a bot), and, in some cases, that you have permission to access their interface. You generally do this by authenticating through the service using credentials that you have registered with them. DPLA lets you register by sending a request through terminal. Below, change "[email protected]" to be an email address of your choice.

After running the command you should get an email with your API key. You'll then need to include this API key in every request you send to the DPLA API. For the sake of not sharing my own API key, I won't write it here. In fact, Python has a handy way for making sure that we don't share our login details in situations just like this. What we'll do is we will store our password locally in our file structure, hidden away from GitHub. Python will read in that variable from our system, store the password, and have access to it in a safe way. This process is sometimes called sanitizing, because you're cleaning your code to make sure that sensitive information is hidden. Run the following terminal command

$ export API_KEY=YOUR_API_KEY_HERE

Now our API key is stored locally, so we'll pull it into Python. To do that, we will pull in 'os', a Python module for interacting with the file system on your computer.

In [2]:
import os
my_api_key = os.getenv('API_KEY')

Now you should have your own API Key stored, and we can use it to make requests. The DPyLA wrapper makes this easy. First we open a connection to the DPLA API. Notice how we're calling it with our stored api_key.

In [3]:
dpla_connection = DPLA(my_api_key)

If you follow along with the documentation for the wrapper on GitHub, you can actually see that the wrapper gives us a handy way of requesting our own API key for the first time. We could have done this instead of calling a command from the terminal to get that email sent to us. This is the line of code the documentation gives us for doing so:

In [9]:
DPLA.new_key("[email protected]")
b'{"message":"API key created and sent via email. Be sure to check your Spam folder, too."}'

But we did this from the command line instead. This is a good first indication of the ways that wrappers can make your lives easier. They provide easy shortcuts for things that we would have to do from scratch otherwise. Now that we're all set up with the API, we can use this our dpla object to get information from their API! Let's do a quick search for something.

In [5]:
result = dpla_connection.search('austen')
print(type(result))
<class 'dpla.api.Results'>

Python's built in type() function tells us what we're doing with - notice that the API did not return us a list of items as you might expect. Instead, it's returned a Results object. This means that we can do all sorts of things to what we've gotten back, and simply dumping out the list of the search results is only one such choice. To see all the different commands that we might call on this object, you can call one of the built in commands. Or, if you're working from iTerm2, you can type "result." and hit tab twice to see options.

In [8]:
str(result.__dict__)[:1000]
Out[8]:
"{'dpla': <dpla.api.DPLA object at 0x10abb9278>, 'request': <dpla.api.Request object at 0x10d06ab38>, 'count': 1431, 'limit': 10, 'start': 0, 'items': [{'@context': 'http://dp.la/api/items/context', 'isShownAt': 'http://digitalcollections.nypl.org/items/510d47dc-7ea0-a3d9-e040-e00a18064a99', 'dataProvider': 'The Miriam and Ira D. Wallach Division of Art, Prints and Photographs: Print Collection. The New York Public Library', '@type': 'ore:Aggregation', 'rights': 'http://rightsstatements.org/vocab/UND/1.0/', 'provider': {'@id': 'http://dp.la/api/contributor/nypl', 'name': 'The New York Public Library'}, 'object': 'http://images.nypl.org/index.php?id=1103428&t=t', 'ingestionSequence': 21, 'id': 'f5fda5d6d8d7011a575f944de8e108c4', 'ingestDate': '2017-01-17T01:02:42.938459Z', '_rev': '9-0a2b767b300f8ef56a28a2c4d19c2758', 'aggregatedCHO': '#sourceResource', '_id': 'nypl--510d47dc-7ea0-a3d9-e040-e00a18064a99', 'sourceResource': {'title': 'J. Austen', 'subject': [{'name': 'Clippings'}, {'name'"

The dict command shows us a range of options. We can get the number of search results, the list of all items, and a couple other bits about the particular connection we've opened up. You can actually use these same tricks - dict and dot + tabbing to explore virtually every other thing that you will encounter in Python. They give you information about the objects that you're working with, which is half the battle in any Python situation. But for now let's get some more information about the API results we see. We'll take a look at the first object here.

In [10]:
item = result.items[0]
item
Out[10]:
{'@context': 'http://dp.la/api/items/context',
 '@id': 'http://dp.la/api/items/f5fda5d6d8d7011a575f944de8e108c4',
 '@type': 'ore:Aggregation',
 '_id': 'nypl--510d47dc-7ea0-a3d9-e040-e00a18064a99',
 '_rev': '9-0a2b767b300f8ef56a28a2c4d19c2758',
 'admin': {'object_status': 1,
  'sourceResource': {'title': 'J. Austen'},
  'valid_after_enrich': True,
  'validation_message': None},
 'aggregatedCHO': '#sourceResource',
 'dataProvider': 'The Miriam and Ira D. Wallach Division of Art, Prints and Photographs: Print Collection. The New York Public Library',
 'id': 'f5fda5d6d8d7011a575f944de8e108c4',
 'ingestDate': '2017-01-17T01:02:42.938459Z',
 'ingestType': 'item',
 'ingestionSequence': 21,
 'isShownAt': 'http://digitalcollections.nypl.org/items/510d47dc-7ea0-a3d9-e040-e00a18064a99',
 'object': 'http://images.nypl.org/index.php?id=1103428&t=t',
 'originalRecord': {'_id': '510d47dc-7ea0-a3d9-e040-e00a18064a99',
  'collection': {'@id': 'http://dp.la/api/collections/3f371a92211aa17caadbb21fb98f3bd4',
   'id': '3f371a92211aa17caadbb21fb98f3bd4'},
  'genre': [{'#text': 'Clippings',
    'authority': 'lctgm',
    'valueURI': 'http://id.loc.gov/vocabulary/graphicMaterials/tgm002169'},
   {'#text': 'Portraits',
    'authority': 'lctgm',
    'valueURI': 'http://id.loc.gov/vocabulary/graphicMaterials/tgm008085'}],
  'identifier': [{'#text': '242',
    'displayLabel': 'Hades Collection Guide ID (legacy)',
    'type': 'local_hades_collection'},
   {'#text': 'Portrait File',
    'displayLabel': 'Other local Identifier',
    'type': 'local_other'},
   {'#text': '348628',
    'displayLabel': 'Hades struc ID (legacy)',
    'type': 'local_hades'},
   {'#text': '36450420-c533-012f-cf67-58d385a7bc34', 'type': 'uuid'}],
  'location': [{'physicalLocation': [{'#text': 'nn',
      'authority': 'marcorg',
      'type': 'repository'},
     {'#text': 'The Miriam and Ira D. Wallach Division of Art, Prints and Photographs: Print Collection',
      'type': 'division'},
     {'#text': 'Wallach Division: Print Collection',
      'type': 'division_short_name'},
     {'#text': 'PRN', 'type': 'code'}]},
   {'physicalLocation': [{'#text': 'The Miriam and Ira D. Wallach Division of Art, Prints and Photographs: Print Collection',
      'type': 'division'},
     {'#text': 'Wallach Division: Print Collection',
      'type': 'division_short_name'},
     {'#text': 'PRN', 'type': 'code'}]}],
  'provider': {'@id': 'http://dp.la/api/contributor/nypl',
   'name': 'The New York Public Library'},
  'relatedItem': {'identifier': [{'#text': '34e5a7f0-c533-012f-aa43-58d385a7bc34',
     'type': 'uuid'},
    {'#text': '348620', 'type': 'local_hades'}],
   'relatedItem': {'identifier': [{'#text': '17513b20-c52e-012f-78fb-58d385a7bc34',
      'type': 'uuid'},
     {'#text': '591659', 'type': 'local_hades'}],
    'relatedItem': {'identifier': [{'#text': '16ad5350-c52e-012f-aecf-58d385a7bc34',
       'type': 'uuid'},
      {'#text': '287739 local_hades_collection', 'type': 'local_hades'}],
     'titleInfo': {'title': 'Print Collection portrait file'},
     'type': 'host'},
    'titleInfo': {'title': 'A'},
    'type': 'host'},
   'titleInfo': {'title': 'Jane Austen.'},
   'type': 'host'},
  'rightsStatementURI': 'http://rightsstatements.org/vocab/UND/1.0/',
  'schemaLocation': 'http://www.loc.gov/mods/v3 http://www.loc.gov/standards/mods/v3/mods-3-4.xsd',
  'subject': {'authority': '', 'topic': 'Public figures'},
  'titleInfo': {'supplied': 'no', 'title': 'J. Austen.', 'usage': 'primary'},
  'tmp_high_res_link': None,
  'tmp_image_id': '1103428',
  'tmp_item_link': 'http://digitalcollections.nypl.org/items/510d47dc-7ea0-a3d9-e040-e00a18064a99',
  'tmp_rights_statement': 'The copyright and related rights status of this item has been reviewed by The New York Public Library, but we were unable to make a conclusive determination as to the copyright status of the item. You are free to use this Item in any way that is permitted by the copyright and related rights legislation that applies to your use.',
  'typeOfResource': 'still image',
  'version': '3.4'},
 'provider': {'@id': 'http://dp.la/api/contributor/nypl',
  'name': 'The New York Public Library'},
 'rights': 'http://rightsstatements.org/vocab/UND/1.0/',
 'score': 7.864037,
 'sourceResource': {'@id': 'http://dp.la/api/items/f5fda5d6d8d7011a575f944de8e108c4#sourceResource',
  'collection': {'@id': 'http://dp.la/api/collections/3f371a92211aa17caadbb21fb98f3bd4',
   'id': '3f371a92211aa17caadbb21fb98f3bd4',
   'title': 'Jane Austen.'},
  'relation': 'Jane Austen',
  'rights': 'The copyright and related rights status of this item has been reviewed by The New York Public Library, but we were unable to make a conclusive determination as to the copyright status of the item. You are free to use this Item in any way that is permitted by the copyright and related rights legislation that applies to your use.',
  'stateLocatedIn': [{'name': 'New York'}],
  'subject': [{'name': 'Clippings'}, {'name': 'Portraits'}],
  'title': 'J. Austen',
  'type': 'image'}}

We get a lot of information from a source like this - far more than you probably wanted to know about this individual object. This is what makes API's both useful and tricky to work with. They often want to set up users with everything they could possibly need, but they can't know what it is that users will be interested in. So very often they seem to err on the side of completion, which can sometimes make it difficult to parse the results. One difficult piece here is that the information is hierarchical - the data is organized a bit like a tree. So you have to respect that hierarchy by unfolding it as it expects. The first line below does not work, but the second does. Can you see why?

In [13]:
item['stateLocatedIn']
---------------------------------------------------------------------------
KeyError                                  Traceback (most recent call last)
<ipython-input-13-0516df9a1c0d> in <module>()
----> 1 item['stateLocatedIn']

KeyError: 'stateLocatedIn'
In [14]:
item['sourceResource']['stateLocatedIn']
Out[14]:
[{'name': 'New York'}]

There is no top-level key for 'stateLocatedIn'. That data is actually organized under 'sourceResource', so we have to tell the script exactly where we want to look. We can confirm this by walking down the tree towards the data we're interested in.

In [15]:
result.items[0]['sourceResource']
Out[15]:
{'@id': 'http://dp.la/api/items/f5fda5d6d8d7011a575f944de8e108c4#sourceResource',
 'collection': {'@id': 'http://dp.la/api/collections/3f371a92211aa17caadbb21fb98f3bd4',
  'id': '3f371a92211aa17caadbb21fb98f3bd4',
  'title': 'Jane Austen.'},
 'relation': 'Jane Austen',
 'rights': 'The copyright and related rights status of this item has been reviewed by The New York Public Library, but we were unable to make a conclusive determination as to the copyright status of the item. You are free to use this Item in any way that is permitted by the copyright and related rights legislation that applies to your use.',
 'stateLocatedIn': [{'name': 'New York'}],
 'subject': [{'name': 'Clippings'}, {'name': 'Portraits'}],
 'title': 'J. Austen',
 'type': 'image'}

This confirms what we had suggested before - things are nested in ways that can be difficult to parse. Imagine saying, "to find Y, first you have to look under X" rather than saying "look at Y. Why can't you find it?" We can get more information by querying 'item.keys()'. We're dealing with a dictionary object, so we can use all the normal dictionary commands.

In [16]:
item.keys()
Out[16]:
dict_keys(['@context', 'isShownAt', 'dataProvider', '@type', 'rights', 'provider', 'object', 'ingestionSequence', 'id', 'ingestDate', '_rev', 'aggregatedCHO', '_id', 'sourceResource', 'admin', 'ingestType', '@id', 'originalRecord', 'score'])

Let's loop over the first ten items here to get some interesting information about them. Notice here that 'item' is our name for the individual object that we are looking at in each iteration of the loop.

In [17]:
for item in result.items[:9]:
    print(item['sourceResource']['stateLocatedIn'])
[{'name': 'New York'}]
[{'name': 'New York'}]
[{'name': 'New York'}]
[{'name': 'New York'}]
---------------------------------------------------------------------------
KeyError                                  Traceback (most recent call last)
<ipython-input-17-bcbe3b18eda9> in <module>()
      1 for item in result.items[:9]:
----> 2     print(item['sourceResource']['stateLocatedIn'])

KeyError: 'stateLocatedIn'

Several New York Objects, and then an error. Let's look at the fifth object to see what is wrong with it.

In [18]:
result.items[4]['sourceResource']
Out[18]:
{'@id': 'http://dp.la/api/items/fc468f34a8666570091a694b6ef7259a#sourceResource',
 'creator': ['Malden, Charles, Mrs'],
 'date': {'begin': '1896', 'displayDate': '1896 [c1889]', 'end': '2017'},
 'extent': ['224 p. 18 cm.'],
 'format': ['Electronic resource', 'Language material'],
 'identifier': ['sdr-nrlfGLAD117809692-B',
  '(OCoLC)217878889',
  'LC call number: PR4036 .M3',
  '(OCoLC)764476',
  'Hathi: 006155179'],
 'language': [{'iso639_3': 'eng', 'name': 'English'}],
 'publisher': ['Boston, Roberts'],
 'rights': 'Public domain. Learn more at http://www.hathitrust.org/access_use',
 'specType': ['Book'],
 'subject': [{'name': 'Austen, Jane, 1775-1817'}],
 'title': ['Jane Austen'],
 'type': 'text'}

The first several results all appear to be held by libraries, while the fifth result is an electronic resource. It makes sense that this resourcee would not be held in a particular state. Let's make our results a bit more nuanced so as to account for these edge cases.

In [19]:
for item in result.items[:9]:
    if 'stateLocatedIn' in item['sourceResource']:
        print(item['sourceResource']['stateLocatedIn'])
    else:
        print(item['sourceResource']['format'])
result.items[:9]
[{'name': 'New York'}]
[{'name': 'New York'}]
[{'name': 'New York'}]
[{'name': 'New York'}]
['Electronic resource', 'Language material']
['Electronic resource', 'Language material']
['Electronic resource', 'Language material']
['Electronic resource', 'Language material']
[{'name': 'UT'}]
Out[19]:
[{'@context': 'http://dp.la/api/items/context',
  '@id': 'http://dp.la/api/items/f5fda5d6d8d7011a575f944de8e108c4',
  '@type': 'ore:Aggregation',
  '_id': 'nypl--510d47dc-7ea0-a3d9-e040-e00a18064a99',
  '_rev': '9-0a2b767b300f8ef56a28a2c4d19c2758',
  'admin': {'object_status': 1,
   'sourceResource': {'title': 'J. Austen'},
   'valid_after_enrich': True,
   'validation_message': None},
  'aggregatedCHO': '#sourceResource',
  'dataProvider': 'The Miriam and Ira D. Wallach Division of Art, Prints and Photographs: Print Collection. The New York Public Library',
  'id': 'f5fda5d6d8d7011a575f944de8e108c4',
  'ingestDate': '2017-01-17T01:02:42.938459Z',
  'ingestType': 'item',
  'ingestionSequence': 21,
  'isShownAt': 'http://digitalcollections.nypl.org/items/510d47dc-7ea0-a3d9-e040-e00a18064a99',
  'object': 'http://images.nypl.org/index.php?id=1103428&t=t',
  'originalRecord': {'_id': '510d47dc-7ea0-a3d9-e040-e00a18064a99',
   'collection': {'@id': 'http://dp.la/api/collections/3f371a92211aa17caadbb21fb98f3bd4',
    'id': '3f371a92211aa17caadbb21fb98f3bd4'},
   'genre': [{'#text': 'Clippings',
     'authority': 'lctgm',
     'valueURI': 'http://id.loc.gov/vocabulary/graphicMaterials/tgm002169'},
    {'#text': 'Portraits',
     'authority': 'lctgm',
     'valueURI': 'http://id.loc.gov/vocabulary/graphicMaterials/tgm008085'}],
   'identifier': [{'#text': '242',
     'displayLabel': 'Hades Collection Guide ID (legacy)',
     'type': 'local_hades_collection'},
    {'#text': 'Portrait File',
     'displayLabel': 'Other local Identifier',
     'type': 'local_other'},
    {'#text': '348628',
     'displayLabel': 'Hades struc ID (legacy)',
     'type': 'local_hades'},
    {'#text': '36450420-c533-012f-cf67-58d385a7bc34', 'type': 'uuid'}],
   'location': [{'physicalLocation': [{'#text': 'nn',
       'authority': 'marcorg',
       'type': 'repository'},
      {'#text': 'The Miriam and Ira D. Wallach Division of Art, Prints and Photographs: Print Collection',
       'type': 'division'},
      {'#text': 'Wallach Division: Print Collection',
       'type': 'division_short_name'},
      {'#text': 'PRN', 'type': 'code'}]},
    {'physicalLocation': [{'#text': 'The Miriam and Ira D. Wallach Division of Art, Prints and Photographs: Print Collection',
       'type': 'division'},
      {'#text': 'Wallach Division: Print Collection',
       'type': 'division_short_name'},
      {'#text': 'PRN', 'type': 'code'}]}],
   'provider': {'@id': 'http://dp.la/api/contributor/nypl',
    'name': 'The New York Public Library'},
   'relatedItem': {'identifier': [{'#text': '34e5a7f0-c533-012f-aa43-58d385a7bc34',
      'type': 'uuid'},
     {'#text': '348620', 'type': 'local_hades'}],
    'relatedItem': {'identifier': [{'#text': '17513b20-c52e-012f-78fb-58d385a7bc34',
       'type': 'uuid'},
      {'#text': '591659', 'type': 'local_hades'}],
     'relatedItem': {'identifier': [{'#text': '16ad5350-c52e-012f-aecf-58d385a7bc34',
        'type': 'uuid'},
       {'#text': '287739 local_hades_collection', 'type': 'local_hades'}],
      'titleInfo': {'title': 'Print Collection portrait file'},
      'type': 'host'},
     'titleInfo': {'title': 'A'},
     'type': 'host'},
    'titleInfo': {'title': 'Jane Austen.'},
    'type': 'host'},
   'rightsStatementURI': 'http://rightsstatements.org/vocab/UND/1.0/',
   'schemaLocation': 'http://www.loc.gov/mods/v3 http://www.loc.gov/standards/mods/v3/mods-3-4.xsd',
   'subject': {'authority': '', 'topic': 'Public figures'},
   'titleInfo': {'supplied': 'no', 'title': 'J. Austen.', 'usage': 'primary'},
   'tmp_high_res_link': None,
   'tmp_image_id': '1103428',
   'tmp_item_link': 'http://digitalcollections.nypl.org/items/510d47dc-7ea0-a3d9-e040-e00a18064a99',
   'tmp_rights_statement': 'The copyright and related rights status of this item has been reviewed by The New York Public Library, but we were unable to make a conclusive determination as to the copyright status of the item. You are free to use this Item in any way that is permitted by the copyright and related rights legislation that applies to your use.',
   'typeOfResource': 'still image',
   'version': '3.4'},
  'provider': {'@id': 'http://dp.la/api/contributor/nypl',
   'name': 'The New York Public Library'},
  'rights': 'http://rightsstatements.org/vocab/UND/1.0/',
  'score': 7.864037,
  'sourceResource': {'@id': 'http://dp.la/api/items/f5fda5d6d8d7011a575f944de8e108c4#sourceResource',
   'collection': {'@id': 'http://dp.la/api/collections/3f371a92211aa17caadbb21fb98f3bd4',
    'id': '3f371a92211aa17caadbb21fb98f3bd4',
    'title': 'Jane Austen.'},
   'relation': 'Jane Austen',
   'rights': 'The copyright and related rights status of this item has been reviewed by The New York Public Library, but we were unable to make a conclusive determination as to the copyright status of the item. You are free to use this Item in any way that is permitted by the copyright and related rights legislation that applies to your use.',
   'stateLocatedIn': [{'name': 'New York'}],
   'subject': [{'name': 'Clippings'}, {'name': 'Portraits'}],
   'title': 'J. Austen',
   'type': 'image'}},
 {'@context': 'http://dp.la/api/items/context',
  '@id': 'http://dp.la/api/items/970af7dfc39299aeea1dbf3ab2ead891',
  '@type': 'ore:Aggregation',
  '_id': 'nypl--510d47dc-7e9e-a3d9-e040-e00a18064a99',
  '_rev': '9-9945c08a102f0795cffc0d8de3f25ed4',
  'admin': {'object_status': 1,
   'sourceResource': {'title': 'J. Austen'},
   'valid_after_enrich': True,
   'validation_message': None},
  'aggregatedCHO': '#sourceResource',
  'dataProvider': 'The Miriam and Ira D. Wallach Division of Art, Prints and Photographs: Print Collection. The New York Public Library',
  'id': '970af7dfc39299aeea1dbf3ab2ead891',
  'ingestDate': '2017-01-17T01:02:42.561986Z',
  'ingestType': 'item',
  'ingestionSequence': 21,
  'isShownAt': 'http://digitalcollections.nypl.org/items/510d47dc-7e9e-a3d9-e040-e00a18064a99',
  'object': 'http://images.nypl.org/index.php?id=1103426&t=t',
  'originalRecord': {'_id': '510d47dc-7e9e-a3d9-e040-e00a18064a99',
   'collection': {'@id': 'http://dp.la/api/collections/3f371a92211aa17caadbb21fb98f3bd4',
    'id': '3f371a92211aa17caadbb21fb98f3bd4'},
   'genre': [{'#text': 'Clippings',
     'authority': 'lctgm',
     'valueURI': 'http://id.loc.gov/vocabulary/graphicMaterials/tgm002169'},
    {'#text': 'Portraits',
     'authority': 'lctgm',
     'valueURI': 'http://id.loc.gov/vocabulary/graphicMaterials/tgm008085'}],
   'identifier': [{'#text': '242',
     'displayLabel': 'Hades Collection Guide ID (legacy)',
     'type': 'local_hades_collection'},
    {'#text': 'Portrait File',
     'displayLabel': 'Other local Identifier',
     'type': 'local_other'},
    {'#text': '348626',
     'displayLabel': 'Hades struc ID (legacy)',
     'type': 'local_hades'},
    {'#text': '35a5ff70-c533-012f-8a9a-58d385a7bc34', 'type': 'uuid'}],
   'location': [{'physicalLocation': [{'#text': 'nn',
       'authority': 'marcorg',
       'type': 'repository'},
      {'#text': 'The Miriam and Ira D. Wallach Division of Art, Prints and Photographs: Print Collection',
       'type': 'division'},
      {'#text': 'Wallach Division: Print Collection',
       'type': 'division_short_name'},
      {'#text': 'PRN', 'type': 'code'}]},
    {'physicalLocation': [{'#text': 'The Miriam and Ira D. Wallach Division of Art, Prints and Photographs: Print Collection',
       'type': 'division'},
      {'#text': 'Wallach Division: Print Collection',
       'type': 'division_short_name'},
      {'#text': 'PRN', 'type': 'code'}]}],
   'provider': {'@id': 'http://dp.la/api/contributor/nypl',
    'name': 'The New York Public Library'},
   'relatedItem': {'identifier': [{'#text': '34e5a7f0-c533-012f-aa43-58d385a7bc34',
      'type': 'uuid'},
     {'#text': '348620', 'type': 'local_hades'}],
    'relatedItem': {'identifier': [{'#text': '17513b20-c52e-012f-78fb-58d385a7bc34',
       'type': 'uuid'},
      {'#text': '591659', 'type': 'local_hades'}],
     'relatedItem': {'identifier': [{'#text': '16ad5350-c52e-012f-aecf-58d385a7bc34',
        'type': 'uuid'},
       {'#text': '287739 local_hades_collection', 'type': 'local_hades'}],
      'titleInfo': {'title': 'Print Collection portrait file'},
      'type': 'host'},
     'titleInfo': {'title': 'A'},
     'type': 'host'},
    'titleInfo': {'title': 'Jane Austen.'},
    'type': 'host'},
   'rightsStatementURI': 'http://rightsstatements.org/vocab/UND/1.0/',
   'schemaLocation': 'http://www.loc.gov/mods/v3 http://www.loc.gov/standards/mods/v3/mods-3-4.xsd',
   'subject': {'authority': '', 'topic': 'Public figures'},
   'titleInfo': {'supplied': 'no', 'title': 'J. Austen.', 'usage': 'primary'},
   'tmp_high_res_link': None,
   'tmp_image_id': '1103426',
   'tmp_item_link': 'http://digitalcollections.nypl.org/items/510d47dc-7e9e-a3d9-e040-e00a18064a99',
   'tmp_rights_statement': 'The copyright and related rights status of this item has been reviewed by The New York Public Library, but we were unable to make a conclusive determination as to the copyright status of the item. You are free to use this Item in any way that is permitted by the copyright and related rights legislation that applies to your use.',
   'typeOfResource': 'still image',
   'version': '3.4'},
  'provider': {'@id': 'http://dp.la/api/contributor/nypl',
   'name': 'The New York Public Library'},
  'rights': 'http://rightsstatements.org/vocab/UND/1.0/',
  'score': 7.864037,
  'sourceResource': {'@id': 'http://dp.la/api/items/970af7dfc39299aeea1dbf3ab2ead891#sourceResource',
   'collection': {'@id': 'http://dp.la/api/collections/3f371a92211aa17caadbb21fb98f3bd4',
    'id': '3f371a92211aa17caadbb21fb98f3bd4',
    'title': 'Jane Austen.'},
   'relation': 'Jane Austen',
   'rights': 'The copyright and related rights status of this item has been reviewed by The New York Public Library, but we were unable to make a conclusive determination as to the copyright status of the item. You are free to use this Item in any way that is permitted by the copyright and related rights legislation that applies to your use.',
   'stateLocatedIn': [{'name': 'New York'}],
   'subject': [{'name': 'Clippings'}, {'name': 'Portraits'}],
   'title': 'J. Austen',
   'type': 'image'}},
 {'@context': 'http://dp.la/api/items/context',
  '@id': 'http://dp.la/api/items/0c14b337ace2392f0d715db429d21c08',
  '@type': 'ore:Aggregation',
  '_id': 'nypl--510d47de-8074-a3d9-e040-e00a18064a99',
  '_rev': '9-fe94d28eca51a19f400de388bbf17405',
  'admin': {'object_status': 1,
   'sourceResource': {'title': 'Austen Chamberlain'},
   'valid_after_enrich': True,
   'validation_message': None},
  'aggregatedCHO': '#sourceResource',
  'dataProvider': 'The Miriam and Ira D. Wallach Division of Art, Prints and Photographs: Print Collection. The New York Public Library',
  'id': '0c14b337ace2392f0d715db429d21c08',
  'ingestDate': '2017-01-17T08:13:27.717710Z',
  'ingestType': 'item',
  'ingestionSequence': 21,
  'isShownAt': 'http://digitalcollections.nypl.org/items/510d47de-8074-a3d9-e040-e00a18064a99',
  'object': 'http://images.nypl.org/index.php?id=1210822&t=t',
  'originalRecord': {'_id': '510d47de-8074-a3d9-e040-e00a18064a99',
   'collection': {'@id': 'http://dp.la/api/collections/3f371a92211aa17caadbb21fb98f3bd4',
    'id': '3f371a92211aa17caadbb21fb98f3bd4'},
   'genre': [{'#text': 'Clippings',
     'authority': 'lctgm',
     'valueURI': 'http://id.loc.gov/vocabulary/graphicMaterials/tgm002169'},
    {'#text': 'Portraits',
     'authority': 'lctgm',
     'valueURI': 'http://id.loc.gov/vocabulary/graphicMaterials/tgm008085'}],
   'identifier': [{'#text': '242',
     'displayLabel': 'Hades Collection Guide ID (legacy)',
     'type': 'local_hades_collection'},
    {'#text': 'Portrait File',
     'displayLabel': 'Other local Identifier',
     'type': 'local_other'},
    {'#text': '486322',
     'displayLabel': 'Hades struc ID (legacy)',
     'type': 'local_hades'},
    {'#text': 'e5cfd9e0-c543-012f-4174-58d385a7bc34', 'type': 'uuid'}],
   'location': [{'physicalLocation': [{'#text': 'nn',
       'authority': 'marcorg',
       'type': 'repository'},
      {'#text': 'The Miriam and Ira D. Wallach Division of Art, Prints and Photographs: Print Collection',
       'type': 'division'},
      {'#text': 'Wallach Division: Print Collection',
       'type': 'division_short_name'},
      {'#text': 'PRN', 'type': 'code'}]},
    {'physicalLocation': [{'#text': 'The Miriam and Ira D. Wallach Division of Art, Prints and Photographs: Print Collection',
       'type': 'division'},
      {'#text': 'Wallach Division: Print Collection',
       'type': 'division_short_name'},
      {'#text': 'PRN', 'type': 'code'}]}],
   'provider': {'@id': 'http://dp.la/api/contributor/nypl',
    'name': 'The New York Public Library'},
   'relatedItem': {'identifier': [{'#text': 'e5235440-c543-012f-bb2a-58d385a7bc34',
      'type': 'uuid'},
     {'#text': '482872', 'type': 'local_hades'}],
    'relatedItem': {'identifier': [{'#text': '8bc69d40-c540-012f-868d-58d385a7bc34',
       'type': 'uuid'},
      {'#text': '591655', 'type': 'local_hades'}],
     'relatedItem': {'identifier': [{'#text': '16ad5350-c52e-012f-aecf-58d385a7bc34',
        'type': 'uuid'},
       {'#text': '287739 local_hades_collection', 'type': 'local_hades'}],
      'titleInfo': {'title': 'Print Collection portrait file'},
      'type': 'host'},
     'titleInfo': {'title': 'C'},
     'type': 'host'},
    'titleInfo': {'title': 'Austen Chamberlain.'},
    'type': 'host'},
   'rightsStatementURI': 'http://rightsstatements.org/vocab/UND/1.0/',
   'schemaLocation': 'http://www.loc.gov/mods/v3 http://www.loc.gov/standards/mods/v3/mods-3-4.xsd',
   'subject': [{'authority': '', 'topic': 'Public figures'},
    {'name': {'authority': 'naf',
      'namePart': 'Chamberlain, Austen, Sir, 1863-1937',
      'type': 'personal'}}],
   'titleInfo': {'lang': 'eng',
    'supplied': 'no',
    'title': 'Austen Chamberlain.',
    'usage': 'primary'},
   'tmp_high_res_link': None,
   'tmp_image_id': '1210822',
   'tmp_item_link': 'http://digitalcollections.nypl.org/items/510d47de-8074-a3d9-e040-e00a18064a99',
   'tmp_rights_statement': 'The copyright and related rights status of this item has been reviewed by The New York Public Library, but we were unable to make a conclusive determination as to the copyright status of the item. You are free to use this Item in any way that is permitted by the copyright and related rights legislation that applies to your use.',
   'typeOfResource': 'still image',
   'version': '3.4'},
  'provider': {'@id': 'http://dp.la/api/contributor/nypl',
   'name': 'The New York Public Library'},
  'rights': 'http://rightsstatements.org/vocab/UND/1.0/',
  'score': 7.864037,
  'sourceResource': {'@id': 'http://dp.la/api/items/0c14b337ace2392f0d715db429d21c08#sourceResource',
   'collection': {'@id': 'http://dp.la/api/collections/3f371a92211aa17caadbb21fb98f3bd4',
    'id': '3f371a92211aa17caadbb21fb98f3bd4',
    'title': 'Austen Chamberlain.'},
   'relation': 'Austen Chamberlain',
   'rights': 'The copyright and related rights status of this item has been reviewed by The New York Public Library, but we were unable to make a conclusive determination as to the copyright status of the item. You are free to use this Item in any way that is permitted by the copyright and related rights legislation that applies to your use.',
   'stateLocatedIn': [{'name': 'New York'}],
   'subject': [{'name': 'Chamberlain, Austen, Sir, 1863-1937'},
    {'name': 'Clippings'},
    {'name': 'Portraits'}],
   'title': 'Austen Chamberlain',
   'type': 'image'}},
 {'@context': 'http://dp.la/api/items/context',
  '@id': 'http://dp.la/api/items/967008a9270774258144d2f9dcf81bad',
  '@type': 'ore:Aggregation',
  '_id': 'nypl--510d47e2-cb07-a3d9-e040-e00a18064a99',
  '_rev': '9-5d4c98f1f3acf33c5acb3cc3c2e6d8ac',
  'admin': {'object_status': 1,
   'sourceResource': {'title': 'Jane Austen'},
   'valid_after_enrich': True,
   'validation_message': None},
  'aggregatedCHO': '#sourceResource',
  'dataProvider': 'George Arents Collection. The New York Public Library',
  'id': '967008a9270774258144d2f9dcf81bad',
  'ingestDate': '2017-01-17T03:04:35.628462Z',
  'ingestType': 'item',
  'ingestionSequence': 21,
  'isShownAt': 'http://digitalcollections.nypl.org/items/510d47e2-cb07-a3d9-e040-e00a18064a99',
  'object': 'http://images.nypl.org/index.php?id=1562446&t=t',
  'originalRecord': {'_id': '510d47e2-cb07-a3d9-e040-e00a18064a99',
   'collection': {'@id': 'http://dp.la/api/collections/4b2c78d8d91b78c5060cdef2b27ff198',
    'id': '4b2c78d8d91b78c5060cdef2b27ff198'},
   'genre': [{'#text': 'Cigarette cards',
     'authority': 'lctgm',
     'usage': 'primary',
     'valueURI': 'http://id.loc.gov/vocabulary/graphicMaterials/tgm002061'},
    {'#text': 'Trade cards',
     'authority': 'lctgm',
     'valueURI': 'http://id.loc.gov/vocabulary/graphicMaterials/tgm010957'}],
   'identifier': [{'#text': 'b6932483',
     'displayLabel': 'CATNYP ID (legacy)',
     'type': 'local_catnyp'},
    {'#text': 'b15262620',
     'displayLabel': 'NYPL catalog ID (B-number)',
     'type': 'local_bnumber'},
    {'#text': '161',
     'displayLabel': 'Hades Collection Guide ID (legacy)',
     'type': 'local_hades_collection'},
    {'#text': '798291',
     'displayLabel': 'Hades struc ID (legacy)',
     'type': 'local_hades'},
    {'#text': '65adba50-c55a-012f-bc51-58d385a7bc34', 'type': 'uuid'}],
   'location': [{'physicalLocation': [{'#text': 'nn',
       'authority': 'marcorg',
       'type': 'repository'},
      {'#text': 'George Arents Collection', 'type': 'division'},
      {'#text': 'George Arents Collection', 'type': 'division_short_name'},
      {'#text': 'ARN', 'type': 'code'}],
     'shelfLocator': 'Arents Cigarette Cards'},
    {'shelfLocator': 'Arents Cigarette Cards 823'},
    {'physicalLocation': [{'#text': 'George Arents Collection',
       'type': 'division'},
      {'#text': 'George Arents Collection', 'type': 'division_short_name'},
      {'#text': 'ARN', 'type': 'code'}]}],
   'note': [{'#text': 'Carreras; Carreras', 'type': 'content'},
    {'#text': 'Cartophilic reference books C18-82',
     'type': 'citation/reference'}],
   'originInfo': {'place': {'placeTerm': 'U.K.'}},
   'provider': {'@id': 'http://dp.la/api/contributor/nypl',
    'name': 'The New York Public Library'},
   'relatedItem': {'identifier': [{'#text': '5d8e3990-c55a-012f-56b1-58d385a7bc34',
      'type': 'uuid'},
     {'#text': '779948', 'type': 'local_hades'}],
    'relatedItem': {'identifier': [{'#text': 'b50ab6f0-c52b-012f-5986-58d385a7bc34',
       'type': 'uuid'},
      {'#text': '108805 local_catnyp', 'type': 'local_hades'}],
     'titleInfo': {'title': 'Cigarette cards'},
     'type': 'host'},
    'titleInfo': {'title': 'Famous women'},
    'type': 'host'},
   'rightsStatementURI': None,
   'schemaLocation': 'http://www.loc.gov/mods/v3 http://www.loc.gov/standards/mods/v3/mods-3-4.xsd',
   'subject': {'topic': {'#text': 'Women', 'authority': 'lctgm'}},
   'titleInfo': {'lang': 'eng',
    'supplied': 'no',
    'title': 'Jane Austen.',
    'usage': 'primary'},
   'tmp_high_res_link': None,
   'tmp_image_id': '1562446',
   'tmp_item_link': 'http://digitalcollections.nypl.org/items/510d47e2-cb07-a3d9-e040-e00a18064a99',
   'tmp_rights_statement': "The New York Public Library is interested in learning more about items you've seen on our websites or elsewhere online. If you have any more information about an item or its copyright status, we want to hear from you. Please contact [email protected] with your contact information and a link to the relevant content.",
   'typeOfResource': 'still image',
   'version': '3.4'},
  'provider': {'@id': 'http://dp.la/api/contributor/nypl',
   'name': 'The New York Public Library'},
  'score': 7.864037,
  'sourceResource': {'@id': 'http://dp.la/api/items/967008a9270774258144d2f9dcf81bad#sourceResource',
   'collection': {'@id': 'http://dp.la/api/collections/4b2c78d8d91b78c5060cdef2b27ff198',
    'id': '4b2c78d8d91b78c5060cdef2b27ff198',
    'title': 'Famous women'},
   'relation': 'Famous women',
   'rights': "The New York Public Library is interested in learning more about items you've seen on our websites or elsewhere online. If you have any more information about an item or its copyright status, we want to hear from you. Please contact [email protected] with your contact information and a link to the relevant content.",
   'spatial': [{'coordinates': '54.5608863831, -2.21251177788',
     'country': 'United Kingdom',
     'name': 'U.K.'}],
   'stateLocatedIn': [{'name': 'New York'}],
   'subject': [{'name': 'Women'},
    {'name': 'Cigarette cards'},
    {'name': 'Trade cards'}],
   'title': 'Jane Austen',
   'type': 'image'}},
 {'@context': 'http://dp.la/api/items/context',
  '@id': 'http://dp.la/api/items/fc468f34a8666570091a694b6ef7259a',
  '@type': 'ore:Aggregation',
  '_id': 'hathitrust--006155179',
  '_rev': '14-96345e11334190d70c67c327292b6db3',
  'admin': {'object_status': 1,
   'sourceResource': {'title': 'Jane Austen'},
   'valid_after_enrich': True,
   'validation_message': None},
  'aggregatedCHO': '#sourceResource',
  'dataProvider': ['University of California'],
  'id': 'fc468f34a8666570091a694b6ef7259a',
  'ingestDate': '2017-02-15T01:47:26.470045Z',
  'ingestType': 'item',
  'ingestionSequence': 29,
  'isShownAt': 'http://catalog.hathitrust.org/Record/006155179',
  'object': 'https://books.google.com/books/content?id=vboEAQAAIAAJ&printsec=frontcover&img=1&zoom=5&edge=curl',
  'originalRecord': {'_id': '006155179',
   'controlfield': [{'#text': '006155179', 'tag': '001'},
    {'#text': 'MiAaHDL', 'tag': '003'},
    {'#text': '20090407000000.0', 'tag': '005'},
    {'#text': 'm d', 'tag': '006'},
    {'#text': 'cr bn ---auaua', 'tag': '007'},
    {'#text': '901202c18961889mau 00010 eng d', 'tag': '008'}],
   'datafield': [{'ind1': '',
     'ind2': '',
     'subfield': {'#text': '12036501', 'code': 'a'},
     'tag': '010'},
    {'ind1': '',
     'ind2': '',
     'subfield': {'#text': 'sdr-nrlfGLAD117809692-B', 'code': 'a'},
     'tag': '035'},
    {'ind1': '',
     'ind2': '',
     'subfield': {'#text': '(OCoLC)217878889', 'code': 'a'},
     'tag': '035'},
    {'ind1': '',
     'ind2': '',
     'subfield': [{'#text': 'HEI', 'code': 'a'},
      {'#text': 'HEI', 'code': 'c'},
      {'#text': 'm.c.', 'code': 'd'},
      {'#text': 'CUY', 'code': 'd'}],
     'tag': '040'},
    {'ind1': '',
     'ind2': '',
     'subfield': [{'#text': 'PR4036', 'code': 'a'},
      {'#text': '.M3', 'code': 'b'}],
     'tag': '050'},
    {'ind1': '',
     'ind2': '',
     'subfield': [{'#text': 'PR4036', 'code': 'a'},
      {'#text': '.M3 1896', 'code': 'b'}],
     'tag': '090'},
    {'ind1': '',
     'ind2': '',
     'subfield': {'#text': '(OCoLC)764476', 'code': 'a'},
     'tag': '035'},
    {'ind1': '1',
     'ind2': '0',
     'subfield': [{'#text': 'Malden, Charles,', 'code': 'a'},
      {'#text': 'Mrs.', 'code': 'c'}],
     'tag': '100'},
    {'ind1': '1',
     'ind2': '0',
     'subfield': [{'#text': 'Jane Austen,', 'code': 'a'},
      {'#text': 'by Mrs. Charles Malden.', 'code': 'c'}],
     'tag': '245'},
    {'ind1': '0',
     'ind2': '',
     'subfield': [{'#text': 'Boston,', 'code': 'a'},
      {'#text': 'Roberts,', 'code': 'b'},
      {'#text': '1896 [c1889]', 'code': 'c'}],
     'tag': '260'},
    {'ind1': '',
     'ind2': '',
     'subfield': [{'#text': '224 p.', 'code': 'a'},
      {'#text': '18 cm.', 'code': 'c'}],
     'tag': '300'},
    {'ind1': '0',
     'ind2': '',
     'subfield': {'#text': 'Famous women', 'code': 'a'},
     'tag': '490'},
    {'ind1': '',
     'ind2': '',
     'subfield': {'#text': 'Mode of access: Internet.', 'code': 'a'},
     'tag': '538'},
    {'ind1': '1',
     'ind2': '0',
     'subfield': [{'#text': 'Austen, Jane,', 'code': 'a'},
      {'#text': '1775-1817.', 'code': 'd'}],
     'tag': '600'},
    {'ind1': '',
     'ind2': '',
     'subfield': {'#text': 'BK', 'code': 'a'},
     'tag': '970'},
    {'ind1': '',
     'ind2': '',
     'subfield': [{'#text': 'UC', 'code': 'b'},
      {'#text': 'NRLF', 'code': 'c'},
      {'#text': '20150503', 'code': 'd'},
      {'#text': 'google', 'code': 's'},
      {'#text': 'uc1.b4102766', 'code': 'u'},
      {'#text': '1896', 'code': 'y'},
      {'#text': 'pd', 'code': 'r'},
      {'#text': 'bib', 'code': 'q'}],
     'tag': '974'}],
   'leader': '00599nam a22002171 4500',
   'provider': {'@id': 'http://dp.la/api/contributor/hathitrust',
    'name': 'HathiTrust'}},
  'provider': {'@id': 'http://dp.la/api/contributor/hathitrust',
   'name': 'HathiTrust'},
  'score': 7.864037,
  'sourceResource': {'@id': 'http://dp.la/api/items/fc468f34a8666570091a694b6ef7259a#sourceResource',
   'creator': ['Malden, Charles, Mrs'],
   'date': {'begin': '1896', 'displayDate': '1896 [c1889]', 'end': '2017'},
   'extent': ['224 p. 18 cm.'],
   'format': ['Electronic resource', 'Language material'],
   'identifier': ['sdr-nrlfGLAD117809692-B',
    '(OCoLC)217878889',
    'LC call number: PR4036 .M3',
    '(OCoLC)764476',
    'Hathi: 006155179'],
   'language': [{'iso639_3': 'eng', 'name': 'English'}],
   'publisher': ['Boston, Roberts'],
   'rights': 'Public domain. Learn more at http://www.hathitrust.org/access_use',
   'specType': ['Book'],
   'subject': [{'name': 'Austen, Jane, 1775-1817'}],
   'title': ['Jane Austen'],
   'type': 'text'}},
 {'@context': 'http://dp.la/api/items/context',
  '@id': 'http://dp.la/api/items/280187e66f0c3af7a6216953cd4517c0',
  '@type': 'ore:Aggregation',
  '_id': 'hathitrust--000426718',
  '_rev': '14-139af316d6934319c8f45a33607b5db6',
  'admin': {'object_status': 1,
   'sourceResource': {'title': 'Jane Austen'},
   'valid_after_enrich': True,
   'validation_message': None},
  'aggregatedCHO': '#sourceResource',
  'dataProvider': ['University of Michigan'],
  'id': '280187e66f0c3af7a6216953cd4517c0',
  'ingestDate': '2017-02-15T06:53:55.321908Z',
  'ingestType': 'item',
  'ingestionSequence': 29,
  'isShownAt': 'http://catalog.hathitrust.org/Record/000426718',
  'object': 'https://books.google.com/books/content?id=2C5aAAAAMAAJ&printsec=frontcover&img=1&zoom=5',
  'originalRecord': {'_id': '000426718',
   'controlfield': [{'#text': '000426718', 'tag': '001'},
    {'#text': 'MiAaHDL', 'tag': '003'},
    {'#text': '20130211000000.0', 'tag': '005'},
    {'#text': 'm d', 'tag': '006'},
    {'#text': 'cr bn ---auaua', 'tag': '007'},
    {'#text': '720714t19651920nyua 000 0 eng', 'tag': '008'}],
   'datafield': [{'ind1': '',
     'ind2': '',
     'subfield': {'#text': '65018805', 'code': 'a'},
     'tag': '010'},
    {'ind1': '',
     'ind2': '',
     'subfield': {'#text': '(MiU)000426718', 'code': 'a'},
     'tag': '035'},
    {'ind1': '',
     'ind2': '',
     'subfield': {'#text': 'sdr-miu000426718', 'code': 'a'},
     'tag': '035'},
    {'ind1': '',
     'ind2': '',
     'subfield': {'#text': '(OCoLC)356048', 'code': 'a'},
     'tag': '035'},
    {'ind1': '',
     'ind2': '',
     'subfield': {'#text': '(CaOTULAS)160214876', 'code': 'a'},
     'tag': '035'},
    {'ind1': '',
     'ind2': '',
     'subfield': {'#text': '(RLIN)MIUG86-B56754', 'code': 'a'},
     'tag': '035'},
    {'ind1': '',
     'ind2': '',
     'subfield': {'#text': 'MiU', 'code': 'c'},
     'tag': '040'},
    {'ind1': '0',
     'ind2': '',
     'subfield': [{'#text': 'PR4036', 'code': 'a'},
      {'#text': '.F5 1965', 'code': 'b'}],
     'tag': '050'},
    {'ind1': '',
     'ind2': '',
     'subfield': {'#text': '823.7', 'code': 'a'},
     'tag': '082'},
    {'ind1': '1',
     'ind2': '',
     'subfield': [{'#text': 'Firkins, Oscar W.,', 'code': 'a'},
      {'#text': '1864-1932.', 'code': 'd'}],
     'tag': '100'},
    {'ind1': '1',
     'ind2': '0',
     'subfield': [{'#text': 'Jane Austen,', 'code': 'a'},
      {'#text': 'by O. W. Firkins.', 'code': 'c'}],
     'tag': '245'},
    {'ind1': '',
     'ind2': '',
     'subfield': [{'#text': 'New York,', 'code': 'a'},
      {'#text': 'Russell & Russell,', 'code': 'b'},
      {'#text': '1965 [c1920]', 'code': 'c'}],
     'tag': '260'},
    {'ind1': '',
     'ind2': '',
     'subfield': [{'#text': 'ix, 254 p.', 'code': 'a'},
      {'#text': '23 cm.', 'code': 'c'}],
     'tag': '300'},
    {'ind1': '',
     'ind2': '',
     'subfield': {'#text': 'Mode of access: Internet.', 'code': 'a'},
     'tag': '538'},
    {'ind1': '1',
     'ind2': '0',
     'subfield': [{'#text': 'Austen, Jane,', 'code': 'a'},
      {'#text': '1775-1817.', 'code': 'd'}],
     'tag': '600'},
    {'ind1': '',
     'ind2': '',
     'subfield': {'#text': 'BK', 'code': 'a'},
     'tag': '970'},
    {'ind1': '',
     'ind2': '',
     'subfield': [{'#text': 'MIU', 'code': 'b'},
      {'#text': 'MIU', 'code': 'c'},
      {'#text': '20161111', 'code': 'd'},
      {'#text': 'google', 'code': 's'},
      {'#text': 'mdp.39015008576251', 'code': 'u'},
      {'#text': '1920', 'code': 'y'},
      {'#text': 'pd', 'code': 'r'},
      {'#text': 'bib', 'code': 'q'}],
     'tag': '974'}],
   'leader': '00726nam a22002651 4500',
   'provider': {'@id': 'http://dp.la/api/contributor/hathitrust',
    'name': 'HathiTrust'}},
  'provider': {'@id': 'http://dp.la/api/contributor/hathitrust',
   'name': 'HathiTrust'},
  'score': 7.864037,
  'sourceResource': {'@id': 'http://dp.la/api/items/280187e66f0c3af7a6216953cd4517c0#sourceResource',
   'creator': ['Firkins, Oscar W., 1864-1932'],
   'date': {'begin': '1965', 'displayDate': '1965 [c1920]', 'end': '1965'},
   'extent': ['ix, 254 p. 23 cm.'],
   'format': ['Electronic resource', 'Language material'],
   'identifier': ['(MiU)000426718',
    'sdr-miu000426718',
    '(OCoLC)356048',
    '(CaOTULAS)160214876',
    '(RLIN)MIUG86-B56754',
    'LC call number: PR4036 .F5 1965',
    'Hathi: 000426718'],
   'language': [{'iso639_3': 'eng', 'name': 'English'}],
   'publisher': ['New York, Russell & Russell'],
   'rights': 'Public domain. Learn more at http://www.hathitrust.org/access_use',
   'specType': ['Book'],
   'subject': [{'name': 'Austen, Jane, 1775-1817'}],
   'title': ['Jane Austen'],
   'type': 'text'}},
 {'@context': 'http://dp.la/api/items/context',
  '@id': 'http://dp.la/api/items/4db8f024727e55971c1d3a864759aa12',
  '@type': 'ore:Aggregation',
  '_id': 'hathitrust--000472502',
  '_rev': '7-ec6bf6ddb2f85539c3946bc86b33fd87',
  'admin': {'object_status': 1,
   'sourceResource': {'title': 'Jane Austen'},
   'valid_after_enrich': True,
   'validation_message': None},
  'aggregatedCHO': '#sourceResource',
  'dataProvider': ['University of Michigan'],
  'id': '4db8f024727e55971c1d3a864759aa12',
  'ingestDate': '2017-02-15T02:59:31.956773Z',
  'ingestType': 'item',
  'ingestionSequence': 29,
  'isShownAt': 'http://catalog.hathitrust.org/Record/000472502',
  'object': 'https://books.google.com/books/content?id=WEVaAAAAMAAJ&printsec=frontcover&img=1&zoom=5',
  'originalRecord': {'_id': '000472502',
   'controlfield': [{'#text': '000472502', 'tag': '001'},
    {'#text': 'MiAaHDL', 'tag': '003'},
    {'#text': '20130211000000.0', 'tag': '005'},
    {'#text': 'm d', 'tag': '006'},
    {'#text': 'cr bn ---auaua', 'tag': '007'},
    {'#text': '880718s1926 enk 00000beng d', 'tag': '008'}],
   'datafield': [{'ind1': '',
     'ind2': '',
     'subfield': {'#text': '(MiU)000472502', 'code': 'a'},
     'tag': '035'},
    {'ind1': '',
     'ind2': '',
     'subfield': {'#text': 'sdr-miu000472502', 'code': 'a'},
     'tag': '035'},
    {'ind1': '',
     'ind2': '',
     'subfield': {'#text': '(OCoLC)6259097', 'code': 'a'},
     'tag': '035'},
    {'ind1': '',
     'ind2': '',
     'subfield': {'#text': '(CaOTULAS)160324501', 'code': 'a'},
     'tag': '035'},
    {'ind1': '',
     'ind2': '',
     'subfield': {'#text': '(RLIN)MIUG86-B63416', 'code': 'a'},
     'tag': '035'},
    {'ind1': '',
     'ind2': '',
     'subfield': [{'#text': 'OU', 'code': 'c'},
      {'#text': 'NNU', 'code': 'd'},
      {'#text': 'CStRLIN', 'code': 'd'},
      {'#text': 'MiU', 'code': 'd'}],
     'tag': '040'},
    {'ind1': '1',
     'ind2': '',
     'subfield': [{'#text': 'Warre Cornish, Francis,', 'code': 'a'},
      {'#text': '1839-1916.', 'code': 'd'}],
     'tag': '100'},
    {'ind1': '0',
     'ind2': '0',
     'subfield': {'#text': 'Jane Austen.', 'code': 'a'},
     'tag': '245'},
    {'ind1': '',
     'ind2': '',
     'subfield': [{'#text': 'London,', 'code': 'a'},
      {'#text': 'Macmillan,', 'code': 'b'},
      {'#text': '1926.', 'code': 'c'}],
     'tag': '260'},
    {'ind1': '',
     'ind2': '',
     'subfield': {'#text': '240 p.', 'code': 'a'},
     'tag': '300'},
    {'ind1': '',
     'ind2': '0',
     'subfield': {'#text': 'English men of letters', 'code': 'a'},
     'tag': '490'},
    {'ind1': '',
     'ind2': '',
     'subfield': {'#text': 'Mode of access: Internet.', 'code': 'a'},
     'tag': '538'},
    {'ind1': '1',
     'ind2': '0',
     'subfield': [{'#text': 'Austen, Jane,', 'code': 'a'},
      {'#text': '1775-1817.', 'code': 'd'}],
     'tag': '600'},
    {'ind1': '',
     'ind2': '',
     'subfield': {'#text': 'BK', 'code': 'a'},
     'tag': '970'},
    {'ind1': '',
     'ind2': '',
     'subfield': [{'#text': 'MIU', 'code': 'b'},
      {'#text': 'MIU', 'code': 'c'},
      {'#text': '20161111', 'code': 'd'},
      {'#text': 'google', 'code': 's'},
      {'#text': 'mdp.39015014185832', 'code': 'u'},
      {'#text': '1926', 'code': 'y'},
      {'#text': 'pd', 'code': 'r'},
      {'#text': 'add', 'code': 'q'}],
     'tag': '974'}],
   'leader': '00660nam a22002411 4500',
   'provider': {'@id': 'http://dp.la/api/contributor/hathitrust',
    'name': 'HathiTrust'}},
  'provider': {'@id': 'http://dp.la/api/contributor/hathitrust',
   'name': 'HathiTrust'},
  'score': 7.864037,
  'sourceResource': {'@id': 'http://dp.la/api/items/4db8f024727e55971c1d3a864759aa12#sourceResource',
   'creator': ['Warre Cornish, Francis, 1839-1916'],
   'date': {'begin': '1926', 'displayDate': '1926', 'end': '1926'},
   'extent': ['240 p.'],
   'format': ['Electronic resource', 'Language material'],
   'identifier': ['(MiU)000472502',
    'sdr-miu000472502',
    '(OCoLC)6259097',
    '(CaOTULAS)160324501',
    '(RLIN)MIUG86-B63416',
    'Hathi: 000472502'],
   'language': [{'iso639_3': 'eng', 'name': 'English'}],
   'publisher': ['London, Macmillan'],
   'rights': 'Public domain. Learn more at http://www.hathitrust.org/access_use',
   'specType': ['Book'],
   'subject': [{'name': 'Austen, Jane, 1775-1817'}],
   'title': ['Jane Austen'],
   'type': 'text'}},
 {'@context': 'http://dp.la/api/items/context',
  '@id': 'http://dp.la/api/items/37cb1f3c0cbd071175ea2392c9f4d26c',
  '@type': 'ore:Aggregation',
  '_id': 'hathitrust--006154680',
  '_rev': '14-d9a4d8584ee5d9fbfd583882d6d0fb06',
  'admin': {'object_status': 1,
   'sourceResource': {'title': 'Jane Austen'},
   'valid_after_enrich': True,
   'validation_message': None},
  'aggregatedCHO': '#sourceResource',
  'dataProvider': ['University of California'],
  'id': '37cb1f3c0cbd071175ea2392c9f4d26c',
  'ingestDate': '2017-02-15T01:45:39.377668Z',
  'ingestType': 'item',
  'ingestionSequence': 29,
  'isShownAt': 'http://catalog.hathitrust.org/Record/006154680',
  'object': 'https://books.google.com/books/content?id=arUEAQAAIAAJ&printsec=frontcover&img=1&zoom=5&edge=curl',
  'originalRecord': {'_id': '006154680',
   'controlfield': [{'#text': '006154680', 'tag': '001'},
    {'#text': 'MiAaHDL', 'tag': '003'},
    {'#text': '20160112000000.0', 'tag': '005'},
    {'#text': 'm d', 'tag': '006'},
    {'#text': 'cr bn ---auaua', 'tag': '007'},
    {'#text': '861016r19141913enk 00010beng d', 'tag': '008'}],
   'datafield': [{'ind1': '',
     'ind2': '',
     'subfield': {'#text': 'sdr-ucbk.b13922015x', 'code': 'a'},
     'tag': '035'},
    {'ind1': '',
     'ind2': '',
     'subfield': {'#text': 'sdr-nrlfGLAD83924386-B', 'code': 'a'},
     'tag': '035'},
    {'ind1': '',
     'ind2': '',
     'subfield': {'#text': 'GLADN83924386', 'code': 'a'},
     'tag': '035'},
    {'ind1': '',
     'ind2': '',
     'subfield': [{'#text': 'SOI', 'code': 'a'},
      {'#text': 'SOI', 'code': 'c'},
      {'#text': 'CUY', 'code': 'd'}],
     'tag': '040'},
    {'ind1': '',
     'ind2': '',
     'subfield': [{'#text': 'PR4036', 'code': 'a'},
      {'#text': '.W3 1914', 'code': 'b'}],
     'tag': '090'},
    {'ind1': '',
     'ind2': '',
     'subfield': {'#text': '(OCoLC)6437207', 'code': 'a'},
     'tag': '035'},
    {'ind1': '1',
     'ind2': '0',
     'subfield': [{'#text': 'Warre Cornish, Francis,', 'code': 'a'},
      {'#text': '1839-1916.', 'code': 'd'}],
     'tag': '100'},
    {'ind1': '1',
     'ind2': '0',
     'subfield': [{'#text': 'Jane Austen,', 'code': 'a'},
      {'#text': 'by Francis Warre Cornish.', 'code': 'c'}],
     'tag': '245'},
    {'ind1': '0',
     'ind2': '',
     'subfield': [{'#text': 'London,', 'code': 'a'},
      {'#text': 'Macmillan and Co., Ltd.,', 'code': 'b'},
      {'#text': '1914.', 'code': 'c'}],
     'tag': '260'},
    {'ind1': '',
     'ind2': '',
     'subfield': [{'#text': 'xiii, 240 p.', 'code': 'a'},
      {'#text': '19 cm.', 'code': 'c'}],
     'tag': '300'},
    {'ind1': '0',
     'ind2': '',
     'subfield': {'#text': 'English men of letters', 'code': 'a'},
     'tag': '490'},
    {'ind1': '',
     'ind2': '',
     'subfield': {'#text': '"First edition 1913; reprinted 1914"--T.p. verso.',
      'code': 'a'},
     'tag': '500'},
    {'ind1': '',
     'ind2': '',
     'subfield': {'#text': 'Mode of access: Internet.', 'code': 'a'},
     'tag': '538'},
    {'ind1': '',
     'ind2': '',
     'subfield': {'#text': 'BK', 'code': 'a'},
     'tag': '970'},
    {'ind1': '',
     'ind2': '',
     'subfield': [{'#text': 'UC', 'code': 'b'},
      {'#text': 'UCBK', 'code': 'c'},
      {'#text': '20160209', 'code': 'd'},
      {'#text': 'google', 'code': 's'},
      {'#text': 'uc1.c055230618', 'code': 'u'},
      {'#text': '1914', 'code': 'y'},
      {'#text': 'pd', 'code': 'r'},
      {'#text': 'add', 'code': 'q'}],
     'tag': '974'},
    {'ind1': '',
     'ind2': '',
     'subfield': [{'#text': 'UC', 'code': 'b'},
      {'#text': 'NRLF', 'code': 'c'},
      {'#text': '20150531', 'code': 'd'},
      {'#text': 'google', 'code': 's'},
      {'#text': 'uc1.b4101687', 'code': 'u'},
      {'#text': '1914', 'code': 'y'},
      {'#text': 'pd', 'code': 'r'},
      {'#text': 'add', 'code': 'q'}],
     'tag': '974'}],
   'leader': '00813nam a22002291 4500',
   'provider': {'@id': 'http://dp.la/api/contributor/hathitrust',
    'name': 'HathiTrust'}},
  'provider': {'@id': 'http://dp.la/api/contributor/hathitrust',
   'name': 'HathiTrust'},
  'score': 7.7425594,
  'sourceResource': {'@id': 'http://dp.la/api/items/37cb1f3c0cbd071175ea2392c9f4d26c#sourceResource',
   'creator': ['Warre Cornish, Francis, 1839-1916'],
   'date': {'begin': '1914', 'displayDate': '1914', 'end': '1914'},
   'description': ['First edition 1913; reprinted 1914"--T.p. verso.'],
   'extent': ['xiii, 240 p. 19 cm.'],
   'format': ['Electronic resource', 'Language material'],
   'identifier': ['sdr-ucbk.b13922015x',
    'sdr-nrlfGLAD83924386-B',
    'GLADN83924386',
    '(OCoLC)6437207',
    'Hathi: 006154680'],
   'language': [{'iso639_3': 'eng', 'name': 'English'}],
   'publisher': ['London, Macmillan and Co., Ltd'],
   'rights': 'Public domain. Learn more at http://www.hathitrust.org/access_use',
   'specType': ['Book'],
   'title': ['Jane Austen'],
   'type': 'text'}},
 {'@context': 'http://dp.la/api/items/context',
  '@id': 'http://dp.la/api/items/d0cc0455749d7f6c342dc72778bedd3b',
  '@type': 'ore:Aggregation',
  '_id': 'mwdl--digcoll_uuu_11ushsobl/19116',
  '_rev': '2-cebc0e30d95238807f173ed2d40fe820',
  'admin': {'sourceResource': {'title': 'Paula Austen'},
   'valid_after_enrich': False,
   'validation_message': "[u'http://content.lib.utah.edu/utils/getthumbnail/collection/ushsobl/id/19116', u'http://content.lib.utah.edu/utils/getthumbnail/collection/ushsobl/id/19116'] is not of type 'string'"},
  'aggregatedCHO': '#sourceResource',
  'dataProvider': 'Utah State Historical Society',
  'id': 'd0cc0455749d7f6c342dc72778bedd3b',
  'ingestDate': '2017-02-21T23:39:09.719301Z',
  'ingestType': 'item',
  'ingestionSequence': 26,
  'isShownAt': 'http://utah-primoprod.hosted.exlibrisgroup.com/primo_library/libweb/action/dlDisplay.do?vid=MWDL&afterPDS=true&docId=digcoll_uuu_11ushsobl/19116',
  'object': ['http://content.lib.utah.edu/utils/getthumbnail/collection/ushsobl/id/19116',
   'http://content.lib.utah.edu/utils/getthumbnail/collection/ushsobl/id/19116'],
  'originalRecord': {'ID': '4169395',
   'NO': '420564',
   'PrimoNMBib': {'record': {'addata': {'date': '1947',
      'pub': 'Digitized by: J. Willard Marriott Library, University of Utah'},
     'control': {'addsrcrecordid': 'uuu-11-119-1603',
      'originalsourceid': '19116',
      'recordid': 'digcoll_uuu_11ushsobl/19116',
      'sourcedbandrecordid': 'ushsobl',
      'sourceformat': 'Digital Entity',
      'sourceid': 'digcoll_uuu_11',
      'sourcerecordid': 'ushsobl/19116',
      'sourcesystem': 'Other'},
     'delivery': {'delcategory': 'Online Resource', 'institution': 'MWDL'},
     'display': {'creationdate': '1947-1966',
      'creator': 'O. Blaine Larson',
      'description': ['The Larson Studio Collection contains portraits and landscape photographs from Thomas Larson and his son O. Blaine Larson, who operated the Larson Studio in Provo, Utah County, Utah.',
       'See http://history.utah.gov/findAids/C00230/c0230.xml'],
      'format': 'image/jpg',
      'identifier': 'http://content.lib.utah.edu/cdm/ref/collection/ushsobl/id/19116',
      'lds01': 'University of Utah, J. Willard Marriott Library',
      'lds02': 'University of Utah J. Willard Marriott Library CONTENTdm OAI Server Repository',
      'lds03': 'Utah State Historical Society',
      'lds04': 'Larson Studio Negative Collection',
      'lds05': '5 x 7 inches',
      'lds12': 'MSS C 230 Larson Studio Negative Collection',
      'lds17': 'image',
      'lds18': 'Image;StillImage',
      'publisher': 'Digitized by: J. Willard Marriott Library, University of Utah',
      'rights': 'Digital Image © 2011 Utah State Historical Society. All Rights Reserved.',
      'subject': 'Portrait collection; Provo (Utah);',
      'title': 'Paula Austen',
      'type': 'Image'},
     'facets': {'collection': 'Digital Collections',
      'creationdate': '1947-1966',
      'creatorcontrib': 'O. Blaine Larson',
      'format': 'image/jpg',
      'frbrgroupid': '316759646',
      'frbrtype': '6',
      'genre': 'unknown',
      'lfc01': 'Larson Studio Negative Collection',
      'lfc02': 'Utah State Historical Society',
      'lfc03': 'University of Utah, J. Willard Marriott Library',
      'lfc04': 'University of Utah J. Willard Marriott Library CONTENTdm OAI Server Repository',
      'prefilter': 'images',
      'rsrctype': 'images',
      'topic': ['Portrait collection', 'Provo (Utah)'],
      'toplevel': 'online_resources'},
     'links': {'linktorsrc': '$$Tdigcoll_uuu_11_linktores$$DOpen resource in a new window',
      'thumbnail': '$$Tdigcoll_uuu_11_linktothumb$$DSee Thumbnail'},
     'ranking': {'booster1': '1', 'booster2': '1'},
     'search': {'addsrcrecordid': 'uuu-11-119-1603',
      'creationdate': '1947-1966',
      'creatorcontrib': 'O. Blaine Larson',
      'description': ['The Larson Studio Collection contains portraits and landscape photographs from Thomas Larson and his son O. Blaine Larson, who operated the Larson Studio in Provo, Utah County, Utah.',
       'See http://history.utah.gov/findAids/C00230/c0230.xml'],
      'lsr01': 'uuu',
      'lsr02': '11',
      'lsr03': '119',
      'lsr04': '1603',
      'lsr09': 'University of Utah, J. Willard Marriott Library',
      'lsr10': 'University of Utah J. Willard Marriott Library CONTENTdm OAI Server Repository',
      'lsr12': 'Utah State Historical Society',
      'lsr13': 'Larson Studio Negative Collection',
      'recordid': 'digcoll_uuu_11ushsobl/19116',
      'rsrctype': 'images',
      'scope': ['uu', 'mw'],
      'sourceid': 'digcoll_uuu_11',
      'subject': 'Portrait collection; Provo (Utah);',
      'title': 'Paula Austen'},
     'sort': {'author': 'O. Blaine Larson',
      'creationdate': '1947',
      'title': 'Paula Austen'}},
    'xmlns': 'http://www.exlibrisgroup.com/xsd/primo/primo_nm_bib'},
   'RANK': '0.79984784',
   'SEARCH_ENGINE': 'Local Search Engine',
   'SEARCH_ENGINE_TYPE': 'Local Search Engine',
   '_id': 'digcoll_uuu_11ushsobl/19116',
   'collection': {'@id': 'http://dp.la/api/collections/7a42f6613be2ac6393c54d6c36f286a7',
    'id': '7a42f6613be2ac6393c54d6c36f286a7',
    'title': 'Larson Studio Negative Collection'},
   'provider': {'@id': 'http://dp.la/api/contributor/mwdl',
    'name': 'Mountain West Digital Library'},
   'sear:GETIT': {'GetIt1': 'http://content.lib.utah.edu/u?/ushsobl,19116',
    'GetIt2': 'http://sfx7.exlibrisgroup.com/uutah?ctx_ver=Z39.88-2004&ctx_enc=info:ofi/enc:UTF-8&ctx_tim=2017-02-21T15%3A36%3A48IST&url_ver=Z39.88-2004&url_ctx_fmt=infofi/fmt:kev:mtx:ctx&rfr_id=info:sid/primo.exlibrisgroup.com:primo3-Journal-digcoll_uuu_11&rft_val_fmt=info:ofi/fmt:kev:mtx:&rft.genre=&rft.atitle=&rft.jtitle=&rft.btitle=&rft.aulast=&rft.auinit=&rft.auinit1=&rft.auinitm=&rft.ausuffix=&rft.au=&rft.aucorp=&rft.volume=&rft.issue=&rft.part=&rft.quarter=&rft.ssn=&rft.spage=&rft.epage=&rft.pages=&rft.artnum=&rft.issn=&rft.eissn=&rft.isbn=&rft.sici=&rft.coden=&rft_id=info:doi/&rft.object_id=&rft.eisbn=&rft_dat=ushsobl/19116316759646&rft_id=info:oai/&req.language=',
    'deliveryCategory': 'Online Resource'},
   'sear:LINKS': {'sear:linktorsrc': 'http://content.lib.utah.edu/u?/ushsobl,19116',
    'sear:thumbnail': ['http://content.lib.utah.edu/utils/getthumbnail/collection/ushsobl/id/19116',
     'http://content.lib.utah.edu/utils/getthumbnail/collection/ushsobl/id/19116']}},
  'provider': {'@id': 'http://dp.la/api/contributor/mwdl',
   'name': 'Mountain West Digital Library'},
  'score': 7.7425594,
  'sourceResource': {'@id': 'http://dp.la/api/items/d0cc0455749d7f6c342dc72778bedd3b#sourceResource',
   'collection': {'@id': 'http://dp.la/api/collections/7a42f6613be2ac6393c54d6c36f286a7',
    'id': '7a42f6613be2ac6393c54d6c36f286a7',
    'title': 'Larson Studio Negative Collection'},
   'creator': 'O. Blaine Larson',
   'date': {'begin': '1947', 'displayDate': '1947-1966', 'end': '1966'},
   'description': ['The Larson Studio Collection contains portraits and landscape photographs from Thomas Larson and his son O. Blaine Larson, who operated the Larson Studio in Provo, Utah County, Utah.',
    'See http://history.utah.gov/findAids/C00230/c0230.xml'],
   'extent': '5 x 7 inches',
   'identifier': 'http://content.lib.utah.edu/u?/ushsobl,19116',
   'isPartOf': 'Larson Studio Negative Collection',
   'rights': 'Digital Image © 2011 Utah State Historical Society. All Rights Reserved.',
   'stateLocatedIn': [{'name': 'UT'}],
   'subject': [{'name': 'Portrait collection'}, {'name': 'Provo (Utah)'}],
   'title': 'Paula Austen',
   'type': 'image'}}]

Above we checked to see if the 'sourceResource' dictionary has a particular key, which allows us to skip over electronic resources. And notice how we have a couple different formats for state names already! The first four list the full state, while the last item lists an abbreviation. This can get very tricky very quickly, and it points to why data cleaning is one of the most important tasks you do as a programming humanist. If we were interested in working across these dates, but they are formatted inconsistently, we would have to clean them up.

Maybe add some more stuff here

API's frequently limit the number of requests you can make to their service during a particular time period. For example, Twitter limits the number of requests you can make to 15 requests per 15 minutes. This ensures that you don't accidentally blow up their system with requests while you're learning, but it also helps to ensure that people are using their service for legitimate scripts rather than incessant spam bots.

That's the easy way to do things. When you're interested in using the data provided by a service, you should always look to see if they have an API. And whenever there is an API, it is worth looking to see whether there is also a wrapper for you to use. There are often different wrappers for different programming languages as well, but Python is a pretty common and popular language. So you'll often find someone else's work that you can build on.

Before we move on, I want to give just a taste of how to do things the hard way, if you didn't have a wrapper for this particular API. There are a few things you need to know:

  • API Endpoint: the base URL that will be responding to your requests. Think of API's like data that live at particular URLS. If you've ever looked at the URL for a page you're in and seen something like shoppingbaseurl.com/q?=shoes&type=mens&cost=expensive, you're using something similar to an API. Basically, using an API entails constructing a URL that points to exactly the data you want. The API consists of the baseurl that gets you to the root/heart/doorway of the API, and then you give params to nuance your search/request.
  • Search Parameters (Params for Short): the particular things you send with your request to get back the information you want. Remember how Python dictionaries used key: value pairs? We'll do the same thing here. In the case of the previous example, you have three params: a search query, a type, and a cost. If this were a Python dictionary, we might write that as {'search': 'shoes', 'type': 'mens', 'cost': 'expensive'}.
  • API key: we've already covered this, but the API key is what authenticates you when the API you're using so that they will allow you to use it. Sometimes, you simply pass your key as an additional search paramater. Other times, you might have to authenticate with a separate service (like OAuth).

First, let's import the Python libraries that we'll need:

In [20]:
import requests

'requests' is a library that allows you to make requests to an API. Now we'll store our API endpoint so that we know where we will be making requests to. In this case, we can find out API endpoint by looking at DPLA's great documentation. Not every API provides you with such great guides to their work, so thanks to the wonderful people at DPLA for making this information available!

In [21]:
endpoint = 'https://api.dp.la/v2/items'

Now we will set up our search params. If we're still working in the same terminal session, we should have our api_key stored in 'my_api_key'. And it's important to note that not just any search parameters would work. The API documentation specifies which pieces are allowed. If we sent over 'how_great_is_ethan' as a part of the API, it would not function.

In [22]:
params = {
    'api_key': my_api_key,
    'q': 'Austin, Texas',
    }

I've set up a basic search here for information about Austin, Texas, and I've given the params my personal api key to authenticate me. I've also specified that I want to get items back. The handy thing about the 'requests' library is that will mash all this together for us in a valid URL.

In [23]:
requested_with_wrapper = dpla_connection
requested_the_hard_way = requests.get(endpoint, params)
requested_the_hard_way.status_code
requested_the_hard_way.url
Out[23]:
'https://api.dp.la/v2/items?api_key=1d622b9c73fedc400aeb278c0c5553ef&q=Austin%2C+Texas'

You might be more familiar with a 404 code, which is what you get if you go to a webpage that doesn't exist. A 200 code is one that we don't often see, because it means that things went OK! For the sake of camparison, I've pulled in our old connection that used the wrapper and renamed it alongside our request done from scratch.

Why is this harder?

For one, we had to find out the correct API endpoint and parameters. Sometimes this is easier said than done. For example, my first attempt at using the API actually failed - I assumed that 'items' was part of the parameters rather than the endpoint, because you can actually get different types of things beyond items - collections, for example. Let's take a look at the things we could do with our 'requested_the_hard_way' object:

res.apparent_encoding      res.elapsed                res.is_redirect            res.ok                     res.status_code
res.close(                 res.encoding               res.iter_content(          res.raise_for_status(      res.text
res.connection             res.headers                res.iter_lines(            res.raw                    res.url
res.content                res.history                res.json(                  res.reason
res.cookies                res.is_permanent_redirect  res.links                  res.request

As we can see, there's nothing here that actually relates to the DPLA yet - all we have are actions that relate to the API - ways to check what kind of data we asked for, where asked for it, and how. The data we got in response is here, though, in two places - .json and .text. The latter gives a long string version of the response, while .json gives us a formatted version of the data. JSON stands for JavaScript Object Notation, and we can interact with it in ways similar to a Python dictionary.

In [24]:
requested_the_hard_way.json()['count']
Out[24]:
71965

Our result got 71575 results! Let's take a closer look.

In [25]:
requested_the_hard_way.json()['docs']
Out[25]:
[{'@context': 'http://dp.la/api/items/context',
  '@id': 'http://dp.la/api/items/c2db8605123c7b7d396c1e3b164d1e51',
  '@type': 'ore:Aggregation',
  '_id': 'smithsonian--http://collections.si.edu/search/results.htm?q=record_ID%3Anasm_A19960136000&repo=DPLA',
  '_rev': '14-6a25eea607f51f7dd9de256bf1dc931f',
  'admin': {'sourceResource': {'title': 'Austin'}},
  'aggregatedCHO': '#sourceResource',
  'dataProvider': 'National Air and Space Museum',
  'id': 'c2db8605123c7b7d396c1e3b164d1e51',
  'ingestDate': '2017-04-07T07:02:13.252984Z',
  'ingestType': 'item',
  'ingestionSequence': 29,
  'isShownAt': 'http://collections.si.edu/search/results.htm?q=record_ID%3Anasm_A19960136000&repo=DPLA',
  'object': 'https://airandspace.si.edu/webimages/collections/thumbnails/a19960136000cp04.jpg',
  'originalRecord': {'_id': 'nasm_A19960136000',
   'collection': [{'@id': 'http://dp.la/api/collections/c349831fbbb138b7176675dc83b12460',
     'id': 'c349831fbbb138b7176675dc83b12460',
     'title': 'National Air and Space Museum Collection'}],
   'descriptiveNonRepeating': {'data_source': 'National Air and Space Museum',
    'online_media': {'@mediaCount': '1',
     'media': {'#text': 'https://airandspace.si.edu/webimages/collections/full/a19960136000cp04.jpg',
      '@idsId': 'https://airandspace.si.edu/webimages/collections/full/a19960136000cp04.jpg',
      '@thumbnail': 'https://airandspace.si.edu/webimages/collections/thumbnails/a19960136000cp04.jpg',
      '@type': 'Images'}},
    'record_ID': 'nasm_A19960136000',
    'record_link': 'http://collections.si.edu/search/results.htm?q=record_ID%3Anasm_A19960136000&repo=DPLA',
    'title': {'#text': 'Austin', '@label': 'Title'},
    'title_sort': 'AUSTIN',
    'unit_code': 'NASM'},
   'freetext': {'dataSource': {'#text': 'National Air and Space Museum',
     '@label': 'Data Source'},
    'identifier': {'#text': 'A19960136000', '@label': 'Inventory Number'},
    'name': {'#text': 'Muse Air', '@label': 'Sponsor'},
    'notes': [{'#text': 'Muse Air makes flying beautiful AUSTIN. Color photographic print advertising air travel to Austin, Texas. A white paper sculpture of the capital building on a blue background. Full text: at top in white script and serif font, "Muse Air makes flying beautiful." At bottom in large white serif font, "AUSTIN."',
      '@label': 'Physical Description'},
     {'#text': 'Fly Now: The National Air and Space Museum Poster Collection',
      '@label': 'Summary'},
     {'#text': 'Throughout their history, posters have been a significant means of mass communication, often with striking visual effect. Wendy Wick Reaves, the Smithsonian Portrait Gallery Curator of Prints and Drawings, comments that "sometimes a pictorial poster is a decorative masterpiece-something I can\'t walk by without a jolt of aesthetic pleasure. Another might strike me as extremely clever advertising … But collectively, these \'pictures of persuasion,\' as we might call them, offer a wealth of art, history, design, and popular culture for us to understand. The poster is a familiar part of our world, and we intuitively understand its role as propaganda, promotion, announcement, or advertisement."',
      '@label': 'Summary'},
     {'#text': "Reaves' observations are especially relevant for the impressive array of aviation posters in the National Air and Space Museum's 1300+ artifact collection. Quite possibly the largest publicly-held collection of its kind in the United States, the National Air and Space Museum's posters focus primarily on advertising for aviation-related products and activities. Among other areas, the collection includes 19th-century ballooning exhibition posters, early 20th-century airplane exhibition and meet posters, and twentieth-century airline advertisements.",
      '@label': 'Summary'},
     {'#text': 'The posters in the collection represent printing technologies that include original lithography, silkscreen, photolithography, and computer-generated imagery. The collection is significant both for its aesthetic value and because it is a unique representation of the cultural, commercial and military history of aviation. The collection represents an intense interest in flight, both public and private, during a significant period of its technological and social development.',
      '@label': 'Summary'},
     {'#text': 'Copyright Disclosure for Orphaned Works', '@label': 'Summary'},
     {'#text': "Whenever possible, the museum provides factual information about copyright owners and related matters in its records and other texts related to the collections. For many of the images in this collection, some of which were created for or by corporate entities that no longer exist, the museum does not own any copyrights. Therefore, it generally does not grant or deny permission to copy, distribute or otherwise use material in this collection. If identified, permission and possible fees may be required from the copyright owner independently of the museum. It is the user's obligation to determine and satisfy copyright or other use restrictions when copying, distributing or otherwise using materials found in the museum's collections. Transmission or reproduction of protected materials beyond that allowed by fair use requires the written permission of the copyright owners. Users must make their own assessments of rights in light of their intended use.",
      '@label': 'Summary'},
     {'#text': "If you have any more information about an item you've seen in the Fly Now: The National Air and Space Museum Poster Collection, or if you are a copyright owner and believe we have not properly attributed your work to you or have used it without permission, we want to hear from you. Please contact [email protected] with your contact information and a link to the relevant content.",
      '@label': 'Summary'},
     {'#text': "View more information about the Smithsonian's general copyright policies at http://www.si.edu/termsofuse",
      '@label': 'Summary'}],
    'objectRights': {'#text': 'Do not reproduce without permission from the Smithsonian Institution, National Air and Space Museum',
     '@label': 'Rights'},
    'objectType': {'#text': 'ART-Posters, Original Art Quality',
     '@label': 'Type'},
    'physicalDescription': [{'#text': 'Poster, Advertising, Commercial Aviation',
      '@label': 'Medium'},
     {'#text': '2-D - Unframed (H x W): 81.3 x 61cm (32 x 24 in.)',
      '@label': 'Dimensions'}],
    'place': {'#text': 'United States of America',
     '@label': 'Country of Origin'},
    'setName': {'#text': 'National Air and Space Museum Collection',
     '@label': 'See more items in'}},
   'indexedStructured': {'geoLocation': {'L1': {'#text': 'Oceania',
      '@type': 'Continent'},
     'L2': {'#text': 'United States', '@type': 'Country'}},
    'name': 'Muse Air',
    'object_type': ['Posters', 'Works of art'],
    'online_media_type': 'Images',
    'place': 'United States of America',
    'usage_flag': ['Aviation', 'Commercial', 'Art']},
   'provider': {'@id': 'http://dp.la/api/contributor/smithsonian',
    'name': 'Smithsonian Institution'}},
  'provider': {'@id': 'http://dp.la/api/contributor/smithsonian',
   'name': 'Smithsonian Institution'},
  'score': 6.5318956,
  'sourceResource': {'@id': 'http://dp.la/api/items/c2db8605123c7b7d396c1e3b164d1e51#sourceResource',
   'collection': [{'@id': 'http://dp.la/api/collections/c349831fbbb138b7176675dc83b12460',
     'id': 'c349831fbbb138b7176675dc83b12460',
     'title': 'National Air and Space Museum Collection'}],
   'description': ['Muse Air makes flying beautiful AUSTIN. Color photographic print advertising air travel to Austin, Texas. A white paper sculpture of the capital building on a blue background. Full text: at top in white script and serif font, "Muse Air makes flying beautiful." At bottom in large white serif font, "AUSTIN.',
    'Fly Now: The National Air and Space Museum Poster Collection',
    'Throughout their history, posters have been a significant means of mass communication, often with striking visual effect. Wendy Wick Reaves, the Smithsonian Portrait Gallery Curator of Prints and Drawings, comments that "sometimes a pictorial poster is a decorative masterpiece-something I can\'t walk by without a jolt of aesthetic pleasure. Another might strike me as extremely clever advertising … But collectively, these \'pictures of persuasion,\' as we might call them, offer a wealth of art, history, design, and popular culture for us to understand. The poster is a familiar part of our world, and we intuitively understand its role as propaganda, promotion, announcement, or advertisement.',
    "Reaves' observations are especially relevant for the impressive array of aviation posters in the National Air and Space Museum's 1300+ artifact collection. Quite possibly the largest publicly-held collection of its kind in the United States, the National Air and Space Museum's posters focus primarily on advertising for aviation-related products and activities. Among other areas, the collection includes 19th-century ballooning exhibition posters, early 20th-century airplane exhibition and meet posters, and twentieth-century airline advertisements.",
    'The posters in the collection represent printing technologies that include original lithography, silkscreen, photolithography, and computer-generated imagery. The collection is significant both for its aesthetic value and because it is a unique representation of the cultural, commercial and military history of aviation. The collection represents an intense interest in flight, both public and private, during a significant period of its technological and social development.',
    'Copyright Disclosure for Orphaned Works',
    "Whenever possible, the museum provides factual information about copyright owners and related matters in its records and other texts related to the collections. For many of the images in this collection, some of which were created for or by corporate entities that no longer exist, the museum does not own any copyrights. Therefore, it generally does not grant or deny permission to copy, distribute or otherwise use material in this collection. If identified, permission and possible fees may be required from the copyright owner independently of the museum. It is the user's obligation to determine and satisfy copyright or other use restrictions when copying, distributing or otherwise using materials found in the museum's collections. Transmission or reproduction of protected materials beyond that allowed by fair use requires the written permission of the copyright owners. Users must make their own assessments of rights in light of their intended use.",
    "If you have any more information about an item you've seen in the Fly Now: The National Air and Space Museum Poster Collection, or if you are a copyright owner and believe we have not properly attributed your work to you or have used it without permission, we want to hear from you. Please contact [email protected] with your contact information and a link to the relevant content.",
    "View more information about the Smithsonian's general copyright policies at http://www.si.edu/termsofuse"],
   'extent': ['2-D - Unframed (H x W): 81.3 x 61cm (32 x 24 in.)'],
   'format': 'Poster, Advertising, Commercial Aviation',
   'rights': ['Do not reproduce without permission from the Smithsonian Institution, National Air and Space Museum'],
   'spatial': [{'country': 'United States', 'name': 'United States'}],
   'stateLocatedIn': [{'name': 'Washington, D.C.'}],
   'subject': [{'name': 'Muse Air'}],
   'title': 'Austin',
   'type': 'image'}},
 {'@context': 'http://dp.la/api/items/context',
  '@id': 'http://dp.la/api/items/82ec8de247bafa3089b1b7e96ab78807',
  '_id': '82ec8de247bafa3089b1b7e96ab78807',
  'aggregatedCHO': '#sourceResource',
  'dataProvider': 'National Archives at College Park - Still Pictures',
  'id': '82ec8de247bafa3089b1b7e96ab78807',
  'ingestDate': '2016-04-13',
  'ingestType': 'item',
  'ingestionSequence': 999999,
  'isShownAt': 'http://catalog.archives.gov/id/24068072',
  'object': 'https://catalog.archives.gov/OpaAPI/media/24068072/opa-renditions/thumbnails/207-DP-10011U_Austin03699.jpg-thumb.jpg',
  'originalRecord': 'http://ldp.dp.la/ldp/original_record/82ec8de247bafa3089b1b7e96ab78807.json',
  'provider': {'@id': 'http://dp.la/api/contributor/nara',
   'name': 'National Archives and Records Administration'},
  'score': 5.112093,
  'sourceResource': {'@id': 'http://dp.la/api/items/82ec8de247bafa3089b1b7e96ab78807#sourceResource',
   'collection': [{'@id': '_:1540686b5ad282',
     'id': '_:1540686b5ad282',
     'title': ['General Records of the Department of Housing and Urban Development']}],
   'date': [{'displayDate': '2007-04-19'}],
   'description': ['Photographer: David Valdez--HUD Photo Creation Date: 4/19/2007'],
   'relation': ["General Records of the Department of Housing and Urban Development; Photographs Documenting the Secretary's Headquarters and Field Activities, and Agency Officials and Events; Cities: Austin, Texas"],
   'rights': 'Unrestricted',
   'title': ['Cities: Austin, Texas']}},
 {'@context': 'http://dp.la/api/items/context',
  '@id': 'http://dp.la/api/items/fb72e06846def6880327561faf669cc6',
  '_id': 'fb72e06846def6880327561faf669cc6',
  'aggregatedCHO': '#sourceResource',
  'dataProvider': 'National Archives at College Park - Still Pictures',
  'id': 'fb72e06846def6880327561faf669cc6',
  'ingestDate': '2016-04-13',
  'ingestType': 'item',
  'ingestionSequence': 999999,
  'isShownAt': 'http://catalog.archives.gov/id/544443',
  'object': 'https://catalog.archives.gov/OpaAPI/media/544443/opa-renditions/thumbnails/05-2491a.gif-thumb.jpg',
  'originalRecord': 'http://ldp.dp.la/ldp/original_record/fb72e06846def6880327561faf669cc6.json',
  'provider': {'@id': 'http://dp.la/api/contributor/nara',
   'name': 'National Archives and Records Administration'},
  'score': 5.112093,
  'sourceResource': {'@id': 'http://dp.la/api/items/fb72e06846def6880327561faf669cc6#sourceResource',
   'collection': [{'@id': '_:1540c4c14723b4',
     'id': '_:1540c4c14723b4',
     'title': ['Records of the Environmental Protection Agency']}],
   'contributor': ['Reaves, Bill, 1934-'],
   'creator': ['Environmental Protection Agency. 12/2/1970-'],
   'date': [{'displayDate': '1972-05'}],
   'identifier': ['Agency-Assigned Identifier: 033/30/001950',
    'NAIL Control Number: NWDNS-412-DA-1950'],
   'relation': ["Records of the Environmental Protection Agency; DOCUMERICA: The Environmental Protection Agency's Program to Photographically Document Subjects of Environmental Concern"],
   'rights': 'Unrestricted',
   'spatial': [{'name': 'Austin, Lake (Tex.)'}],
   'subject': [{'name': 'Environmental protection'}],
   'title': ['TEXAS--NEAR LAKE AUSTIN']}},
 {'@context': 'http://dp.la/api/items/context',
  '@id': 'http://dp.la/api/items/8306033e8e414549d68041a74eec716e',
  '_id': '8306033e8e414549d68041a74eec716e',
  'aggregatedCHO': '#sourceResource',
  'dataProvider': 'National Archives at College Park - Still Pictures',
  'id': '8306033e8e414549d68041a74eec716e',
  'ingestDate': '2016-04-13',
  'ingestType': 'item',
  'ingestionSequence': 999999,
  'isShownAt': 'http://catalog.archives.gov/id/544440',
  'object': 'https://catalog.archives.gov/OpaAPI/media/544440/opa-renditions/thumbnails/05-2488a.gif-thumb.jpg',
  'originalRecord': 'http://ldp.dp.la/ldp/original_record/8306033e8e414549d68041a74eec716e.json',
  'provider': {'@id': 'http://dp.la/api/contributor/nara',
   'name': 'National Archives and Records Administration'},
  'score': 5.112093,
  'sourceResource': {'@id': 'http://dp.la/api/items/8306033e8e414549d68041a74eec716e#sourceResource',
   'collection': [{'@id': '_:154078b7c1147',
     'id': '_:154078b7c1147',
     'title': ['Records of the Environmental Protection Agency']}],
   'contributor': ['Reaves, Bill, 1934-'],
   'creator': ['Environmental Protection Agency. 12/2/1970-'],
   'date': [{'displayDate': '1972-05'}],
   'identifier': ['Agency-Assigned Identifier: 033/27/001947',
    'NAIL Control Number: NWDNS-412-DA-1947'],
   'relation': ["Records of the Environmental Protection Agency; DOCUMERICA: The Environmental Protection Agency's Program to Photographically Document Subjects of Environmental Concern"],
   'rights': 'Unrestricted',
   'spatial': [{'name': 'Austin, Lake (Tex.)'}],
   'subject': [{'name': 'Environmental protection'}],
   'title': ['TEXAS--NEAR LAKE AUSTIN']}},
 {'@context': 'http://dp.la/api/items/context',
  '@id': 'http://dp.la/api/items/af110971cabf4af78a00d16bdb8e9273',
  '@type': 'ore:Aggregation',
  '_id': 'nypl--510d47d9-b395-a3d9-e040-e00a18064a99',
  '_rev': '9-15e5547229496911854954734aad62be',
  'admin': {'object_status': 1,
   'sourceResource': {'title': 'Aviation Cadets. Austin, Texas'},
   'valid_after_enrich': True,
   'validation_message': None},
  'aggregatedCHO': '#sourceResource',
  'dataProvider': 'The Miriam and Ira D. Wallach Division of Art, Prints and Photographs: Photography Collection. The New York Public Library',
  'id': 'af110971cabf4af78a00d16bdb8e9273',
  'ingestDate': '2017-01-17T04:32:50.436096Z',
  'ingestType': 'item',
  'ingestionSequence': 21,
  'isShownAt': 'http://digitalcollections.nypl.org/items/510d47d9-b395-a3d9-e040-e00a18064a99',
  'object': 'http://images.nypl.org/index.php?id=115690&t=t',
  'originalRecord': {'_id': '510d47d9-b395-a3d9-e040-e00a18064a99',
   'collection': {'@id': 'http://dp.la/api/collections/fb7938da1e388efaecb99e643497420b',
    'id': 'fb7938da1e388efaecb99e643497420b'},
   'genre': {'#text': 'Photographs',
    'authority': 'lcsh',
    'valueURI': 'http://id.loc.gov/authorities/subjects/sh85101195'},
   'identifier': [{'#text': '187',
     'displayLabel': 'Hades Collection Guide ID (legacy)',
     'type': 'local_hades_collection'},
    {'#text': '133976',
     'displayLabel': 'Hades struc ID (legacy)',
     'type': 'local_hades'},
    {'#text': '349e54d0-c615-012f-7b83-58d385a7bc34', 'type': 'uuid'}],
   'location': [{'physicalLocation': [{'#text': 'nn',
       'authority': 'marcorg',
       'type': 'repository'},
      {'#text': 'The Miriam and Ira D. Wallach Division of Art, Prints and Photographs: Photography Collection',
       'type': 'division'},
      {'#text': 'Wallach Division: Photography Collection',
       'type': 'division_short_name'},
      {'#text': 'PHG', 'type': 'code'}]},
    {'physicalLocation': [{'#text': 'The Miriam and Ira D. Wallach Division of Art, Prints and Photographs: Photography Collection',
       'type': 'division'},
      {'#text': 'Wallach Division: Photography Collection',
       'type': 'division_short_name'},
      {'#text': 'PHG', 'type': 'code'}]}],
   'note': {'#text': '[Handwritten on reverse:] "Aviation Cadets in training [?] at Austin, Texas. Cadets registering at the ground school."',
    'type': 'content'},
   'originInfo': {'dateCreated': [{'#text': '1860',
      'encoding': 'w3cdtf',
      'keyDate': 'yes',
      'point': 'start',
      'qualifier': 'approximate'},
     {'#text': '1920',
      'encoding': 'w3cdtf',
      'point': 'end',
      'qualifier': 'approximate'}]},
   'physicalDescription': {'extent': '16.5 x 22 cm'},
   'provider': {'@id': 'http://dp.la/api/contributor/nypl',
    'name': 'The New York Public Library'},
   'relatedItem': {'identifier': [{'#text': '2529f7f0-c615-012f-08e1-58d385a7bc34',
      'type': 'uuid'},
     {'#text': '133467', 'type': 'local_hades'}],
    'relatedItem': {'identifier': [{'#text': '8568ccd0-c614-012f-1d74-58d385a7bc34',
       'type': 'uuid'},
      {'#text': '251100', 'type': 'local_hades'}],
     'relatedItem': {'identifier': [{'#text': '1b800a10-c614-012f-fa4a-58d385a7bc34',
        'type': 'uuid'},
       {'#text': '251099', 'type': 'local_hades'}],
      'relatedItem': {'identifier': [{'#text': '26818d00-c611-012f-a212-58d385a7bc34',
         'type': 'uuid'},
        {'#text': '204711 local_hades_collection', 'type': 'local_hades'}],
       'titleInfo': {'title': '"The Pageant of America" Collection'},
       'type': 'host'},
      'titleInfo': {'title': 'v.7 - In defense of liberty'},
      'type': 'host'},
     'titleInfo': {'title': '(unpublished photographs)'},
     'type': 'host'},
    'titleInfo': {'title': 'World War : Aviation'},
    'type': 'host'},
   'rightsStatementURI': None,
   'schemaLocation': 'http://www.loc.gov/mods/v3 http://www.loc.gov/standards/mods/v3/mods-3-4.xsd',
   'titleInfo': {'supplied': 'no',
    'title': 'Aviation Cadets. Austin, Texas.',
    'usage': 'primary'},
   'tmp_high_res_link': None,
   'tmp_image_id': '115690',
   'tmp_item_link': 'http://digitalcollections.nypl.org/items/510d47d9-b395-a3d9-e040-e00a18064a99',
   'tmp_rights_statement': 'The copyright and related rights status of this item has been reviewed by The New York Public Library, but we were unable to make a conclusive determination as to the copyright status of the item. You are free to use this Item in any way that is permitted by the copyright and related rights legislation that applies to your use.',
   'typeOfResource': 'still image',
   'version': '3.4'},
  'provider': {'@id': 'http://dp.la/api/contributor/nypl',
   'name': 'The New York Public Library'},
  'score': 5.112093,
  'sourceResource': {'@id': 'http://dp.la/api/items/af110971cabf4af78a00d16bdb8e9273#sourceResource',
   'collection': {'@id': 'http://dp.la/api/collections/fb7938da1e388efaecb99e643497420b',
    'id': 'fb7938da1e388efaecb99e643497420b',
    'title': 'World War : Aviation'},
   'date': {'begin': '1860', 'displayDate': '1860 - 1920', 'end': '1920'},
   'description': '[Handwritten on reverse:] "Aviation Cadets in training [?] at Austin, Texas. Cadets registering at the ground school.',
   'extent': '16.5 x 22 cm',
   'relation': 'World War : Aviation',
   'rights': 'The copyright and related rights status of this item has been reviewed by The New York Public Library, but we were unable to make a conclusive determination as to the copyright status of the item. You are free to use this Item in any way that is permitted by the copyright and related rights legislation that applies to your use.',
   'stateLocatedIn': [{'name': 'New York'}],
   'subject': [{'name': 'Photographs'}],
   'title': 'Aviation Cadets. Austin, Texas',
   'type': 'image'}},
 {'@context': 'http://dp.la/api/items/context',
  '@id': 'http://dp.la/api/items/6596bcccdb4cbe138951b3be838ceb5a',
  '@type': 'ore:Aggregation',
  '_id': 'texas--info:ark/67531/metapth435748',
  '_rev': '14-39ccde122e99cdd3bd530eb1c1a27081',
  'admin': {'sourceResource': {'title': '[Postcard of the Capitol in Austin, Texas]'}},
  'aggregatedCHO': '#sourceResource',
  'dataProvider': ['Sam Rayburn House Museum'],
  'id': '6596bcccdb4cbe138951b3be838ceb5a',
  'ingestDate': '2017-04-04T20:14:49.637775Z',
  'ingestType': 'item',
  'ingestionSequence': 25,
  'isShownAt': 'https://texashistory.unt.edu/ark:/67531/metapth435748/',
  'object': 'https://texashistory.unt.edu/ark:/67531/metapth435748/thumbnail/',
  'originalRecord': {'collection': {'@id': 'http://dp.la/api/collections/7df77b687b361383f125c99e1d7be944',
    'description': '',
    'id': '7df77b687b361383f125c99e1d7be944',
    'title': 'Sam Rayburn House Museum'},
   'header': {'datestamp': '2014-07-17T20:17:34Z',
    'identifier': 'info:ark/67531/metapth435748',
    'setSpec': ['partner:SRH', 'collection:SG13', 'access_rights:public']},
   'id': 'info:ark/67531/metapth435748',
   'metadata': {'untl:metadata': {'untl:collection': 'SG13',
     'untl:coverage': [{'#text': 'United States - Texas - Travis County - Austin',
       'qualifier': 'placeName'},
      {'#text': 'United States - Texas - Fannin County - Windom',
       'qualifier': 'placeName'},
      {'#text': 'mod-tim', 'qualifier': 'timePeriod'},
      {'#text': '1913-04', 'qualifier': 'date'}],
     'untl:date': {'#text': '1913-04', 'qualifier': 'creation'},
     'untl:description': [{'#text': "Postcard of the Capitol in Austin, Texas. Handwritten note on the back of the postcard is addressed to Lou Rayburn and tells of the author's time in Austin.",
       'qualifier': 'content'},
      {'#text': '1 postcard : b 14 x 9 cm.', 'qualifier': 'physical'}],
     'untl:format': 'image',
     'untl:identifier': [{'#text': 'https://texashistory.unt.edu/ark:/67531/metapth435748/',
       'qualifier': 'itemURL'},
      {'#text': 'SRH_I72-175', 'qualifier': 'LOCAL-CONT-NO'},
      {'#text': 'https://texashistory.unt.edu/ark:/67531/metapth435748/thumbnail/',
       'qualifier': 'thumbnailURL'},
      {'#text': 'ark:/67531/metapth435748', 'qualifier': 'ARK'}],
     'untl:institution': 'SRH',
     'untl:language': 'eng',
     'untl:meta': [{'#text': 'False', 'qualifier': 'hidden'},
      {'#text': 'lcarter', 'qualifier': 'metadataCreator'},
      {'#text': 'PTH', 'qualifier': 'system'},
      {'#text': 'ark:/67531/metapth435748', 'qualifier': 'ark'},
      {'#text': '2014-07-17, 20:17:34', 'qualifier': 'metadataCreationDate'}],
     'untl:primarySource': '1',
     'untl:resourceType': 'image_postcard',
     'untl:rights': {'#text': 'The contents of The Portal to Texas History (digital content including images, text, and sound and video recordings) are made publicly available by the collection-holding partners for use in research, teaching, and private study. For the full terms of use, see https://texashistory.unt.edu/terms-of-use/',
      'qualifier': 'statement'},
     'untl:subject': [{'#text': 'Rayburn, Sam, 1882-1961.',
       'qualifier': 'LCSH'},
      {'#text': 'state capitols', 'qualifier': 'KWD'},
      {'#text': 'Rayburn, Lucinda (Lou)', 'qualifier': 'named_person'},
      {'#text': 'Architecture - Landmarks - Texas State Capitol',
       'qualifier': 'UNTL-BS'},
      {'#text': 'Government and Law - State Capitols',
       'qualifier': 'UNTL-BS'}],
     'untl:title': {'#text': '[Postcard of the Capitol in Austin, Texas]',
      'qualifier': 'officialtitle'},
     'xmlns:untl': 'http://digital2.library.unt.edu/untl/'}},
   'provider': {'@id': 'http://dp.la/api/contributor/the_portal_to_texas_history',
    'name': 'The Portal to Texas History'}},
  'provider': {'@id': 'http://dp.la/api/contributor/the_portal_to_texas_history',
   'name': 'The Portal to Texas History'},
  'score': 5.112093,
  'sourceResource': {'@id': 'http://dp.la/api/items/6596bcccdb4cbe138951b3be838ceb5a#sourceResource',
   'collection': {'@id': 'http://dp.la/api/collections/7df77b687b361383f125c99e1d7be944',
    'description': '',
    'id': '7df77b687b361383f125c99e1d7be944',
    'title': 'Sam Rayburn House Museum'},
   'date': {'begin': '1913-04', 'displayDate': '1913-04', 'end': '1913-04'},
   'description': ["Postcard of the Capitol in Austin, Texas. Handwritten note on the back of the postcard is addressed to Lou Rayburn and tells of the author's time in Austin.",
    '1 postcard : b 14 x 9 cm.'],
   'format': 'Image',
   'identifier': ['itemURL: https://texashistory.unt.edu/ark:/67531/metapth435748/',
    'LOCAL-CONT-NO: SRH_I72-175',
    'thumbnailURL: https://texashistory.unt.edu/ark:/67531/metapth435748/thumbnail/',
    'ARK: ark:/67531/metapth435748'],
   'language': [{'iso639_3': 'eng', 'name': 'English'}],
   'rights': 'The contents of The Portal to Texas History (digital content including images, text, and sound and video recordings) are made publicly available by the collection-holding partners for use in research, teaching, and private study. For the full terms of use, see https://texashistory.unt.edu/terms-of-use/',
   'spatial': [{'city': 'Austin',
     'coordinates': '30.26715, -97.74306',
     'country': 'United States',
     'county': 'Travis County',
     'name': 'United States - Texas - Travis County - Austin',
     'state': 'Texas'},
    {'city': 'Windom',
     'coordinates': '33.56538, -95.99914',
     'country': 'United States',
     'county': 'Fannin County',
     'name': 'United States - Texas - Fannin County - Windom',
     'state': 'Texas'}],
   'subject': [{'name': 'Rayburn, Sam, 1882-1961'},
    {'name': 'State capitols'},
    {'name': 'Rayburn, Lucinda (Lou)'},
    {'name': 'Architecture'},
    {'name': 'Landmarks'},
    {'name': 'Texas State Capitol'},
    {'name': 'Government and Law'},
    {'name': 'State Capitols'}],
   'title': ['[Postcard of the Capitol in Austin, Texas]'],
   'type': 'image'}},
 {'@context': 'http://dp.la/api/items/context',
  '@id': 'http://dp.la/api/items/a6579158177091a4733a23cf2c3cdd85',
  '@type': 'ore:Aggregation',
  '_id': 'texas--info:ark/67531/metapth28771',
  '_rev': '14-da33a606a56386ceef4805a410f4fe71',
  'admin': {'sourceResource': {'title': '["Texas Special" departing Austin]'}},
  'aggregatedCHO': '#sourceResource',
  'dataProvider': ['Museum of the American Railroad'],
  'id': 'a6579158177091a4733a23cf2c3cdd85',
  'ingestDate': '2017-04-04T19:25:11.860098Z',
  'ingestType': 'item',
  'ingestionSequence': 25,
  'isShownAt': 'https://texashistory.unt.edu/ark:/67531/metapth28771/',
  'object': 'https://texashistory.unt.edu/ark:/67531/metapth28771/thumbnail/',
  'originalRecord': {'collection': {'@id': 'http://dp.la/api/collections/4e31bbfaacdc3720c41906879d11226b',
    'description': '',
    'id': '4e31bbfaacdc3720c41906879d11226b',
    'title': 'Museum of the American Railroad'},
   'header': {'datestamp': '2017-03-01T18:17:23Z',
    'identifier': 'info:ark/67531/metapth28771',
    'setSpec': ['partner:MARD', 'collection:SG07', 'access_rights:public']},
   'id': 'info:ark/67531/metapth28771',
   'metadata': {'untl:metadata': {'untl:collection': 'SG07',
     'untl:contributor': {'qualifier': 'dnr',
      'untl:info': 'Administrator, First Christian Church',
      'untl:name': 'Blanton, Burt C.',
      'untl:type': 'per'},
     'untl:coverage': [{'#text': 'United States - Texas - Travis County - Austin',
       'qualifier': 'placeName'},
      {'#text': 'mod-tim', 'qualifier': 'timePeriod'}],
     'untl:creator': {'qualifier': 'pht',
      'untl:name': 'Plummer, Roger S.',
      'untl:type': 'per'},
     'untl:date': [{'#text': '1949', 'qualifier': 'creation'},
      {'#text': '2007-08-17', 'qualifier': 'digitized'}],
     'untl:description': [{'#text': 'Katy\'s "Texas Special" train No.1, southbound, headed by Engine No. 389, a Pacific type 4-6-2 locomotive, near the suburbs of Austin, Texas.',
       'qualifier': 'content'},
      {'#text': '1 photograph : b 8 x 10 in.', 'qualifier': 'physical'}],
     'untl:format': 'image',
     'untl:identifier': [{'#text': 'https://texashistory.unt.edu/ark:/67531/metapth28771/',
       'qualifier': 'itemURL'},
      {'#text': '2-0184', 'qualifier': 'LOCAL-CONT-NO'},
      {'#text': 'https://texashistory.unt.edu/ark:/67531/metapth28771/thumbnail/',
       'qualifier': 'thumbnailURL'},
      {'#text': 'ark:/67531/metapth28771', 'qualifier': 'ARK'}],
     'untl:institution': 'MARD',
     'untl:language': 'eng',
     'untl:meta': [{'#text': '24820568', 'qualifier': 'objectMasterSize'},
      {'#text': 'ark:/67531/metapth28771', 'qualifier': 'ark'},
      {'#text': 'meta-pth-28771', 'qualifier': 'meta-id'},
      {'#text': 'meta-pcc-ca5cf811-6dde-11dc-b90b-001676dae105',
       'qualifier': 'meta-id'},
      {'#text': 'mphillips', 'qualifier': 'metadataCreator'},
      {'#text': '2007-09-28, 16:20:55', 'qualifier': 'metadataCreationDate'},
      {'#text': 'htarver', 'qualifier': 'metadataModifier'},
      {'#text': '2017-03-01, 18:17:23',
       'qualifier': 'metadataModificationDate'},
      {'#text': 'PTH', 'qualifier': 'system'},
      {'#text': '/data/SUM2007/MARD/box_02', 'qualifier': 'TKLPath'},
      {'#text': 'False', 'qualifier': 'hidden'}],
     'untl:note': {'#text': 'creationHardware: Epson Perfection V700 Photo',
      'qualifier': 'digitalPreservation'},
     'untl:primarySource': '1',
     'untl:resourceType': 'image_photo',
     'untl:rights': [{'#text': 'public', 'qualifier': 'access'},
      {'#text': 'The contents of The Portal to Texas History (digital content including images, text, and sound and video recordings) are made publicly available by the collection-holding partners for use in research, teaching, and private study. For the full terms of use, see https://texashistory.unt.edu/terms-of-use/',
       'qualifier': 'statement'}],
     'untl:subject': [{'#text': 'Business, Economics and Finance - Transportation - Railroads',
       'qualifier': 'UNTL-BS'},
      {'#text': 'Places - United States - Texas', 'qualifier': 'UNTL-BS'},
      {'#text': 'Missouri - Kansas - Texas Railroad', 'qualifier': 'KWD'},
      {'#text': 'Texas Special', 'qualifier': 'KWD'},
      {'#text': 'steam engines', 'qualifier': 'KWD'}],
     'untl:title': {'#text': '["Texas Special" departing Austin]',
      'qualifier': 'officialtitle'},
     'xmlns:untl': 'http://digital2.library.unt.edu/untl/'}},
   'provider': {'@id': 'http://dp.la/api/contributor/the_portal_to_texas_history',
    'name': 'The Portal to Texas History'}},
  'provider': {'@id': 'http://dp.la/api/contributor/the_portal_to_texas_history',
   'name': 'The Portal to Texas History'},
  'score': 5.112093,
  'sourceResource': {'@id': 'http://dp.la/api/items/a6579158177091a4733a23cf2c3cdd85#sourceResource',
   'collection': {'@id': 'http://dp.la/api/collections/4e31bbfaacdc3720c41906879d11226b',
    'description': '',
    'id': '4e31bbfaacdc3720c41906879d11226b',
    'title': 'Museum of the American Railroad'},
   'contributor': ['Blanton, Burt C'],
   'creator': ['Plummer, Roger S'],
   'date': {'begin': '1949', 'displayDate': '1949', 'end': '1949'},
   'description': ['Katy\'s "Texas Special" train No.1, southbound, headed by Engine No. 389, a Pacific type 4-6-2 locomotive, near the suburbs of Austin, Texas.',
    '1 photograph : b 8 x 10 in.'],
   'format': 'Image',
   'identifier': ['itemURL: https://texashistory.unt.edu/ark:/67531/metapth28771/',
    'LOCAL-CONT-NO: 2-0184',
    'thumbnailURL: https://texashistory.unt.edu/ark:/67531/metapth28771/thumbnail/',
    'ARK: ark:/67531/metapth28771'],
   'language': [{'iso639_3': 'eng', 'name': 'English'}],
   'rights': 'The contents of The Portal to Texas History (digital content including images, text, and sound and video recordings) are made publicly available by the collection-holding partners for use in research, teaching, and private study. For the full terms of use, see https://texashistory.unt.edu/terms-of-use/',
   'spatial': [{'city': 'Austin',
     'coordinates': '30.26715, -97.74306',
     'country': 'United States',
     'county': 'Travis County',
     'name': 'United States - Texas - Travis County - Austin',
     'state': 'Texas'}],
   'subject': [{'name': 'Business, Economics and Finance'},
    {'name': 'Transportation'},
    {'name': 'Railroads'},
    {'name': 'Places'},
    {'name': 'United States'},
    {'name': 'Texas'},
    {'name': 'Missouri'},
    {'name': 'Kansas'},
    {'name': 'Texas Railroad'},
    {'name': 'Texas Special'},
    {'name': 'Steam engines'}],
   'title': ['["Texas Special" departing Austin]'],
   'type': 'image'}},
 {'@context': 'http://dp.la/api/items/context',
  '@id': 'http://dp.la/api/items/e38d59139e40207b8519555551571c1d',
  '@type': 'ore:Aggregation',
  '_id': 'texas--info:ark/67531/metapth74611',
  '_rev': '14-8e3c5fbd02d39d83d230c7b8f5d2eef2',
  'admin': {'sourceResource': {'title': '[Construction at the University of Texas at Austin]'}},
  'aggregatedCHO': '#sourceResource',
  'dataProvider': ['Austin History Center, Austin Public Library'],
  'id': 'e38d59139e40207b8519555551571c1d',
  'ingestDate': '2017-04-04T16:39:37.392140Z',
  'ingestType': 'item',
  'ingestionSequence': 25,
  'isShownAt': 'https://texashistory.unt.edu/ark:/67531/metapth74611/',
  'object': 'https://texashistory.unt.edu/ark:/67531/metapth74611/thumbnail/',
  'originalRecord': {'collection': {'@id': 'http://dp.la/api/collections/ad69680193c8a3f9108011ea19bf88ca',
    'description': '',
    'id': 'ad69680193c8a3f9108011ea19bf88ca',
    'title': 'Austin History Center, Austin Public Library'},
   'header': {'datestamp': '2012-01-06T18:10:13Z',
    'identifier': 'info:ark/67531/metapth74611',
    'setSpec': ['partner:ASPL', 'collection:NDPC', 'access_rights:public']},
   'id': 'info:ark/67531/metapth74611',
   'metadata': {'untl:metadata': {'untl:collection': 'NDPC',
     'untl:contributor': {'untl:name': 'Collins Construction',
      'untl:type': 'org'},
     'untl:coverage': [{'#text': 'United States - Texas - Travis County - Austin',
       'qualifier': 'placeName'},
      {'#text': 'mod-tim', 'qualifier': 'timePeriod'},
      {'#text': '1951-02-07', 'qualifier': 'date'}],
     'untl:creator': {'qualifier': 'pht',
      'untl:name': 'Douglass, Neal',
      'untl:type': 'per'},
     'untl:date': '1951-02-07',
     'untl:description': [{'#text': '1 photograph : negative, b 4 x 5 in.',
       'qualifier': 'physical'},
      {'#text': 'View of construction fencing to the north of the intersection of E. Campus Dr. and 23rd St.',
       'qualifier': 'content'}],
     'untl:format': 'image',
     'untl:identifier': [{'#text': 'https://texashistory.unt.edu/ark:/67531/metapth74611/',
       'qualifier': 'itemURL'},
      {'#text': 'ND-51-235-01', 'qualifier': 'LOCAL-CONT-NO'},
      {'#text': 'https://texashistory.unt.edu/ark:/67531/metapth74611/thumbnail/',
       'qualifier': 'thumbnailURL'},
      {'#text': 'ark:/67531/metapth74611', 'qualifier': 'ARK'}],
     'untl:institution': 'ASPL',
     'untl:language': 'nol',
     'untl:meta': [{'#text': 'metapth74611', 'qualifier': 'meta-id'},
      {'#text': 'PTH', 'qualifier': 'system'},
      {'#text': 'ark:/67531/metapth74611', 'qualifier': 'ark'},
      {'#text': '2010-01-26, 11:19:37', 'qualifier': 'metadataCreationDate'},
      {'#text': 'acpmaker', 'qualifier': 'metadataCreator'},
      {'#text': 'mmiller', 'qualifier': 'metadataModifier'},
      {'#text': '2012-01-06, 18:10:13',
       'qualifier': 'metadataModificationDate'},
      {'#text': 'False', 'qualifier': 'hidden'}],
     'untl:note': {'#text': 'comment: Descriptive metadata template by htarver 2010-01-21.',
      'qualifier': 'nonDisplay'},
     'untl:primarySource': '1',
     'untl:resourceType': 'image_photo',
     'untl:rights': {'#text': 'The contents of The Portal to Texas History (digital content including images, text, and sound and video recordings) are made publicly available by the collection-holding partners for use in research, teaching, and private study. For the full terms of use, see https://texashistory.unt.edu/terms-of-use/',
      'qualifier': 'statement'},
     'untl:subject': [{'#text': 'Education - Colleges and Universities - University of Texas',
       'qualifier': 'UNTL-BS'},
      {'#text': 'Architecture - Construction', 'qualifier': 'UNTL-BS'}],
     'untl:title': {'#text': '[Construction at the University of Texas at Austin]',
      'qualifier': 'officialtitle'},
     'xmlns:untl': 'http://digital2.library.unt.edu/untl/'}},
   'provider': {'@id': 'http://dp.la/api/contributor/the_portal_to_texas_history',
    'name': 'The Portal to Texas History'}},
  'provider': {'@id': 'http://dp.la/api/contributor/the_portal_to_texas_history',
   'name': 'The Portal to Texas History'},
  'score': 5.112093,
  'sourceResource': {'@id': 'http://dp.la/api/items/e38d59139e40207b8519555551571c1d#sourceResource',
   'collection': {'@id': 'http://dp.la/api/collections/ad69680193c8a3f9108011ea19bf88ca',
    'description': '',
    'id': 'ad69680193c8a3f9108011ea19bf88ca',
    'title': 'Austin History Center, Austin Public Library'},
   'contributor': ['Collins Construction'],
   'creator': ['Douglass, Neal'],
   'description': ['1 photograph : negative, b 4 x 5 in.',
    'View of construction fencing to the north of the intersection of E. Campus Dr. and 23rd St.'],
   'format': 'Image',
   'identifier': ['itemURL: https://texashistory.unt.edu/ark:/67531/metapth74611/',
    'LOCAL-CONT-NO: ND-51-235-01',
    'thumbnailURL: https://texashistory.unt.edu/ark:/67531/metapth74611/thumbnail/',
    'ARK: ark:/67531/metapth74611'],
   'rights': 'The contents of The Portal to Texas History (digital content including images, text, and sound and video recordings) are made publicly available by the collection-holding partners for use in research, teaching, and private study. For the full terms of use, see https://texashistory.unt.edu/terms-of-use/',
   'spatial': [{'city': 'Austin',
     'coordinates': '30.26715, -97.74306',
     'country': 'United States',
     'county': 'Travis County',
     'name': 'United States - Texas - Travis County - Austin',
     'state': 'Texas'}],
   'subject': [{'name': 'Education'},
    {'name': 'Colleges and Universities'},
    {'name': 'University of Texas'},
    {'name': 'Architecture'},
    {'name': 'Construction'}],
   'title': ['[Construction at the University of Texas at Austin]'],
   'type': 'image'}},
 {'@context': 'http://dp.la/api/items/context',
  '@id': 'http://dp.la/api/items/ed4004beb79d66b06e5b73776f100955',
  '@type': 'ore:Aggregation',
  '_id': 'texas--info:ark/67531/metapth124492',
  '_rev': '14-7bdecf94a30aeee86589c830f96f8e4d',
  'admin': {'sourceResource': {'title': '[The University of Texas, Austin]'}},
  'aggregatedCHO': '#sourceResource',
  'dataProvider': ['Austin History Center, Austin Public Library'],
  'id': 'ed4004beb79d66b06e5b73776f100955',
  'ingestDate': '2017-04-04T17:25:15.182052Z',
  'ingestType': 'item',
  'ingestionSequence': 25,
  'isShownAt': 'https://texashistory.unt.edu/ark:/67531/metapth124492/',
  'object': 'https://texashistory.unt.edu/ark:/67531/metapth124492/thumbnail/',
  'originalRecord': {'collection': {'@id': 'http://dp.la/api/collections/ad69680193c8a3f9108011ea19bf88ca',
    'description': '',
    'id': 'ad69680193c8a3f9108011ea19bf88ca',
    'title': 'Austin History Center, Austin Public Library'},
   'header': {'datestamp': '2012-06-19T16:30:08Z',
    'identifier': 'info:ark/67531/metapth124492',
    'setSpec': ['partner:ASPL', 'collection:AHCP', 'access_rights:public']},
   'id': 'info:ark/67531/metapth124492',
   'metadata': {'untl:metadata': {'untl:collection': 'AHCP',
     'untl:coverage': [{'#text': 'United States - Texas - Travis County - Austin',
       'qualifier': 'placeName'},
      {'#text': 'mod-tim', 'qualifier': 'timePeriod'}],
     'untl:creator': {'qualifier': 'pht',
      'untl:name': 'Neal Douglass',
      'untl:type': 'per'},
     'untl:description': [{'#text': 'Photograph of an aerial view of the University of Texas, Austin campus and the surrounding area.',
       'qualifier': 'content'},
      {'#text': '1 photograph : b 8 x 10 in.', 'qualifier': 'physical'}],
     'untl:format': 'image',
     'untl:identifier': [{'#text': 'https://texashistory.unt.edu/ark:/67531/metapth124492/',
       'qualifier': 'itemURL'},
      {'#text': 'PICA 19318', 'qualifier': 'LOCAL-CONT-NO'},
      {'#text': 'https://texashistory.unt.edu/ark:/67531/metapth124492/thumbnail/',
       'qualifier': 'thumbnailURL'},
      {'#text': 'ark:/67531/metapth124492', 'qualifier': 'ARK'}],
     'untl:institution': 'ASPL',
     'untl:language': 'nol',
     'untl:meta': [{'#text': 'metapth124492', 'qualifier': 'meta-id'},
      {'#text': 'PTH', 'qualifier': 'system'},
      {'#text': 'ark:/67531/metapth124492', 'qualifier': 'ark'},
      {'#text': '2010-10-27, 19:34:31', 'qualifier': 'metadataCreationDate'},
      {'#text': 'acpmaker', 'qualifier': 'metadataCreator'},
      {'#text': 'dalonzo', 'qualifier': 'metadataModifier'},
      {'#text': '2012-06-19, 16:30:08',
       'qualifier': 'metadataModificationDate'},
      {'#text': 'False', 'qualifier': 'hidden'}],
     'untl:note': {'#text': 'comment: Descriptive metadata template by htarver 2010-10-25.',
      'qualifier': 'nonDisplay'},
     'untl:primarySource': '1',
     'untl:resourceType': 'image_photo',
     'untl:rights': {'#text': 'The contents of The Portal to Texas History (digital content including images, text, and sound and video recordings) are made publicly available by the collection-holding partners for use in research, teaching, and private study. For the full terms of use, see https://texashistory.unt.edu/terms-of-use/',
      'qualifier': 'statement'},
     'untl:subject': [{'#text': 'Education - Colleges and Universities - University of Texas',
       'qualifier': 'UNTL-BS'},
      {'#text': 'AUSTIN PICTURES, ILLUSTRATIONS, ETC. - (1940 - 1949)',
       'qualifier': 'OTH'}],
     'untl:title': {'#text': '[The University of Texas, Austin]',
      'qualifier': 'officialtitle'},
     'xmlns:untl': 'http://digital2.library.unt.edu/untl/'}},
   'provider': {'@id': 'http://dp.la/api/contributor/the_portal_to_texas_history',
    'name': 'The Portal to Texas History'}},
  'provider': {'@id': 'http://dp.la/api/contributor/the_portal_to_texas_history',
   'name': 'The Portal to Texas History'},
  'score': 5.112093,
  'sourceResource': {'@id': 'http://dp.la/api/items/ed4004beb79d66b06e5b73776f100955#sourceResource',
   'collection': {'@id': 'http://dp.la/api/collections/ad69680193c8a3f9108011ea19bf88ca',
    'description': '',
    'id': 'ad69680193c8a3f9108011ea19bf88ca',
    'title': 'Austin History Center, Austin Public Library'},
   'creator': ['Neal Douglass'],
   'description': ['Photograph of an aerial view of the University of Texas, Austin campus and the surrounding area.',
    '1 photograph : b 8 x 10 in.'],
   'format': 'Image',
   'identifier': ['itemURL: https://texashistory.unt.edu/ark:/67531/metapth124492/',
    'LOCAL-CONT-NO: PICA 19318',
    'thumbnailURL: https://texashistory.unt.edu/ark:/67531/metapth124492/thumbnail/',
    'ARK: ark:/67531/metapth124492'],
   'rights': 'The contents of The Portal to Texas History (digital content including images, text, and sound and video recordings) are made publicly available by the collection-holding partners for use in research, teaching, and private study. For the full terms of use, see https://texashistory.unt.edu/terms-of-use/',
   'spatial': [{'city': 'Austin',
     'coordinates': '30.26715, -97.74306',
     'country': 'United States',
     'county': 'Travis County',
     'name': 'United States - Texas - Travis County - Austin',
     'state': 'Texas'}],
   'subject': [{'name': 'Education'},
    {'name': 'Colleges and Universities'},
    {'name': 'University of Texas'},
    {'name': 'AUSTIN PICTURES, ILLUSTRATIONS, ETC'},
    {'name': '(1940 - 1949)'}],
   'title': ['[The University of Texas, Austin]'],
   'type': 'image'}},
 {'@context': 'http://dp.la/api/items/context',
  '@id': 'http://dp.la/api/items/b0cdb00a3888c45a3762b102e1975c06',
  '@type': 'ore:Aggregation',
  '_id': 'scdl--http://lcdl.library.cofc.edu/lcdl/catalog/lcdl:37271',
  '_rev': '4-65266fcf7fea02b6918441125df34747',
  'admin': {'sourceResource': {'title': 'Jewish Synagogue, Austin, Texas'}},
  'aggregatedCHO': '#sourceResource',
  'dataProvider': 'College of Charleston Libraries',
  'id': 'b0cdb00a3888c45a3762b102e1975c06',
  'ingestDate': '2017-04-10T18:18:36.188759Z',
  'ingestType': 'item',
  'ingestionSequence': 4,
  'isShownAt': 'http://lcdl.library.cofc.edu/lcdl/catalog/lcdl:37271',
  'object': 'http://fedora.library.cofc.edu:8080/fedora/objects/lcdl:37271/datastreams/THUMB1/content',
  'originalRecord': {'date': '1913',
   'datestamp': '2017-04-07T16:50:59Z',
   'description': 'Color postcard of the exterior of the former location of Congregation Beth Israel in Austin.',
   'handle': 'http://lcdl.library.cofc.edu/lcdl/catalog/lcdl:37271',
   'hasFormat': 'http://fedora.library.cofc.edu:8080/fedora/objects/lcdl:37271/datastreams/THUMB1/content',
   'id': 'oai:scmemory-search.org/lcdl-37271',
   'isPartOf': 'William A. Rosenthall Judaica Collection - Postcards',
   'label': 'Jewish Synagogue, Austin, Texas',
   'language': 'English',
   'medium': 'Postcards',
   'provider': {'@id': 'http://dp.la/api/contributor/scdl',
    'name': 'South Carolina Digital Library'},
   'publisher': 'College of Charleston Libraries',
   'rights': 'Digital image copyright 2011, The College of Charleston Libraries. All rights reserved. Contact The College of Charleston Library, Charleston, SC 29424 for more information.',
   'spatial': 'Austin (Tex.)',
   'status': [],
   'subject': ['Synagogues--United States', 'Synagogues--Texas--Austin'],
   'title': 'Jewish Synagogue, Austin, Texas',
   'type': 'StillImage'},
  'provider': {'@id': 'http://dp.la/api/contributor/scdl',
   'name': 'South Carolina Digital Library'},
  'score': 5.112093,
  'sourceResource': {'@id': 'http://dp.la/api/items/b0cdb00a3888c45a3762b102e1975c06#sourceResource',
   'collection': [{'title': 'William A. Rosenthall Judaica Collection - Postcards'}],
   'date': {'begin': '1913', 'displayDate': '1913', 'end': '1913'},
   'description': 'Color postcard of the exterior of the former location of Congregation Beth Israel in Austin.',
   'format': 'Postcards',
   'language': [{'iso639_3': 'eng', 'name': 'English'}],
   'rights': ['Digital image copyright 2011, The College of Charleston Libraries. All rights reserved. Contact The College of Charleston Library, Charleston, SC 29424 for more information.'],
   'spatial': [{'city': 'Austin',
     'coordinates': '30.26715, -97.74306',
     'country': 'United States',
     'county': 'Travis County',
     'name': 'Austin TX',
     'state': 'Texas'}],
   'stateLocatedIn': [{'name': 'South Carolina'}],
   'subject': [{'name': 'Synagogues--United States'},
    {'name': 'Synagogues--Texas--Austin'}],
   'title': 'Jewish Synagogue, Austin, Texas',
   'type': ['image']}}]

The API limits our results to ten per page, so in order to get an analysis of the full sweep of the search results, we'll need to increment over each page and add the results together, like so.

We use the math.ceil function to round up the number get. We know we have 500 results per page in this, more expanded version of the api call. By dividing the total number of results by 500, we'll get how many pages we need to iterate over. We round up because that last page will have a few results on it. To do this over the full collection of results, we would go all the way up to the total count - 144 pages. We'll just go 20 pages in to save bandwidth and time. Surely 10,000 results is enough to do something interesting.

In [26]:
import math

total_hard_way_results = []
params = {
    'api_key': my_api_key,
    'q': 'Austin, Texas',
    'page_size': '500'
    }
total_results = requested_the_hard_way.json()['count']
number_of_pages = math.ceil(total_results / 500)
print(number_of_pages)
list_of_page_numbers = range(1, 21, 1)
for page_number in list_of_page_numbers:
    print(page_number)
    params['page'] = page_number
    for result in requests.get(endpoint, params).json()['docs']:
        total_hard_way_results.append(result)
    
print(len(total_hard_way_results))
144
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
10000
In [68]:
state_results = {}
state_results['other_format'] = 0
for item in total_hard_way_results:
    if 'stateLocatedIn' in item['sourceResource']:
        if item['sourceResource']['stateLocatedIn'][0]['name'] in state_results:
            state_results[item['sourceResource']['stateLocatedIn'][0]['name']] += 1
        else:            
            state_results[item['sourceResource']['stateLocatedIn'][0]['name']] = 1
    elif 'format' in item['sourceResource'] and item['sourceResource']['format'] != 'Text':
        state_results['other_format'] += 1
    else:
        pass
print(state_results)
{'other_format': 1879, 'Washington, D.C.': 9, 'New York': 15, 'South Carolina': 3, 'Massachusetts': 14, '302': 1, 'Virginia': 2, 'UT': 28, 'North Carolina': 3, 'Tennessee': 1, 'Wisconsin': 3, 'Michigan': 2, 'Illinois': 1, 'Missouri': 18, 'Georgia State University Library': 2, 'Duke University. Library': 2}

We see a number interesting things here. For one, we see that Texas has the largest number of holdings about Texas. This makes sense. But look how low those numbers are. We can start to get a sense of how difficult it is to work with this API data. We have 10,000 files we're looking at, but only a small percentage of them have physical locations. We captured all of these other materials in the other_format key. This key, were we to open it up, contains images, electronic resources, and more. But where are all the other search results coming from? More information would be required. but this tells us that the DPLA is just that - Digital. While it might aggregate materials for some physical holdings, it primarily deals in materials that live electronically.

Exercises

  1. Write your own script to use the DPLA API for a search item using the Python wrapper.
  2. Do the same search, but from scratch rather than using the wrapper.
  3. Manipulate the DPLA metadata to do something interesting with the results.