XNAT Docs Index

Related Pages

 Click here to expand...
Child pages
  • XNAT REST XML Path Shortcuts

This documentation is for XNAT versions 1.6.0 - 1.6.5. You can find the latest documentation for XNAT 1.7 at https://xnat.org/documentation

Skip to end of metadata
Go to start of metadata

Quick Index

 

REST API: XML Shortcuts

These keys can be substituted for the full XML Path when referencing variables in PUT or POST procedures. When using the querystring to define your variables, you should include the ?req_format parameter with a value of "qs" to prevent the body of the message from being parsed.

xsiType

All PUT and POST operations allow you to use the querystring parameter 'xsiType' to specify the related data type in your schema. This is only necessary when the level you are referencing could have multiple extensions. For example, /data/archive/projects/X/subjects/Y/experiments/X_Y_1. This could be an instance of an xnat:mrSessionData, xnat:petSessionData, or any other data type which extends xnat:subjectAssessorData. So, if you are not including an xml to desribe your resource, you must use the xsiType parameter (before any other parameters) to specify which type of item you are creating. /data/archive/projects/X/subjects/Y/experiments/X_Y_1?xsiType=xnat:mrSessionData.


xnat:projectData

The following parameters are available at these URIs:

/data/archive/projects
/data/archive/projects/X

VARIABLE NAME

XML PATH

ID

xnat:projectData/ID

secondary_ID

xnat:projectData/secondary_ID

name

xnat:projectData/name

description

xnat:projectData/description

keywords

xnat:projectData/keywords

alias

xnat:projectData/aliases/alias

pi_firstname

xnat:projectData/PI/firstname

pi_lastname

xnat:projectData/PI/lastname

note

xnat:projectData/fields/fieldname=note/field

last_modified (READ-ONLY)

xnat:projectData/meta/last_modified

insert_date (READ-ONLY)

xnat:projectData/meta/insert_date

insert_user (READ-ONLY)

xnat:projectData/meta/insert_user



xnat:subjectData

The following parameters are available at these URIs:

/data/archive/projects/X/subjects
/data/archive/projects/X/subjects/Y

VARIABLE NAMEXML PATH
groupxnat:subjectData/group
srcxnat:subjectData/src
pi_firstnamexnat:subjectData/investigator/firstname
pi_lastnamexnat:subjectData/investigator/lastname
dobxnat:subjectData/demographics[@xsi:type=xnat:demographicData]/dob
yobxnat:subjectData/demographics[@xsi:type=xnat:demographicData]/yob
agexnat:subjectData/demographics[@xsi:type=xnat:demographicData]/age
genderxnat:subjectData/demographics[@xsi:type=xnat:demographicData]/gender
handednessxnat:subjectData/demographics[@xsi:type=xnat:demographicData]/handedness
sesxnat:subjectData/demographics[@xsi:type=xnat:demographicData]/ses
educationxnat:subjectData/demographics[@xsi:type=xnat:demographicData]/education
educationDescxnat:subjectData/demographics[@xsi:type=xnat:demographicData]/educationDesc
racexnat:subjectData/demographics[@xsi:type=xnat:demographicData]/race
ethnicityxnat:subjectData/demographics[@xsi:type=xnat:demographicData]/ethnicity
weightxnat:subjectData/demographics[@xsi:type=xnat:demographicData]/weight
heightxnat:subjectData/demographics[@xsi:type=xnat:demographicData]/height
gestational_agexnat:subjectData/demographics[@xsi:type=xnat:demographicData]/gestational_age
post_menstrual_agexnat:subjectData/demographics[@xsi:type=xnat:demographicData]/post_menstrual_age
birth_weightxnat:subjectData/demographics[@xsi:type=xnat:demographicData]/birth_weight
last_modified (READ-ONLY)xnat:subjectData/meta/last_modified
insert_date (READ-ONLY)xnat:subjectData/meta/insert_date
insert_user (READ-ONLY)xnat:subjectData/meta/insert_user

xnat:experimentData

These URIs require the use of the xsiType parameter if you are using the query string option. The following parameters are available at these URIs:

/data/archive/projects/X/subjects/Y/experiments
/data/archive/projects/X/subjects/Y/experiments/X_Y_1

VARIABLE NAME

XML PATH

visit_id

xnat:experimentdata/visit_id

date

xnat:experimentdata/date

ID

xnat:experimentdata/ID

project

xnat:experimentdata/project

label

xnat:experimentdata/label

time

xnat:experimentdata/time

note

xnat:experimentdata/note

pi_firstname

xnat:experimentdata/investigator/firstname

pi_lastname

xnat:experimentdata/investigator/lastname

validation_method

xnat:experimentdata/validation/method

validation_status

xnat:experimentdata/validation/status

validation_date

xnat:experimentdata/validation/date

validation_notes

xnat:experimentdata/validation/notes

last_modified (READ-ONLY)

xnat:experimentdata/meta/last_modified

insert_date (READ-ONLY)

xnat:experimentdata/meta/insert_date

insert_user (READ-ONLY)

xnat:experimentdata/meta/insert_user

subject_ID

xnat:subjectData/ID

subject_label

xnat:subjectData/label

subject_project

xnat:subjectData/project

scanner

xnat:imageSessionData/scanner

operator

xnat:imageSessionData/operator

dcmAccessionNumber

xnat:imageSessionData/dcmAccessionNumber

dcmPatientId

xnat:imageSessionData/dcmPatientId

dcmPatientName

xnat:imageSessionData/dcmPatientName

session_type

xnat:imageSessionData/session_type

modality

xnat:imageSessionData/modality

UID

xnat:imageSessionData/UID

coil

xnat:mrSessionData/coil

fieldStrength

xnat:mrSessionData/fieldStrength

marker

xnat:mrSessionData/marker

stabilization

xnat:mrSessionData/stabilization

studyType

xnat:petSessionData/studyType

patientID

xnat:petSessionData/patientID

patientName

xnat:petSessionData/patientName

stabilization

xnat:petSessionData/stabilization

scan_start_time

xnat:petSessionData/start_time/scan

injection_start_time

xnat:petSessionData/start_time/injection

tracer_name

xnat:petSessionData/tracer/name

tracer_startTime

xnat:petSessionData/tracer/startTime

tracer_dose

xnat:petSessionData/tracer/dose

tracer_sa

xnat:petSessionData/tracer/specificActivity

tracer_totalmass

xnat:petSessionData/tracer/totalMass

tracer_intermediate

xnat:petSessionData/tracer/intermediate

tracer_isotope

xnat:petSessionData/tracer/isotope

tracer_isotope

xnat:petSessionData/tracer/isotope/half-life

tracer_transmissions

xnat:petSessionData/tracer/transmissions

tracer_transmissions_start

xnat:petSessionData/tracer/transmissions/startTime

xnat:imageScanData

These URIs require the use of the xsiType parameter if you are using the query string option. The following parameters are available at these URIs:

/data/archive/projects/X/subjects/Y/experiments/X_Y_1/scans
/data/archive/projects/X/subjects/Y/experiments/X_Y_1/scans/1

 

VARIABLE NAME

XML PATH

ID

xnat:imageScanData/ID

type

xnat:imageScanData/type

UID

xnat:imageScanData/UID

note

xnat:imageScanData/note

quality

xnat:imageScanData/quality

condition

xnat:imageScanData/condition

series_description

xnat:imageScanData/series_description

documentation

xnat:imageScanData/documentation

scanner

xnat:imageScanData/scanner

modality

xnat:imageScanData/modality

frames

xnat:imageScanData/frames

validation_method

xnat:imageScanData/validation/method

validation_status

xnat:imageScanData/validation/status

validation_date

xnat:imageScanData/validation/date

validation_notes

xnat:imageScanData/validation/notes

last_modified (READ-ONLY)

xnat:imageScanData/meta/last_modified

insert_date (READ-ONLY)

xnat:imageScanData/meta/insert_date

insert_user (READ-ONLY)

xnat:imageScanData/meta/insert_user

coil

xnat:mrScanData/coil

fieldStrength

xnat:mrScanData/fieldStrength

marker

xnat:mrScanData/marker

stabilization

xnat:mrScanData/stabilization

orientation

xnat:petScanData/parameters/orientation

scanTime

xnat:petScanData/parameters/scanTime

originalFileName

xnat:petScanData/parameters/originalFileName

systemType

xnat:petScanData/parameters/systemType

fileType

xnat:petScanData/parameters/fileType

transaxialFOV

xnat:petScanData/parameters/transaxialFOV

acqType

xnat:petScanData/parameters/acqType

facility

xnat:petScanData/parameters/facility

numPlanes

xnat:petScanData/parameters/numPlanes

numFrames

xnat:petScanData/parameters/frames/numFrames

numGates

xnat:petScanData/parameters/numGates

planeSeparation

xnat:petScanData/parameters/planeSeparation

binSize

xnat:petScanData/parameters/binSize

dataType

xnat:petScanData/parameters/dataType

 

xnat:reconstructedImageData

The following parameters are available at these URIs:

/data/archive/projects/X/subjects/Y/experiments/X_Y_1/reconstructions
/data/archive/projects/X/subjects/Y/experiments/X_Y_1/reconstructions/X_Y_1_r1

 

VARIABLE NAME

XML PATH

ID

xnat:reconstructedImageData/ID

type

xnat:reconstructedImageData/type

baseScanType

xnat:reconstructedImageData/baseScanType

last_modified (READ-ONLY)

xnat:reconstructedImageData/meta/last_modified

insert_date (READ-ONLY)

xnat:reconstructedImageData/meta/insert_date

insert_user (READ-ONLY)

xnat:reconstructedImageData/meta/insert_user

 

xnat:imageAssessorData

These URIs require the use of the xsiType parameter if you are using the query string option. The following parameters are available at these URIs:

/data/archive/projects/X/subjects/Y/experiments/X_Y_1/assessors
/data/archive/projects/X/subjects/Y/experiments/X_Y_1/assessors/X_Y_1_a1

VARIABLE NAME

XML PATH

visit_id

xnat:experimentdata/visit_id

date

xnat:experimentdata/date

time

xnat:experimentdata/time

note

xnat:experimentdata/note

pi_firstname

xnat:experimentdata/investigator/firstname

pi_lastname

xnat:experimentdata/investigator/lastname

validation_method

xnat:experimentdata/validation/method

validation_status

xnat:experimentdata/validation/status

validation_date

xnat:experimentdata/validation/date

validation_notes

xnat:experimentdata/validation/notes

last_modified (READ-ONLY)

xnat:experimentdata/meta/last_modified

insert_date (READ-ONLY)

xnat:experimentdata/meta/insert_date

insert_user (READ-ONLY)

xnat:experimentdata/meta/insert_user

  • No labels