Skip to content
AstroWay/api v2.190.0 · integrations
all systems operational

n8n

A workflow of four nodes: birth data in, natal chart from the API, Sun, Moon and rising sign out. It was imported into n8n 2.39.7 and run against production on 2026-09-17, and the output below is what it returned.

Before you start, create a key as described in A key for an automation, scoped to chart.

The key goes into n8n’s credential store, not into the node, so it does not travel with an exported workflow.

  1. In n8n create a new credential of type Header Auth.
  2. Name: X-Api-Key.
  3. Value: your key.
  4. Save it as AstroWay API key. The workflow below looks the credential up by that name.

Download n8n-natal-chart.json, open an empty workflow and paste the file’s contents onto the canvas, or use the import from file in the workflow menu.

It contains four nodes:

  • Start, a Manual Trigger: runs the workflow when you test it.
  • Birth data, an Edit Fields (Set) node: date, time, timezone, latitude and longitude for one person.
  • AstroWay chart, an HTTP Request node: calls POST /v1/chart.
  • Big three, an Edit Fields (Set) node: turns longitudes into sign names.

Execute the workflow. Big three returns:

{
"sun": "Taurus",
"moon": "Capricorn",
"rising": "Virgo",
"offset_used": 4
}

offset_used is the UTC offset the server worked out from Europe/Kyiv for 1990-05-15: 4, not the 3 a hand-typed offset would usually say.

  • Method: POST.

  • URL:

    https://api.astroway.info/v1/chart
  • Authentication: Generic Credential Type.

  • Generic Auth Type: Header Auth, with the credential AstroWay API key.

  • Send Body: on.

  • Body Content Type: JSON.

  • Specify Body: Using JSON.

The body is an expression, so values from any earlier node pass through as they are:

{{ JSON.stringify({ date: $json.date, time: $json.time, timezone: $json.timezone, latitude: $json.latitude, longitude: $json.longitude }) }}

Each field in Big three is an expression. The sign is the longitude divided by 30, rounded down, used as an index:

{{ ['Aries','Taurus','Gemini','Cancer','Leo','Virgo','Libra','Scorpio','Sagittarius','Capricorn','Aquarius','Pisces'][Math.floor($json.data.houses.ascendant / 30)] }}

For the Sun and the Moon the longitude comes from $json.data.planets.find(p => p.name === 'Sun').longitude and the same with 'Moon'.

Replace Start and Birth data with the trigger you actually use, a form, a webhook or a new spreadsheet row, and map its fields onto the five names above. Two things to check:

  • timezone must not be empty. An empty value is refused with 400, so map the field or set it to auto when your coordinates are reliable.
  • Coordinates are required. The API does not geocode a city name; if your form only asks for a place, add a geocoding step before AstroWay chart.
Was this helpful?
Suggest an edit

Last updated: