Accessing images through the command line, using the Simple Image Access Protocol (SIAP) and the cutout service

Euclid implements VO SIAP v2.0 to access the Euclid Observation Images. This service will return public images from:

  • Calibrated and Stacked NISP and VIS images.

  • MER Mosaics from VIS and NISP.

  • Level 1 (RAW) images for NISP and VIS.

The base URL of this Service is https://eas.esac.esa.int/sas-sia/sia2/query?
This should be followed by the SIAP required parameters, which are defined in the table below.

Parameter Name(s)

Description

Mandatory?

Possible Values

POS

Search region as [CIRCLE, BOX or POLYGON], followed by the search position (positions for POLYGON) in the form "ra,dec", in decimal degrees and ICRS frame. CIRCLE and BOX also requires a radius in degrees

YES

[CIRCLE, BOX or POLYGON], and three numeric values delimited by a comma (or 2 * n for POLYGON). Embedded whitespace is not allowed

CALIB

Calibration level according to ObsCore VO standard

YES

CALIB_ONE | CALIB_TWO | CALIB_THREE

INSTRUMENT

Instrument name

YES

VIS | NISP

BAND

Filter name

YES

VIS | NIR_H | NIR_J | NIR_Y

The images can be obtained and downloaded through the web interface, using the Search option, and in tabs Observations and Cutout. The cutout will return the part of the original observation included within a given area in the sky provided by the user. In this section you will find how to access the cutouts using the command line. The access to complete observations is provided in the sas-dd service, described in the next help page, section Accessing L1, L2, and LE3 products through the command line, with the Data Download (sas-dd) service.

Search examples

BOX Search Example

The following queries can be invoked using curl or by copying the url to a web browser. The output will contain, inside the TABLEDATA block, direct links to the fits files. If you use curl, remember to log in sas-dd (not in tap-server), before trying to download the images. See the next section for a complete example.

Invoke:

curl "https://eas.esac.esa.int/sas-sia/sia2/query?POS=BOX,20.91,-20.13,17.5"

Example Output:

<?xml version="1.0" encoding="UTF-8"?>
<VOTABLE version="1.4" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.ivoa.net/xml/VOTable/v1.3 http://www.ivoa.net/xml/VOTable/v1.3" xmlns="http://www.ivoa.net/xml/VOTable/v1.3">
<RESOURCE type="results">
<INFO name="QUERY_STATUS" value="OK" />
<INFO name="PROVIDER" value=""></INFO>
<TABLE>
<FIELD name="access_url" ucd="meta.ref.url" datatype="char" arraysize="*"/>
<FIELD name="instrument_name" ucd="meta.id;instr" datatype="char" arraysize="*"/>
<FIELD name="facility_name" ucd="meta.id;instr.tel" datatype="char" arraysize="*"/>
<FIELD name="s_region" ucd="phys.angArea;obs" datatype="char" arraysize="*"/>
<FIELD name="s_ra" ucd="pos.eq.ra" datatype="char" arraysize="*"/>
<FIELD name="s_dec" ucd="pos.eq.dec" datatype="char" arraysize="*"/>
<FIELD name="obs_id" ucd="meta.id" datatype="char" arraysize="*"/>
<FIELD name="obs_collection" ucd="meta.id" datatype="char" arraysize="*"/>
<FIELD name="dataproduct_type" ucd="meta.id" datatype="char" arraysize="*"/>
<FIELD name="dataproduct_subtype" ucd="meta.id" datatype="char" arraysize="*"/>
<FIELD name="calib_level" ucd="meta.id" datatype="char" arraysize="*"/>
<DATA>
<TABLEDATA>
<TR>
<TD><![CDATA[https://eas.esac.esa.int/sas-dd/cutout?filepath=/data/repository_SC8/VIS/52930/EUC_VIS_SWL-DET-003-052930-0000000__20200312T122021.304478Z.fits&collection=VIS&obsid=52930&POS=BOX,20.91,-20.13,17.5]]></TD>
<TD>VIS</TD>
<TD>LOCAL</TD>
<TD>{(0.187796741659535 , -0.313231004754935),(0.205062207849311 , -0.305728145820939),(0.213953839020568 , -0.323849132670641),(0.19660678223477 , -0.331397552487519)}</TD>
<TD>11.5079943262</TD>
<TD>-18.2524590675</TD>
<TD>52930</TD>
<TD>EUC-SC7</TD>
<TD>image</TD>
<TD>dpdVisCalibratedFrame3</TD>
<TD>2</TD>
</TR>
<TR>
<TD><![CDATA[https://eas.esac.esa.int/sas-dd/cutout?filepath=/data/repository_SC8/VIS/52930/EUC_VIS_SWL-DET-001-052930-0000000__20200312T122843.768360Z.fits&collection=VIS&obsid=52930&POS=BOX,20.91,-20.13,17.5]]></TD>
<TD>VIS</TD>
<TD>LOCAL</TD>
<TD>{(0.187796741659535 , -0.313231004754935),(0.205062207849311 , -0.305728145820939),(0.213953839020568 , -0.323849132670641),(0.19660678223477 , -0.331397552487519)}</TD>
<TD>11.5079943262</TD>
<TD>-18.2524590675</TD>
<TD>52930</TD>
<TD>EUC-SC7</TD>
<TD>image</TD>
<TD>dpdVisCalibratedFrame1</TD>
<TD>2</TD>
</TR>
...
</TABLEDATA>
</DATA>
</TABLE>
</RESOURCE>
</VOTABLE>

CONE Search

Invoke:

curl "https://eas.esac.esa.int/sas-sia/sia2/query?POS=CIRCLE,20.91,-20.13,8.35"

Example Output:

?xml version="1.0" encoding="UTF-8"?>
<VOTABLE version="1.4" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.ivoa.net/xml/VOTable/v1.3 http://www.ivoa.net/xml/VOTable/v1.3" xmlns="http://www.ivoa.net/xml/VOTable/v1.3">
<RESOURCE type="results">
<INFO name="QUERY_STATUS" value="OK" />
<INFO name="PROVIDER" value=""></INFO>
<TABLE>
<FIELD name="access_url" ucd="meta.ref.url" datatype="char" arraysize="*"/>
<FIELD name="instrument_name" ucd="meta.id;instr" datatype="char" arraysize="*"/>
<FIELD name="facility_name" ucd="meta.id;instr.tel" datatype="char" arraysize="*"/>
<FIELD name="s_region" ucd="phys.angArea;obs" datatype="char" arraysize="*"/>
<FIELD name="s_ra" ucd="pos.eq.ra" datatype="char" arraysize="*"/>
<FIELD name="s_dec" ucd="pos.eq.dec" datatype="char" arraysize="*"/>
<FIELD name="obs_id" ucd="meta.id" datatype="char" arraysize="*"/>
<FIELD name="obs_collection" ucd="meta.id" datatype="char" arraysize="*"/>
<FIELD name="dataproduct_type" ucd="meta.id" datatype="char" arraysize="*"/>
<FIELD name="dataproduct_subtype" ucd="meta.id" datatype="char" arraysize="*"/>
<FIELD name="calib_level" ucd="meta.id" datatype="char" arraysize="*"/>
<DATA>
<TABLEDATA>
<TR>
<TD><![CDATA[https://eas.esac.esa.int/sas-dd/cutout?filepath=/data/repository_SC8/VIS/52930/EUC_VIS_SWL-DET-003-052930-0000000__20200312T122021.304478Z.fits&collection=VIS&obsid=52930&POS=CIRCLE,20.91,-20.13,8.35]]></TD>
<TD>VIS</TD>
<TD>LOCAL</TD>
<TD>{(0.187796741659535 , -0.313231004754935),(0.205062207849311 , -0.305728145820939),(0.213953839020568 , -0.323849132670641),(0.19660678223477 , -0.331397552487519)}</TD>
<TD>11.5079943262</TD>
<TD>-18.2524590675</TD>
<TD>52930</TD>
<TD>EUC-SC7</TD>
<TD>image</TD>
<TD>dpdVisCalibratedFrame3</TD>
<TD>2</TD>
</TR>
<TR>
<TD><![CDATA[https://eas.esac.esa.int/sas-dd/cutout?filepath=/data/repository_SC8/VIS/52930/EUC_VIS_SWL-DET-001-052930-0000000__20200312T122843.768360Z.fits&collection=VIS&obsid=52930&POS=CIRCLE,20.91,-20.13,8.35]]></TD>
<TD>VIS</TD>
<TD>LOCAL</TD>
<TD>{(0.187796741659535 , -0.313231004754935),(0.205062207849311 , -0.305728145820939),(0.213953839020568 , -0.323849132670641),(0.19660678223477 , -0.331397552487519)}</TD>
<TD>11.5079943262</TD>
<TD>-18.2524590675</TD>
<TD>52930</TD>
<TD>EUC-SC7</TD>
<TD>image</TD>
<TD>dpdVisCalibratedFrame1</TD>
<TD>2</TD>
</TR>
...
</TABLEDATA>
</DATA>
</TABLE>
</RESOURCE>
</VOTABLE>

POLYGON Search

Invoke:

curl "https://eas.esac.esa.int/sas-sia/sia2/query?POS=POLYGON,236,35,237,35,237,36,236,36"

Example Output (only first two results):

<?xml version="1.0" encoding="UTF-8"?>
<VOTABLE version="1.4" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.ivoa.net/xml/VOTable/v1.3 http://www.ivoa.net/xml/VOTable/v1.3" xmlns="http://www.ivoa.net/xml/VOTable/v1.3">
<RESOURCE type="results">
<INFO name="QUERY_STATUS" value="OK" />
<INFO name="PROVIDER" value=""></INFO>
<TABLE>
<FIELD name="access_url" ucd="meta.ref.url" datatype="char" arraysize="*"/>
<FIELD name="instrument_name" ucd="meta.id;instr" datatype="char" arraysize="*"/>
<FIELD name="facility_name" ucd="meta.id;instr.tel" datatype="char" arraysize="*"/>
<FIELD name="s_region" ucd="phys.angArea;obs" datatype="char" arraysize="*"/>
<FIELD name="s_ra" ucd="pos.eq.ra" datatype="char" arraysize="*"/>
<FIELD name="s_dec" ucd="pos.eq.dec" datatype="char" arraysize="*"/>
<FIELD name="obs_id" ucd="meta.id" datatype="char" arraysize="*"/>
<FIELD name="obs_collection" ucd="meta.id" datatype="char" arraysize="*"/>
<FIELD name="dataproduct_type" ucd="meta.id" datatype="char" arraysize="*"/>
<FIELD name="dataproduct_subtype" ucd="meta.id" datatype="char" arraysize="*"/>
<FIELD name="calib_level" ucd="meta.id" datatype="char" arraysize="*"/>
<DATA>
<TABLEDATA>
<TR>
<TD><![CDATA[https://eas.esac.esa.int/sas-dd/cutout?filepath=/data_staging/repository_SC8_test/VIS/18564/EUC_VIS_SWL-STK-000-000000-0000000__20210616T225608.771473Z.fits&collection=VIS&obsid=18564&POS=POLYGON,236.0,35.0,236.25,35.0,236.25,35.25,236.0,35.25]]></TD>
<TD>VIS</TD>
<TD></TD>
<TD>{(4.1101788123007 , 0.635387855335392),(4.11552206024856 , 0.633650189660458),(4.12085186046415 , 0.631898859638117),(4.12616796200301 , 0.630134024360106),(4.1314701183058 , 0.628355845292756),(4.12919210127594 , 0.623858883851949),(4.12692868150264 , 0.619359266964032),(4.12467974209763 , 0.614857245808604),(4.12244516707755 , 0.610353071352817),(4.11719923276864 , 0.612108225587659),(4.11194017313743 , 0.613850481704836),(4.10666823084876 , 0.61557968371816),(4.10138365262192 , 0.6172956779436),(4.10356091613544 , 0.621822043696588),(4.10575245074143 , 0.626346362254132),(4.10795837595374 , 0.630868383058724)}</TD>
<TD>235.8504637282</TD>
<TD>35.68835928829</TD>
<TD>18564</TD>
<TD>EUC-SC8</TD>
<TD>image</TD>
<TD>dpdVisStackedFrame</TD>
<TD>2</TD>
</TR>
<TR>
<TD><![CDATA[https://eas.esac.esa.int/sas-dd/cutout?filepath=/data_staging/repository_SC8_test/VIS/18565/EUC_VIS_SWL-STK-000-000000-0000000__20210616T231027.612325Z.fits&collection=VIS&obsid=18565&POS=POLYGON,236.0,35.0,236.25,35.0,236.25,35.25,236.0,35.25]]></TD>
<TD>VIS</TD>
<TD></TD>
<TD>{(4.10851689486889 , 0.621412449958531),(4.11379919092435 , 0.619707730846624),(4.11906883097245 , 0.617989777169228),(4.12432556884174 , 0.616258741319726),(4.12956916241674 , 0.614514777987319),(4.12735596927115 , 0.610020286935622),(4.12515653923124 , 0.60552330086941),(4.12297076539494 , 0.601024066767862),(4.12079854166158 , 0.596522831424079),(4.11560929497803 , 0.59824485823252),(4.1104076728932 , 0.599954397271445),(4.1051939135583 , 0.601651298968624),(4.0999682588764 , 0.60333541597463),(4.10208511941577 , 0.607857776377304),(4.10421543927645 , 0.612378233160017),(4.10635932771093 , 0.616896539893604)}</TD>
<TD>235.7555751717</TD>
<TD>34.89178251021</TD>
<TD>18565</TD>
<TD>EUC-SC8</TD>
<TD>image</TD>
<TD>dpdVisStackedFrame</TD>
<TD>2</TD>
</TR>
<TR>
...
</TABLEDATA>
</DATA>
</TABLE>
</RESOURCE>
</VOTABLE>

BOX Search by CALIB, INSTRUMENT and BAND

Invoke:

curl "https://eas.esac.esa.int/sas-sia/sia2/query?POS=BOX,20.91,-20.13,17.5&CALIB=CALIB_TWO&INSTRUMENT=VIS&BAND=VIS"

Example Output:

<?xml version="1.0" encoding="UTF-8"?>
<VOTABLE version="1.4" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.ivoa.net/xml/VOTable/v1.3 http://www.ivoa.net/xml/VOTable/v1.3" xmlns="http://www.ivoa.net/xml/VOTable/v1.3">
<RESOURCE type="results">
<INFO name="QUERY_STATUS" value="OK" />
<INFO name="PROVIDER" value=""></INFO>
<TABLE>
<FIELD name="access_url" ucd="meta.ref.url" datatype="char" arraysize="*"/>
<FIELD name="instrument_name" ucd="meta.id;instr" datatype="char" arraysize="*"/>
<FIELD name="facility_name" ucd="meta.id;instr.tel" datatype="char" arraysize="*"/>
<FIELD name="s_region" ucd="phys.angArea;obs" datatype="char" arraysize="*"/>
<FIELD name="s_ra" ucd="pos.eq.ra" datatype="char" arraysize="*"/>
<FIELD name="s_dec" ucd="pos.eq.dec" datatype="char" arraysize="*"/>
<FIELD name="obs_id" ucd="meta.id" datatype="char" arraysize="*"/>
<FIELD name="obs_collection" ucd="meta.id" datatype="char" arraysize="*"/>
<FIELD name="dataproduct_type" ucd="meta.id" datatype="char" arraysize="*"/>
<FIELD name="dataproduct_subtype" ucd="meta.id" datatype="char" arraysize="*"/>
<FIELD name="calib_level" ucd="meta.id" datatype="char" arraysize="*"/>
<DATA>
<TABLEDATA>
<TR>
<TD><![CDATA[https://eas.esac.esa.int/sas-dd/cutout?filepath=/data/repository_SC8/VIS/52930/EUC_VIS_SWL-DET-003-052930-0000000__20200312T122021.304478Z.fits&collection=VIS&obsid=52930&POS=BOX,20.91,-20.13,17.5]]></TD>
<TD>VIS</TD>
<TD>LOCAL</TD>
<TD>{(0.187796741659535 , -0.313231004754935),(0.205062207849311 , -0.305728145820939),(0.213953839020568 , -0.323849132670641),(0.19660678223477 , -0.331397552487519)}</TD>
<TD>11.5079943262</TD>
<TD>-18.2524590675</TD>
<TD>52930</TD>
<TD>EUC-SC7</TD>
<TD>image</TD>
<TD>dpdVisCalibratedFrame3</TD>
<TD>2</TD>
</TR>
<TR>
<TD><![CDATA[https://eas.esac.esa.int/sas-dd/cutout?filepath=/data/repository_SC8/VIS/52930/EUC_VIS_SWL-DET-001-052930-0000000__20200312T122843.768360Z.fits&collection=VIS&obsid=52930&POS=BOX,20.91,-20.13,17.5]]></TD>
<TD>VIS</TD>
<TD>LOCAL</TD>
<TD>{(0.187796741659535 , -0.313231004754935),(0.205062207849311 , -0.305728145820939),(0.213953839020568 , -0.323849132670641),(0.19660678223477 , -0.331397552487519)}</TD>
<TD>11.5079943262</TD>
<TD>-18.2524590675</TD>
<TD>52930</TD>
<TD>EUC-SC7</TD>
<TD>image</TD>
<TD>dpdVisCalibratedFrame1</TD>
<TD>2</TD>
</TR>
...
</TABLEDATA>
</DATA>
</TABLE>
</RESOURCE>
</VOTABLE>

Download individual cutouts

Individual cutouts can be downloaded with the links embedded in the above responses, but a previous log in sas-dd is required. For instance:

curl -k -c cookies.txt -X POST -d username=USERNAME -d password=PASSWORD -L "https://eas.esac.esa.int/sas-cutout/login"
curl -k -b cookies.txt -X GET "https://eas.esac.esa.int/sas-cutout/cutout?filepath=/data/repository/NIR/19704/EUC_NIR_W-STACK_NIR-J-19704_20190718T001858.5Z_00.00.fits&collection=NISP&obsid=19704&POS=CIRCLE,187.89,29.54,0.0333333333333333" > out.fits
curl -k -b cookies.txt -X POST -d -L "https://eas.esac.esa.int/sas-cutout/logout"

The response is the following image (out.fits):

images/confluence/download/attachments/120474430/Screenshot_20220601_193457.png

Parameter

Description

Mandatory

Possible values

FILEPATH

Path to the image to run the cutout algorithm

YES

NA

OBSID

Describes the Tile identifier or a list of them

YES (VIS, NIR)

NA

TILEINDEX

Tile index of the MER mosaic

YES (MER)

NA

POS

Describes the instruments within the following valid values or a list of them

YES

  • BOX

  • CIRCLE

  • POLYGON

COLLECTION

Name of the release collection

YES (VIS, NIR)

Optional for MER

  • NIR / NISP

  • VIS

  • MER

For a given known image you can modify the obsid and pos parameters in the previous example to directly request a cutout.