Download OpenAPI specification:Download
SkyPortal provides an API to access most of its underlying
functionality. To use it, you will need an API token. This
can be generated via the web application from your profile page or, if
you are an admin, you may use the system provisioned token stored
inside of .tokens.yaml
.
Once you have a token, you may access SkyPortal programmatically as follows.
import requests
token = 'ea70a5f0-b321-43c6-96a1-b2de225e0339'
def api(method, endpoint, data=None):
headers = {'Authorization': f'token {token}'}
response = requests.request(method, endpoint, json=data, headers=headers)
return response
response = api('GET', 'http://localhost:5000/api/sysinfo')
print(f'HTTP code: {response.status_code}, {response.reason}')
if response.status_code in (200, 400):
print(f'JSON response: {response.json()}')
curl -s -H 'Authorization: token ea70a5f0-b321-43c6-96a1-b2de225e0339' http://localhost:5000/api/sysinfo
There are two ways to pass information along with a request: path and body parameters.
Path parameters (also called query or URL parameters) are embedded in
the URL called. For example, you can specify numPerPage
or
pageNumber
path parameters when calling /api/candidates
as
follows:
curl -s -H 'Authorization: token ea70a5f0-b321-43c6-96a1-b2de225e0339' \
http://localhost:5000/api/candidates?numPerPage=100&pageNumber=1
When using Python's requests
library, a dictionary of path
parameters can be passed in via the params
keyword argument:
token = 'ea70a5f0-b321-43c6-96a1-b2de225e0339'
response = requests.get(
"http://localhost:5000/api/sources",
params={"includeComments": True, "includeThumbnails": False},
headers={'Authorization': f'token {token}'},
)
Request body parameters (or simply: the body of the request)
contains data uploaded to a specific endpoint. These are the
parameters listed under REQUEST BODY SCHEMA: application/json
in the
API docs.
When using Python's requests
library, body parameters are specified
using the json
keyword argument:
token = "abc"
response = requests.post(
"http://localhost:5000/api/sources",
json={
"id": "14gqr",
"ra": 353.36647,
"dec": 33.646149,
"group_ids": [52, 97],
},
headers={"Authorization": f"token {token}"},
)
In the above examples, the SkyPortal server is located at
http://localhost:5000
. In case of success, the HTTP response is 200:
HTTP code: 200, OK
JSON response: {'status': 'success', 'data': {}, 'version': '0.9.dev0+git20200819.84c453a'}
On failure, it is 400; the JSON response has status="error"
with the reason
for the failure given in message
:
{
"status": "error",
"message": "Invalid API endpoint",
"data": {},
"version": "0.9.1"
}
Several API endpoints (notably the sources and candidates APIs) enforce pagination to limit the number of records that can be fetched per request. These APIs expose parameters that facilitate pagination (see the various API docs for details). A sample pagination script is included here:
import requests
import time
base_url = "https://fritz.science/api/sources"
token = "your_token_id_here"
group_ids = [4, 71] # If applicable
all_sources = []
num_per_page = 500
page = 1
total_matches = None
retry_attempts = 0
max_retry_attempts = 10
while retry_attempts <= max_retry_attempts:
r = requests.get(
f"{base_url}?group_ids={','.join([str(gid) for gid in group_ids])}&pageNumber={page}&numPerPage={num_per_page}&totalMatches={total_matches}",
headers={"Authorization": f"token {token}"},
)
if r.status_code == 429:
print("Request rate limit exceeded; sleeping 1s before trying again...")
time.sleep(1)
continue
data = r.json()
if data["status"] != "success":
print(data) # log as appropriate
retry_attempts += 1
time.sleep(5)
continue
else:
retry_attempts = 0
all_sources.extend(data["data"]["sources"])
total_matches = data["data"]["totalMatches"]
print(f"Fetched {len(all_sources)} of {total_matches} sources.")
if len(all_sources) >= total_matches:
break
page += 1
Produce a report on allocations for an instrument
instrument_id required | integer |
output_format | string Output format for analysis. Can be png or pdf |
{- "status": "success",
- "message": "string"
}
Retrieve an allocation
allocation_id required | integer |
{- "status": "success",
- "data": {
- "requests": [
- null
], - "default_requests": [
- null
], - "default_observation_plans": [
- null
], - "catalog_queries": [
- null
], - "observation_plans": [
- null
], - "group": null,
- "instrument": null,
- "allocation_users": [
- null
], - "gcn_triggers": [
- null
], - "pi": "string",
- "proposal_id": "string",
- "start_date": "2023-07-10T21:32:34Z",
- "end_date": "2023-07-10T21:32:34Z",
- "hours_allocated": 0,
- "default_share_group_ids": null,
- "group_id": 0,
- "instrument_id": 0,
- "_altdata": "string",
- "id": 0
}, - "message": "string"
}
Update an allocation on a robotic instrument
allocation_id required | integer |
requests | Array of any |
default_requests | Array of any |
default_observation_plans | Array of any |
catalog_queries | Array of any |
observation_plans | Array of any |
group | any Nullable The Group the allocation is associated with. |
instrument | any Nullable The Instrument the allocation is associated with. |
allocation_users | Array of any |
gcn_triggers | Array of any |
pi | string Nullable The PI of the allocation's proposal. |
proposal_id | string Nullable The ID of the proposal associated with this allocation. |
start_date | string <date-time> Nullable The UTC start date of the allocation. |
end_date | string <date-time> Nullable The UTC end date of the allocation. |
hours_allocated required | number The number of hours allocated. |
default_share_group_ids | any Nullable |
group_id required | integer The ID of the Group the allocation is associated with. |
instrument_id required | integer The ID of the Instrument the allocation is associated with. |
_altdata | string Nullable |
{- "requests": [
- null
], - "default_requests": [
- null
], - "default_observation_plans": [
- null
], - "catalog_queries": [
- null
], - "observation_plans": [
- null
], - "group": null,
- "instrument": null,
- "allocation_users": [
- null
], - "gcn_triggers": [
- null
], - "pi": "string",
- "proposal_id": "string",
- "start_date": "2023-07-10T21:32:34Z",
- "end_date": "2023-07-10T21:32:34Z",
- "hours_allocated": 0,
- "default_share_group_ids": null,
- "group_id": 0,
- "instrument_id": 0,
- "_altdata": "string"
}
{- "status": "success",
- "message": "string"
}
{- "status": "success",
- "message": "string"
}
Retrieve all allocations
instrument_id | number Instrument ID to retrieve allocations for |
{- "status": "success",
- "data": [
- {
- "requests": [
- null
], - "default_requests": [
- null
], - "default_observation_plans": [
- null
], - "catalog_queries": [
- null
], - "observation_plans": [
- null
], - "group": null,
- "instrument": null,
- "allocation_users": [
- null
], - "gcn_triggers": [
- null
], - "pi": "string",
- "proposal_id": "string",
- "start_date": "2023-07-10T21:32:34Z",
- "end_date": "2023-07-10T21:32:34Z",
- "hours_allocated": 0,
- "default_share_group_ids": null,
- "group_id": 0,
- "instrument_id": 0,
- "_altdata": "string",
- "id": 0
}
], - "message": "string"
}
Post new allocation on a robotic instrument
requests | Array of any |
default_requests | Array of any |
default_observation_plans | Array of any |
catalog_queries | Array of any |
observation_plans | Array of any |
group | any Nullable The Group the allocation is associated with. |
instrument | any Nullable The Instrument the allocation is associated with. |
allocation_users | Array of any |
gcn_triggers | Array of any |
pi | string Nullable The PI of the allocation's proposal. |
proposal_id | string Nullable The ID of the proposal associated with this allocation. |
start_date | string <date-time> Nullable The UTC start date of the allocation. |
end_date | string <date-time> Nullable The UTC end date of the allocation. |
hours_allocated required | number The number of hours allocated. |
default_share_group_ids | any Nullable |
group_id required | integer The ID of the Group the allocation is associated with. |
instrument_id required | integer The ID of the Instrument the allocation is associated with. |
_altdata | string Nullable |
{- "requests": [
- null
], - "default_requests": [
- null
], - "default_observation_plans": [
- null
], - "catalog_queries": [
- null
], - "observation_plans": [
- null
], - "group": null,
- "instrument": null,
- "allocation_users": [
- null
], - "gcn_triggers": [
- null
], - "pi": "string",
- "proposal_id": "string",
- "start_date": "2023-07-10T21:32:34Z",
- "end_date": "2023-07-10T21:32:34Z",
- "hours_allocated": 0,
- "default_share_group_ids": null,
- "group_id": 0,
- "instrument_id": 0,
- "_altdata": "string"
}
{- "status": "success",
- "message": "string",
- "data": {
- "id": 0
}
}
Retrieve all observation analyses
gcnevent_id | number GcnEvent ID to retrieve observation efficiency analyses for |
{- "status": "success",
- "data": [
- {
- "gcnevent": null,
- "localization": null,
- "instrument": null,
- "requester": null,
- "groups": [
- null
], - "gcnevent_id": 0,
- "localization_id": 0,
- "instrument_id": 0,
- "id": 0,
- "payload": null,
- "status": "string",
- "lightcurves": null,
- "requester_id": 0
}
], - "message": "string"
}
Retrieve all observation plan efficiency analyses
observation_plan_id | number EventObservationPlan ID to retrieve observation plan efficiency analyses for |
{- "status": "success",
- "data": [
- {
- "observation_plan": null,
- "requester": null,
- "groups": [
- null
], - "observation_plan_id": 0,
- "id": 0,
- "payload": null,
- "status": "string",
- "lightcurves": null,
- "requester_id": 0
}
], - "message": "string"
}
Retrieve a default analysis
analysis_service_id required | any Analysis service ID |
default_analysis_id required | any Default analysis ID |
{- "status": "success",
- "data": {
- "analysis_service": null,
- "groups": [
- null
], - "author": null,
- "analysis_service_id": 0,
- "show_parameters": true,
- "show_plots": true,
- "show_corner": true,
- "default_analysis_parameters": "string",
- "source_filter": null,
- "stats": null,
- "author_id": 0,
- "id": 0
}, - "message": "string"
}
Delete a default analysis
analysis_service_id required | integer Analysis service ID |
default_analysis_id required | integer Default analysis ID |
{- "status": "success",
- "message": "string"
}
Retrieve all default analyses
analysis_service_id required | any Analysis service ID, if not provided, return all default analyses for all analysis services |
{- "status": "success",
- "data": [
- {
- "analysis_service": null,
- "groups": [
- null
], - "author": null,
- "analysis_service_id": 0,
- "show_parameters": true,
- "show_plots": true,
- "show_corner": true,
- "default_analysis_parameters": "string",
- "source_filter": null,
- "stats": null,
- "author_id": 0,
- "id": 0
}
], - "message": "string"
}
Get Swift LSXPS objects and post them as sources. Repeated posting will skip the existing source.
telescope_name | integer Name of telescope to assign this catalog to. Use the same name as your nickname for the Neil Gehrels Swift Observatory. Defaults to Swift. |
groupIDs | object If provided, save to these group IDs. |
{- "telescope_name": 0,
- "groupIDs": { }
}
{- "status": "success",
- "message": "string"
}
Get Gaia Photometric Alert objects and post them as sources. Repeated posting will skip the existing source.
telescope_name | string Name of telescope to assign this catalog to. Use the same name as your nickname for Gaia. Defaults to Gaia. |
groupIDs | object If provided, save to these group IDs. |
startDate | str Arrow parsable string. Filter by start date. |
endDate | str Arrow parsable string. Filter by end date. |
{- "telescope_name": "string",
- "groupIDs": { },
- "startDate": null,
- "endDate": null
}
{- "status": "success",
- "message": "string"
}
{- "status": "success",
- "data": [
- {
- "sent_by": null,
- "notices": [
- null
], - "predictions": [
- null
], - "measurements": [
- null
], - "comments": [
- null
], - "reminders": [
- null
], - "sent_by_id": 0,
- "event_id": "string",
- "event_uri": "string",
- "status": "string",
- "id": 0
}
], - "message": "string"
}
get Gaia parallax and magnitudes and post them as an annotation, based on cross-match to the Gaia DR3.
obj_id required | string ID of the object to retrieve Gaia colors for |
catalog | string The name of the catalog key, associated with a catalog cross match, from which the data should be retrieved. Default is "gaiadr3.gaia_source". |
crossmatchRadius | number Crossmatch radius (in arcseconds) to retrieve Gaia sources If not specified (or None) will use the default from the config file, or 2 arcsec if not specified in the config. |
crossmatchLimmag | number Crossmatch limiting magnitude (for Gaia G mag). Will ignore sources fainter than this magnitude. If not specified, will use the default value in the config file, or None if not specified in the config. If value is cast to False (0, False or None), will take sources of any magnitude. |
group_ids | Array of integers List of group IDs corresponding to which groups should be able to view annotation. Defaults to all of requesting user's groups. |
{- "catalog": "string",
- "crossmatchRadius": 0,
- "crossmatchLimmag": 0,
- "group_ids": [
- 0
]
}
{- "status": "success",
- "message": "string"
}
get WISE colors and post them as an annotation based on cross-matches to some catalog (default is allwise_p3as_psd).
obj_id required | string ID of the object to retrieve WISE colors for |
catalog | string The name of the catalog key, associated with a catalog cross match, from which the data should be retrieved. Default is allwise_p3as_psd. |
crossmatchRadius | number Crossmatch radius (in arcseconds) to retrieve photoz's Default is 2. |
group_ids | Array of integers List of group IDs corresponding to which groups should be able to view annotation. Defaults to all of requesting user's groups. |
{- "catalog": "string",
- "crossmatchRadius": 0,
- "group_ids": [
- 0
]
}
{- "status": "success",
- "message": "string"
}
get cross-match with Vizier and post them as an annotation based on cross-matches to some catalog (default is VII/290, i.e. the million quasar catalog).
obj_id required | string ID of the object to retrieve the Vizier crossmatch for |
catalog | string The name of the catalog key, associated with a catalog cross match, from which the data should be retrieved. Default is VII/290. |
crossmatchRadius | number Crossmatch radius (in arcseconds) to retrieve photoz's Default is 2. |
group_ids | Array of integers List of group IDs corresponding to which groups should be able to view annotation. Defaults to all of requesting user's groups. |
{- "catalog": "string",
- "crossmatchRadius": 0,
- "group_ids": [
- 0
]
}
{- "status": "success",
- "message": "string"
}
Generate a PDF/PNG finding chart for a position or Gaia ID
location_type required | string Enum: "gaia_dr3" "gaia_dr2" "pos" What is the type of the search? From gaia or by position? If |
catalog_id | string |
ra | float [ 0 .. 360 ) RA of the source of interest at the time of observation of interest (ie. the user is responsible for proper motion calulations). |
dec | float [ -90 .. 90 ] DEC of the source of interest at the time of observation of interest (ie. the user is responsible for proper motion calulations). |
imsize | float [ 2 .. 15 ] Image size in arcmin (square). Defaults to 4.0 |
facility | string Enum: "Keck" "Shane" "P200" What type of starlist should be used? Defaults to Keck |
image_source | string Enum: "ps1" "desi" "dss" "ztfref" Source of the image used in the finding chart. Defaults to ps1 |
use_ztfref | boolean Use ZTFref catalog for offset star positions, otherwise DR3. Defaults to True. |
obstime | string datetime of observation in isoformat (e.g. 2020-12-30T12:34:10). Defaults to now. |
type | string Enum: "png" "pdf" Output datafile type. Defaults to pdf. |
num_offset_stars | integer [ 0 .. 4 ] Number of offset stars to determine and show [0,4] (default: 3) |
A PDF/PNG finding chart file
{- "status": "error",
- "data": { },
- "message": "string"
}
Retrieve an Analysis Service by id
analysis_service_id required | integer |
{- "status": "success",
- "data": {
- "groups": [
- null
], - "obj_analyses": [
- null
], - "default_analyses": [
- null
], - "name": "string",
- "display_name": "string",
- "description": "string",
- "version": "string",
- "contact_name": "string",
- "contact_email": "string",
- "url": "string",
- "optional_analysis_parameters": "string",
- "authentication_type": "none",
- "_authinfo": "string",
- "enabled": true,
- "analysis_type": "lightcurve_fitting",
- "input_data_types": [
- null
], - "timeout": 0,
- "upload_only": true,
- "display_on_resource_dropdown": true,
- "is_summary": true,
- "id": 0
}, - "message": "string"
}
Delete an Analysis Service.
analysis_service_id required | integer |
{- "status": "success",
- "message": "string"
}
{- "status": "success",
- "data": [
- {
- "groups": [
- null
], - "obj_analyses": [
- null
], - "default_analyses": [
- null
], - "name": "string",
- "display_name": "string",
- "description": "string",
- "version": "string",
- "contact_name": "string",
- "contact_email": "string",
- "url": "string",
- "optional_analysis_parameters": "string",
- "authentication_type": "none",
- "_authinfo": "string",
- "enabled": true,
- "analysis_type": "lightcurve_fitting",
- "input_data_types": [
- null
], - "timeout": 0,
- "upload_only": true,
- "display_on_resource_dropdown": true,
- "is_summary": true,
- "id": 0
}
], - "message": "string"
}
Upload an upload_only analysis result
analysis_resource_type required | string What underlying data the analysis is on: must be "obj" (more to be added in the future) |
resource_id required | string The ID of the underlying data. This would be a string for an object ID. |
analysis_service_id required | string the analysis service id to be used |
results | object Results data of this analysis |
show_parameters | boolean Whether to render the parameters of this analysis |
show_plots | boolean Whether to render the plots of this analysis |
show_corner | boolean Whether to render the corner plots of this analysis |
group_ids | Array of integers List of group IDs corresponding to which groups should be able to view analysis results. Defaults to all of requesting user's groups. |
{- "results": { },
- "show_parameters": true,
- "show_plots": true,
- "show_corner": true,
- "group_ids": [
- 0
]
}
{- "status": "success",
- "message": "string",
- "data": {
- "analysis_id": 0
}
}
Retrieve an Analysis by id
analysis_resource_type required | string What underlying data the analysis is on: must be "obj" (more to be added in the future) |
analysis_id required | int ID of the analysis to return. |
objID | string Return any analysis on an object with ID objID |
analysisServiceID | int ID of the analysis service used to create the analysis, used only if no analysis_id is given |
includeAnalysisData | boolean Boolean indicating whether to include the data associated with the analysis in the response. Could be a large amount of data. Only works for single analysis requests. Defaults to false. |
summaryOnly | boolean Boolean indicating whether to return only analyses that
use analysis services with |
includeFilename | boolean Boolean indicating whether to include the filename of the data associated with the analysis in the response. Defaults to false. |
{- "status": "success",
- "data": {
- "obj": null,
- "author": null,
- "analysis_service": null,
- "groups": [
- null
], - "obj_id": "string",
- "id": 0,
- "_unique_id": "string",
- "hash": "string",
- "_full_name": "string",
- "show_parameters": true,
- "show_plots": true,
- "show_corner": true,
- "analysis_parameters": "string",
- "author_id": 0,
- "analysis_service_id": 0,
- "invalid_after": "2023-07-10T21:32:34Z",
- "token": "string",
- "handled_by_url": "string",
- "status": "queued",
- "duration": 0,
- "last_activity": "2023-07-10T21:32:34Z",
- "status_message": "string"
}, - "message": "string"
}
{- "status": "success",
- "message": "string"
}
{- "status": "success",
- "data": [
- {
- "obj": null,
- "author": null,
- "analysis_service": null,
- "groups": [
- null
], - "obj_id": "string",
- "id": 0,
- "_unique_id": "string",
- "hash": "string",
- "_full_name": "string",
- "show_parameters": true,
- "show_plots": true,
- "show_corner": true,
- "analysis_parameters": "string",
- "author_id": 0,
- "analysis_service_id": 0,
- "invalid_after": "2023-07-10T21:32:34Z",
- "token": "string",
- "handled_by_url": "string",
- "status": "queued",
- "duration": 0,
- "last_activity": "2023-07-10T21:32:34Z",
- "status_message": "string"
}
], - "message": "string"
}
Begin an analysis run
analysis_resource_type required | string What underlying data the analysis is on: must be "obj" (more to be added in the future) |
resource_id required | string The ID of the underlying data. This would be a string for an object ID. |
analysis_service_id required | string the analysis service id to be used |
show_parameters | boolean Whether to render the parameters of this analysis |
show_plots | boolean Whether to render the plots of this analysis |
show_corner | boolean Whether to render the corner plots of this analysis |
analysis_parameters | object Dictionary of parameters to be passed thru to the analysis |
group_ids | Array of integers List of group IDs corresponding to which groups should be able to view analysis results. Defaults to all of requesting user's groups. |
{- "show_parameters": true,
- "show_plots": true,
- "show_corner": true,
- "analysis_parameters": {
- "property1": "string",
- "property2": "string"
}, - "group_ids": [
- 0
]
}
{- "status": "success",
- "message": "string",
- "data": {
- "analysis_id": 0
}
}
Retrieve an Analysis by id
analysis_resource_type required | string What underlying data the analysis is on: must be "obj" (more to be added in the future) |
analysis_id required | int ID of the analysis to return. |
objID | string Return any analysis on an object with ID objID |
analysisServiceID | int ID of the analysis service used to create the analysis, used only if no analysis_id is given |
includeAnalysisData | boolean Boolean indicating whether to include the data associated with the analysis in the response. Could be a large amount of data. Only works for single analysis requests. Defaults to false. |
summaryOnly | boolean Boolean indicating whether to return only analyses that
use analysis services with |
includeFilename | boolean Boolean indicating whether to include the filename of the data associated with the analysis in the response. Defaults to false. |
{- "status": "success",
- "data": {
- "obj": null,
- "author": null,
- "analysis_service": null,
- "groups": [
- null
], - "obj_id": "string",
- "id": 0,
- "_unique_id": "string",
- "hash": "string",
- "_full_name": "string",
- "show_parameters": true,
- "show_plots": true,
- "show_corner": true,
- "analysis_parameters": "string",
- "author_id": 0,
- "analysis_service_id": 0,
- "invalid_after": "2023-07-10T21:32:34Z",
- "token": "string",
- "handled_by_url": "string",
- "status": "queued",
- "duration": 0,
- "last_activity": "2023-07-10T21:32:34Z",
- "status_message": "string"
}, - "message": "string"
}
{- "status": "success",
- "message": "string"
}
{- "status": "success",
- "data": [
- {
- "obj": null,
- "author": null,
- "analysis_service": null,
- "groups": [
- null
], - "obj_id": "string",
- "id": 0,
- "_unique_id": "string",
- "hash": "string",
- "_full_name": "string",
- "show_parameters": true,
- "show_plots": true,
- "show_corner": true,
- "analysis_parameters": "string",
- "author_id": 0,
- "analysis_service_id": 0,
- "invalid_after": "2023-07-10T21:32:34Z",
- "token": "string",
- "handled_by_url": "string",
- "status": "queued",
- "duration": 0,
- "last_activity": "2023-07-10T21:32:34Z",
- "status_message": "string"
}
], - "message": "string"
}
Begin an analysis run
analysis_resource_type required | string What underlying data the analysis is on: must be "obj" (more to be added in the future) |
resource_id required | string The ID of the underlying data. This would be a string for an object ID. |
analysis_service_id required | string the analysis service id to be used |
show_parameters | boolean Whether to render the parameters of this analysis |
show_plots | boolean Whether to render the plots of this analysis |
show_corner | boolean Whether to render the corner plots of this analysis |
analysis_parameters | object Dictionary of parameters to be passed thru to the analysis |
group_ids | Array of integers List of group IDs corresponding to which groups should be able to view analysis results. Defaults to all of requesting user's groups. |
{- "show_parameters": true,
- "show_plots": true,
- "show_corner": true,
- "analysis_parameters": {
- "property1": "string",
- "property2": "string"
}, - "group_ids": [
- 0
]
}
{- "status": "success",
- "message": "string",
- "data": {
- "analysis_id": 0
}
}
Retrieve primary data associated with an Analysis.
analysis_resource_type required | string What underlying data the analysis is on: must be "obj" (more to be added in the future) |
analysis_id required | integer |
product_type required | string What type of data to retrieve: must be one of "corner", "results", or "plot" |
plot_number required | integer if product_type == "plot", which plot number should be returned? Default to zero (first plot). |
download | bool Download the results as a file |
plot_kwargs | object Extra parameters to pass to the plotting functions if new plots are to be generated (e.g. with corner plots) |
Requested analysis file
{- "download": null,
- "plot_kwargs": {
- "property1": { },
- "property2": { }
}
}
{ }
Retrieve an observing run assignment
assignment_id required | integer |
{- "status": "success",
- "data": {
- "requester": null,
- "last_modified_by": null,
- "obj": null,
- "spectra": [
- null
], - "photometry": [
- null
], - "photometric_series": [
- null
], - "run": null,
- "requester_id": 0,
- "last_modified_by_id": 0,
- "obj_id": "string",
- "comment": "string",
- "status": "string",
- "priority": "1",
- "run_id": 0,
- "id": 0
}, - "message": "string"
}
Update an assignment
assignment_id required | integer |
requester | any Nullable The User who created this assignment. |
last_modified_by | any Nullable |
obj | any Nullable The assigned Obj. |
spectra | Array of any |
photometry | Array of any |
photometric_series | Array of any |
run | any Nullable The ObservingRun this target was assigned to. |
requester_id required | integer The ID of the User who created this assignment. |
obj_id required | string ID of the assigned Obj. |
comment | string Nullable A comment on the assignment. Typically a justification for the request, or instructions for taking the data. |
status | string Status of the assignment [done, not done, pending]. |
priority required | string <= 1 characters Enum: "1" "2" "3" "4" "5" Priority of the request (1 = lowest, 5 = highest). |
run_id required | integer ID of the ObservingRun this target was assigned to. |
{- "requester": null,
- "last_modified_by": null,
- "obj": null,
- "spectra": [
- null
], - "photometry": [
- null
], - "photometric_series": [
- null
], - "run": null,
- "requester_id": 0,
- "obj_id": "string",
- "comment": "string",
- "status": "string",
- "priority": "1",
- "run_id": 0
}
{- "status": "success",
- "message": "string"
}
{- "status": "success",
- "message": "string"
}
{- "status": "success",
- "data": [
- {
- "requester": null,
- "last_modified_by": null,
- "obj": null,
- "spectra": [
- null
], - "photometry": [
- null
], - "photometric_series": [
- null
], - "run": null,
- "requester_id": 0,
- "last_modified_by_id": 0,
- "obj_id": "string",
- "comment": "string",
- "status": "string",
- "priority": "1",
- "run_id": 0,
- "id": 0
}
], - "message": "string"
}
Post new target assignment to observing run
comment | string An optional comment describing the request. |
obj_id required | string The ID of the object to observe. |
run_id required | integer |
status | string The status of the request |
priority required | any Enum: "1" "2" "3" "4" "5" Priority of the request, (lowest = 1, highest = 5). |
{- "comment": "string",
- "obj_id": "string",
- "run_id": 0,
- "status": "string",
- "priority": "1"
}
{- "status": "success",
- "message": "string",
- "data": {
- "id": 0
}
}
Retrieve a candidate
obj_id required | string |
includeComments | boolean Boolean indicating whether to include associated comments. Defaults to false. |
includeAlerts | boolean Boolean indicating whether to include associated alerts. Defaults to false. |
{- "status": "success",
- "data": {
- "host": null,
- "comments": [
- null
], - "reminders": [
- null
], - "comments_on_spectra": [
- null
], - "reminders_on_spectra": [
- null
], - "annotations": [
- null
], - "annotations_on_spectra": [
- null
], - "annotations_on_photometry": [
- null
], - "classifications": [
- null
], - "photometry": [
- null
], - "photstats": [
- null
], - "photometric_series": [
- null
], - "spectra": [
- null
], - "thumbnails": [
- null
], - "followup_requests": [
- null
], - "assignments": [
- null
], - "obj_notifications": [
- null
], - "obj_analyses": [
- null
], - "sources_in_gcns": [
- null
], - "id": "string",
- "ra_dis": 0,
- "dec_dis": 0,
- "ra_err": 0,
- "dec_err": 0,
- "offset": 0,
- "redshift": 0,
- "redshift_error": 0,
- "redshift_origin": "string",
- "redshift_history": null,
- "host_id": 0,
- "summary": "string",
- "summary_history": null,
- "altdata": null,
- "dist_nearest_source": 0,
- "mag_nearest_source": 0,
- "e_mag_nearest_source": 0,
- "transient": true,
- "varstar": true,
- "is_roid": true,
- "mpc_name": "string",
- "gcn_crossmatch": null,
- "tns_name": "string",
- "tns_info": null,
- "score": 0,
- "origin": "string",
- "alias": null,
- "internal_key": "string",
- "detect_photometry_count": 0,
- "ra": 0,
- "dec": 0,
- "candidates": [
- null
], - "sources": [
- null
], - "users": [
- null
]
}, - "message": "string"
}
Check if a Candidate exists
obj_id required | string |
{- "status": "success",
- "message": "string"
}
Delete candidate(s)
obj_id required | string |
filter_id required | integer |
{- "status": "success",
- "message": "string"
}
Retrieve all candidates
numPerPage | integer Number of candidates to return per paginated request. Defaults to 25. Capped at 500. |
pageNumber | integer Page number for paginated query results. Defaults to 1 |
totalMatches | integer Used only in the case of paginating query results - if provided, this allows for avoiding a potentially expensive query.count() call. |
autosave | boolean Automatically save candidates passing query. |
autosaveGroupIds | boolean Group ID(s) to save candidates to. |
savedStatus | string Enum: "all" "savedToAllSelected" "savedToAnySelected" "savedToAnyAccessible" "notSavedToAnyAccessible" "notSavedToAnySelected" "notSavedToAllSelected" String indicating the saved status to filter candidate results for. Must be one of the enumerated values. |
startDate | string Arrow-parseable date string (e.g. 2020-01-01). If provided, filter by Candidate.passed_at >= startDate |
endDate | string Arrow-parseable date string (e.g. 2020-01-01). If provided, filter by Candidate.passed_at <= endDate |
groupIDs | Array of integers Comma-separated string of group IDs (e.g. "1,2"). Defaults to all of user's groups if filterIDs is not provided. |
filterIDs | Array of integers Comma-separated string of filter IDs (e.g. "1,2"). Defaults to all of user's groups' filters if groupIDs is not provided. |
annotationExcludeOrigin | string Only load objects that do not have annotations from this origin. If the annotationsExcludeOutdatedDate is also given, then annotations with this origin will still be loaded if they were modified before that date. |
annotationExcludeOutdatedDate | string An Arrow parseable string designating when an existing annotation is outdated. Only relevant if giving the annotationExcludeOrigin argument. Will treat objects with outdated annotations as if they did not have that annotation, so it will load an object if it doesn't have an annotation with the origin specified or if it does have it but the annotation modified date < annotationsExcludeOutdatedDate |
sortByAnnotationOrigin | string The origin of the Annotation to sort by |
sortByAnnotationKey | string The key of the Annotation data value to sort by |
sortByAnnotationOrder | string The sort order for annotations - either "asc" or "desc". Defaults to "asc". |
annotationFilterList | Array of strings Comma-separated string of JSON objects representing annotation filters. Filter objects are expected to have keys { origin, key, value } for non-numeric value types, or { origin, key, min, max } for numeric values. |
includePhotometry | boolean Boolean indicating whether to include associated photometry. Defaults to false. |
includeSpectra | boolean Boolean indicating whether to include associated spectra. Defaults to false. |
includeComments | boolean Boolean indicating whether to include associated comments. Defaults to false. |
classifications | Array of strings Comma-separated string of classification(s) to filter for candidates matching that/those classification(s). |
minRedshift | number If provided, return only candidates with a redshift of at least this value |
maxRedshift | number If provided, return only candidates with a redshift of at most this value |
listName | string Get only candidates saved to the querying user's list, e.g., "favorites". |
listNameReject | string Get only candidates that ARE NOT saved to the querying user's list, e.g., "rejected_candidates". |
photometryAnnotationsFilter | Array of strings Comma-separated string of "annotation: value: operator" triplet(s) to filter for sources matching that/those photometry annotation(s), i.e. "drb: 0.5: lt" |
photometryAnnotationsFilterOrigin | string Comma separated string of origins. Only photometry annotations from these origins are used when filtering with the photometryAnnotationsFilter. |
photometryAnnotationsFilterBefore | string Only return sources that have photometry annotations before this UTC datetime. |
photometryAnnotationsFilterAfter | string Only return sources that have photometry annotations after this UTC datetime. |
photometryAnnotationsFilterMinCount | string Only return sources that have at least this number of photometry annotations passing the photometry annotations filtering criteria. Defaults to 1. |
localizationDateobs | string Event time in ISO 8601 format ( |
localizationName | string Name of localization / skymap to use. Can be found in Localization.localization_name queried from /api/localization endpoint or skymap name in GcnEvent page table. |
localizationCumprob | number Cumulative probability up to which to include sources |
{- "status": "success",
- "message": "string",
- "data": {
- "candidates": [
- {
- "host": null,
- "comments": [
- null
], - "reminders": [
- null
], - "comments_on_spectra": [
- null
], - "reminders_on_spectra": [
- null
], - "annotations": [
- null
], - "annotations_on_spectra": [
- null
], - "annotations_on_photometry": [
- null
], - "classifications": [
- null
], - "photometry": [
- null
], - "photstats": [
- null
], - "photometric_series": [
- null
], - "spectra": [
- null
], - "thumbnails": [
- null
], - "followup_requests": [
- null
], - "assignments": [
- null
], - "obj_notifications": [
- null
], - "obj_analyses": [
- null
], - "sources_in_gcns": [
- null
], - "id": "string",
- "ra_dis": 0,
- "dec_dis": 0,
- "ra_err": 0,
- "dec_err": 0,
- "offset": 0,
- "redshift": 0,
- "redshift_error": 0,
- "redshift_origin": "string",
- "redshift_history": null,
- "host_id": 0,
- "summary": "string",
- "summary_history": null,
- "altdata": null,
- "dist_nearest_source": 0,
- "mag_nearest_source": 0,
- "e_mag_nearest_source": 0,
- "transient": true,
- "varstar": true,
- "is_roid": true,
- "mpc_name": "string",
- "gcn_crossmatch": null,
- "tns_name": "string",
- "tns_info": null,
- "score": 0,
- "origin": "string",
- "alias": null,
- "internal_key": "string",
- "detect_photometry_count": 0,
- "ra": 0,
- "dec": 0,
- "candidates": [
- null
], - "sources": [
- null
], - "users": [
- null
], - "is_source": true
}
], - "totalMatches": 0,
- "pageNumber": 0,
- "numPerPage": 0
}
}
Create new candidate(s) (one per filter).
host | any Nullable The Galaxy associated with this source. |
comments | Array of any |
reminders | Array of any |
comments_on_spectra | Array of any |
reminders_on_spectra | Array of any |
annotations | Array of any |
annotations_on_spectra | Array of any |
annotations_on_photometry | Array of any |
classifications | Array of any |
photometry | Array of any |
photstats | Array of any |
photometric_series | Array of any |
spectra | Array of any |
thumbnails | Array of any |
followup_requests | Array of any |
assignments | Array of any |
obj_notifications | Array of any |
obj_analyses | Array of any |
sources_in_gcns | Array of any |
id required | string Name of the object. |
ra_dis | number Nullable J2000 Right Ascension at discovery time [deg]. |
dec_dis | number Nullable J2000 Declination at discovery time [deg]. |
ra_err | number Nullable Error on J2000 Right Ascension at discovery time [deg]. |
dec_err | number Nullable Error on J2000 Declination at discovery time [deg]. |
offset | number Nullable Offset from nearest static object [arcsec]. |
redshift | number Nullable Redshift. |
redshift_error | number Nullable Redshift error. |
redshift_origin | string Nullable Redshift source. |
host_id | integer Nullable The ID of the Galaxy to which this Obj is associated. |
summary | string Nullable Summary of the obj. |
summary_history | any Nullable Record of the summaries generated and written about this obj |
altdata | any Nullable Misc. alternative metadata stored in JSON format, e.g. |
dist_nearest_source | number Nullable Distance to the nearest Obj [arcsec]. |
mag_nearest_source | number Nullable Magnitude of the nearest Obj [AB]. |
e_mag_nearest_source | number Nullable Error on magnitude of the nearest Obj [mag]. |
transient | boolean Nullable Boolean indicating whether the object is an astrophysical transient. |
varstar | boolean Nullable Boolean indicating whether the object is a variable star. |
is_roid | boolean Nullable Boolean indicating whether the object is a moving object. |
mpc_name | string Nullable Minor planet center name. |
gcn_crossmatch | any Nullable List of GCN event dateobs for crossmatched events. |
tns_name | string Nullable Transient Name Server name. |
tns_info | any Nullable TNS info in JSON format |
score | number Nullable Machine learning score. |
origin | string Nullable Origin of the object. |
alias | any Nullable Alternative names for this object. |
healpix | integer Nullable |
detect_photometry_count | integer Nullable How many times the object was detected above :math: |
ra | number Nullable |
dec | number Nullable |
candidates | Array of any |
sources | Array of any |
users | Array of any |
filter_ids required | Array of integers List of associated filter IDs |
passing_alert_id | integer Nullable ID of associated filter that created candidate |
passed_at required | string Nullable Arrow-parseable datetime string indicating when passed filter. |
{- "host": null,
- "comments": [
- null
], - "reminders": [
- null
], - "comments_on_spectra": [
- null
], - "reminders_on_spectra": [
- null
], - "annotations": [
- null
], - "annotations_on_spectra": [
- null
], - "annotations_on_photometry": [
- null
], - "classifications": [
- null
], - "photometry": [
- null
], - "photstats": [
- null
], - "photometric_series": [
- null
], - "spectra": [
- null
], - "thumbnails": [
- null
], - "followup_requests": [
- null
], - "assignments": [
- null
], - "obj_notifications": [
- null
], - "obj_analyses": [
- null
], - "sources_in_gcns": [
- null
], - "id": "string",
- "ra_dis": 0,
- "dec_dis": 0,
- "ra_err": 0,
- "dec_err": 0,
- "offset": 0,
- "redshift": 0,
- "redshift_error": 0,
- "redshift_origin": "string",
- "host_id": 0,
- "summary": "string",
- "summary_history": null,
- "altdata": null,
- "dist_nearest_source": 0,
- "mag_nearest_source": 0,
- "e_mag_nearest_source": 0,
- "transient": true,
- "varstar": true,
- "is_roid": true,
- "mpc_name": "string",
- "gcn_crossmatch": null,
- "tns_name": "string",
- "tns_info": null,
- "score": 0,
- "origin": "string",
- "alias": null,
- "healpix": 0,
- "detect_photometry_count": 0,
- "ra": 0,
- "dec": 0,
- "candidates": [
- null
], - "sources": [
- null
], - "users": [
- null
], - "filter_ids": [
- 0
], - "passing_alert_id": 0,
- "passed_at": "string"
}
{- "status": "success",
- "message": "string",
- "data": {
- "ids": [
- 0
]
}
}
Create new candidate(s) (one per filter).
host | any Nullable The Galaxy associated with this source. |
comments | Array of any |
reminders | Array of any |
comments_on_spectra | Array of any |
reminders_on_spectra | Array of any |
annotations | Array of any |
annotations_on_spectra | Array of any |
annotations_on_photometry | Array of any |
classifications | Array of any |
photometry | Array of any |
photstats | Array of any |
photometric_series | Array of any |
spectra | Array of any |
thumbnails | Array of any |
followup_requests | Array of any |
assignments | Array of any |
obj_notifications | Array of any |
obj_analyses | Array of any |
sources_in_gcns | Array of any |
id required | string Name of the object. |
ra_dis | number Nullable J2000 Right Ascension at discovery time [deg]. |
dec_dis | number Nullable J2000 Declination at discovery time [deg]. |
ra_err | number Nullable Error on J2000 Right Ascension at discovery time [deg]. |
dec_err | number Nullable Error on J2000 Declination at discovery time [deg]. |
offset | number Nullable Offset from nearest static object [arcsec]. |
redshift | number Nullable Redshift. |
redshift_error | number Nullable Redshift error. |
redshift_origin | string Nullable Redshift source. |
host_id | integer Nullable The ID of the Galaxy to which this Obj is associated. |
summary | string Nullable Summary of the obj. |
summary_history | any Nullable Record of the summaries generated and written about this obj |
altdata | any Nullable Misc. alternative metadata stored in JSON format, e.g. |
dist_nearest_source | number Nullable Distance to the nearest Obj [arcsec]. |
mag_nearest_source | number Nullable Magnitude of the nearest Obj [AB]. |
e_mag_nearest_source | number Nullable Error on magnitude of the nearest Obj [mag]. |
transient | boolean Nullable Boolean indicating whether the object is an astrophysical transient. |
varstar | boolean Nullable Boolean indicating whether the object is a variable star. |
is_roid | boolean Nullable Boolean indicating whether the object is a moving object. |
mpc_name | string Nullable Minor planet center name. |
gcn_crossmatch | any Nullable List of GCN event dateobs for crossmatched events. |
tns_name | string Nullable Transient Name Server name. |
tns_info | any Nullable TNS info in JSON format |
score | number Nullable Machine learning score. |
origin | string Nullable Origin of the object. |
alias | any Nullable Alternative names for this object. |
healpix | integer Nullable |
detect_photometry_count | integer Nullable How many times the object was detected above :math: |
ra | number Nullable |
dec | number Nullable |
candidates | Array of any |
sources | Array of any |
users | Array of any |
filter_ids required | Array of integers List of associated filter IDs |
passing_alert_id | integer Nullable ID of associated filter that created candidate |
passed_at required | string Nullable Arrow-parseable datetime string indicating when passed filter. |
{- "host": null,
- "comments": [
- null
], - "reminders": [
- null
], - "comments_on_spectra": [
- null
], - "reminders_on_spectra": [
- null
], - "annotations": [
- null
], - "annotations_on_spectra": [
- null
], - "annotations_on_photometry": [
- null
], - "classifications": [
- null
], - "photometry": [
- null
], - "photstats": [
- null
], - "photometric_series": [
- null
], - "spectra": [
- null
], - "thumbnails": [
- null
], - "followup_requests": [
- null
], - "assignments": [
- null
], - "obj_notifications": [
- null
], - "obj_analyses": [
- null
], - "sources_in_gcns": [
- null
], - "id": "string",
- "ra_dis": 0,
- "dec_dis": 0,
- "ra_err": 0,
- "dec_err": 0,
- "offset": 0,
- "redshift": 0,
- "redshift_error": 0,
- "redshift_origin": "string",
- "host_id": 0,
- "summary": "string",
- "summary_history": null,
- "altdata": null,
- "dist_nearest_source": 0,
- "mag_nearest_source": 0,
- "e_mag_nearest_source": 0,
- "transient": true,
- "varstar": true,
- "is_roid": true,
- "mpc_name": "string",
- "gcn_crossmatch": null,
- "tns_name": "string",
- "tns_info": null,
- "score": 0,
- "origin": "string",
- "alias": null,
- "healpix": 0,
- "detect_photometry_count": 0,
- "ra": 0,
- "dec": 0,
- "candidates": [
- null
], - "sources": [
- null
], - "users": [
- null
], - "filter_ids": [
- 0
], - "passing_alert_id": 0,
- "passed_at": "string"
}
{- "status": "success",
- "message": "string",
- "data": {
- "ids": [
- 0
]
}
}
Delete candidate(s)
obj_id required | string |
filter_id required | integer |
{- "status": "success",
- "message": "string"
}
Submit catalog queries
status | string Default: "pending submission" The status of the request. |
allocation_id required | integer Catalog query request allocation ID. |
payload | any Content of the catalog query request. |
target_group_ids | Array of integers IDs of groups to share the results of the observation plan request with. |
{- "status": "pending submission",
- "allocation_id": 0,
- "payload": null,
- "target_group_ids": [
- 0
]
}
{- "status": "success",
- "message": "string"
}
Vote for a classification.
classification_id required | string ID of classification to indicate the vote for |
vote required | integer Upvote or downvote a classification |
{- "vote": 0
}
{- "status": "success",
- "message": "string"
}
Delete classification vote.
classification_id required | string |
{- "status": "success",
- "message": "string"
}
Retrieve a classification
classification_id required | integer |
includeTaxonomy | boolean Return associated taxonomy. |
{- "status": "success",
- "data": {
- "taxonomy": null,
- "author": null,
- "obj": null,
- "groups": [
- null
], - "votes": [
- null
], - "classification": "string",
- "origin": "string",
- "taxonomy_id": 0,
- "probability": 0,
- "author_id": 0,
- "author_name": "string",
- "obj_id": "string",
- "id": 0
}, - "message": "string"
}
Update a classification
classification required | integer |
taxonomy | any Nullable Taxonomy in which this Classification was made. |
author | any Nullable The User that made this classification. |
obj | any Nullable The Classification's Obj. |
groups | Array of any |
votes | Array of any |
classification required | string The assigned class. |
origin | string Nullable String describing the source of this classification. |
taxonomy_id required | integer ID of the Taxonomy in which this Classification was made. |
probability | number Nullable User-assigned probability of belonging to this class |
author_id required | integer ID of the User that made this Classification |
author_name required | string User.username or Token.id of the Classification's author. |
obj_id required | string ID of the Classification's Obj. |
group_ids | Array of integers List of group IDs corresponding to which groups should be able to view classification. |
{- "taxonomy": null,
- "author": null,
- "obj": null,
- "groups": [
- null
], - "votes": [
- null
], - "classification": "string",
- "origin": "string",
- "taxonomy_id": 0,
- "probability": 0,
- "author_id": 0,
- "author_name": "string",
- "obj_id": "string",
- "group_ids": [
- 0
]
}
{- "status": "success",
- "message": "string"
}
Delete a classification
classification_id required | integer |
label | boolean Nullable Add label associated with classification. |
{- "label": true
}
{- "status": "success",
- "message": "string"
}
Retrieve all classifications
startDate | string Arrow-parseable date string (e.g. 2020-01-01). If provided, filter by created_at >= startDate |
endDate | string Arrow-parseable date string (e.g. 2020-01-01). If provided, filter by created_at <= endDate |
includeTaxonomy | boolean Return associated taxonomy. |
numPerPage | integer Number of sources to return per paginated request. Defaults to 100. Max 500. |
pageNumber | integer Page number for paginated query results. Defaults to 1 |
{- "status": "success",
- "message": "string",
- "data": {
- "sources": [
- {
- "taxonomy": null,
- "author": null,
- "obj": null,
- "groups": [
- null
], - "votes": [
- null
], - "classification": "string",
- "origin": "string",
- "taxonomy_id": 0,
- "probability": 0,
- "author_id": 0,
- "author_name": "string",
- "obj_id": "string",
- "id": 0
}
], - "totalMatches": 0
}
}
Post a classification
obj_id required | string |
classification required | string |
origin | string String describing the source of this classification. |
taxonomy_id required | integer |
probability | float [ 0 .. 1 ] Nullable User-assigned probability of this classification on this taxonomy. If multiple classifications are given for the same source by the same user, the sum of the classifications ought to equal unity. Only individual probabilities are checked. |
group_ids | Array of integers List of group IDs corresponding to which groups should be able to view classification. Defaults to all of requesting user's groups. |
vote | boolean Nullable Add vote associated with classification. |
label | boolean Nullable Add label associated with classification. |
{- "obj_id": "string",
- "classification": "string",
- "origin": "string",
- "taxonomy_id": 0,
- "probability": null,
- "group_ids": [
- 0
], - "vote": true,
- "label": true
}
{- "status": "success",
- "message": "string",
- "data": {
- "classification_id": 0
}
}
Retrieve an object's classifications
obj_id required | string |
{- "status": "success",
- "data": [
- {
- "taxonomy": null,
- "author": null,
- "obj": null,
- "groups": [
- null
], - "votes": [
- null
], - "classification": "string",
- "origin": "string",
- "taxonomy_id": 0,
- "probability": 0,
- "author_id": 0,
- "author_name": "string",
- "obj_id": "string",
- "id": 0
}
], - "message": "string"
}
Delete all of an object's classifications
classification_id required | integer |
label | boolean Nullable Add label associated with classification. |
{- "label": true
}
{- "status": "success",
- "message": "string"
}
Vote for a classification.
classification_id required | string ID of classification to indicate the vote for |
vote required | integer Upvote or downvote a classification |
{- "vote": 0
}
{- "status": "success",
- "message": "string"
}
Delete classification vote.
classification_id required | string |
{- "status": "success",
- "message": "string"
}
find the sources with classifications
startDate | string Arrow-parseable date string (e.g. 2020-01-01) for when the classification was made. If provided, filter by created_at >= startDate |
endDate | string Arrow-parseable date string (e.g. 2020-01-01) for when the classification was made. If provided, filter by created_at <= endDate |
{- "status": "success",
- "message": "string",
- "data": [
- 0
]
}
find the number of sources with and without a Healpix value
{- "status": "success",
- "message": "string",
- "data": {
- "totalWithoutHealpix": 0,
- "totalWithHealpix": 0
}
}
{- "status": "success",
- "message": "string",
- "data": {
- "ALLOWED_SPECTRUM_TYPES": [ ],
- "ALLOWED_MAGSYSTEMS": [ ],
- "ALLOWED_BANDPASSES": [ ],
- "THUMBNAIL_TYPES": [ ],
- "FOLLOWUP_PRIORITIES": [ ],
- "ALLOWED_API_CLASSNAMES": [ ],
- "ANALYSIS_TYPES": [ ],
- "ANALYSIS_INPUT_TYPES": [ ],
- "AUTHENTICATION_TYPES": [ ]
}
}
{- "status": "success",
- "message": "string",
- "data": {
- "Number of candidates": 0,
- "Number of objs": 0,
- "Number of sources": 0,
- "Number of photometry": 0,
- "Number of spectra": 0,
- "Number of groups": 0,
- "Number of users": 0,
- "Number of tokens": 0,
- "Oldest candidate creation datetime": "string",
- "Newest candidate creation datetime": "string"
}
}
Retrieve a single default follow-up request
default_followup_request_id required | integer |
{- "status": "success",
- "data": {
- "requester": null,
- "allocation": null,
- "target_groups": [
- null
], - "requester_id": 0,
- "payload": null,
- "allocation_id": 0,
- "default_followup_name": "string",
- "source_filter": null,
- "id": 0
}, - "message": "string"
}
Delete a default follow-up request
default_followup_request_id required | integer |
{- "status": "success",
- "message": "string"
}
{- "status": "success",
- "data": [
- {
- "requester": null,
- "allocation": null,
- "target_groups": [
- null
], - "requester_id": 0,
- "payload": null,
- "allocation_id": 0,
- "default_followup_name": "string",
- "source_filter": null,
- "id": 0
}
], - "message": "string"
}
{- "status": "success",
- "data": [
- {
- "requester": null,
- "requester_id": 0,
- "filters": null,
- "default_tag_name": "string",
- "id": 0
}
], - "message": "string"
}
Delete a default observation plan
default_observation_plan_id required | integer |
{- "status": "success",
- "message": "string"
}
{- "status": "success",
- "data": [
- {
- "requester": null,
- "allocation": null,
- "target_groups": [
- null
], - "default_survey_efficiencies": [
- null
], - "requester_id": 0,
- "payload": null,
- "filters": null,
- "allocation_id": 0,
- "default_plan_name": "string",
- "id": 0
}
], - "message": "string"
}
Delete a default survey efficiency
default_survey_efficiency_id required | integer |
{- "status": "success",
- "message": "string"
}
{- "status": "success",
- "data": [
- {
- "default_observationplan_request": null,
- "default_observationplan_request_id": 0,
- "payload": null,
- "id": 0
}
], - "message": "string"
}
{- "status": "success",
- "data": {
- "stream": null,
- "group": null,
- "candidates": [
- null
], - "name": "string",
- "stream_id": 0,
- "group_id": 0,
- "id": 0
}, - "message": "string"
}
Update filter name
filter_id required | integer |
stream | any Nullable The Filter's Stream. |
group | any Nullable The Filter's Group. |
candidates | Array of any |
name required | string Filter name. |
stream_id required | integer ID of the Filter's Stream. |
group_id required | integer ID of the Filter's Group. |
{- "stream": null,
- "group": null,
- "candidates": [
- null
], - "name": "string",
- "stream_id": 0,
- "group_id": 0
}
{- "status": "success",
- "message": "string"
}
{- "status": "success",
- "data": [
- {
- "stream": null,
- "group": null,
- "candidates": [
- null
], - "name": "string",
- "stream_id": 0,
- "group_id": 0,
- "id": 0
}
], - "message": "string"
}
POST a new filter.
stream | any Nullable The Filter's Stream. |
group | any Nullable The Filter's Group. |
candidates | Array of any |
name required | string Filter name. |
stream_id required | integer ID of the Filter's Stream. |
group_id required | integer ID of the Filter's Group. |
{- "stream": null,
- "group": null,
- "candidates": [
- null
], - "name": "string",
- "stream_id": 0,
- "group_id": 0
}
{- "status": "success",
- "message": "string",
- "data": {
- "id": 0
}
}
Retrieve a filter as stored on Kowalski
filter_id required | integer |
{- "status": "success",
- "message": "string",
- "data": { }
}
POST a new filter version.
stream | any Nullable The Filter's Stream. |
group | any Nullable The Filter's Group. |
candidates | Array of any |
name required | string Filter name. |
stream_id required | integer ID of the Filter's Stream. |
group_id required | integer ID of the Filter's Group. |
{- "stream": null,
- "group": null,
- "candidates": [
- null
], - "name": "string",
- "stream_id": 0,
- "group_id": 0
}
{- "status": "success",
- "message": "string",
- "data": {
- "pipeline": [
- { }
]
}
}
Delete a filter on Kowalski
filter_id required | integer |
{- "status": "success",
- "message": "string"
}
Update a filter on Kowalski
filter_id required | integer |
filter_id required | integer >= 1 [fritz] science program filter id for this user group id |
active | boolean activate or deactivate filter |
active_fid | string 6 characters set fid as active version |
autosave | boolean automatically save passing candidates to filter's group |
update_annotations | boolean update annotations for existing candidates |
{- "filter_id": 1,
- "active": true,
- "active_fid": "string",
- "autosave": true,
- "update_annotations": true
}
{- "status": "success",
- "message": "string"
}
Create default follow-up request.
allocation_id required | integer Follow-up request allocation ID. |
target_group_ids | Array of integers IDs of groups to share the results of the default follow-up request with. |
payload | any Content of the default follow-up request. |
{- "allocation_id": 0,
- "target_group_ids": [
- 0
], - "payload": null
}
{- "status": "success",
- "message": "string",
- "data": {
- "id": 0
}
}
Retrieve a single default observation plan
default_observation_plan_id required | integer |
{- "status": "success",
- "data": {
- "requester": null,
- "allocation": null,
- "target_groups": [
- null
], - "default_survey_efficiencies": [
- null
], - "requester_id": 0,
- "payload": null,
- "filters": null,
- "allocation_id": 0,
- "default_plan_name": "string",
- "id": 0
}, - "message": "string"
}
Create default observation plan requests.
allocation_id required | integer Observation plan request allocation ID. |
target_group_ids | Array of integers IDs of groups to share the results of the default observation plan request with. |
payload | any Content of the default observation plan request. |
{- "allocation_id": 0,
- "target_group_ids": [
- 0
], - "payload": null
}
{- "status": "success",
- "message": "string",
- "data": {
- "id": 0
}
}
Retrieve a single default survey efficiency
default_survey_efficiency_id required | integer |
{- "status": "success",
- "data": {
- "default_observationplan_request": null,
- "default_observationplan_request_id": 0,
- "payload": null,
- "id": 0
}, - "message": "string"
}
Create default survey efficiency requests.
payload | any Content of the default survey efficiency analysis. |
default_observationplan_request_id required | integer Default observation plan request ID. |
{- "payload": null,
- "default_observationplan_request_id": 0
}
{- "status": "success",
- "message": "string",
- "data": {
- "id": 0
}
}
Post a message from a remote facility
new_status required | string |
followup_request_id required | integer |
{- "new_status": "string",
- "followup_request_id": 0
}
{- "status": "success",
- "message": "string"
}
Add follow-up request to watch list
followup_request_id required | integer |
{- "status": "success",
- "message": "string"
}
Delete follow-up request from watch list
followup_request_id required | integer |
{- "status": "success",
- "message": "string"
}
Retrieve followup requests schedule
sourceID | string Portion of ID to filter on |
startDate | string Arrow-parseable date string (e.g. 2020-01-01). If provided, filter by created_at >= startDate |
endDate | string Arrow-parseable date string (e.g. 2020-01-01). If provided, filter by created_at <= endDate |
status | string String to match status of request against |
observationStartDate | string Arrow-parseable date string (e.g. 2020-01-01). If provided, start time of observation window, otherwise now. |
observationEndDate | string Arrow-parseable date string (e.g. 2020-01-01). If provided, end time of observation window, otherwise 12 hours from now. |
includeStandards | boolean Include standards in schedule. Defaults to False. |
standardsOnly | boolean Only request standards in schedule. Defaults to False. |
standardType | string Origin of the standard stars, defined in config.yaml. Defaults to ESO. |
magnitudeRange | list lowest and highest magnitude to return, e.g. "(12,9)" |
output_format | string Output format for schedule. Can be png, pdf, or csv |
A PDF/PNG schedule file
{- "status": "error",
- "data": { },
- "message": "string"
}
Reprioritize followup requests schedule automatically based on either magnitude or location within skymap.
{- "status": "success",
- "message": "string"
}
Update a follow-up request
request_id required | string |
target_group_ids | Array of integers IDs of groups to share the results of the followup request with. |
obj_id required | string ID of the target Obj. |
status | string Default: "pending submission" The status of the request. |
allocation_id required | integer Followup request allocation ID. |
payload | any Content of the followup request. |
{- "target_group_ids": [
- 0
], - "obj_id": "string",
- "status": "pending submission",
- "allocation_id": 0,
- "payload": null
}
{- "status": "success",
- "message": "string"
}
Delete follow-up request.
request_id required | string |
{- "status": "success",
- "message": "string"
}
Submit follow-up request.
target_group_ids | Array of integers IDs of groups to share the results of the followup request with. |
obj_id required | string ID of the target Obj. |
status | string Default: "pending submission" The status of the request. |
allocation_id required | integer Followup request allocation ID. |
payload | any Content of the followup request. |
{- "target_group_ids": [
- 0
], - "obj_id": "string",
- "status": "pending submission",
- "allocation_id": 0,
- "payload": null
}
{- "status": "success",
- "message": "string",
- "data": {
- "id": 0
}
}
Get photometry request.
request_id required | string |
{- "status": "success",
- "message": "string"
}
Upload galaxies from GLADE+ catalog. If no file_name or file_url is provided, will look for the GLADE+ catalog in the data directory. If it can't be found, it will download it.
file_name | string Name of the file containing the galaxies (in the data directory) |
file_url | string URL of the file containing the galaxies |
{- "file_name": "string",
- "file_url": "string"
}
{- "status": "success",
- "message": "string"
}