Contents



Get A List Of All Sessions In The Prearchive

This REST endpoint returns a list of all sessions waiting to be archived that the currently logged-in user has permission to view.

GET - /data/prearchive/projects
GET - /data/prearchive/projects/{project-id}

Parameters

{project-id}Optional path parameter. Restricts the results to a specified project
format

Optional querystring parameter. Specify the format of the response text

  • json (default)
  • html
  • xml
  • csv

Response

{
  "ResultSet": {
    "Result": [
      {
        "autoarchive": "",
        "folderName": "string",
        "lastmod": "datetime",
        "name": "string",
        "prevent_anon": boolean,
        "prevent_auto_commit": boolean,
        "project": "string {project-id}",
        "PROTOCOL": "",
        "scan_date": "date",
        "scan_time": "time",
        "SOURCE": "SessionImporter",
        "status": "string",
        "subject": "string",
        "tag": "string {UID}",
        "timestamp": "string",
        "TIMEZONE": "",
        "uploaded": "datetime",
        "url": "relative path",
        "VISIT": ""
      }
    ]
  }
}



Move A Session To A New Project

When an image session is imported into the prearchive, session metadata is inspected to determine which project it should eventually be archived in. This also determines which project users can see this session in the prearchive. If no project is found, an image session will go into the "Unassigned" prearchive, which is only visible to site administrators. This REST endpoint allows admins or project owners to change the project associated with an image session.

This URI is a mirror of /data/prearchive/projects/{project-id}/{timestamp}/{session-label}?action=move, where the src param replaces the relative path and move replaces the action parameter


POST - /data/services/prearchive/move

Parameters

srcRequired body parameter: The location of the session relative to the prearchive path. (e.g. /prearchive/projects/Sample_Project/20140411_140005287/Sample_Session)
newProjectRequired body parameter: The ID of the destination project
asyncOptional body parameter. Default is "false"
format

Optional querystring parameter. Specify the format of the response text

  • xml (default)
  • html
  • json
  • csv

Response (JSON format shown)

{
  "ResultSet": {
    "Result": [
      {
        "autoarchive": "",
        "folderName": "string",
        "lastmod": "datetime",
        "name": "string",
        "prevent_anon": boolean,
        "prevent_auto_commit": boolean,
        "project": "string {project-id}",
        "PROTOCOL": "",
        "scan_date": "date",
        "scan_time": "time",
        "SOURCE": "SessionImporter",
        "status": "string",
        "subject": "string",
        "tag": "string {UID}",
        "timestamp": "string",
        "TIMEZONE": "",
        "uploaded": "datetime",
        "url": "relative path",
        "VISIT": ""
      }
    ]
  }
}

Rebuild An Image Session Listing

Refreshes the session XML metadata. Note that if a session was moved, this function will not reset the project to its original state.

POST - /data/services/prearchive/rebuild

Parameters

srcRequired body parameter. The location of the session relative to the prearchive path. (e.g. /prearchive/projects/Sample_Project/20140411_140005287/Sample_Session)
format

Optional querystring parameter. Specify the format of the response text

  • xml (default)
  • html
  • json
  • csv

Response (JSON format shown)

{
  "ResultSet": {
    "Result": [
      {
        "autoarchive": "",
        "folderName": "string",
        "lastmod": "datetime",
        "name": "string",
        "prevent_anon": boolean,
        "prevent_auto_commit": boolean,
        "project": "string {project-id}",
        "PROTOCOL": "",
        "scan_date": "date",
        "scan_time": "time",
        "SOURCE": "SessionImporter",
        "status": "string",
        "subject": "string",
        "tag": "string {UID}",
        "timestamp": "string",
        "TIMEZONE": "",
        "uploaded": "datetime",
        "url": "relative path",
        "VISIT": ""
      }
    ]
  }
}


Delete An Image Session From The Prearchive

This URI is a mirror of DELETE - /data/prearchive/projects/{project-id}/{timestamp}/{session-label}, where the src param replaces the relative path

POST - /data/services/prearchive/delete

Parameters

srcRequired body parameter. The location of the session relative to the prearchive path. (e.g. /prearchive/projects/Unassigned/20140411_140005287/Sample_Session)
format

Optional querystring parameter. Specify the format of the response text

  • xml (default)
  • html
  • json
  • csv

Response (JSON format shown)

{
  "ResultSet": {
    "Result": [
      {
        "autoarchive": "",
        "folderName": "string",
        "lastmod": "datetime",
        "name": "string",
        "prevent_anon": boolean,
        "prevent_auto_commit": boolean,
        "project": "string {project-id}",
        "PROTOCOL": "",
        "scan_date": "date",
        "scan_time": "time",
        "SOURCE": "SessionImporter",
        "status": "string",
        "subject": "string",
        "tag": "string {UID}",
        "timestamp": "string",
        "TIMEZONE": "",
        "uploaded": "datetime",
        "url": "relative path",
        "VISIT": ""
      }
    ]
  }
}


Get A List Of Scans From A Session In The Prearchive

GET - /data/prearchive/projects/{project-id}/{timestamp}/{session}/scans

Parameters

project-id/timestamp/sessionThese src path attributes can be found in the "url" parameter of one of the above queries for sessions in the Prearchive

Response

{
  "ResultSet": {
    "Result": [
      {
        "ID": "integer"
        "series_description": "string",
        "xsiType": "xsiType",
      }
    ]
  }
}



Delete A Single Scan From A Session In The Prearchive

Specify a Scan ID from the above query.

DELETE - /data/prearchive/projects/{project-id}/{timestamp}/{session}/scans/{scan-ID}

Parameters

project-id/timestamp/sessionThese src path attributes can be found in the "url" parameter of one of the above queries for sessions in the Prearchive
{scan-ID}Required path parameter.

Get A List Of Scan Resources From A Session In The Prearchive

GET - /data/prearchive/projects/{project-id}/{timestamp}/{session}/scans/{scan-ID}/resources


Get A List Of Scan Resource Files From A Session In The Prearchive

GET - /data/prearchive/projects/{project-id}/{timestamp}/{session}/scans/{scan-ID}/resources/{resource}/files


Get A Scan Resource File From A Session In The Prearchive

GET - /data/prearchive/projects/{project-id}/{timestamp}/{session}/scans/{scan-ID}/resources/{resource}/files/{filename}

Set Project Prearchive Settings

PUT - /data/projects/{project-id}/prearchive_code/{prearchive-code}

Parameters

project-idRequired body parameter. Specify the project ID of the project to set
prearchive-code

Use one of the following three single-digit options:

  • "0": All uploaded image data will be placed into the prearchive. Users will have to manually transfer sessions into the permanent archive
  • "4": All uploaded image data will be auto-archived. If a session with the same label already exists, new files will NOT overwrite old ones
  • "5": All uploaded image data will be auto-archived. If a session with the same label already exists, new files WILL overwrite old ones


Check Project Prearchive Settings

GET - /data/projects/{project-id}/prearchive_code


  • No labels