Versions Compared

Key

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

...

PUT Object (deposit)

Description

Create or update a gateway object for preservation of an Object from the repository.

...

  • Request: PUT /ObjectId HTTP/1.1

  • Request Body: Compressed Bag
  • Request Headers:
    • Content-Type
    • Content-Length
  • Response Codes:

    • 201 Created (on success)

    • 200 OK  (on success; update)

Examples

...

Create an Object
Code Block
titleRequest
PUT /af48c3d HTTP/1.1
Host: preservation-gateway.institution.edu
Date: Tue, 02 Jul 2019 20:15:00 GMT
Content-Type: application/zip
Content-Length: 493285
Content-MD5: 4efcb3d98ce0fabfd585eb6c4332859
[493285 bytes of object data]

...

Description

Request removal of a Bag an Object and all its contents from the archive

Requests/Responses

  • Request: DELETE /ObjectId HTTP/1.1

  • Request Body: n/a
  • Response CodeCodes:
    • 204 No Content

Examples

Destroy an Object


Code Block
titleRequest
DELETE /af48c3d HTTP/1.1
Host: preservation-gateway.institution.edu
Date: Tue, 02 Jul 2019 20:25:00 GMT
Content-Type: text/plain


Code Block
titleResponse
HTTP/1.1 204 NoContent
Date: Tue, 02 Jul 2019 20:25:00 GMT
Content-Length: 0
Server: OTM Preservation Gateway

POST Object Restore

Description

...

  • Request: POST /ObjectId?restore HTTP/1.1

  • Request Body: n/a
  • Response Code:
    • 202 Accepted (if the object is not already restored)
    • 200 OK (if the object is already restored and available for retrieval)

Examples

Restore an Object
Code Block
titleRequest
POST /af48c3d?restore HTTP/1.1
Host: preservation-gateway.institution.edu
Date: Tue, 02 Jul 2019 20:35:00 GMT
Content-Length: 0


Code Block
titleResponse
HTTP/1.1 202 Accepted
Date: Tue, 02 Jul 2019 20:35:00 GMT
Content-Length: 0
Server: OTM Preservation Gateway
Requesting a Restore on an Object that is Available
Code Block
titleRequest
POST /af48c3d?restore HTTP/1.1
Host: preservation-gateway.institution.edu
Date: Tue, 02 Jul 2019 20:35:00 GMT
Content-Length: 0


Code Block
titleResponse
HTTP/1.1 200 OK
Date: Tue, 02 Jul 2019 20:35:00 GMT
Content-Length: 0
Server: OTM Preservation Gateway
ERROR: Restore Already in Progress
Code Block
titleRequest
POST /af48c3d?restore HTTP/1.1
Host: preservation-gateway.institution.edu
Date: Tue, 02 Jul 2019 20:35:00 GMT
Content-Length: 0


Code Block
titleResponse
HTTP/1.1 409 Conflict
Date: Tue, 02 Jul 2019 20:35:00 GMT
Content-Type: application/xml
Server: OTM Preservation Gateway
<?xml version="1.0" encoding="UTF-8"?>
<Error>
  <Code>RestoreAlreadyInProgress</Code>
  <Message>Object restore is already in progress.</Message>
  <Resource>/af48c3d</Resource> 
</Error>


Info
titleQuestion

Can HTTP Range requests be used to retrieve individual files (e.g. metadata)

...