SkyPortal (0.9.dev0)

Download OpenAPI specification:Download

SkyPortal API

Authentication

token

Header should be in the format 'token abcd-efgh-0000-1234'

Security scheme type: API Key
Header parameter name: Authorization

Retrieve a source

Retrieve a source

path Parameters
source_id
required
integer

Responses

200
400
get /api/sources/source_id
/api/sources/source_id

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "data":
    {
    },
  • "status": "success",
  • "message": "string"
}

Update a source

Update a source

path Parameters
redshift
required
number <float> Nullable
simag1
required
number <float> Nullable
comments
required
Array of strings
spectra
required
Array of strings
dec_err
required
number <float> Nullable
altdata
required
string Nullable
origin
required
string Nullable
ra
required
number <float> Nullable
mag_nearest_source
required
number <float> Nullable
created_at
required
string <date-time>
tns_name
required
string Nullable
id
required
string
simbad_class
required
string Nullable
dec_dis
required
number <float> Nullable
dec
required
number <float> Nullable
groups
required
Array of strings
ra_dis
required
number <float> Nullable
ra_err
required
number <float> Nullable
last_detected
required
string <date-time> Nullable
score
required
number <float> Nullable
is_roid
required
boolean Nullable
modified
required
string <date-time>
distpsnr1
required
number <float> Nullable
offset
required
number <float> Nullable
photometry
required
Array of strings
transient
required
boolean Nullable
varstar
required
boolean Nullable
users
required
Array of strings
gaia_info
required
string Nullable
thumbnails
required
Array of strings
detect_photometry_count
required
integer <int32> Nullable
simbad_info
required
string Nullable
sgscore1
required
number <float> Nullable
tns_info
required
string Nullable
e_mag_nearest_source
required
number <float> Nullable
dist_nearest_source
required
number <float> Nullable
objectidps1
required
integer <int32> Nullable
sgmag1
required
number <float> Nullable
srmag1
required
number <float> Nullable
created
required
string <date-time>

Responses

200
400
put /api/sources/source_id
/api/sources/source_id

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "status": "success",
  • "message": "string"
}

Delete a source

Delete a source

path Parameters
redshift
required
number <float> Nullable
simag1
required
number <float> Nullable
comments
required
Array of strings
spectra
required
Array of strings
dec_err
required
number <float> Nullable
altdata
required
string Nullable
origin
required
string Nullable
ra
required
number <float> Nullable
mag_nearest_source
required
number <float> Nullable
created_at
required
string <date-time>
tns_name
required
string Nullable
id
required
string
simbad_class
required
string Nullable
dec_dis
required
number <float> Nullable
dec
required
number <float> Nullable
groups
required
Array of strings
ra_dis
required
number <float> Nullable
ra_err
required
number <float> Nullable
last_detected
required
string <date-time> Nullable
score
required
number <float> Nullable
is_roid
required
boolean Nullable
modified
required
string <date-time>
distpsnr1
required
number <float> Nullable
offset
required
number <float> Nullable
photometry
required
Array of strings
transient
required
boolean Nullable
varstar
required
boolean Nullable
users
required
Array of strings
gaia_info
required
string Nullable
thumbnails
required
Array of strings
detect_photometry_count
required
integer <int32> Nullable
simbad_info
required
string Nullable
sgscore1
required
number <float> Nullable
tns_info
required
string Nullable
e_mag_nearest_source
required
number <float> Nullable
dist_nearest_source
required
number <float> Nullable
objectidps1
required
integer <int32> Nullable
sgmag1
required
number <float> Nullable
srmag1
required
number <float> Nullable
created
required
string <date-time>

Responses

200
delete /api/sources/source_id
/api/sources/source_id

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "status": "success",
  • "message": "string"
}

Retrieve all sources

Retrieve all sources

Responses

200
400
get /api/sources
/api/sources

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "data":
    [
    ],
  • "status": "success",
  • "message": "string"
}

Upload a source. If group_ids is not specified, th

Upload a source. If group_ids is not specified, the user or token's groups will be used.

path Parameters
redshift
required
number <float> Nullable
simag1
required
number <float> Nullable
comments
required
Array of strings
spectra
required
Array of strings
dec_err
required
number <float> Nullable
altdata
required
string Nullable
origin
required
string Nullable
ra
required
number <float> Nullable
mag_nearest_source
required
number <float> Nullable
created_at
required
string <date-time>
tns_name
required
string Nullable
id
required
string
simbad_class
required
string Nullable
dec_dis
required
number <float> Nullable
dec
required
number <float> Nullable
groups
required
Array of strings
ra_dis
required
number <float> Nullable
ra_err
required
number <float> Nullable
last_detected
required
string <date-time> Nullable
score
required
number <float> Nullable
is_roid
required
boolean Nullable
modified
required
string <date-time>
distpsnr1
required
number <float> Nullable
offset
required
number <float> Nullable
photometry
required
Array of strings
transient
required
boolean Nullable
varstar
required
boolean Nullable
users
required
Array of strings
gaia_info
required
string Nullable
thumbnails
required
Array of strings
detect_photometry_count
required
integer <int32> Nullable
simbad_info
required
string Nullable
sgscore1
required
number <float> Nullable
tns_info
required
string Nullable
e_mag_nearest_source
required
number <float> Nullable
dist_nearest_source
required
number <float> Nullable
objectidps1
required
integer <int32> Nullable
sgmag1
required
number <float> Nullable
srmag1
required
number <float> Nullable
created
required
string <date-time>

Responses

200
post /api/sources/
/api/sources/

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": 0
}

Update a group user

Update a group user

path Parameters
group_id
required
integer
username
required
string
admin
required
boolean

Responses

200
put /api/groups//group_id/users//username
/api/groups//group_id/users//username

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "group_id": 0,
  • "user_id": 0,
  • "admin": true
}

Delete a group user

Delete a group user

path Parameters
group_id
required
integer
username
required
string

Responses

200
delete /api/groups//group_id/users//username
/api/groups//group_id/users//username

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "status": "success",
  • "message": "string"
}

Retrieve a group

Retrieve a group

path Parameters
group_id
required
integer

Responses

200
400
get /api/groups/group_id
/api/groups/group_id

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "data":
    {
    },
  • "status": "success",
  • "message": "string"
}

Update a group

Update a group

path Parameters
users
required
Array of strings
streams
required
Array of strings
name
required
string
tokens
required
Array of strings
created_at
required
string <date-time>
group_users
required
Array of strings
sources
required
Array of strings
id
required
integer <int32>
group_tokens
required
Array of strings

Responses

200
400
put /api/groups/group_id
/api/groups/group_id

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "status": "success",
  • "message": "string"
}

Delete a group

Delete a group

path Parameters
group_id
required
integer

Responses

200
delete /api/groups/group_id
/api/groups/group_id

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "status": "success",
  • "message": "string"
}

Retrieve all groups

Retrieve all groups

Responses

200
400
get /api/groups
/api/groups

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "data":
    [
    ],
  • "status": "success",
  • "message": "string"
}

Create a new group

Create a new group

path Parameters
users
required
Array of strings
streams
required
Array of strings
name
required
string
tokens
required
Array of strings
created_at
required
string <date-time>
group_users
required
Array of strings
sources
required
Array of strings
id
required
integer <int32>
group_tokens
required
Array of strings

Responses

200
post /api/groups/
/api/groups/

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "id": 0
}

Retrieve a comment

Retrieve a comment

path Parameters
attachment_name
required
string Nullable
attachment_type
required
string Nullable
attachment_bytes
required
string Nullable
author
required
string
origin
required
string Nullable
source
required
string Nullable
created_at
required
string <date-time>
ctype
required
string <= 14 characters Nullable
Enum: "text" "redshift" "classification"
id
required
integer <int32>
text
required
string

Responses

200
get /api/comment/comment_id
/api/comment/comment_id

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "data":
    {
    },
  • "status": "success",
  • "message": "string"
}

Update a comment

Update a comment

path Parameters
attachment_name
required
string Nullable
attachment_type
required
string Nullable
attachment_bytes
required
string Nullable
author
required
string
origin
required
string Nullable
source
required
string Nullable
created_at
required
string <date-time>
ctype
required
string <= 14 characters Nullable
Enum: "text" "redshift" "classification"
id
required
integer <int32>
text
required
string

Responses

200
400
put /api/comment/comment_id
/api/comment/comment_id

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "status": "success",
  • "message": "string"
}

Delete a comment

Delete a comment

path Parameters
comment_id
required
integer

Responses

200
delete /api/comment/comment_id
/api/comment/comment_id

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "status": "success",
  • "message": "string"
}

Post a comment

Post a comment

path Parameters
attachment_name
required
string Nullable
attachment_type
required
string Nullable
attachment_bytes
required
string Nullable
author
required
string
origin
required
string Nullable
source
required
string Nullable
created_at
required
string <date-time>
ctype
required
string <= 14 characters Nullable
Enum: "text" "redshift" "classification"
id
required
integer <int32>
text
required
string

Responses

200
post /api/comment/
/api/comment/

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "source_id": 0
}

Retrieve a comment

Retrieve a comment

path Parameters
attachment_name
required
string Nullable
attachment_type
required
string Nullable
attachment_bytes
required
string Nullable
author
required
string
origin
required
string Nullable
source
required
string Nullable
created_at
required
string <date-time>
ctype
required
string <= 14 characters Nullable
Enum: "text" "redshift" "classification"
id
required
integer <int32>
text
required
string

Responses

200
get /api/comment/comment_id//action
/api/comment/comment_id//action

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "data":
    {
    },
  • "status": "success",
  • "message": "string"
}

Update a comment

Update a comment

path Parameters
attachment_name
required
string Nullable
attachment_type
required
string Nullable
attachment_bytes
required
string Nullable
author
required
string
origin
required
string Nullable
source
required
string Nullable
created_at
required
string <date-time>
ctype
required
string <= 14 characters Nullable
Enum: "text" "redshift" "classification"
id
required
integer <int32>
text
required
string

Responses

200
400
put /api/comment/comment_id//
/api/comment/comment_id//

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "status": "success",
  • "message": "string"
}

Delete a comment

Delete a comment

path Parameters
comment_id
required
integer

Responses

200
delete /api/comment/comment_id//
/api/comment/comment_id//

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "status": "success",
  • "message": "string"
}

Post a comment

Post a comment

path Parameters
attachment_name
required
string Nullable
attachment_type
required
string Nullable
attachment_bytes
required
string Nullable
author
required
string
origin
required
string Nullable
source
required
string Nullable
created_at
required
string <date-time>
ctype
required
string <= 14 characters Nullable
Enum: "text" "redshift" "classification"
id
required
integer <int32>
text
required
string

Responses

200
post /api/comment///
/api/comment///

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "source_id": 0
}

Upload photometry

Upload photometry

path Parameters
var_mag
required
number <float> Nullable
altdata
required
string Nullable
var_e_mag
required
number <float> Nullable
origin
required
string Nullable
mag_nearest_source
required
number <float> Nullable
created_at
required
string <date-time>
instrument
required
string Nullable
id
required
integer <int32>
e_mag
required
number <float> Nullable
lim_mag
required
number <float> Nullable
score
required
number <float> Nullable
time_scale
required
string Nullable
candid
required
integer <int32> Nullable
time_format
required
string Nullable
mjd
required
number <float> Nullable
isdiffpos
required
boolean Nullable
thumbnails
required
Array of strings
observed_at
required
string <date-time> Nullable
filter
required
string Nullable
mag
required
number <float> Nullable
source
required
string Nullable
e_mag_nearest_source
required
number <float> Nullable
dist_nearest_source
required
number <float> Nullable
created
required
string <date-time>

Responses

200
post /api/photometry/
/api/photometry/

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "ids": [ ]
}

Retrieve system info

Retrieve system info

Responses

200
get /api/sysinfo
/api/sysinfo

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "sources_table_empty": true,
  • "version": "string"
}

Generate new token

Generate new token

path Parameters
acls
required
Array of strings
groups
required
Array of strings
name
required
string
created_at
required
string <date-time>
id
required
string
group_tokens
required
Array of strings

Responses

200
post /api/internal/tokens/
/api/internal/tokens/

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "status": "success",
  • "message": "string"
}

Delete a token

Delete a token

path Parameters
token_id
required
integer

Responses

200
400
delete /api/internal/tokens/token_id
/api/internal/tokens/token_id

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "status": "success",
  • "message": "string"
}

Retrieve user profile

Retrieve user profile

Responses

200
get /api/internal/profile
/api/internal/profile

Response samples

Content type
application/json
Copy
Expand all Collapse all
{
  • "data":
    {
    },
  • "status": "success",
  • "message": "string"
}