Skip to content

SBDB Lookup

API reference for the JPL Small-Body Database Lookup client. All types are available via brahe.datasets.sbdb.

SBDBClient

SBDBClient

SBDBClient(base_url: str = None, cache_max_age: int = None)

Client for the JPL Small-Body Database (SBDB) Lookup API.

Parameters:

Name Type Description Default
base_url str

Override the SBDB base URL (for testing).

None
cache_max_age int

Cache max age in seconds (0 = always refetch).

None
Example
1
2
3
4
import brahe as bh
client = bh.datasets.sbdb.SBDBClient()
ceres = client.lookup("Ceres")
print(ceres.naif_id())  # 20000001

Initialize instance.

lookup method descriptor

lookup(sstr: str) -> SBDBObject

Resolve a search string to an SBDBObject.

Parameters:

Name Type Description Default
sstr str

Object search string, e.g. "Ceres" or "20000001".

required

Returns:

Name Type Description
SBDBObject SBDBObject

The resolved object.

SBDBObject

SBDBObject

SBDBObject()

A resolved JPL Small-Body Database object.

Attributes:

Name Type Description
spkid int

Primary SPK-ID (NAIF ID).

full_name str

Full designation and name.

des str

Primary designation.

shortname str | None

Name without alternate designation.

kind str

Object kind code.

neo bool

Whether the object is a near-Earth object.

gm float | None

Gravitational parameter [m^3/s^2], if catalogued.

radius float | None

Mean radius [m], if catalogued.

Initialize instance.

des property

des: Any

TODO: Add docstring

full_name property

full_name: Any

TODO: Add docstring

gm property

gm: Any

TODO: Add docstring

kind property

kind: Any

TODO: Add docstring

neo property

neo: Any

TODO: Add docstring

radius property

radius: Any

TODO: Add docstring

shortname property

shortname: Any

TODO: Add docstring

spkid property

spkid: Any

TODO: Add docstring

naif_id method descriptor

naif_id() -> int

Return the object's NAIF ID (identical to its SPK-ID).

Returns:

Name Type Description
int int

The NAIF ID.


See Also