Skip to content

Commit 4ea1aa8

Browse files
committed
fix(php): expose humanDesign and forecast on the Roxy facade and stage Roxy.php in releases
The release commit step never git-added src/Roxy.php, so when generate.mjs regenerated the facade for the new domains the RESOURCES map was not committed. Published 0.1.9 threw Unknown resource for roxy->humanDesign and roxy->forecast despite shipping the resource classes. Regenerate the facade from the live spec (also picks up forecastSolarReturn and the penta, variables, digest, solar-return endpoints) and add src/Roxy.php to the release git add so it cannot drift again.
1 parent 0c7f1a9 commit 4ea1aa8

6 files changed

Lines changed: 166 additions & 76 deletions

File tree

.github/workflows/release.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ jobs:
8282
git config user.name "github-actions[bot]"
8383
git config user.email "github-actions[bot]@users.noreply.github.com"
8484
VERSION="${{ steps.bump.outputs.version }}"
85-
git add composer.json package.json src/Version.php specs/openapi.json src/Generated tests/Generated README.md AGENTS.md
85+
git add composer.json package.json src/Version.php specs/openapi.json src/Roxy.php src/Generated tests/Generated README.md AGENTS.md
8686
git commit -m "release: v$VERSION"
8787
git tag "v$VERSION"
8888
git push --follow-tags

specs/openapi.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53376,7 +53376,7 @@
5337653376
},
5337753377
"/forecast/solar-return": {
5337853378
"post": {
53379-
"operationId": "generateSolarReturn",
53379+
"operationId": "forecastSolarReturn",
5338053380
"tags": [
5338153381
"Forecast"
5338253382
],
Lines changed: 84 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,84 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
/**
6+
* AUTO-GENERATED by scripts/generate.mjs from the live OpenAPI spec.
7+
* Do not edit this file by hand. Regenerate with: node scripts/generate.mjs
8+
*/
9+
10+
namespace RoxyAPI\Sdk\Generated\Requests;
11+
12+
use Saloon\Enums\Method;
13+
use Saloon\Http\Request;
14+
use Saloon\Contracts\Body\HasBody;
15+
use Saloon\Traits\Body\HasJsonBody;
16+
17+
/**
18+
* Solar return chart - Annual birthday forecast chart for a single subject
19+
*
20+
* Cast the solar return chart for one subject and year: the chart erected for the exact moment
21+
* the transiting Sun returns to its natal ecliptic longitude, the foundational technique for
22+
* annual astrological forecasting. Returns the full tropical chart with planetary positions,
23+
* house cusps, aspects, Ascendant, and Midheaven. Location-sensitive: pass the birthplace to
24+
* anchor the chart to natal geography, or the current city for a relocated solar return where
25+
* the houses and Ascendant shift to where you are on your birthday. Built for year-ahead
26+
* forecast tools, birthday charts, and annual horoscope features.
27+
*
28+
* POST /forecast/solar-return
29+
*/
30+
class ForecastSolarReturnRequest extends Request implements HasBody
31+
{
32+
use HasJsonBody;
33+
34+
protected Method $method = Method::POST;
35+
36+
public function __construct(
37+
public readonly string $date,
38+
public readonly float $latitude,
39+
public readonly float $longitude,
40+
public readonly string $time,
41+
public readonly mixed $timezone,
42+
public readonly int $year,
43+
public readonly ?string $houseSystem = null,
44+
public readonly ?string $lang = null,
45+
) {
46+
}
47+
48+
public function resolveEndpoint(): string
49+
{
50+
return "/forecast/solar-return";
51+
}
52+
53+
/**
54+
* @return array<string, mixed>
55+
*/
56+
protected function defaultBody(): array
57+
{
58+
$body = [];
59+
$body['date'] = $this->date;
60+
if ($this->houseSystem !== null) {
61+
$body['houseSystem'] = $this->houseSystem;
62+
}
63+
$body['latitude'] = $this->latitude;
64+
$body['longitude'] = $this->longitude;
65+
$body['time'] = $this->time;
66+
$body['timezone'] = $this->timezone;
67+
$body['year'] = $this->year;
68+
69+
return $body;
70+
}
71+
72+
/**
73+
* @return array<string, mixed>
74+
*/
75+
protected function defaultQuery(): array
76+
{
77+
$query = [];
78+
if ($this->lang !== null) {
79+
$query['lang'] = $this->lang;
80+
}
81+
82+
return $query;
83+
}
84+
}

src/Generated/Requests/GenerateSolarReturnRequest.php

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -15,17 +15,17 @@
1515
use Saloon\Traits\Body\HasJsonBody;
1616

1717
/**
18-
* Solar return chart - Annual birthday forecast chart for a single subject
18+
* Solar Return Chart - Annual birthday forecast with relocated chart
1919
*
20-
* Cast the solar return chart for one subject and year: the chart erected for the exact moment
21-
* the transiting Sun returns to its natal ecliptic longitude, the foundational technique for
22-
* annual astrological forecasting. Returns the full tropical chart with planetary positions,
23-
* house cusps, aspects, Ascendant, and Midheaven. Location-sensitive: pass the birthplace to
24-
* anchor the chart to natal geography, or the current city for a relocated solar return where
25-
* the houses and Ascendant shift to where you are on your birthday. Built for year-ahead
26-
* forecast tools, birthday charts, and annual horoscope features.
20+
* Generate a solar return chart for any year, the foundational technique for annual
21+
* astrological forecasting. The chart is cast for the exact moment the transiting Sun returns
22+
* to its natal ecliptic longitude (your astrological birthday). Returns full tropical zodiac
23+
* chart with planetary positions, house cusps, aspects, Ascendant, and Midheaven.
24+
* Location-sensitive: relocating your solar return chart to a different city changes the
25+
* houses and Ascendant. Solar return chart API, annual horoscope forecast, birthday chart
26+
* calculator, yearly astrology prediction, relocated solar return.
2727
*
28-
* POST /forecast/solar-return
28+
* POST /astrology/solar-return
2929
*/
3030
class GenerateSolarReturnRequest extends Request implements HasBody
3131
{
@@ -34,20 +34,20 @@ class GenerateSolarReturnRequest extends Request implements HasBody
3434
protected Method $method = Method::POST;
3535

3636
public function __construct(
37-
public readonly string $date,
37+
public readonly string $birthDate,
38+
public readonly string $birthTime,
3839
public readonly float $latitude,
3940
public readonly float $longitude,
40-
public readonly string $time,
41+
public readonly int $returnYear,
4142
public readonly mixed $timezone,
42-
public readonly int $year,
4343
public readonly ?string $houseSystem = null,
4444
public readonly ?string $lang = null,
4545
) {
4646
}
4747

4848
public function resolveEndpoint(): string
4949
{
50-
return "/forecast/solar-return";
50+
return "/astrology/solar-return";
5151
}
5252

5353
/**
@@ -56,15 +56,15 @@ public function resolveEndpoint(): string
5656
protected function defaultBody(): array
5757
{
5858
$body = [];
59-
$body['date'] = $this->date;
59+
$body['birthDate'] = $this->birthDate;
60+
$body['birthTime'] = $this->birthTime;
6061
if ($this->houseSystem !== null) {
6162
$body['houseSystem'] = $this->houseSystem;
6263
}
6364
$body['latitude'] = $this->latitude;
6465
$body['longitude'] = $this->longitude;
65-
$body['time'] = $this->time;
66+
$body['returnYear'] = $this->returnYear;
6667
$body['timezone'] = $this->timezone;
67-
$body['year'] = $this->year;
6868

6969
return $body;
7070
}

src/Generated/Resources/ForecastResource.php

Lines changed: 58 additions & 58 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,64 @@ public function findSignificantDates(
6767
return $this->callRequest($request);
6868
}
6969

70+
/**
71+
* Solar return chart - Annual birthday forecast chart for a single subject
72+
*
73+
* Cast the solar return chart for one subject and year: the chart erected for the exact moment
74+
* the transiting Sun returns to its natal ecliptic longitude, the foundational technique for
75+
* annual astrological forecasting. Returns the full tropical chart with planetary positions,
76+
* house cusps, aspects, Ascendant, and Midheaven. Location-sensitive: pass the birthplace to
77+
* anchor the chart to natal geography, or the current city for a relocated solar return where
78+
* the houses and Ascendant shift to where you are on your birthday. Built for year-ahead
79+
* forecast tools, birthday charts, and annual horoscope features.
80+
*
81+
* POST /forecast/solar-return
82+
*
83+
* @param string $date
84+
* Birth date in YYYY-MM-DD format. Anchors the natal Sun longitude the transiting Sun returns
85+
* to each year.
86+
* @param float $latitude
87+
* Latitude of the solar return location in decimal degrees. The solar return is
88+
* location-sensitive: use the birthplace to anchor the chart to natal geography, or the
89+
* current city for a relocated solar return.
90+
* @param float $longitude
91+
* Longitude of the solar return location in decimal degrees. Sets the local sidereal time, so
92+
* it drives the Ascendant, Midheaven, and house cusps of the return chart.
93+
* @param string $time
94+
* Birth time in 24-hour HH:MM:SS format. Pins the exact natal Sun position that defines the
95+
* solar return moment.
96+
* @param mixed $timezone
97+
* Decimal hours (e.g. 5.5 for IST, -5 for EST) OR IANA name (e.g. "America/New_York", "UTC").
98+
* IANA is resolved to the DST-correct offset for the request date. Invalid timezones return
99+
* 400 with a validation error.
100+
* @param int $year
101+
* Year to cast the solar return for. The chart is erected for the moment in this year when the
102+
* transiting Sun returns to the natal Sun longitude, on or within a day of the birthday.
103+
* @param string|null $houseSystem
104+
* House system for the return chart. placidus is the Western default. whole-sign, equal, and
105+
* koch are also supported.
106+
* @param string|null $lang
107+
* Response language (ISO 639-1). Supported: en, tr, de, es, hi, pt, fr, ru. Defaults to en.
108+
* Languages without translations yet return English.
109+
*
110+
* @return array<string, mixed>
111+
*/
112+
public function forecastSolarReturn(
113+
string $date,
114+
float $latitude,
115+
float $longitude,
116+
string $time,
117+
mixed $timezone,
118+
int $year,
119+
?string $houseSystem = null,
120+
?string $lang = null
121+
): array
122+
{
123+
$request = new \RoxyAPI\Sdk\Generated\Requests\ForecastSolarReturnRequest(date: $date, latitude: $latitude, longitude: $longitude, time: $time, timezone: $timezone, year: $year, houseSystem: $houseSystem, lang: $lang);
124+
125+
return $this->callRequest($request);
126+
}
127+
70128
/**
71129
* Western transit forecast - Transit aspects, sign ingresses, retrograde stations
72130
*
@@ -155,64 +213,6 @@ public function generateDigest(
155213
return $this->callRequest($request);
156214
}
157215

158-
/**
159-
* Solar return chart - Annual birthday forecast chart for a single subject
160-
*
161-
* Cast the solar return chart for one subject and year: the chart erected for the exact moment
162-
* the transiting Sun returns to its natal ecliptic longitude, the foundational technique for
163-
* annual astrological forecasting. Returns the full tropical chart with planetary positions,
164-
* house cusps, aspects, Ascendant, and Midheaven. Location-sensitive: pass the birthplace to
165-
* anchor the chart to natal geography, or the current city for a relocated solar return where
166-
* the houses and Ascendant shift to where you are on your birthday. Built for year-ahead
167-
* forecast tools, birthday charts, and annual horoscope features.
168-
*
169-
* POST /forecast/solar-return
170-
*
171-
* @param string $date
172-
* Birth date in YYYY-MM-DD format. Anchors the natal Sun longitude the transiting Sun returns
173-
* to each year.
174-
* @param float $latitude
175-
* Latitude of the solar return location in decimal degrees. The solar return is
176-
* location-sensitive: use the birthplace to anchor the chart to natal geography, or the
177-
* current city for a relocated solar return.
178-
* @param float $longitude
179-
* Longitude of the solar return location in decimal degrees. Sets the local sidereal time, so
180-
* it drives the Ascendant, Midheaven, and house cusps of the return chart.
181-
* @param string $time
182-
* Birth time in 24-hour HH:MM:SS format. Pins the exact natal Sun position that defines the
183-
* solar return moment.
184-
* @param mixed $timezone
185-
* Decimal hours (e.g. 5.5 for IST, -5 for EST) OR IANA name (e.g. "America/New_York", "UTC").
186-
* IANA is resolved to the DST-correct offset for the request date. Invalid timezones return
187-
* 400 with a validation error.
188-
* @param int $year
189-
* Year to cast the solar return for. The chart is erected for the moment in this year when the
190-
* transiting Sun returns to the natal Sun longitude, on or within a day of the birthday.
191-
* @param string|null $houseSystem
192-
* House system for the return chart. placidus is the Western default. whole-sign, equal, and
193-
* koch are also supported.
194-
* @param string|null $lang
195-
* Response language (ISO 639-1). Supported: en, tr, de, es, hi, pt, fr, ru. Defaults to en.
196-
* Languages without translations yet return English.
197-
*
198-
* @return array<string, mixed>
199-
*/
200-
public function generateSolarReturn(
201-
string $date,
202-
float $latitude,
203-
float $longitude,
204-
string $time,
205-
mixed $timezone,
206-
int $year,
207-
?string $houseSystem = null,
208-
?string $lang = null
209-
): array
210-
{
211-
$request = new \RoxyAPI\Sdk\Generated\Requests\GenerateSolarReturnRequest(date: $date, latitude: $latitude, longitude: $longitude, time: $time, timezone: $timezone, year: $year, houseSystem: $houseSystem, lang: $lang);
212-
213-
return $this->callRequest($request);
214-
}
215-
216216
/**
217217
* Cross-domain forecast timeline - Transits, ingresses, stations, dasha changes, critical days
218218
*

src/Roxy.php

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,8 @@
1919
use RoxyAPI\Sdk\Generated\Resources\BiorhythmResource;
2020
use RoxyAPI\Sdk\Generated\Resources\CrystalsResource;
2121
use RoxyAPI\Sdk\Generated\Resources\DreamsResource;
22+
use RoxyAPI\Sdk\Generated\Resources\ForecastResource;
23+
use RoxyAPI\Sdk\Generated\Resources\HumanDesignResource;
2224
use RoxyAPI\Sdk\Generated\Resources\IchingResource;
2325
use RoxyAPI\Sdk\Generated\Resources\LanguagesResource;
2426
use RoxyAPI\Sdk\Generated\Resources\LocationResource;
@@ -39,6 +41,8 @@
3941
* @property BiorhythmResource $biorhythm
4042
* @property CrystalsResource $crystals
4143
* @property DreamsResource $dreams
44+
* @property ForecastResource $forecast
45+
* @property HumanDesignResource $humanDesign
4246
* @property IchingResource $iching
4347
* @property LanguagesResource $languages
4448
* @property LocationResource $location
@@ -60,6 +64,8 @@ class Roxy extends Connector
6064
'biorhythm' => BiorhythmResource::class,
6165
'crystals' => CrystalsResource::class,
6266
'dreams' => DreamsResource::class,
67+
'forecast' => ForecastResource::class,
68+
'humanDesign' => HumanDesignResource::class,
6369
'iching' => IchingResource::class,
6470
'languages' => LanguagesResource::class,
6571
'location' => LocationResource::class,

0 commit comments

Comments
 (0)