University of Vienna object-advanced API

Additional requests for the manipulation of digital objects

Documentation

Specifications

Schemas & Data

Other Resources

OpenAPI Specification

university-of-vienna-object-advanced-api-openapi.yml Raw ↑
openapi: 3.0.2
info:
  title: PHAIDRA datastream object-advanced API
  version: '3.0'
  description: Documentation of the PHAIDRA API.
  license:
    name: Apache 2.0
    url: http://www.apache.org/licenses/LICENSE-2.0.html
servers:
- description: University of Vienna PHAIDRA
  url: https://services.phaidra.univie.ac.at/api/
- description: PHAIDRA Sandbox
  url: https://sandbox.phaidra.org/api/
tags:
- name: object-advanced
  description: Additional requests for the manipulation of digital objects
paths:
  /object/{pid}/uwmetadata:
    get:
      summary: Get uwmetadata.
      description: Retrieves the object uwmetadata datastream.
      tags:
      - object-advanced
      parameters:
      - in: path
        name: pid
        schema:
          type: string
          required: true
        description: the requested object id
      - in: query
        name: format
        schema:
          type: string
          enum:
          - xml
          required: false
        description: Specifies the format to be returned. If the format param is set to 'xml', the datastream would be returned as it is saved in Fedora.
      - in: query
        name: mode
        schema:
          type: string
          enum:
          - full
          - basic
          - resoved
          required: false
        description: If the mode is 'full', the whole tree with filled-in values will be returned. If the mode is 'basic' (default), only the filled-in nodes are returned. If the mode is 'resolved', the same JSON as in 'basic' mode will be returned, but all IDs will be resolved to labels. If format param and mode param are both used, only format param will be considered.
      responses:
        '200':
          description: JSON of uwmetadata datastream
          content:
            application/json:
              schema:
                type: object
                properties:
                  alerts:
                    type: array
                    items:
                      type: object
                      properties:
                        msg:
                          type: string
                        type:
                          type: string
                  metadata:
                    type: object
                    properties:
                      uwmetadata:
                        $ref: '#/components/schemas/uwmetadata_min'
                  status:
                    type: string
        '404':
          description: Failed to fetch data
          content:
            application/json:
              schema:
                type: object
    post:
      summary: Saves uwmetadata.
      description: This method saves the object's metadata if you are using the uwmetadata as a metadata structure.
      tags:
      - object-advanced
      security:
      - basicAuth: []
      parameters:
      - in: path
        name: pid
        schema:
          type: string
          required: true
        description: object pid
      requestBody:
        content:
          multipart/form-data:
            schema:
              type: object
              properties:
                metadata:
                  type: object
                  properties:
                    metadata:
                      type: object
                      properties:
                        uwmetadata:
                          $ref: '#/components/schemas/uwmetadata_min'
                      description: See [datastream examples](https://github.com/phaidra/phaidra-api/wiki/Datastream-examples) for the the metadata.json.
      responses:
        '200':
          description: uwmetadata saved
          content:
            application/json:
              schema:
                type: object
                properties:
                  alerts:
                    type: array
                    items:
                      type: object
                      properties:
                        msg:
                          type: string
                        type:
                          type: string
                  status:
                    type: string
  /object/{pid}/mods:
    get:
      summary: Get mods.
      description: Retrieves object mods datastream.
      tags:
      - object-advanced
      parameters:
      - in: path
        name: pid
        schema:
          type: string
          required: true
        description: the requested object id
      - in: query
        name: format
        schema:
          type: string
          enum:
          - xml
          required: false
        description: Specifies the format to be returned. If the format param is set to 'xml', the datastream would be returned as it is saved in Fedora.
      - in: query
        name: mode
        schema:
          type: string
          enum:
          - full
          - basic
          required: false
        description: If the mode is 'full', the whole tree with filled-in values will be returned. If the mode is 'basic' (default), only the filled-in nodes are returned. If the mode is 'resolved', the same JSON as in 'basic' mode will be returned, but all IDs will be resolved to labels. If format param and mode param are both used, only format param will be considered.
      responses:
        '200':
          description: mods JSON
          content:
            application/json:
              schema:
                type: object
                properties:
                  alerts:
                    type: array
                    items:
                      type: object
                      properties:
                        msg:
                          type: string
                        type:
                          type: string
                  mods:
                    $ref: '#/components/schemas/mods'
                  status:
                    type: string
        '404':
          description: failed to fetch data
          content:
            application/json:
              schema:
                type: object
    post:
      summary: Saves mods.
      description: 'This method saves the object''s metadata if you are using the mods as a metadata structure. '
      tags:
      - object-advanced
      security:
      - basicAuth: []
      parameters:
      - in: path
        name: pid
        schema:
          type: string
          required: true
        description: object pid
      requestBody:
        content:
          multipart/form-data:
            schema:
              type: object
              properties:
                metadata:
                  $ref: '#/components/schemas/mods'
                  description: example of mods JSON
      responses:
        '200':
          description: mods metadata saved
          content:
            application/json:
              schema:
                type: object
                properties:
                  alerts:
                    type: array
                    items:
                      type: object
                      properties:
                        msg:
                          type: string
                        type:
                          type: string
                  status:
                    type: string
  /object/{pid}/jsonld:
    get:
      description: Retrieve object JSON-LD metadata.
      summary: Get JSON-LD.
      tags:
      - object-advanced
      parameters:
      - in: path
        name: pid
        schema:
          type: string
          required: true
        description: the requested object id
      responses:
        '200':
          description: JSON-LD metadata
          content:
            application/json:
              schema:
                type: object
                properties:
                  alerts:
                    type: array
                    items:
                      type: object
                      properties:
                        msg:
                          type: string
                        type:
                          type: string
                  jsonld:
                    $ref: '#/components/schemas/jsonld'
                  status:
                    type: string
        '404':
          description: failed to fetch data
          content:
            application/json:
              schema:
                type: object
    post:
      summary: Saves JSON-LD.
      description: This method saves the metadata if you are using JSON-LD as a metadata structure.
      tags:
      - object-advanced
      security:
      - basicAuth: []
      parameters:
      - in: path
        name: pid
        schema:
          type: string
          required: true
        description: object pid
      requestBody:
        content:
          multipart/form-data:
            schema:
              type: object
              properties:
                metadata:
                  type: object
                  properties:
                    metadata:
                      type: object
                      properties:
                        json-ld:
                          $ref: '#/components/schemas/json-ld'
      responses:
        '200':
          description: JSON-LD metadata saved
          content:
            application/json:
              schema:
                type: object
                properties:
                  alerts:
                    type: array
                    items:
                      type: object
                      properties:
                        msg:
                          type: string
                        type:
                          type: string
                  status:
                    type: string
  /object/{pid}/json-ld:
    get:
      summary: Get full JSON-LD.
      description: Retrieve full object JSON-LD, with `@context` header, etc.
      tags:
      - object-advanced
      parameters:
      - in: path
        name: pid
        schema:
          type: string
          required: true
        description: the requested object id
      responses:
        '200':
          description: JSON-LD metadata
          content:
            application/json:
              schema:
                type: object
                properties:
                  alerts:
                    type: array
                    items:
                      type: object
                      properties:
                        msg:
                          type: string
                        type:
                          type: string
                  jsonld:
                    $ref: '#/components/schemas/json-ld'
                  status:
                    type: string
        '404':
          description: failed to fetch data
          content:
            application/json:
              schema:
                type: object
  /object/{pid}/geo:
    get:
      summary: Get geo.
      description: Retrieves geo datastream of object.
      tags:
      - object-advanced
      parameters:
      - in: path
        name: pid
        schema:
          type: string
          required: true
        description: the requested object id
      responses:
        '200':
          description: JSON of geo metadata. The datastream is saved as OGC-KML XML but currently only returned as JSON.
          content:
            application/json:
              schema:
                type: object
                properties:
                  alerts:
                    type: array
                    items:
                      type: object
                      properties:
                        msg:
                          type: string
                        type:
                          type: string
                  geo:
                    $ref: '#/components/schemas/geo'
                  status:
                    type: string
        '404':
          description: Failed to fetch data
          content:
            application/json:
              schema:
                type: object
    post:
      summary: Saves geo.
      description: This method saves information about the object's geolocation.
      tags:
      - object-advanced
      security:
      - basicAuth: []
      parameters:
      - in: path
        name: pid
        schema:
          type: string
          required: true
        description: object pid
      requestBody:
        content:
          multipart/form-data:
            schema:
              type: object
              properties:
                metadata:
                  $ref: '#/components/schemas/geo'
      responses:
        '200':
          description: geolocation data saved
          content:
            application/json:
              schema:
                type: object
                properties:
                  alerts:
                    type: array
                    items:
                      type: object
                      properties:
                        msg:
                          type: string
                        type:
                          type: string
                  status:
                    type: string
  /object/{pid}/members/order:
    get:
      summary: Retrieve members
      tags:
      - object-advanced
      parameters:
      - in: path
        name: pid
        schema:
          type: string
          required: true
        description: the requested object id
      responses:
        '200':
          description: '...'
          content:
            application/json:
              schema:
                type: object
                properties:
                  alerts:
                    type: array
                    items:
                      type: object
                      properties:
                        msg:
                          type: string
                        type:
                          type: string
                  status:
                    type: string
        '404':
          description: Failed to fetch data
          content:
            application/json:
              schema:
                type: object
  /object/{pid}/annotations:
    get:
      summary: Get annotations.
      description: Retrieve annotations datastream.
      tags:
      - object-advanced
      parameters:
      - in: path
        name: pid
        schema:
          type: string
          required: true
        description: the requested object id
      responses:
        '200':
          description: JSON with annotations (saved as XML but currently only returned as JSON)
          content:
            application/json:
              schema:
                type: object
                properties:
                  alerts:
                    type: array
                    items:
                      type: object
                      properties:
                        msg:
                          type: string
                        type:
                          type: string
                  annotations:
                    $ref: '#/components/schemas/annotations'
                  status:
                    type: string
        '404':
          description: Failed to fetch data
          content:
            application/json:
              schema:
                type: object
    post:
      summary: Saves annotations.
      description: This method can save annotations to an object. The format chosen is taken from IIPMooViewer.
      tags:
      - object-advanced
      security:
      - basicAuth: []
      parameters:
      - in: path
        name: pid
        schema:
          type: string
          required: true
        description: object pid
      requestBody:
        description: Adds annotation JSON. See datastream examples for the [annotations.json](https://github.com/phaidra/phaidra-api/wiki/Annotations).
        content:
          multipart/form-data:
            schema:
              type: object
              properties:
                metadata:
                  $ref: '#/components/schemas/annotations'
      responses:
        '200':
          description: Annotation saved
          content:
            application/json:
              schema:
                type: object
                properties:
                  alerts:
                    type: array
                    items:
                      type: object
                      properties:
                        msg:
                          type: string
                        type:
                          type: string
                  status:
                    type: string
  /object/{pid}/index/dc:
    get:
      summary: Get DC
      description: Get metadata exported (and significantly reduced) in Dublin Core standard
      tags:
      - object-advanced
      parameters:
      - in: path
        name: pid
        schema:
          type: string
          required: true
        description: object id
      responses:
        '200':
          description: dc - in XML
          content:
            text/xml:
              schema:
                type: string
              example: <oai_dc:dc xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:oai_dc="http://www.openarchives.org/OAI/2.0/oai_dc/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/oai_dc/ http://www.openarchives.org/OAI/2.0/oai_dc.xsd"></oai_dc:dc>
        '404':
          description: Failed to fetch data
          content:
            application/json:
              schema:
                type: object
  /object/{pid}/index/relationships:
    get:
      description: Retrieves the object's relationships using indexed data.
      summary: Get relationships, from index.
      tags:
      - object-advanced
      parameters:
      - in: path
        name: pid
        schema:
          type: string
          required: true
        description: object id
      responses:
        '200':
          description: relationships, from index
          content:
            application/json:
              schema:
                type: object
                properties:
                  alerts:
                    type: array
                    items:
                      type: object
                      properties:
                        msg:
                          type: string
                        type:
                          type: string
                  relationships:
                    $ref: '#/components/schemas/index_relationship'
                  alternativeformats:
                    type: array
                    items:
                      type: string
                  alternativeversions:
                    type: array
                    items:
                      type: string
                  versions:
                    type: array
                    items:
                      type: string
                  status:
                    type: string
        '404':
          description: Failed to fetch data
          content:
            application/json:
              schema:
                type: object
  /object/{pid}/index/members:
    get:
      summary: Get object's members.
      description: Get object's members using indexed data.
      tags:
      - object-advanced
      parameters:
      - in: path
        name: pid
        schema:
          type: string
          required: true
        description: object id
      responses:
        '200':
          description: members
          content:
            application/json:
              schema:
                type: object
                properties:
                  alerts:
                    type: array
                    items:
                      type: object
                      properties:
                        msg:
                          type: string
                        type:
                          type: string
                  status:
                    type: string
                  members:
                    type: array
        '404':
          description: Failed to fetch data
          content:
            application/json:
              schema:
                type: object
  /object/{pid}/datacite:
    get:
      summary: Transforms metadata to DataCite.
      tags:
      - object-advanced
      parameters:
      - in: path
        name: pid
        schema:
          type: string
          required: true
        description: object id
      responses:
        '200':
          description: DataCite metadata
          content:
            application/json:
              schema:
                type: object
                properties:
                  alerts:
                    type: array
                    items:
                      type: object
                      properties:
                        msg:
                          type: string
                        type:
                          type: string
                  datacite:
                    $ref: '#/components/schemas/datacite'
                  status:
                    type: string
        '404':
          description: Failed to fetch data
          content:
            application/json:
              schema:
                type: object
  /object/{pid}/state:
    get:
      summary: Get state
      description: Returns the state of the object.
      tags:
      - object-advanced
      parameters:
      - in: path
        name: pid
        schema:
          type: string
          required: true
        description: object id
      responses:
        '200':
          description: state of object, Active/Inactive/Deleted
          content:
            application/json:
              schema:
                type: object
                properties:
                  alerts:
                    type: array
                    items:
                      type: object
                      properties:
                        msg:
                          type: string
                        type:
                          type: string
                  state:
                    type: string
                  status:
                    type: number
  /object/{pid}/cmodel:
    get:
      summary: Get cmodel
      description: Returns the object cmodel
      tags:
      - object-advanced
      parameters:
      - in: path
        name: pid
        schema:
          type: string
          required: true
        description: object id
      responses:
        '200':
          description: cmodel (e.g. collection)
          content:
            application/json:
              schema:
                type: object
                properties:
                  alerts:
                    type: array
                    items:
                      type: object
                      properties:
                        msg:
                          type: string
                        type:
                          type: string
                  cmodel:
                    type: string
                  status:
                    type: number
  /object/{pid}/relationships:
    get:
      summary: Get relationships.
      description: Returns the object relationships (triplestore).
      tags:
      - object-advanced
      parameters:
      - in: path
        name: pid
        schema:
          type: string
          required: true
        description: object id
      responses:
        '200':
          description: Relationships
          content:
            application/json:
              schema:
                type: object
                properties:
                  alerts:
                    type: array
                    items:
                      type: object
                      properties:
                        msg:
                          type: string
                        type:
                          type: string
                  relationships:
                    type: object
                    properties:
                      haspart:
                        type: array
                        items:
                          type: string
                  status:
                    type: string
  /object/{pid}/iiifmanifest:
    get:
      summary: Get iiifmanifest.
      description: Retrieves the iiifmanifest datastream.
      tags:
      - object-advanced
      parameters:
      - in: path
        name: pid
        schema:
          type: string
          required: true
        description: requested pid
      responses:
        '200':
          description: iiifmanifest data
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/iiifmanifest'
    post:
      summary: Saves the iiifmanifest.
      tags:
      - object-advanced
      security:
      - basicAuth: []
      parameters:
      - in: path
        name: pid
        schema:
          type: string
          required: true
        description: object pid
      requestBody:
        content:
          multipart/form-data:
            schema:
              type: object
              properties:
                metadata:
                  type: object
                  properties:
                    metadata:
                      type: object
                      properties:
                        IIIF-MANIFEST:
                          $ref: '#/components/schemas/iiifmanifest'
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: object
                properties:
                  alerts:
                    type: array
                    items:
                      type: object
                      properties:
                        msg:
                          type: string
                        type:
                          type: string
                  status:
                    type: string
  /object/{pid}/id:
    get:
      summary: Get Dublin Core identifiers.
      description: Get a list of identifiers that are saved in Dublin Core as [http://purl.org/dc/terms/identifier](http://purl.org/dc/terms/identifier).
      tags:
      - object-advanced
      parameters:
      - in: path
        name: pid
        schema:
          type: string
          required: true
        description: object id
      responses:
        '200':
          description: ids
          content:
            application/json:
              schema:
                type: object
                properties:
                  alerts:
                    type: array
                    items:
                      type: object
                      properties:
                        msg:
                          type: string
                        type:
                          type: string
                  ids:
                    type: array
                    items:
                      type: string
                  status:
                    type: string
  /authz/check/{pid}/{op}:
    get:
      summary: Checks rights
      description: Checks if the authenticated user has appropriate rights for an operation on the object (readable/writable). Can also be checked for unauthenticated user.
      tags:
      - object-advanced
      security:
      - basicAuth: []
      parameters:
      - in: path
        name: pid
        schema:
          type: string
          required: false
        description: pid - object id
      - in: path
        name: op
        schema:
          type: string
          enum:
          - ro
          - rw
          required: true
        description: rights for operation
      responses:
        '200':
          description: readable/writable, depending on parameter 'op'. This method can be used to check if an object is readable/writable. The authentication is optional, as you might want to know if an object is readable for an unauthenticated user. An object is never writable for an unauthenticated user, so checking 'rw' only makes sense with authentication. Typically, an object is only writable for its owner.
          content:
            application/json:
              schema:
                type: object
                properties:
                  alerts:
                    type: array
                    items:
                      type: object
                      properties:
                        msg:
                          type: string
                        type:
                          type: string
                  status:
                    type: string
        '403':
          description: not op
          content:
            application/json:
              schema:
                type: object
                properties:
                  alerts:
                    type: array
                    items:
                      type: object
                      properties:
                        msg:
                          type: string
                        type:
                          type: string
                  status:
                    type: string
  /object/{pid}/metadata:
    get:
      summary: Get object's metadata
      description: Retrieve the object metadata (UWMETADATA, MODS, JSON-LD, etc., depending on the metadata datastream).
      tags:
      - object-advanced
      parameters:
      - in: path
        name: pid
        schema:
          type: string
          required: true
        description: object pid
      responses:
        '200':
          description: object metadata
          content:
            application/json:
              schema:
                type: object
                properties:
                  metadata:
                    type: object
        '404':
          description: object has not been found
          content:
            application/json:
              schema:
                type: object
  /object/{pid}/fulltext:
    get:
      summary: 'Retrieves the FULLTEXT datastream of a specified object. It returns this datastream as it was saved: this is not a method which extracts fulltext from object''s data.'
      tags:
      - object-advanced
      security:
      - basicAuth: []
      parameters:
      - in: path
        name: pid
        schema:
          type: string
          required: true
        description: requested pid - object id
      - in: query
        name: format
        schema:
          type: string
          required: false
          default: txt
        description: specifies the  desired format for the return
      responses:
        '200':
          description: requested objects fulltext data
          content:
            application/json:
              schema:
                type: object
                properties:
                  alerts:
                    type: array
                    items:
                      type: object
                      properties:
                        msg:
                          type: string
                        type:
                          type: string
                  streaming:
                    type: object
                  status:
                    type: number
        '404':
          description: object has not been found
          content:
            application/json:
              schema:
                type: object
  /object/{pid}/jsonldprivate:
    get:
      summary: Get the non-public JSON-LD-PRIVATE datastream.
      tags:
      - object-advanced
      security:
      - basicAuth: []
      parameters:
      - in: path
        name: pid
        schema:
          type: string
          required: true
        description: object pid
      responses:
        '200':
          description: JSON-LD-PRIVATE datastream
          content:
            application/json:
              schema:
                type: object
                properties:
                  alerts:
                    type: array
                    items:
                      type: object
                      properties:
                        msg:
                          type: string
                        type:
                          type: string
                  status:
                    type: number
        '404':
          description: object has not been found
          content:
            application/json:
              schema:
                type: object
    post:
      summary: Save JSON-LD-PRIVATE datastream
      description: This method saves the object's metadata if you are using jsonld as a metadata structure. Unlike JSON-LD which is always visible, JSON-LD-PRIVATE is only available to the owner/admin.
      tags:
      - object-advanced
      security:
      - basicAuth: []
      requestBody:
        content:
          multipart/form-data:
            sch

# --- truncated at 32 KB (73 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/university-of-vienna/refs/heads/main/openapi/university-of-vienna-object-advanced-api-openapi.yml