/v1/crossings
API-Key noetig Ereignisse Exakte Zeitpunkte, zu denen ein Koerper eine ekliptikale Laenge ueberquert (Konstellationsscanner-Baustein).
Beschreibung
"Wann steht Mars auf 15° Widder?" — findet alle Ueberquerungen der Ziel-Laengen im Zeitraum, inklusive Mehrfach-Treffern durch Rueckläufigkeit (direkt → retro → direkt). Bisection-Toleranz 1e-4°. Unterstuetzt die Beobachtungs-Optionen (zodiac/ayanamsa/center) — z. B. siderische Ingresse oder heliozentrische Zyklen. Max. Zeitraum ~200 Jahre, max. 500 Events pro Anfrage (settings.truncated zeigt Abschneiden an).
Parameter
| Name | In | Typ | Pflicht | Beschreibung |
|---|---|---|---|---|
body |
body | string | ja | Ein Koerper aus dem Planeten-Katalog (sun … pluto, mean/true_node, mean/osculating_apogee, chiron, pholus, ceres, pallas, juno, vesta). |
longitude / longitudes |
body | number|array | ja | Ziel-Laenge(n) in Dezimalgrad (0..360, max. 24 pro Anfrage). |
start |
body | string | ja | ISO 8601 UTC. |
end |
body | string | ja | ISO 8601 UTC, nach "start". |
step_days |
body | number | nein | Scan-Schrittweite (0.01..30). Default koerperabhaengig (Mond 0.5, Sonne/Merkur/Venus 1, sonst 2–3). |
zodiac / ayanamsa / center / observer |
body | mixed | nein | Beobachtungs-Optionen wie bei /v1/planets. Bei center=planet:<name> muss "body" vom Zentrum verschieden sein. |
Beispiel-Aufruf
curl -sS \
-H "X-API-Key: ak_test_<DEIN_KEY>" \
-H "Content-Type: application/json" \
-X POST \
-d '{
"body": "mars",
"longitude": 15,
"start": "2026-01-01T00:00:00Z",
"end": "2028-01-01T00:00:00Z"
}' \
"https://astroapi.services/v1/crossings"
<?php
$ch = curl_init("https://astroapi.services/v1/crossings");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, ["X-API-Key: ak_test_<DEIN_KEY>", "Content-Type: application/json"]);
curl_setopt($ch, CURLOPT_POST, true);
curl_setopt($ch, CURLOPT_POSTFIELDS, '{"body":"mars","longitude":15,"start":"2026-01-01T00:00:00Z","end":"2028-01-01T00:00:00Z"}');
$response = json_decode(curl_exec($ch), true);
curl_close($ch);
print_r($response);
<?php
require 'astroapi-client.php';
$api = new AstroApiClient('ak_test_<DEIN_KEY>');
$response = $api->crossings([
'body' => 'mars',
'longitude' => 15,
'start' => '2026-01-01T00:00:00Z',
'end' => '2028-01-01T00:00:00Z',
]);
print_r($response);
const response = await fetch('https://astroapi.services/v1/crossings', {
method: 'POST',
headers: { 'X-API-Key': 'ak_test_<DEIN_KEY>', 'Content-Type': 'application/json' },
body: JSON.stringify({
"body": "mars",
"longitude": 15,
"start": "2026-01-01T00:00:00Z",
"end": "2028-01-01T00:00:00Z"
}),
});
const data = await response.json();
console.log(data);
import { AstroApiClient } from './astroapi-client.js';
const api = new AstroApiClient('ak_test_<DEIN_KEY>');
const response = await api.crossings({
"body": "mars",
"longitude": 15,
"start": "2026-01-01T00:00:00Z",
"end": "2028-01-01T00:00:00Z"
});
console.log(response);
import requests
url = 'https://astroapi.services/v1/crossings'
headers = {'X-API-Key': 'ak_test_<DEIN_KEY>'}
payload = {
"body": "mars",
"longitude": 15,
"start": "2026-01-01T00:00:00Z",
"end": "2028-01-01T00:00:00Z"
}
response = requests.post(url, headers=headers, json=payload)
print(response.json())
from astroapi_client import AstroApiClient
api = AstroApiClient('ak_test_<DEIN_KEY>')
response = api.crossings({
'body': 'mars',
'longitude': 15,
'start': '2026-01-01T00:00:00Z',
'end': '2028-01-01T00:00:00Z',
})
print(response)