MocServer / Form & Documentation v5.06 - May 2022
Form & Doc   Examples   Browser   Lint   Admin

MOC Server tool for retrieving as fast as possible the list of astronomical data sets (32794 catalogs, surveys, ... harvested from CDS and VO servers) having at least one observation in a specifical sky region/and or time range. The default result is an ID list. MOC Server is based on Multi-Order Coverage maps (MOC) described in the IVOA REC standard.

This form allows one to discover, test and check the various HTTP parameters supported by the MocServer remote API (inline spec).

Basic search

1) Cone & time search

MOC server can be queried by SIMPLE CONE SEARCH syntax. The search region is a circle on the sky and/or a time range.

RA,DEC must be expressed in degrees (ICRS), SR in degrees, TIME as 2 MJD values space separated

RA= & DEC= & SR= & TIME=

2) Basic space STC search

MOC server can be queried via a basic STC syntax. The search region is a STC string:

This version only supports Circle & Polygon in ICRS


3) Inline MOC search

MOC server can be queried by MOC string. The search coverage is a MOC (space, time or space-time) expressed as a string.

MOC must be a string following the ASCII or JSON syntax


4) URL MOC search

MOC server can be queried by a remote MOC. The search coverage is a remote MOC uploaded via an URL.

MOC must be a HTTP stream (FITS, ASCII or JSON syntax)


5) File MOC search

MOC server can be queried by a local MOC file. The search coverage is a local MOC uploaded via Multipart POST method (multipartID: moc).

MOC must be a local file (FITS, ASCII or JSON syntax)

*) Additionnal parameters

The following parameters can be added to the above queries in order to filter the results.

'intersect' param determines if the query coverage must overlap (default), enclosed, or cover the matching collection coverages,
'spacesys' and 'timesys' params determine the space and the time reference system concerned by the query coverage (if not specified, reference system will be ignored).

intersect= & spacesys= & timesys=

Advanced queries & parameters

i) Filtering by IDs or properties and output control

MOC server can also be queried/filtered by IDs(*) or any other property values. In this case, the query is not a query coverage but a combination of ID mask and property values. The default ASCII output format can be replaced by JSON. And the result list can provide a full record for each data set rather than a simple ID. In this case, the ouptut fields can be designated explicitely. It is also possible to get the number of matching data sets, or to be HTTP redirected on the URL (only in case of an unique answer and url field).

The ID selection must be an identifier or a template(**) of identifier or a comma separated template list. The field names are used for filtering the properties (***). The associated value must be a template(**) or a comma separated template list. The boolean logic is OR inside comma lists and AND between fields.
In "record" get mode, the list of output fields can be explicitely specified in "fields" as a comma separated template(**) list.

ID= & moc_sky_fraction= & ...
     & get= & fields= & fmt=
     & casesensitive= & MAXREC= &

Previous basic query modes can also accept any of these additional parameters in order to filter and/or control the result.

ii) Full set algebraic language control

Alternatively, MOC server can be queried via a full set algebra expression.

Each operand is a filter rule expression as described above. The operators are the union (→ ||), the intersection (→ &&) and the subtraction (→ &!).Parenthesis must be used to change the default operator priority. Expression values containing control characters (,),|,& must be quoted (" or '), and the possible internal quotes must be backslashed.Output control fields described above may be added for controlling the output content and format.

     & get= & fmt=

Previous query modes can also accept the MOC retrieval mode. In case of Cone Search or other query by region, the resulting MOC will be the intersection with the union (or intersection) of all matching MOCs

(*) ID is built from "creator_did" (alternatively "publisher_did", or or "creator_id/obs_id" or "publisher_id/obs_id") without "ivo://" prefix and only with slash (/) separator (canonical form)
(**) A template is a mask with basic wildcards (*, ?), possibly starting with (!) for negation mode or (<,>,<=,>=) for numerical, ISO8601 date or alphanumerical inequality test, ormin..max for range test.
(***) The field name must be prefixed by "filter." in case of parameter name synonym. It can incorporate wildcards.List of field name templates, comma (,) separated, are authorized. Templates without any explicit field name are relative to ID.
(****) An OR logic algorithm is used in case of list of fields/values/masks, except for the case where the operator is != (ex: obs_title,ID=!*CDS*,!*ESAVO*)

Meta data server

i) MOC server

MOC server can also be queried to retrieve MOC rather than IDs or dataset records.

The query must be an identifier or a mask of identifier (with wildcards), or a list of, comma separated.
The resulting MOC will be the union (resp. intersection) of the matching MOCs, projected on the spatial dimension (smoc), or explicitly on the temporal dimension (tmoc), or on both dimensions (stmoc) or according to the matching MOCs (anymoc). (If a physical dimension is required but missing, it is assumed to be present on the whole coverage.)
The resolution of the resulting MOC can be reduced, either explicitly by setting the maximum order (1 value in the case of a SMOC or TMOC, or 2 values preceded by an 's' and a 't' in the case of a STMOC), and/or by indicating the maximum allowed size suffixed by 'KB' or 'MB'.

ID= & get= op= & order= & fmt=

ii) Dataset record server

MOC server can also be used as a basic metadata server providing/updating dataset records for any remote client. With this form, MOC server returns the records requiring an update by comparing them with an input ID[=TIMESTAMP] list.

In case of empty list, all records are provided. If the list only contains one TIMESTAMP value, all records updated after the specified date will be provided. If the IDs are provided without =TIMESTAMP suffix, only these records will be provided. If the IDs are provided with a =TIMESTAMP suffix, only the records, amongs this list, updated after each specified date + the new records will be provided. The returned fields may be controlled with the "fields" parameter as described above. The IDs removed or unknown by the MOC server will be returned with the dedicated field: MOCSERVER_REMOVE = true.
List of ID[=TIMESTAMP] must be coded in ASCII format, one per line and sent via POST method (multipartID: maj).

& fields= & fmt=

iii) Property field list retrieval

MOC server may return the list of all used property key words (mainly ObsCore vocabulary), with a random example.
get= & fmt=

 MOCserver is developped by CDS