Generate OEM from a state vector
curl --request POST \
--url https://api.valar.space/operations/state-vectors/{id}/generate-oem \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"finalDate": "2024-01-02T00:00:00Z",
"initialDate": "2024-01-01T00:00:00Z",
"referenceFrame": "GCRF",
"timeBetweenPoints": 60,
"timeSystem": "UTC",
"covarianceFrame": "RTN",
"covarianceFrameValid": true,
"dateRangeValid": true,
"includeCovariance": false,
"timeSpanValid": true
}
'import requests
url = "https://api.valar.space/operations/state-vectors/{id}/generate-oem"
payload = {
"finalDate": "2024-01-02T00:00:00Z",
"initialDate": "2024-01-01T00:00:00Z",
"referenceFrame": "GCRF",
"timeBetweenPoints": 60,
"timeSystem": "UTC",
"covarianceFrame": "RTN",
"covarianceFrameValid": True,
"dateRangeValid": True,
"includeCovariance": False,
"timeSpanValid": True
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
finalDate: '2024-01-02T00:00:00Z',
initialDate: '2024-01-01T00:00:00Z',
referenceFrame: 'GCRF',
timeBetweenPoints: 60,
timeSystem: 'UTC',
covarianceFrame: 'RTN',
covarianceFrameValid: true,
dateRangeValid: true,
includeCovariance: false,
timeSpanValid: true
})
};
fetch('https://api.valar.space/operations/state-vectors/{id}/generate-oem', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.valar.space/operations/state-vectors/{id}/generate-oem",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'finalDate' => '2024-01-02T00:00:00Z',
'initialDate' => '2024-01-01T00:00:00Z',
'referenceFrame' => 'GCRF',
'timeBetweenPoints' => 60,
'timeSystem' => 'UTC',
'covarianceFrame' => 'RTN',
'covarianceFrameValid' => true,
'dateRangeValid' => true,
'includeCovariance' => false,
'timeSpanValid' => true
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.valar.space/operations/state-vectors/{id}/generate-oem"
payload := strings.NewReader("{\n \"finalDate\": \"2024-01-02T00:00:00Z\",\n \"initialDate\": \"2024-01-01T00:00:00Z\",\n \"referenceFrame\": \"GCRF\",\n \"timeBetweenPoints\": 60,\n \"timeSystem\": \"UTC\",\n \"covarianceFrame\": \"RTN\",\n \"covarianceFrameValid\": true,\n \"dateRangeValid\": true,\n \"includeCovariance\": false,\n \"timeSpanValid\": true\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.valar.space/operations/state-vectors/{id}/generate-oem")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"finalDate\": \"2024-01-02T00:00:00Z\",\n \"initialDate\": \"2024-01-01T00:00:00Z\",\n \"referenceFrame\": \"GCRF\",\n \"timeBetweenPoints\": 60,\n \"timeSystem\": \"UTC\",\n \"covarianceFrame\": \"RTN\",\n \"covarianceFrameValid\": true,\n \"dateRangeValid\": true,\n \"includeCovariance\": false,\n \"timeSpanValid\": true\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.valar.space/operations/state-vectors/{id}/generate-oem")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"finalDate\": \"2024-01-02T00:00:00Z\",\n \"initialDate\": \"2024-01-01T00:00:00Z\",\n \"referenceFrame\": \"GCRF\",\n \"timeBetweenPoints\": 60,\n \"timeSystem\": \"UTC\",\n \"covarianceFrame\": \"RTN\",\n \"covarianceFrameValid\": true,\n \"dateRangeValid\": true,\n \"includeCovariance\": false,\n \"timeSpanValid\": true\n}"
response = http.request(request)
puts response.read_bodyCCSDS_OEM_VERS = 2.0
CREATION_DATE = 2024-06-15T12:30:00
ORIGINATOR = VALAR
...{
"timestamp": "2025-01-15T10:30:00.000Z",
"status": 400,
"error": "Bad Request",
"message": "Time span cannot exceed 30 days",
"path": "/operations/state-vectors/{id}/generate-oem"
}{
"error": "invalid_token",
"error_description": "An error occurred while attempting to decode the Jwt"
}{
"code": "import.tracking.tdm.parse_failed",
"correlationId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"details": {},
"error": "Bad Request",
"fieldErrors": {},
"message": "Invalid spacecraft ID format",
"params": {},
"path": "/api/v1/stm/credentials",
"status": 400,
"timestamp": "2025-11-14T10:15:30.123Z"
}{
"timestamp": "2025-01-15T10:30:00.000Z",
"status": 404,
"error": "Not Found",
"message": "StateVector not found with id: SV-999",
"path": "/operations/state-vectors/SV-999/generate-oem"
}{
"code": "import.tracking.tdm.parse_failed",
"correlationId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"details": {},
"error": "Bad Request",
"fieldErrors": {},
"message": "Invalid spacecraft ID format",
"params": {},
"path": "/api/v1/stm/credentials",
"status": 400,
"timestamp": "2025-11-14T10:15:30.123Z"
}{
"code": "import.tracking.tdm.parse_failed",
"correlationId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"details": {},
"error": "Bad Request",
"fieldErrors": {},
"message": "Invalid spacecraft ID format",
"params": {},
"path": "/api/v1/stm/credentials",
"status": 400,
"timestamp": "2025-11-14T10:15:30.123Z"
}State Vectors
Generate OEM from a state vector
Generate CCSDS OEM v2.0 format ephemerides from a state vector with specified time range, reference frame, time system, and optional covariance propagation. Maximum time span is 30 days.
POST
/
operations
/
state-vectors
/
{id}
/
generate-oem
Generate OEM from a state vector
curl --request POST \
--url https://api.valar.space/operations/state-vectors/{id}/generate-oem \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"finalDate": "2024-01-02T00:00:00Z",
"initialDate": "2024-01-01T00:00:00Z",
"referenceFrame": "GCRF",
"timeBetweenPoints": 60,
"timeSystem": "UTC",
"covarianceFrame": "RTN",
"covarianceFrameValid": true,
"dateRangeValid": true,
"includeCovariance": false,
"timeSpanValid": true
}
'import requests
url = "https://api.valar.space/operations/state-vectors/{id}/generate-oem"
payload = {
"finalDate": "2024-01-02T00:00:00Z",
"initialDate": "2024-01-01T00:00:00Z",
"referenceFrame": "GCRF",
"timeBetweenPoints": 60,
"timeSystem": "UTC",
"covarianceFrame": "RTN",
"covarianceFrameValid": True,
"dateRangeValid": True,
"includeCovariance": False,
"timeSpanValid": True
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
finalDate: '2024-01-02T00:00:00Z',
initialDate: '2024-01-01T00:00:00Z',
referenceFrame: 'GCRF',
timeBetweenPoints: 60,
timeSystem: 'UTC',
covarianceFrame: 'RTN',
covarianceFrameValid: true,
dateRangeValid: true,
includeCovariance: false,
timeSpanValid: true
})
};
fetch('https://api.valar.space/operations/state-vectors/{id}/generate-oem', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.valar.space/operations/state-vectors/{id}/generate-oem",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'finalDate' => '2024-01-02T00:00:00Z',
'initialDate' => '2024-01-01T00:00:00Z',
'referenceFrame' => 'GCRF',
'timeBetweenPoints' => 60,
'timeSystem' => 'UTC',
'covarianceFrame' => 'RTN',
'covarianceFrameValid' => true,
'dateRangeValid' => true,
'includeCovariance' => false,
'timeSpanValid' => true
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.valar.space/operations/state-vectors/{id}/generate-oem"
payload := strings.NewReader("{\n \"finalDate\": \"2024-01-02T00:00:00Z\",\n \"initialDate\": \"2024-01-01T00:00:00Z\",\n \"referenceFrame\": \"GCRF\",\n \"timeBetweenPoints\": 60,\n \"timeSystem\": \"UTC\",\n \"covarianceFrame\": \"RTN\",\n \"covarianceFrameValid\": true,\n \"dateRangeValid\": true,\n \"includeCovariance\": false,\n \"timeSpanValid\": true\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.valar.space/operations/state-vectors/{id}/generate-oem")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"finalDate\": \"2024-01-02T00:00:00Z\",\n \"initialDate\": \"2024-01-01T00:00:00Z\",\n \"referenceFrame\": \"GCRF\",\n \"timeBetweenPoints\": 60,\n \"timeSystem\": \"UTC\",\n \"covarianceFrame\": \"RTN\",\n \"covarianceFrameValid\": true,\n \"dateRangeValid\": true,\n \"includeCovariance\": false,\n \"timeSpanValid\": true\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.valar.space/operations/state-vectors/{id}/generate-oem")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"finalDate\": \"2024-01-02T00:00:00Z\",\n \"initialDate\": \"2024-01-01T00:00:00Z\",\n \"referenceFrame\": \"GCRF\",\n \"timeBetweenPoints\": 60,\n \"timeSystem\": \"UTC\",\n \"covarianceFrame\": \"RTN\",\n \"covarianceFrameValid\": true,\n \"dateRangeValid\": true,\n \"includeCovariance\": false,\n \"timeSpanValid\": true\n}"
response = http.request(request)
puts response.read_bodyCCSDS_OEM_VERS = 2.0
CREATION_DATE = 2024-06-15T12:30:00
ORIGINATOR = VALAR
...{
"timestamp": "2025-01-15T10:30:00.000Z",
"status": 400,
"error": "Bad Request",
"message": "Time span cannot exceed 30 days",
"path": "/operations/state-vectors/{id}/generate-oem"
}{
"error": "invalid_token",
"error_description": "An error occurred while attempting to decode the Jwt"
}{
"code": "import.tracking.tdm.parse_failed",
"correlationId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"details": {},
"error": "Bad Request",
"fieldErrors": {},
"message": "Invalid spacecraft ID format",
"params": {},
"path": "/api/v1/stm/credentials",
"status": 400,
"timestamp": "2025-11-14T10:15:30.123Z"
}{
"timestamp": "2025-01-15T10:30:00.000Z",
"status": 404,
"error": "Not Found",
"message": "StateVector not found with id: SV-999",
"path": "/operations/state-vectors/SV-999/generate-oem"
}{
"code": "import.tracking.tdm.parse_failed",
"correlationId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"details": {},
"error": "Bad Request",
"fieldErrors": {},
"message": "Invalid spacecraft ID format",
"params": {},
"path": "/api/v1/stm/credentials",
"status": 400,
"timestamp": "2025-11-14T10:15:30.123Z"
}{
"code": "import.tracking.tdm.parse_failed",
"correlationId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"details": {},
"error": "Bad Request",
"fieldErrors": {},
"message": "Invalid spacecraft ID format",
"params": {},
"path": "/api/v1/stm/credentials",
"status": 400,
"timestamp": "2025-11-14T10:15:30.123Z"
}Body
application/json
Request parameters for OEM generation with configurable propagation settings
Response
OEM file generated successfully
The response is of type string.
Was this page helpful?