/v1/schedulesList schedules#
Schedules
The schedules not final (scheduled, at_risk), every one with all (fired, missed, cancelled too).
Query parameters
passstring
Only the schedules of this pass.
allboolean
Final schedules too.
Responses
200Schedules, by start.application/json
schedulesrequiredarray of Schedule
Schedules, by start.
Schedule · 20 fields
bystring
Who created it.
environmentstring
Environment; by default the last environment of the target of the pass.
fire_at string
Start time from the current pass, set by the MCS.
idrequiredstring
Identifier.
inputsobject
Input values, as written in a run request.
irstring
Hash of the resolved run, set by the MCS.
librarystring
Library of the procedure, when several have a procedure of that name.
max_duration string
Maximum duration of the run, set by the MCS.
needs_validation boolean
Whether a supervisor must validate the plan before it starts: a hazardous
telecommand in an environment where the supervisor confirms. Set by the MCS.
passrequiredstring
Pass.
reasonsarray of string
Why at risk, cancelled or missed.
runrequiredstring
Procedure.
run_id string
Run submitted, set by the MCS.
sendsboolean
Whether the run sends telecommands, set by the MCS.
startrequiredstring
Start relative to the AOS: aos, aos + 30 s.
stateState, set by the MCS.
targetstring
Target of the pass, set by the MCS.
targetsrequiredmap of string
Target of each role.
updated_at string
Last change.
validationone of PlanValidation | null
Validation of the plan, while it holds.
503The MCS bus (NATS) is unavailable: api::unavailable.application/json
errorsrequiredarray of ErrorItem
Every error found.
ErrorItem · 3 fields
coderequiredstring
Stable code.
messagerequiredstring
Message for the operator.
helpstring
Suggested fix.
Request
curl "http://localhost:8080/v1/schedules"import requests
BASE_URL = "http://localhost:8080"
response = requests.get(f"{BASE_URL}/v1/schedules")
response.raise_for_status()
print(response.json())let base_url = "http://localhost:8080";
let response = reqwest::Client::new()
.get(format!("{base_url}/v1/schedules"))
.send()
.await?
.error_for_status()?;
let body: serde_json::Value = response.json().await?;
println!("{body:#}");Response
{
"schedules": [
{
"by": "string",
"environment": "string",
"fire_at": "string",
"id": "string",
"inputs": {},
"ir": "string",
"library": "string",
"max_duration": "string",
"needs_validation": false,
"pass": "string",
"reasons": [
"string"
],
"run": "string",
"run_id": "string",
"sends": false,
"start": "string",
"state": "scheduled",
"target": "string",
"targets": {
"key": "string"
},
"updated_at": "string",
"validation": {
"aos": "string",
"at": "string",
"by": "string",
"ir": "string",
"los": "string",
"pass": "string"
}
}
]
}{
"errors": [
{
"code": "string",
"message": "string",
"help": "string"
}
]
}/v1/schedulesCreate schedule#
Schedule a run on a pass
Resolves the run request on the current configuration with plan = the pass, stores the resolved run and keeps its maximum duration. The runs of a pass must fit between their start and LOS minus scheduler.margin, in order; in in_orbit, the pass must be booked. A schedule not fired yet can be replaced under the same identifier. A schedule whose run sends a hazardous telecommand where a supervisor confirms needs a validation (needs_validation).
Request body application/jsonrequired
bystring
Who created it.
environmentstring
Environment; by default the last environment of the target of the pass.
fire_at string
Start time from the current pass, set by the MCS.
idrequiredstring
Identifier.
inputsobject
Input values, as written in a run request.
irstring
Hash of the resolved run, set by the MCS.
librarystring
Library of the procedure, when several have a procedure of that name.
max_duration string
Maximum duration of the run, set by the MCS.
needs_validation boolean
Whether a supervisor must validate the plan before it starts: a hazardous
telecommand in an environment where the supervisor confirms. Set by the MCS.
passrequiredstring
Pass.
reasonsarray of string
Why at risk, cancelled or missed.
runrequiredstring
Procedure.
run_id string
Run submitted, set by the MCS.
sendsboolean
Whether the run sends telecommands, set by the MCS.
startrequiredstring
Start relative to the AOS: aos, aos + 30 s.
stateState, set by the MCS.
targetstring
Target of the pass, set by the MCS.
targetsrequiredmap of string
Target of each role.
updated_at string
Last change.
validationone of PlanValidation | null
Validation of the plan, while it holds.
Responses
201The schedule as stored, with its state.application/json
bystring
Who created it.
environmentstring
Environment; by default the last environment of the target of the pass.
fire_at string
Start time from the current pass, set by the MCS.
idrequiredstring
Identifier.
inputsobject
Input values, as written in a run request.
irstring
Hash of the resolved run, set by the MCS.
librarystring
Library of the procedure, when several have a procedure of that name.
max_duration string
Maximum duration of the run, set by the MCS.
needs_validation boolean
Whether a supervisor must validate the plan before it starts: a hazardous
telecommand in an environment where the supervisor confirms. Set by the MCS.
passrequiredstring
Pass.
reasonsarray of string
Why at risk, cancelled or missed.
runrequiredstring
Procedure.
run_id string
Run submitted, set by the MCS.
sendsboolean
Whether the run sends telecommands, set by the MCS.
startrequiredstring
Start relative to the AOS: aos, aos + 30 s.
stateState, set by the MCS.
targetstring
Target of the pass, set by the MCS.
targetsrequiredmap of string
Target of each role.
updated_at string
Last change.
validationone of PlanValidation | null
Validation of the plan, while it holds.
401Identity required by the environment.application/json
errorsrequiredarray of ErrorItem
Every error found.
ErrorItem · 3 fields
coderequiredstring
Stable code.
messagerequiredstring
Message for the operator.
helpstring
Suggested fix.
422Invalid, unresolved or refused schedule: schedule::invalid, schedule::refused.application/json
errorsrequiredarray of ErrorItem
Every error found.
ErrorItem · 3 fields
coderequiredstring
Stable code.
messagerequiredstring
Message for the operator.
helpstring
Suggested fix.
503The MCS bus (NATS) is unavailable: api::unavailable.application/json
errorsrequiredarray of ErrorItem
Every error found.
ErrorItem · 3 fields
coderequiredstring
Stable code.
messagerequiredstring
Message for the operator.
helpstring
Suggested fix.
Request
curl -X POST "http://localhost:8080/v1/schedules" \
-H "Content-Type: application/json" \
-d '{
"by": "string",
"environment": "string",
"fire_at": "string",
"id": "string",
"inputs": {},
"ir": "string",
"library": "string",
"max_duration": "string",
"needs_validation": false,
"pass": "string",
"reasons": [
"string"
],
"run": "string",
"run_id": "string",
"sends": false,
"start": "string",
"state": "scheduled",
"target": "string",
"targets": {
"key": "string"
},
"updated_at": "string",
"validation": {
"aos": "string",
"at": "string",
"by": "string",
"ir": "string",
"los": "string",
"pass": "string"
}
}'import requests
BASE_URL = "http://localhost:8080"
response = requests.post(
f"{BASE_URL}/v1/schedules",
json={
"by": "string",
"environment": "string",
"fire_at": "string",
"id": "string",
"inputs": {},
"ir": "string",
"library": "string",
"max_duration": "string",
"needs_validation": False,
"pass": "string",
"reasons": [
"string",
],
"run": "string",
"run_id": "string",
"sends": False,
"start": "string",
"state": "scheduled",
"target": "string",
"targets": {
"key": "string",
},
"updated_at": "string",
"validation": {
"aos": "string",
"at": "string",
"by": "string",
"ir": "string",
"los": "string",
"pass": "string",
},
},
)
response.raise_for_status()
print(response.json())let base_url = "http://localhost:8080";
let response = reqwest::Client::new()
.post(format!("{base_url}/v1/schedules"))
.json(&serde_json::json!({
"by": "string",
"environment": "string",
"fire_at": "string",
"id": "string",
"inputs": {},
"ir": "string",
"library": "string",
"max_duration": "string",
"needs_validation": false,
"pass": "string",
"reasons": [
"string"
],
"run": "string",
"run_id": "string",
"sends": false,
"start": "string",
"state": "scheduled",
"target": "string",
"targets": {
"key": "string"
},
"updated_at": "string",
"validation": {
"aos": "string",
"at": "string",
"by": "string",
"ir": "string",
"los": "string",
"pass": "string"
}
}))
.send()
.await?
.error_for_status()?;
let body: serde_json::Value = response.json().await?;
println!("{body:#}");Response
{
"by": "string",
"environment": "string",
"fire_at": "string",
"id": "string",
"inputs": {},
"ir": "string",
"library": "string",
"max_duration": "string",
"needs_validation": false,
"pass": "string",
"reasons": [
"string"
],
"run": "string",
"run_id": "string",
"sends": false,
"start": "string",
"state": "scheduled",
"target": "string",
"targets": {
"key": "string"
},
"updated_at": "string",
"validation": {
"aos": "string",
"at": "string",
"by": "string",
"ir": "string",
"los": "string",
"pass": "string"
}
}{
"errors": [
{
"code": "string",
"message": "string",
"help": "string"
}
]
}{
"errors": [
{
"code": "string",
"message": "string",
"help": "string"
}
]
}{
"errors": [
{
"code": "string",
"message": "string",
"help": "string"
}
]
}/v1/schedules/{id}Get schedule#
A schedule
Path parameters
idrequiredstring
Schedule identifier.
Responses
200The schedule.application/json
bystring
Who created it.
environmentstring
Environment; by default the last environment of the target of the pass.
fire_at string
Start time from the current pass, set by the MCS.
idrequiredstring
Identifier.
inputsobject
Input values, as written in a run request.
irstring
Hash of the resolved run, set by the MCS.
librarystring
Library of the procedure, when several have a procedure of that name.
max_duration string
Maximum duration of the run, set by the MCS.
needs_validation boolean
Whether a supervisor must validate the plan before it starts: a hazardous
telecommand in an environment where the supervisor confirms. Set by the MCS.
passrequiredstring
Pass.
reasonsarray of string
Why at risk, cancelled or missed.
runrequiredstring
Procedure.
run_id string
Run submitted, set by the MCS.
sendsboolean
Whether the run sends telecommands, set by the MCS.
startrequiredstring
Start relative to the AOS: aos, aos + 30 s.
stateState, set by the MCS.
targetstring
Target of the pass, set by the MCS.
targetsrequiredmap of string
Target of each role.
updated_at string
Last change.
validationone of PlanValidation | null
Validation of the plan, while it holds.
404No such schedule: schedule::unknown.application/json
errorsrequiredarray of ErrorItem
Every error found.
ErrorItem · 3 fields
coderequiredstring
Stable code.
messagerequiredstring
Message for the operator.
helpstring
Suggested fix.
503The MCS bus (NATS) is unavailable: api::unavailable.application/json
errorsrequiredarray of ErrorItem
Every error found.
ErrorItem · 3 fields
coderequiredstring
Stable code.
messagerequiredstring
Message for the operator.
helpstring
Suggested fix.
Request
curl "http://localhost:8080/v1/schedules/<id>"import requests
BASE_URL = "http://localhost:8080"
id = "<id>" # Schedule identifier.
response = requests.get(f"{BASE_URL}/v1/schedules/{id}")
response.raise_for_status()
print(response.json())let base_url = "http://localhost:8080";
let id = "<id>"; // Schedule identifier.
let response = reqwest::Client::new()
.get(format!("{base_url}/v1/schedules/{id}"))
.send()
.await?
.error_for_status()?;
let body: serde_json::Value = response.json().await?;
println!("{body:#}");Response
{
"by": "string",
"environment": "string",
"fire_at": "string",
"id": "string",
"inputs": {},
"ir": "string",
"library": "string",
"max_duration": "string",
"needs_validation": false,
"pass": "string",
"reasons": [
"string"
],
"run": "string",
"run_id": "string",
"sends": false,
"start": "string",
"state": "scheduled",
"target": "string",
"targets": {
"key": "string"
},
"updated_at": "string",
"validation": {
"aos": "string",
"at": "string",
"by": "string",
"ir": "string",
"los": "string",
"pass": "string"
}
}{
"errors": [
{
"code": "string",
"message": "string",
"help": "string"
}
]
}{
"errors": [
{
"code": "string",
"message": "string",
"help": "string"
}
]
}/v1/schedules/{id}/cancelCancel schedule#
Cancel a schedule
Cancels a schedule not final yet, as the operator of X-Stellar-User.
Path parameters
idrequiredstring
Schedule identifier.
Responses
200The cancelled schedule.application/json
bystring
Who created it.
environmentstring
Environment; by default the last environment of the target of the pass.
fire_at string
Start time from the current pass, set by the MCS.
idrequiredstring
Identifier.
inputsobject
Input values, as written in a run request.
irstring
Hash of the resolved run, set by the MCS.
librarystring
Library of the procedure, when several have a procedure of that name.
max_duration string
Maximum duration of the run, set by the MCS.
needs_validation boolean
Whether a supervisor must validate the plan before it starts: a hazardous
telecommand in an environment where the supervisor confirms. Set by the MCS.
passrequiredstring
Pass.
reasonsarray of string
Why at risk, cancelled or missed.
runrequiredstring
Procedure.
run_id string
Run submitted, set by the MCS.
sendsboolean
Whether the run sends telecommands, set by the MCS.
startrequiredstring
Start relative to the AOS: aos, aos + 30 s.
stateState, set by the MCS.
targetstring
Target of the pass, set by the MCS.
targetsrequiredmap of string
Target of each role.
updated_at string
Last change.
validationone of PlanValidation | null
Validation of the plan, while it holds.
404No such schedule.application/json
errorsrequiredarray of ErrorItem
Every error found.
ErrorItem · 3 fields
coderequiredstring
Stable code.
messagerequiredstring
Message for the operator.
helpstring
Suggested fix.
409Already final (schedule::final), or changed meanwhile (schedule::changed).application/json
errorsrequiredarray of ErrorItem
Every error found.
ErrorItem · 3 fields
coderequiredstring
Stable code.
messagerequiredstring
Message for the operator.
helpstring
Suggested fix.
503The MCS bus (NATS) is unavailable: api::unavailable.application/json
errorsrequiredarray of ErrorItem
Every error found.
ErrorItem · 3 fields
coderequiredstring
Stable code.
messagerequiredstring
Message for the operator.
helpstring
Suggested fix.
Request
curl -X POST "http://localhost:8080/v1/schedules/<id>/cancel"import requests
BASE_URL = "http://localhost:8080"
id = "<id>" # Schedule identifier.
response = requests.post(f"{BASE_URL}/v1/schedules/{id}/cancel")
response.raise_for_status()
print(response.json())let base_url = "http://localhost:8080";
let id = "<id>"; // Schedule identifier.
let response = reqwest::Client::new()
.post(format!("{base_url}/v1/schedules/{id}/cancel"))
.send()
.await?
.error_for_status()?;
let body: serde_json::Value = response.json().await?;
println!("{body:#}");Response
{
"by": "string",
"environment": "string",
"fire_at": "string",
"id": "string",
"inputs": {},
"ir": "string",
"library": "string",
"max_duration": "string",
"needs_validation": false,
"pass": "string",
"reasons": [
"string"
],
"run": "string",
"run_id": "string",
"sends": false,
"start": "string",
"state": "scheduled",
"target": "string",
"targets": {
"key": "string"
},
"updated_at": "string",
"validation": {
"aos": "string",
"at": "string",
"by": "string",
"ir": "string",
"los": "string",
"pass": "string"
}
}{
"errors": [
{
"code": "string",
"message": "string",
"help": "string"
}
]
}{
"errors": [
{
"code": "string",
"message": "string",
"help": "string"
}
]
}{
"errors": [
{
"code": "string",
"message": "string",
"help": "string"
}
]
}/v1/schedules/{id}/validateValidate schedule#
Validate the plan of a schedule (supervisor)
A supervisor validates the plan of a schedule as it is: its resolved run (procedure, inputs, targets), its pass, and the AOS and LOS of the pass. Any later change of them makes the validation fall, and the schedule is at_risk again.
Path parameters
idrequiredstring
Schedule identifier.
Responses
200The validated schedule.application/json
bystring
Who created it.
environmentstring
Environment; by default the last environment of the target of the pass.
fire_at string
Start time from the current pass, set by the MCS.
idrequiredstring
Identifier.
inputsobject
Input values, as written in a run request.
irstring
Hash of the resolved run, set by the MCS.
librarystring
Library of the procedure, when several have a procedure of that name.
max_duration string
Maximum duration of the run, set by the MCS.
needs_validation boolean
Whether a supervisor must validate the plan before it starts: a hazardous
telecommand in an environment where the supervisor confirms. Set by the MCS.
passrequiredstring
Pass.
reasonsarray of string
Why at risk, cancelled or missed.
runrequiredstring
Procedure.
run_id string
Run submitted, set by the MCS.
sendsboolean
Whether the run sends telecommands, set by the MCS.
startrequiredstring
Start relative to the AOS: aos, aos + 30 s.
stateState, set by the MCS.
targetstring
Target of the pass, set by the MCS.
targetsrequiredmap of string
Target of each role.
updated_at string
Last change.
validationone of PlanValidation | null
Validation of the plan, while it holds.
401No identity, or refused by the environment.application/json
errorsrequiredarray of ErrorItem
Every error found.
ErrorItem · 3 fields
coderequiredstring
Stable code.
messagerequiredstring
Message for the operator.
helpstring
Suggested fix.
403Not a supervisor: schedule::not-supervisor.application/json
errorsrequiredarray of ErrorItem
Every error found.
ErrorItem · 3 fields
coderequiredstring
Stable code.
messagerequiredstring
Message for the operator.
helpstring
Suggested fix.
404No such schedule.application/json
errorsrequiredarray of ErrorItem
Every error found.
ErrorItem · 3 fields
coderequiredstring
Stable code.
messagerequiredstring
Message for the operator.
helpstring
Suggested fix.
422Refused: schedule::refused.application/json
errorsrequiredarray of ErrorItem
Every error found.
ErrorItem · 3 fields
coderequiredstring
Stable code.
messagerequiredstring
Message for the operator.
helpstring
Suggested fix.
503The MCS bus (NATS) is unavailable: api::unavailable.application/json
errorsrequiredarray of ErrorItem
Every error found.
ErrorItem · 3 fields
coderequiredstring
Stable code.
messagerequiredstring
Message for the operator.
helpstring
Suggested fix.
Request
curl -X POST "http://localhost:8080/v1/schedules/<id>/validate"import requests
BASE_URL = "http://localhost:8080"
id = "<id>" # Schedule identifier.
response = requests.post(f"{BASE_URL}/v1/schedules/{id}/validate")
response.raise_for_status()
print(response.json())let base_url = "http://localhost:8080";
let id = "<id>"; // Schedule identifier.
let response = reqwest::Client::new()
.post(format!("{base_url}/v1/schedules/{id}/validate"))
.send()
.await?
.error_for_status()?;
let body: serde_json::Value = response.json().await?;
println!("{body:#}");Response
{
"by": "string",
"environment": "string",
"fire_at": "string",
"id": "string",
"inputs": {},
"ir": "string",
"library": "string",
"max_duration": "string",
"needs_validation": false,
"pass": "string",
"reasons": [
"string"
],
"run": "string",
"run_id": "string",
"sends": false,
"start": "string",
"state": "scheduled",
"target": "string",
"targets": {
"key": "string"
},
"updated_at": "string",
"validation": {
"aos": "string",
"at": "string",
"by": "string",
"ir": "string",
"los": "string",
"pass": "string"
}
}{
"errors": [
{
"code": "string",
"message": "string",
"help": "string"
}
]
}{
"errors": [
{
"code": "string",
"message": "string",
"help": "string"
}
]
}{
"errors": [
{
"code": "string",
"message": "string",
"help": "string"
}
]
}{
"errors": [
{
"code": "string",
"message": "string",
"help": "string"
}
]
}{
"errors": [
{
"code": "string",
"message": "string",
"help": "string"
}
]
}/v1/schedule-rulesList schedule rules#
Recurring rules
Responses
200Rules, by identifier.application/json
rulesrequiredarray of ScheduleRule
Rules, by identifier.
ScheduleRule · 10 fields
bystring
Who created it.
environmentstring
Environment; by default the last environment of the target.
filterPasses it applies to.
PassFilter · 4 fields
min_elevation string
Lowest maximum elevation (20 deg).
stationstring
Ground station.
statusone of PassStatus | null
Status of the pass (booked).
uplinkboolean
Whether the pass must allow the uplink.
idrequiredstring
Identifier.
inputsobject
Input values, as written in a run request.
librarystring
Library of the procedure, when several have a procedure of that name.
runrequiredstring
Procedure.
startrequiredstring
Start relative to the AOS: aos, aos + 30 s.
targetrequiredstring
Target of the passes.
targetsrequiredmap of string
Target of each role.
503The MCS bus (NATS) is unavailable: api::unavailable.application/json
errorsrequiredarray of ErrorItem
Every error found.
ErrorItem · 3 fields
coderequiredstring
Stable code.
messagerequiredstring
Message for the operator.
helpstring
Suggested fix.
Request
curl "http://localhost:8080/v1/schedule-rules"import requests
BASE_URL = "http://localhost:8080"
response = requests.get(f"{BASE_URL}/v1/schedule-rules")
response.raise_for_status()
print(response.json())let base_url = "http://localhost:8080";
let response = reqwest::Client::new()
.get(format!("{base_url}/v1/schedule-rules"))
.send()
.await?
.error_for_status()?;
let body: serde_json::Value = response.json().await?;
println!("{body:#}");Response
{
"rules": [
{
"by": "string",
"environment": "string",
"filter": {
"min_elevation": "string",
"station": "string",
"status": null,
"uplink": true
},
"id": "string",
"inputs": {},
"library": "string",
"run": "string",
"start": "string",
"target": "string",
"targets": {
"key": "string"
}
}
]
}{
"errors": [
{
"code": "string",
"message": "string",
"help": "string"
}
]
}/v1/schedule-rulesCreate schedule rule#
Write a recurring rule
A rule that schedules its run on every pass of its target matching its filter (status, min_elevation, station, uplink), as the scheduler sees the passes arrive. Its request is resolved on the current configuration; a procedure that sends a hazardous telecommand is refused.
Request body application/jsonrequired
bystring
Who created it.
environmentstring
Environment; by default the last environment of the target.
filterPasses it applies to.
PassFilter · 4 fields
min_elevation string
Lowest maximum elevation (20 deg).
stationstring
Ground station.
statusone of PassStatus | null
Status of the pass (booked).
uplinkboolean
Whether the pass must allow the uplink.
idrequiredstring
Identifier.
inputsobject
Input values, as written in a run request.
librarystring
Library of the procedure, when several have a procedure of that name.
runrequiredstring
Procedure.
startrequiredstring
Start relative to the AOS: aos, aos + 30 s.
targetrequiredstring
Target of the passes.
targetsrequiredmap of string
Target of each role.
Responses
201The rule as stored.application/json
bystring
Who created it.
environmentstring
Environment; by default the last environment of the target.
filterPasses it applies to.
PassFilter · 4 fields
min_elevation string
Lowest maximum elevation (20 deg).
stationstring
Ground station.
statusone of PassStatus | null
Status of the pass (booked).
uplinkboolean
Whether the pass must allow the uplink.
idrequiredstring
Identifier.
inputsobject
Input values, as written in a run request.
librarystring
Library of the procedure, when several have a procedure of that name.
runrequiredstring
Procedure.
startrequiredstring
Start relative to the AOS: aos, aos + 30 s.
targetrequiredstring
Target of the passes.
targetsrequiredmap of string
Target of each role.
422Invalid or refused rule: schedule::invalid, schedule::refused.application/json
errorsrequiredarray of ErrorItem
Every error found.
ErrorItem · 3 fields
coderequiredstring
Stable code.
messagerequiredstring
Message for the operator.
helpstring
Suggested fix.
503The MCS bus (NATS) is unavailable: api::unavailable.application/json
errorsrequiredarray of ErrorItem
Every error found.
ErrorItem · 3 fields
coderequiredstring
Stable code.
messagerequiredstring
Message for the operator.
helpstring
Suggested fix.
Request
curl -X POST "http://localhost:8080/v1/schedule-rules" \
-H "Content-Type: application/json" \
-d '{
"by": "string",
"environment": "string",
"filter": {
"min_elevation": "string",
"station": "string",
"status": "predicted",
"uplink": true
},
"id": "string",
"inputs": {},
"library": "string",
"run": "string",
"start": "string",
"target": "string",
"targets": {
"key": "string"
}
}'import requests
BASE_URL = "http://localhost:8080"
response = requests.post(
f"{BASE_URL}/v1/schedule-rules",
json={
"by": "string",
"environment": "string",
"filter": {
"min_elevation": "string",
"station": "string",
"status": "predicted",
"uplink": True,
},
"id": "string",
"inputs": {},
"library": "string",
"run": "string",
"start": "string",
"target": "string",
"targets": {
"key": "string",
},
},
)
response.raise_for_status()
print(response.json())let base_url = "http://localhost:8080";
let response = reqwest::Client::new()
.post(format!("{base_url}/v1/schedule-rules"))
.json(&serde_json::json!({
"by": "string",
"environment": "string",
"filter": {
"min_elevation": "string",
"station": "string",
"status": "predicted",
"uplink": true
},
"id": "string",
"inputs": {},
"library": "string",
"run": "string",
"start": "string",
"target": "string",
"targets": {
"key": "string"
}
}))
.send()
.await?
.error_for_status()?;
let body: serde_json::Value = response.json().await?;
println!("{body:#}");Response
{
"by": "string",
"environment": "string",
"filter": {
"min_elevation": "string",
"station": "string",
"status": "predicted",
"uplink": true
},
"id": "string",
"inputs": {},
"library": "string",
"run": "string",
"start": "string",
"target": "string",
"targets": {
"key": "string"
}
}{
"errors": [
{
"code": "string",
"message": "string",
"help": "string"
}
]
}{
"errors": [
{
"code": "string",
"message": "string",
"help": "string"
}
]
}/v1/schedule-rules/{id}Delete schedule rule#
Remove a recurring rule
No new schedule from the rule; the schedules it made remain.
Path parameters
idrequiredstring
Rule identifier.
Responses
404No such rule: schedule::unknown-rule.application/json
errorsrequiredarray of ErrorItem
Every error found.
ErrorItem · 3 fields
coderequiredstring
Stable code.
messagerequiredstring
Message for the operator.
helpstring
Suggested fix.
503The MCS bus (NATS) is unavailable: api::unavailable.application/json
errorsrequiredarray of ErrorItem
Every error found.
ErrorItem · 3 fields
coderequiredstring
Stable code.
messagerequiredstring
Message for the operator.
helpstring
Suggested fix.
Request
curl -X DELETE "http://localhost:8080/v1/schedule-rules/<id>"import requests
BASE_URL = "http://localhost:8080"
id = "<id>" # Rule identifier.
response = requests.delete(f"{BASE_URL}/v1/schedule-rules/{id}")
response.raise_for_status()let base_url = "http://localhost:8080";
let id = "<id>"; // Rule identifier.
let response = reqwest::Client::new()
.delete(format!("{base_url}/v1/schedule-rules/{id}"))
.send()
.await?
.error_for_status()?;Response
{
"errors": [
{
"code": "string",
"message": "string",
"help": "string"
}
]
}{
"errors": [
{
"code": "string",
"message": "string",
"help": "string"
}
]
}/v1/schedules/watchWatch schedules#
Watch the schedules (WebSocket)
Sends every schedule, then each one that changes (scheduled, at risk, cancelled, fired, missed).
Query parameters
targetstring
Only the schedules on the passes of this target.
Responses
101WebSocket: one Schedule per message.application/json
bystring
Who created it.
environmentstring
Environment; by default the last environment of the target of the pass.
fire_at string
Start time from the current pass, set by the MCS.
idrequiredstring
Identifier.
inputsobject
Input values, as written in a run request.
irstring
Hash of the resolved run, set by the MCS.
librarystring
Library of the procedure, when several have a procedure of that name.
max_duration string
Maximum duration of the run, set by the MCS.
needs_validation boolean
Whether a supervisor must validate the plan before it starts: a hazardous
telecommand in an environment where the supervisor confirms. Set by the MCS.
passrequiredstring
Pass.
reasonsarray of string
Why at risk, cancelled or missed.
runrequiredstring
Procedure.
run_id string
Run submitted, set by the MCS.
sendsboolean
Whether the run sends telecommands, set by the MCS.
startrequiredstring
Start relative to the AOS: aos, aos + 30 s.
stateState, set by the MCS.
targetstring
Target of the pass, set by the MCS.
targetsrequiredmap of string
Target of each role.
updated_at string
Last change.
validationone of PlanValidation | null
Validation of the plan, while it holds.
503The MCS bus (NATS) is unavailable: api::unavailable.application/json
errorsrequiredarray of ErrorItem
Every error found.
ErrorItem · 3 fields
coderequiredstring
Stable code.
messagerequiredstring
Message for the operator.
helpstring
Suggested fix.
Request
curl "http://localhost:8080/v1/schedules/watch"import requests
BASE_URL = "http://localhost:8080"
response = requests.get(f"{BASE_URL}/v1/schedules/watch")
response.raise_for_status()let base_url = "http://localhost:8080";
let response = reqwest::Client::new()
.get(format!("{base_url}/v1/schedules/watch"))
.send()
.await?
.error_for_status()?;Response
{
"by": "string",
"environment": "string",
"fire_at": "string",
"id": "string",
"inputs": {},
"ir": "string",
"library": "string",
"max_duration": "string",
"needs_validation": false,
"pass": "string",
"reasons": [
"string"
],
"run": "string",
"run_id": "string",
"sends": false,
"start": "string",
"state": "scheduled",
"target": "string",
"targets": {
"key": "string"
},
"updated_at": "string",
"validation": {
"aos": "string",
"at": "string",
"by": "string",
"ir": "string",
"los": "string",
"pass": "string"
}
}{
"errors": [
{
"code": "string",
"message": "string",
"help": "string"
}
]
}