Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Panel
bgColorwhite
borderStylenone

URL Syntax

/objects/{pid}/datastreams/{dsID}/content ? [asOfDateTime] [download]

HTTP Method

GET

HTTP Response

200Parameters

Info

Name

Description

Default

Options

{pid}

persistent identifier of the digital object

 

 

{dsID}

datastream identifier

 

 

asOfDateTime

indicates that the result should be relative to the digital object as it existed at the given date and time

 

yyyy-MM-dd or yyyy-MM-ddTHH:mm:ssZ

download

If true,  a content-disposition header value "attachment" will be included in the response, prompting the user to save the datastream as a file.  A content-disposition header value "inline" will be used otherwise.  The filename used in the header is generated by examining in order: RELS-INT for the relationship fedora-model:downloadFilename, the datastream label, and the datastream ID.  The file extension (apart from where the filename is specified in RELS-INT) is determined from the MIMETYPE.  The order in which these filename sources are searched, and whether or not to generate an extension from the MIMETYPE, is configured in fedora.fcfg.  The file used to map between MIMETYPEs and extensions is mime-to-extensions.xml located in the server config directory.

 

 

Examples

/objects/demo:29/datastreams/DC/content

/objects/demo:29/datastreams/DC/content?asOfDateTime=2008-01-01

getDissemination

titleHTTP 1.1 Conditional GET

The following HTTP 1.1 conditional GET request headers are supported for datastream dissemination requests:

  • If-None-Match (The ETag for managed and inline datastreams will be the datastream checksum)
    304 Not Modified is returned if the request header value matches the ETag. 
  • If-Modified-Since
    304 Not Modified is returned if the datastream has not been modified since the time specified in the request header value
  • Range
    206 Partial content is returned if the range request has been satisfied; otherwise, a 416 Requested Range Not Satisfiable status will be returned.
     

Conditional GET headers will be passed along to backend servers hosting external and redirect datastreams; responses from those servers will be sent back to the Fedora client. 

Parameters

Name

Description

Default

Options

{pid}

persistent identifier of the digital object

 

 

{dsID}

datastream identifier

 

 

asOfDateTime

indicates that the result should be relative to the digital object as it existed at the given date and time

 

yyyy-MM-dd or yyyy-MM-ddTHH:mm:ssZ

download

If true,  a content-disposition header value "attachment" will be included in the response, prompting the user to save the datastream as a file.  A content-disposition header value "inline" will be used otherwise.  The filename used in the header is generated by examining in order: RELS-INT for the relationship fedora-model:downloadFilename, the datastream label, and the datastream ID.  The file extension (apart from where the filename is specified in RELS-INT) is determined from the MIMETYPE.  The order in which these filename sources are searched, and whether or not to generate an extension from the MIMETYPE, is configured in fedora.fcfg.  The file used to map between MIMETYPEs and extensions is mime-to-extensions.xml located in the server config directory.

Panel
bgColorwhite
borderStylenone

URL Syntax

/objects/{pid}/methods/{sdefPid}/{method} ? [method parameters]

HTTP Method

GET

HTTP Response

200

Parameters

Name

Description

Default

Options

{pid}

persistent identifier of the digital object

 

 

{sdefPid}

persistent identifier of the sDef defining the methods

 

 

{method}

method to invoke

 

 

method parameters

any parameters required by the method

 

 

Examples

/objects/demo:29/methodsdatastreams/demo:27/resizeImage?width=100DC/content

/objects/demo:SmileyEarring29/methodsdatastreams/demo:DualResolution/fullSize

...

DC/content?asOfDateTime=2008-01-01

getDissemination

Panel
bgColorwhite
borderStylenone

URL Syntax

/objects/{pid}/methods/{sdefPid}/versions {method} ? [formatmethod parameters]

HTTP Method

GET

HTTP Response

200

Parameters

Name

Description

Default

Options

{pid}

persistent identifier of the digital object

 

 

{sdefPid}

persistent identifier of the sDef defining the methods

 

 

{method}

method to invoke

 

 

method parameters

any parameters required by the method

 

 

format

the preferred output format

html

xml, html

Examples

/objects/demo:29/versions/objectsmethods/demo:2927/versionsresizeImage?formatwidth=xml

...

100

/objects/demo:SmileyEarring/methods/demo:DualResolution/fullSize

getObjectHistory

Panel
bgColorwhite
borderStylenone

URL Syntax

/objects/{pid}/versions ? [format] [asOfDateTime]

HTTP Method

GET

HTTP Response

200

Parameters

Name

Description

Default

Options

{pid}

persistent identifier of the digital object

 

 

format

the preferred output format

html

xml, html

asOfDateTime

indicates that the result should be relative to the digital object as it existed on the given date

 

yyyy-MM-dd or yyyy-MM-ddTHH:mm:ssZ

Examples

/objects/demo:29/versions

/objects/demo:29/versions?format=xml

/objects/demo:29?asOfDateTime=2008-01-01

...

getObjectProfile

Panel
bgColorwhite
borderStylenone

URL Syntax

/objects/{pid} /datastreams ? [format] [asOfDateTime]

HTTP Method

GET

HTTP Response

200

Parameters

Name

Description

Default

Options

{pid}

persistent identifier of the digital object

 

 

format

the preferred output format

html

xml, html

asOfDateTime

indicates that the result should be relative to the digital object as it existed on the given date

 

yyyy-MM-dd or yyyy-MM-ddTHH:mm:ssZ

Examples

/objects/demo:35/datastreams29

/objects/demo:35/datastreams29?format=xml&asOfDateTime=

/objects/demo:29?asOfDateTime=2008-01-01T05:15:00Z

...

01

listDatastreams

Panel
bgColorwhite
borderStylenone

URL Syntax

/objects/{pid}/

methods

datastreams ? [format] [asOfDateTime]

  • /objects/{pid}/methods/{sdefPid} ? [format] [asOfDateTime]
  • HTTP Method

    GET

    HTTP Response

    200

    Parameters

    Name

    Description

    Default

    Options

    {pid}

    persistent identifier of the digital object

     

     

    {sdefPid}

    persistent identifier of the SDef defining the methods

     

     

    format

    the preferred output format

    html

    xml, html

    asOfDateTime

    indicates that the result should be relative to the digital object as it existed on the given date

     

    yyyy-MM-dd or yyyy-MM-ddTHH:mm:ssZ

    Examples

    /objects/demo:2935/methodsdatastreams

    /objects/demo:2935/methodsdatastreams?format=xml&asOfDateTime=2008-01-01T05:15:00Z

    listMethods

    Panel
    bgColorwhite
    borderStylenone

    URL Syntax

    1. /objects/
    demo:29/methods/demo:27
    1. {pid}/methods ? [format] [asOfDateTime]
    2. /objects/
    demo:29
    1. {pid}/methods/
    demo:27?format=xml&asOfDateTime=2008-01-01T05:15:00Z

    resumeFindObjects

    Panel
    bgColorwhite
    borderStylenone

    URL Syntax

    /objects ? [sessionToken] [all findObjects options
    1. {sdefPid} ? [format] [asOfDateTime]

    HTTP Method

    GET

    HTTP Response

    200

    Parameters

    Name

    Description

    Default

    Options

    sessionToken{pid}

    the persistent identifier of the session to which the search results are being returneddigital object

     

     

    {sdefPid}

    persistent identifier of the SDef defining the methods

    all findObjects options

    all of the same options are available for resumeFindObjects as for findObjects

     

     

    Examples

    /objects?terms=*&format=xml&pid=true&subject=true&label=true&sessionToken=xyz\\\\

     

    API-M Methods

     

    addDatastream

    format

    the preferred output format

    html

    xml, html

    asOfDateTime

    indicates that the result should be relative to the digital object as it existed on the given date

     

    yyyy-MM-dd or yyyy-MM-ddTHH:mm:ssZ

    Examples

    /objects/demo:29/methods

    /objects/demo:29/methods?format=xml&asOfDateTime=2008-01-01T05:15:00Z

    /objects/demo:29/methods/demo:27

    /objects/demo:29/methods/demo:27?format=xml&asOfDateTime=2008-01-01T05:15:00Z

    resumeFindObjects

    Panel
    bgColorwhite
    borderStylenone

    URL Syntax

    /objects ? [sessionToken] [all findObjects options]

    HTTP Method

    GET

    HTTP Response

    200

    Parameters

    Name

    Description

    Default

    Options

    sessionToken

    the identifier of the session to which the search results are being returned

     

     

    all findObjects options

    all of the same options are available for resumeFindObjects as for findObjects

     

     

    Examples

    /objects?terms=*&format=xml&pid=true&subject=true&label=true&sessionToken=xyz\\\\

     

    API-M Methods

     

    addDatastream

    Panel
    bgColorwhite
    borderStylenone

    URL Syntax

    /objects/{pid}/datastreams/{dsID} ? [controlGroup] [dsLocation] [altIDs] [dsLabel] [versionable] [dsState] [formatURI] [checksumType] [checksum] [mimeType] [logMessage]

    HTTP Method

    POST

    HTTP Response

    201

    Parameters

    Name

    Description

    Default

    Options

    {pid}

    persistent identifier of the digital object

     

     

    {dsID}

    datastream identifier

     

     

    controlGroup

    one of "X", "M", "R", or "E" (Inline *X*ML, *M*anaged Content, *R*edirect, or *E*xternal Referenced)

    X

    X, M, R, E

    dsLocation

    location of managed or external datastream content

     

     

    altIDs

    alternate identifiers for the datastream

     

     

    dsLabel

    the label for the datastream

     

     

    versionable

    enable versioning of the datastream

    true

    true, false

    dsState

    one of "A", "I", "D" (*A*ctive, *I*nactive, *D*eleted)

    A

    A, I, D

    formatURI

    the format URI of the datastream

     

     

    checksumType

    the algorithm used to compute the checksum

    DEFAULT

    DEFAULT, DISABLED, MD5, SHA-1, SHA-256, SHA-385, SHA-512

    checksum

    the value of the checksum represented as a hexadecimal string

     

     

    mimeType

    the MIME type of the content being added, this overrides the Content-Type request header

     

     

    logMessage

    a message describing the activity being performed

     

     

    multipart file as request content

    datastream file (for Managed datastreams)

     

     

    Examples

    POST: /objects/demo:29/datastreams/NEWDS?controlGroup=X&dsLabel=New (with Multipart file)

    POST: /objects/demo:29/datastreams/NEWDS?controlGroup=M&dsLocation=http://example:80/newds&dsLabel=New

    addRelationship

    Panel
    bgColorwhite
    borderStylenone

    URL Syntax

    /objects/{pid}/relationships/new ? [subject] [predicate] [object] [isLiteral] [datatype]

    HTTP Method

    POST

    HTTP Response

    200

    Parameters

    Name

    Description

    Default

    Options

    {pid}

    persistent identifier of the digital object

     

     

    subject

    subject of the relationship. Either a URI for the object or one of its datastreams

    URI of this object

     

    predicate

    predicate of the relationship

     

     

    object

    object of the relationship

     

     

    isLiteral

    true if the object of the relationship is a literal, false if it is a URI

     

    true, false

    datatype

    if the object is a literal, the datatype of the literal (optional

    Panel
    bgColorwhite
    borderStylenone

    URL Syntax

    /objects/{pid}/datastreams/{dsID} ? [controlGroup] [dsLocation] [altIDs] [dsLabel] [versionable] [dsState] [formatURI] [checksumType] [checksum] [mimeType] [logMessage]

    HTTP Method

    POST

    HTTP Response

    201

    Parameters

    Name

    Description

    Default

    Options

    {pid}

    persistent identifier of the digital object

     

     

    {dsID}

    datastream identifier

     

     

    controlGroup

    one of "X", "M", "R", or "E" (Inline *X*ML, *M*anaged Content, *R*edirect, or *E*xternal Referenced)

    X

    X, M, R, E

    dsLocation

    location of managed or external datastream content

     

     

    altIDs

    alternate identifiers for the datastream

     

     

    dsLabel

    the label for the datastream

     

     

    versionable

    enable versioning of the datastream

    true

    true, false

    dsState

    one of "A", "I", "D" (*A*ctive, *I*nactive, *D*eleted)

    A

    A, I, D

    formatURI

    the format URI of the datastream

     

     

    checksumType

    the algorithm used to compute the checksum

    DEFAULT

    DEFAULT, DISABLED, MD5, SHA-1, SHA-256, SHA-385, SHA-512

    checksum

    the value of the checksum represented as a hexadecimal string

     

     

    mimeType

    the MIME type of the content being added, this overrides the Content-Type request header

     

     

    logMessage

    a message describing the activity being performed

     

     

    multipart file as request content

    datastream file (for Managed datastreams)

     

     

    Examples

    POST : /objects/demo:29/datastreamsrelationships/NEWDSnew?controlGroupsubject=Xinfo%3afedora%2fdemo%3a29%2fDC&dsLabel=New (with Multipart file)

    POST: /objects/demo:29/datastreams/NEWDS?controlGroup=M&dsLocation=http://example:80/newds&dsLabel=New

    ...

    predicate=http%3a%2f%2fwww.example.org%2frels%2fname&object=dublin%20core&isLiteral=true

    compareDatastreamChecksum

    Panel
    bgColorwhite
    borderStylenone

    See #getDatastream

    export

    Panel
    bgColorwhite
    borderStylenone

    URL Syntax

    /objects/{pid}/relationships/new export ? [subjectformat] [predicatecontext] [object] [isLiteral] [datatypeencoding]

    HTTP Method

    POSTGET

    HTTP Response

    200

    Parameters

    Name

    Description

    Default

    Options

    {pid}

    persistent identifier of the digital object

     

     

    subject

    subject of the relationship. Either a URI for the object or one of its datastreams

    URI of this object

     

    predicate

    predicate of the relationship

     

     

    object

    object of the relationship

     

     

    isLiteral

    true if the object of the relationship is a literal, false if it is a URI

     

    true, false

    datatype

    if the object is a literal, the datatype of the literal (optional)

     

     

    Examples

    POST /objects/demo:29/relationships/new?subject=info%3afedora%2fdemo%3a29%2fDC&predicate=http%3a%2f%2fwww.example.org%2frels%2fname&object=dublin%20core&isLiteral=true

    compareDatastreamChecksum

    Panel
    bgColorwhite
    borderStylenone

    See #getDatastream

    export

    Default

    Options

    {pid}

    persistent identifier of the digital object

     

     

    format

    the XML format to export

    info:fedora/fedora-system:FOXML-1.1

    info:fedora/fedora-system:FOXML-1.1, info:fedora/fedora-system:FOXML-1.0, info:fedora/fedora-system:METSFedoraExt-1.1, info:fedora/fedora-system:METSFedoraExt-1.0, info:fedora/fedora-system:ATOM-1.1, info:fedora/fedora-system:ATOMZip-1.1

    context

    the export context, which determines how datastream URLs and content are represented

    public

    • public: This is context is appropriate when the exporting repository will continue to exist and will continue to support callback URLs for datastream content and disseminations. This gives a "public" export of an object in which all relative repository URLs AND internal identifiers are converted to absolute callback URLs.
    • migrate: This context is appropriate when the local repository will NOT be available after objects have been migrated to a new repository. For External (E) and Redirected (R)datastreams, any URLs that are relative to the local repository will be expressed with the Fedora local URL syntax (which consists of the string "local.fedora.server" standing in place of the actual "hostname:port"). Managed content (M) datastream identifiers are converted into default dissemination URLs.
    • archive: This context is appropriate for creating a stand alone archive of objects from a repository that will NOT be available after objects have been exported. For External (E) and Redirected (R) datastreams, any URLs that are relative to the local repository will be expressed with the Fedora local URL syntax (see "migrate"). Managed content (M) datastream identifiers are converted into default dissemination URLs, and their contents included inline via base-64 encoding.
    Panel
    bgColorwhite
    borderStylenone

    URL Syntax

    /objects/{pid}/export ? [format] [context] [encoding]

    HTTP Method

    GET

    HTTP Response

    200

    Parameters

    Name

    Description

    Default

    Options

    {pid}

    persistent identifier of the digital object

     

     

    format

    the XML format to export

    info:fedora/fedora-system:FOXML-1.1

    info:fedora/fedora-system:FOXML-1.1, info:fedora/fedora-system:FOXML-1.0, info:fedora/fedora-system:METSFedoraExt-1.1, info:fedora/fedora-system:METSFedoraExt-1.0, info:fedora/fedora-system:ATOM-1.1, info:fedora/fedora-system:ATOMZip-1.1

    context

    the export context, which determines how datastream URLs and content are represented

    public

    public, migrate, archive

    encoding

    the preferred encoding of the exported XML

    UTF-8

     

    Examples

    /objects/demo:29/export

    /objects/demo:29/export?context=migrate

    ...

    Panel
    bgColorwhite
    borderStylenone

    URL Syntax

    /objects/{pid} ? [logMessage]

    HTTP Method

    DELETE

    HTTP Response

    204200

    Parameters

    Name

    Description

    Default

    Options

    {pid}

    persistent identifier of the digital object

     

     

    logMessage

    a message describing the activity being performed

     

     

    Examples

    DELETE: /objects/demo:29

    ...