Omeka Sの特定のvocabularyのプロパティ一覧を取得する
概要 Omeka Sの特定のvocabularyのプロパティ一覧を取得する方法です。 方法 以下を対象にします。 https://uta.u-tokyo.ac.jp/uta/api/properties?vocabulary_id=5 次のプログラムにより、プロパティ一覧をMS Excelに書き込みます。 import pandas as pd import requests url = "https://uta.u-tokyo.ac.jp/uta/api/properties?vocabulary_id=5" page = 1 data_list = [] while 1: response = requests.get(url + "&page=" + str(page)) data = response.json() if len(data) == 0: break data_list.extend(data) page += 1 remove_keys = ["@context", "@id", "@type", "o:vocabulary", "o:id", "o:local_name"] for data in data_list: for key in remove_keys: if key in data: del data[key] # DataFrameに変換 df = pd.DataFrame(data_list) df.to_excel("archiveshub.xlsx", index=False) 結果 以下のようなMS Excelが得られます。 o:label o:comment o:term Maintenance Agency A repository responsible for the maintenance of the archival finding aid. archiveshub:maintenanceAgency Is Maintenance Agency Of An archival finding aid for which the repository is responsible for the maintenance. archiveshub:isMaintenanceAgencyOf Encoded As An EAD document that is an encoding of the archival finding aid. archiveshub:encodedAs Encoding Of An archival finding aid of which the EAD document is an encoding. archiveshub:encodingOf Administers A resource which the agent manages. archiveshub:administers Is Administered By An agent that manages the resource. archiveshub:isAdministeredBy Provides Access To A resource to which the agent provides access. archiveshub:providesAccessTo Access Provided By An agent that provides access to the resource. archiveshub:accessProvidedBy Is Publisher Of A resource which the agent makes available. archiveshub:isPublisherOf Level An indicator of the part of an archival collection constituted by an archival resource. archiveshub:level Is Represented By A resource which represents the archival resource, such as an image of a text page, a transcription of text, an audio or video clip, or an aggregation of such resources. archiveshub:isRepresentedBy Origination An agent responsible for the creation or accumulation of the archival resource. archiveshub:origination Is Origination Of An archival resource for which the agent is responsible for the creation or accumulation. archiveshub:isOriginationOf Has Biographical History A narrative or chronology that places archival materials in context by providing information about their creator(s). archiveshub:hasBiographicalHistory Is Biographical History For An archival resource that the narrative or chronology places in context by providing information about their creator(s). archiveshub:isBiographicalHistoryFor Associated With A concept adjudged by a cataloguer to have an association with an archival resource which they consider useful for the purposes of discovering that resource. archiveshub:associatedWith Members Members archiveshub:members Country Code The ISO 3166-1 code for the country of the repository. archiveshub:countryCode Maintenance Agency Code The ISO 15511 code for the repository. archiveshub:maintenanceAgencyCode Body A literal representation of the content of the document. archiveshub:body Date created or accumulated The date, represented as a string, of a time interval during which the archival resource was created or accumulated. archiveshub:dateCreatedAccumulatedString Date created or accumulated The date, represented as a typed literal, of a time interval during which the archival resource was created or accumulated. archiveshub:dateCreatedAccumulated Date created or accumulated (start) The start date, represented as a typed literal, of a time interval during which the archival resource was created or accumulated. archiveshub:dateCreatedAccumulatedStart Date created or accumulated (end) The end date, represented as a typed literal, of a time interval during which the archival resource was created or accumulated. archiveshub:dateCreatedAccumulatedEnd Date of Birth The date of birth of the person. archiveshub:dateBirth Date of Death The date of death of the person. archiveshub:dateDeath Extent The size of the archival resource. archiveshub:extent Custodial History Custodial History archiveshub:custodialHistory Acquisitions Acquisitions archiveshub:acquisitions Scope and Content Scope and Content archiveshub:scopecontent Appraisal Appraisal archiveshub:appraisal Accruals Accruals archiveshub:accruals Access Restrictions Access Restrictions archiveshub:accessRestrictions Use Restrictions Use Restrictions archiveshub:useRestrictions Physical and Technical Requirements Physical and Technical Requirements archiveshub:physicalTechnicalRequirements Other Finding Aids Other Finding Aids archiveshub:otherFindingAids Location of Originals Location of Originals archiveshub:locationOfOriginals Alternate Forms Available Alternate Forms Available archiveshub:alternateFormsAvailable Related Material Related Material archiveshub:relatedMaterial Bibliography Bibliography archiveshub:bibliography Note Note archiveshub:note Processing Processing archiveshub:processing Name Name archiveshub:name Dates Dates archiveshub:dates Location Location archiveshub:location Other Other archiveshub:other Surname The surname of a person who is the focus of the concept archiveshub:surname Forename The forename of a person who is the focus of the concept archiveshub:forename Title The title of a person who is the focus of the concept archiveshub:title Epithet Epithet archiveshub:epithet Archival Box A number of archival boxes archiveshub:archbox Metre A number of metres archiveshub:metre Cubic Metre A number of cubic metres archiveshub:cubicmetre Folder A number of folders archiveshub:folder Envelope A number of envelopes archiveshub:envelope Volume A number of volumes archiveshub:volume File A number of files archiveshub:file Item A number of items archiveshub:item Page A number of pages archiveshub:page Paper A number of papers archiveshub:paper まとめ Omeka Sの利用にあたり、参考になりましたら幸いです。 ...













