OurskyClient.Sda (OurskyClient v0.1.4)
View SourceClient for the OurSky SDA API https://api.prod.oursky.ai/docs/sda
Summary
Functions
Cancel a plane scan given its UUID
Cancel a volumetric search given its UUID
Create a custom target for your organization using a two-line element set (TLE)
Get node properties given a node's UUID (found in observation sequence results)
Get observation sequence results for a given target UUID
Get target information for a given NORAD ID
Get all targets tasked by your organization
Schedule a plane scan on a target
Schedule a volumetric search on a target
Task a target to be observed given a UUID (OurSky uses immutable UUIDs for each target- these can be retrieved using the get_targets_by_norad_id function)
Untask a target given its UUID.
PUT request to update a target's TLE
Functions
Cancel a plane scan given its UUID
Parameters
scan_uuid
: The UUID of the scan
Cancel a volumetric search given its UUID
Parameters
search_uuid
: The UUID of the search
Create a custom target for your organization using a two-line element set (TLE)
Parameters
tle_line_1
: The first line of the TLEtle_line_2
: The second line of the TLEname
: The name of the target
Options
:mass
- Mass in kg (default: 100.0):area
- Cross-sectional area in square meters (default: 1.0):reflection_coefficient
- Reflection coefficient (default: 0.2):linked_target_id
- UUID of linked target (default: nil)
Examples
iex> OurskyClient.Sda.create_target(
...> "1 25544U 98067A 25080.55743056 .00026289 00000-0 47116-3 0 9999",
...> "2 25544 51.6381 21.0488 0004053 35.5022 296.1249 15.49747147501567",
...> "ISS (ZARYA)",
...> mass: 420000.0,
...> area: 160.0
...> )
{:ok, "6e801835-4aae-4b78-9741-f10fbab472db"}
Get node properties given a node's UUID (found in observation sequence results)
Examples
iex> OurskyClient.Sda.get_node_properties("3be53422-5c54-413c-9a54-2a8e73c0ed27")
{:ok,
%OurskyClient.Sda.Node{
id: "3be53422-5c54-413c-9a54-2a8e73c0ed27",
gps_timestamps: false,
location: %{latitude: 52.200239, longitude: 6.857524, altitude: 30.0},
mount_type: "EQUITORIAL",
ota_aperture_mm: 207,
ota_focal_length_mm: 831,
pixel_size_microns: 4.78,
focuser_travel_distance_mm: nil,
shutter_type: "ROLLING",
megapixels: 16.236096
}}
Get observation sequence results for a given target UUID
- If you intend to receive many observations, set up webhooks on the API console.
Parameters
target_uuid
: The UUID of the targetmin_epoch
: The minimum epoch to filter resultsmax_pages
: The maximum number of pages to retrieve (default: 100)
Examples
iex> OurskyClient.Sda.get_observation_sequence_results("c0baf754-4561-4219-a559-03f648c1208e", "2025-03-21T00:00:00Z")
{:ok, [%OurskyClient.Sda.ObservationSequenceResult{...}]}
Get target information for a given NORAD ID
Examples
iex> OurskyClient.Sda.get_targets_by_norad_id("25544")
{:ok,
[
%OurskyClient.Sda.SatelliteTarget{
id: "6e801835-4aae-4b78-9741-f10fbab472db",
norad_id: "25544",
name: "ISS (ZARYA)",
description: nil,
area: 160.273,
mass: 20351.0,
classification: "U",
reflection_coefficient: nil,
launch_year: 1998,
elset_number: nil,
orbit_type: "LEO",
mean_motion: 15.497471470000002,
eccentricity: 4.053e-4,
inclination: 51.6381,
raan: 21.0488,
arg_of_perigee: 35.5022,
mean_anomaly: 296.1249,
epoch: ~U[2025-03-21 13:22:42Z],
mean_motion_dot: nil,
mean_motion_ddot: 0.0,
bstar: 0.0,
tle_line_1: "1 25544U 98067A 25080.55743056 .00026289 00000-0 47116-3 0 9999",
tle_line_2: "2 25544 51.6381 21.0488 0004053 35.5022 296.1249 15.49747147501567",
tracking_status: "ACTIVE",
linked_target_id: nil,
rev_at_epoch: 50156
}
]}
Get all targets tasked by your organization
Schedule a plane scan on a target
- Searches a target's orbital plane in the specified angle range, centered on the target
- Returns a UUID for the scan
- Observations generated by the scan are available in the observation sequence results endpoint or webhooks
- Webhooks for searches are also available in the API console
Parameters
target_uuid
: The UUID of the targetstep_size
: The step size in degrees (default: 1.0)half_angle_range
: The half angle range in degrees (default: 5.0) - the scan will cover this range on either side of the target
Schedule a volumetric search on a target
- Searches a volume around a target (volume is specified by a 3-sigma RIC uncertainty)
- Returns a UUID for the search
- Observations generated by the search are available in the observation sequence results endpoint or webhooks
- Webhooks for searches are also available in the API console
Parameters
target_uuid
: The UUID of the targetradial_3_sigma
: The radial 3-sigma uncertainty in m (default: 20000.0)intrack_3_sigma
: The in-track 3-sigma uncertainty in m (default: 50000.0)cross_track_3_sigma
: The cross-track 3-sigma uncertainty in m (default: 10000.0)covariance_epoch
: The epoch of the covariance in ISO 8601 format (default: nil - use the current epoch)
Task a target to be observed given a UUID (OurSky uses immutable UUIDs for each target- these can be retrieved using the get_targets_by_norad_id function)
Returns an OrganizationTarget
(SatelliteTarget
+ tasking information)
Examples
iex> OurskyClient.Sda.task_observations_on_target("c0baf754-4561-4219-a559-03f648c1208e")
{:ok,
%OurskyClient.Sda.OrganizationTarget{
created_at: ~U[2025-03-21 23:25:50.445716Z],
created_by: "123e4567-e89b-12d3-a456-426614174000",
id: "333afd5e-9b4e-4811-8a18-fde7b2604fce",
revisit_rate_minutes: nil,
satellite_target: %OurskyClient.Sda.SatelliteTarget{
id: "c0baf754-4561-4219-a559-03f648c1208e",
norad_id: "41937",
name: "SBIRS GEO 4 (USA 273)",
description: nil,
area: 33.213,
mass: nil,
classification: "U",
reflection_coefficient: nil,
launch_year: 2017,
elset_number: nil,
orbit_type: "EGO",
mean_motion: 0.9999522199999998,
eccentricity: 2.276e-4,
inclination: 1.5423,
raan: 21.6811,
arg_of_perigee: 329.5307,
mean_anomaly: 172.5673,
epoch: ~U[2025-03-21 09:49:38.672Z],
mean_motion_dot: nil,
mean_motion_ddot: 0.0,
bstar: 0.0,
tle_line_1: "1 41937U 17004A 25080.40947537 .00000107 00000-0 00000-0 0 9998",
tle_line_2: "2 41937 1.5423 21.6811 0002276 329.5307 172.5673 0.99995222 30063",
tracking_status: "ACTIVE",
linked_target_id: nil,
rev_at_epoch: 3006
}
}}
Untask a target given its UUID.
Examples
iex> OurskyClient.Sda.untask_target("c0baf754-4561-4219-a559-03f648c1208e")
{:ok, %{"id" => "333afd5e-9b4e-4811-8a18-fde7b2604fce"}}
PUT request to update a target's TLE