+
+

Response Types

+

The Copernicus Marine Toolbox commands return some information about the download. +It can contain useful metadata for the user.

+

For the CLI, all the returned data will be in a form of a json sent to stdout. +You can easily save it locally by doing, for example:

+
copernicusmarine get -i cmems_mod_glo_phy-thetao_anfc_0.083deg_P1M-m > my_json.json
+
+
+
+

Note

+

For the “get” and “subset” commands you can get those metadata without +downloading anything by using the dry_run option (or --dry-run flag for the CLI).

+
+
+

Commands Response

+
+
+class copernicusmarine.ResponseGet
+

Metadata returned when using get()

+
+
+files: list[FileGet]
+

Description of the files concerned by the query

+
+ +
+ +
+
+class copernicusmarine.ResponseSubset
+

Metadata returned when using subset()

+
+
+output: str
+

Path to the result file.

+
+ +
+
+size: float | None
+

Estimation of the size of the final result file.

+
+ +
+
+data_needed: float | None
+

Estimation of the maximum amount of data needed to +get the final result.

+
+ +
+
+coodinates_extent: DatasetCoordinatesExtent
+

The bounds of the subsetted dataset.

+
+ +
+ +
+
+

Subtypes

+
+
+class copernicusmarine.FileGet
+
+
+url: str
+

Full url of the location of the file server side.

+
+ +
+
+size: float
+

Size of the file in MB.

+
+ +
+
+last_modified: str
+

Last modified date.

+
+ +
+
+output: str
+

Path to the local downloaded file

+
+ +
+ +
+
+class copernicusmarine.DatasetCoordinatesExtent
+
+
+longitude: GeographicalExtent
+

Longitude Interval of the subsetted data.

+
+ +
+
+latitude: GeographicalExtent
+

Latitude Interval of the subsetted data.

+
+ +
+
+time: TimeExtent
+

Time Interval of the subsetted data in iso8601 string

+
+ +
+
+depth: GeographicalExtent | None
+

Depth Interval of the subsetted data.

+
+ +
+
+elevation: GeographicalExtent | None
+

Elevation Interval of the subsetted data. +Is relevant if data are requested for elevation +instead of depth

+
+ +
+ +
+
+class copernicusmarine.GeographicalExtent
+

Interval for geographical coordinates.

+
+
+minimum: float | None
+
+ +
+
+maximum: float | None
+
+ +
+ +
+
+class copernicusmarine.TimeExtent
+

Interval for time coordinate.

+
+
+minimum: str | None
+
+ +
+
+maximum: str | None
+
+ +
+ +
+
+ +