REST Functionality

GET : retrieval

PUT : ingest

PATCH : update (restricted by users and few definitions)

DELETE : deletion (restricted by users and few definitions)

Retrieve Data products

Retrieve single data product in XML

curl -u EC_ABELIKOV:XXX "https://eas-dps-rest-ops.esac.esa.int/REST?class_name=DpdVisRawFrame&Header.ProductId.LimitedString=SIMPV009230110351-NY9OCY9N-20230110-135847-0-outputSIM-18&project=EUCLID" 
<?xml version="1.0" encoding="UTF-8"?>
<dpd-le1-visrawframe:DpdVisRawFrame xmlns:dpd-le1-visrawframe="http://euclid.esa.org/schema/dpd/le1/visrawframe" xmlns:sys="http://euclid.esa.org/schema/sys" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:pro-le1-vis="http://euclid.esa.org/schema/pro/le1/vis" xmlns:pro-le1="http://euclid.esa.org/schema/pro/le1" xmlns:bas-img="http://euclid.esa.org/schema/bas/img" xmlns:ins="http://euclid.esa.org/schema/ins" xmlns:bas-utd="http://euclid.esa.org/schema/bas/utd" xmlns:bas-imp-eso="http://euclid.esa.org/schema/bas/imp/eso" xmlns:bas-dtd="http://euclid.esa.org/schema/bas/dtd" xmlns:bas-imp-fits="http://euclid.esa.org/schema/bas/imp/fits" xmlns:bas-imp-stc="http://euclid.esa.org/schema/bas/imp/stc" xmlns:bas-cot="http://euclid.esa.org/schema/bas/cot" xmlns:bas-fit="http://euclid.esa.org/schema/bas/fit" xmlns:sys-dss="http://euclid.esa.org/schema/sys/dss" xmlns:bas-ppr="http://euclid.esa.org/schema/bas/ppr" xmlns:bas-dqc="http://euclid.esa.org/schema/bas/dqc">
 <Header>
   <ProductId>SIMPV009230110351-NY9OCY9N-20230110-135847-0-outputSIM-18</ProductId>

Retrieve group of products in TGZ format (each data product in separate file) – 20 data products in tgz file

curl -u EC_ABELIKOV:XXX "https://eas-dps-rest-ops.esac.esa.int/REST?class_name=DpdVisRawFrame&Header.ProductId.LimitedString=likeSIMPV009230110351-NY9OCY9N-20230110-135847-0-outputSIM-*&project=EUCLID&file_format=TGZ" -o myproducts.tgz  
     % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current                                 Dload  Upload   Total   Spent    Left  Speed
     100 74561  100 74561    0     0   1056      0  0:01:10  0:01:10 --:--:-- 17610

Retrieve Data Products asynchronously

  1. submit request with make_asy=True
    curl -u EC_ABELIKOV:XXX "https://eas-dps-rest-ops.esac.esa.int/REST?class_name=DpdVisRawFrame&Header.ProductId.LimitedString=likeSIMPV009230110351-NY9OCY9N-20230110-135847-0-outputSIM-*&project=EUCLID&file_format=TGZ&make_asy=True"
    
    {"status": "RUNNING", "url": "https://eas-dps-rest-ops-node03.esac.esa.int/REST?job_id=a65067d4-30d8-4bc1-8132-9a6b3c45af33", "message": "", "errors": "", "stats": ""}
    
  2. check job status
    curl -u EC_ABELIKOV:XXX "https://eas-dps-rest-ops-node03.esac.esa.int/REST?job_id=a65067d4-30d8-4bc1-8132-9a6b3c45af33"
    
    {"status": "RUNNING", "url": "https://eas-dps-rest-ops-node03.esac.esa.int/REST?job_id=a65067d4-30d8-4bc1-8132-9a6b3c45af33", "message": "", "errors": "", "stats": ""}
    
    curl -u EC_ABELIKOV:XXX "https://eas-dps-rest-ops-node03.esac.esa.int/REST?job_id=a65067d4-30d8-4bc1-8132-9a6b3c45af33"
    
    {"status": "FINISHED", "url": "https://eas-dps-rest-ops-node03.esac.esa.int/REST?file_name=2023-03-13/DpdVisRawFrame-a65067d4-30d8-4bc1-8132-9a6b3c45af33.tgz", "message": "", "errors": "", "stats": ""}
    
  3. retrieve results
    curl -u EC_ABELIKOV:XXX "https://eas-dps-rest-ops-node03.esac.esa.int/REST?file_name=2023-03-13/DpdVisRawFrame-a65067d4-30d8-4bc1-8132-9a6b3c45af33.tgz" -o myproducts.tgz
    
      % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                  Dload  Upload   Total   Spent    Left  Speed
    100 75088  100 75088    0     0   106k      0 --:--:-- --:--:-- --:--:--  106k
    

Ingest Data Products

Ingest XML file

curl -k -X PUT  -u EC_ABELIKOV:XXX "https://eas-dps-rest-ops.esac.esa.int/REST?PROJECT=DMTEST&commit=True" --data-binary @ppo_test.xml
{'status': 'FINISHED', 'url': '', 'message': '', 'errors': {}, 'stats': {'fileload_time': 0.0027227401733398438, 'database_time': 2.384185791015625e-06, 'datamodel_time': 0.7243959903717041, 'ingest_time': 0.8513739109039307, 'total_time': 1.5784950256347656, 'filename': '', 'project': 'DMTEST', 'commit': 'True', 'privileges': 2, 'username': 'EC_ABELIKOV'}}

Ingest a number of data products in TGZ file

curl -k -X PUT  -u EC_ABELIKOV:XXX "https://eas-dps-rest-ops.esac.esa.int/REST?PROJECT=DMTEST&commit=True" --data-binary @myproducts.tgz

In case of many data products to ingest please use make_asy=True