Create Product
This section describes how to submit a new product to the OAIS service (rs-ingest microservice) of REGARDS with
REST interfaces. The process and the input data are quite similar with AMQP interfaces to
submit a new
OAIS product.
Introduction
The diagram below explains the global processing of a new product submission request by REGARDS system.
For a REGARDS client using REST interface, the main steps are:
- Authenticate to REGARDS in order to retrieve a valid token for user. See the authenticate guide.
- Send your product archive request containing product information to
rs-ingestmicroservice - Retrieve information about your request status from
rs-ingestmicroservice.

REST API
How to
The Regards REST API concept describe how REST interfaces must be handled to submit requests.
Endpoint
| Endpoint | Verb |
|---|---|
| /sips | POST |
Request format
To submit a SIP Collection request, refers to openAPI description without filling the ref section. The ref section is used to submit a SIP by referencing a file instead of providing SIP information in the request body.
Request body parameter is a json formated object.
{
"type": "FeatureCollection",
"metadata": {},
"features": []
}
| Parameter | Description |
|---|---|
| type | Entity type, only possible value at this level is FeatureCollection |
| metadata | Contains metadata used by the service to process the SIP |
| features | List of SIP to submit. You can find more information about SIP format in the REGARDS OAIS appendice. |
metadata section contains :
Exemple with files storage
In the following example, only one SIP RawProduct_001 is submitted.
This product contains only one file located on file system at /products/2024/data_file.raw that will be stored one
Local Regards data storage ("pluginBusinessId": "Local"). That means that the Regards system and more
precisely rs-storage microservice must be able to access this file
to copy it to the
destination storage. Storage locations are configured in rs-storage microservice.
The "targetTypes" parameter can have the following values: ["THUMBNAIL", "RAWDATA", "QUICKLOOK_SD", "QUICKLOOK_MD",
"QUICKLOOK_HD", "OTHER", "DOCUMENT", "DESCRIPTION"]. If no value is specified, it will be all types.
{
"type": "FeatureCollection",
"metadata": {
"categories": [
"January-2024"
],
"ingestChain": "DefaultIngestChain",
"model": "DataModel01",
"session": "Submissions of 2024-08-01",
"sessionOwner": "Jean",
"storages": [
{
"pluginBusinessId": "Local",
"targetTypes": []
}
],
"submissionDate": "2024-08-01T00:15:22Z",
"versioningMode": "INC_VERSION"
},
"features": [
{
"type": "Feature",
"id": "RawProduct_001",
"bbox": [
-122.7,
45.51,
-122.64,
45.53
],
"crs": "WGS84",
"geometry": {
"coordinates": [
125.6,
10.1
],
"type": "Point"
},
"ipType": "DATA",
"properties": {
"contentInformations": [
{
"dataObject": {
"algorithm": "MD5",
"checksum": "145ff4e2fb057359fe66bd398aef3f9b",
"filename": "data_file.raw",
"locations": [
{
"url": "file:/products/2024/data_file.raw"
}
],
"regardsDataType": "RAWDATA"
},
"representationInformation": {
"syntax": {
"description": "Scientific raw data",
"mimeType": "application/octet-stream",
"name": "data_file.raw"
}
}
}
],
"descriptiveInformation": {
"mesure": "value"
},
"pdi": {}
}
}
]
}
Example with files reference
In the following example, only one SIP RawProduct_001 is submitted.
This product contains only one file located on a S3 server at https:/my.s3.server/bucket_01/data_file.raw.
As the storage location of the file is provided (properties.contentInformations.dataObject.locations.storage = S3Server), Regards system will not try to store the file but only
reference its given location. Nevertheless, with this system you must provide :
- Storage location : Should be an existing storage location defined
on rs-storage microservice.
If not, the file will be considered as
Offline and Regards will create the new storage location Offline in
rs-storagemicroservice. - File size in bytes : Regards will not access the file by itself so the information must be provided.
{
"type": "FeatureCollection",
"metadata": {
"categories": [
"January-2024"
],
"ingestChain": "DefaultIngestChain",
"model": "DataModel01",
"session": "Submissions of 2024-08-01",
"sessionOwner": "Jean",
"storages": [],
"submissionDate": "2024-08-01T00:15:22Z",
"versioningMode": "INC_VERSION"
},
"features": [
{
"type": "Feature",
"id": "RawProduct_001",
"bbox": [
-122.7,
45.51,
-122.64,
45.53
],
"crs": "WGS84",
"geometry": {
"coordinates": [
125.6,
10.1
],
"type": "Point"
},
"ipType": "DATA",
"properties": {
"contentInformations": [
{
"dataObject": {
"algorithm": "MD5",
"checksum": "145ff4e2fb057359fe66bd398aef3f9b",
"filename": "data_file.raw",
"fileSize": 1235689,
"locations": [
{
"storage": "S3Server",
"url": "https:/my.s3.server/bucket_01/data_file.raw"
}
],
"regardsDataType": "RAWDATA"
},
"representationInformation": {
"syntax": {
"description": "Scientific raw data",
"mimeType": "application/octet-stream",
"name": "data_file.raw"
}
}
}
],
"descriptiveInformation": {
"mesure": "value"
},
"pdi": {}
}
}
]
}
Response
Response body is a json formated object with :