tangled
alpha
login
or
join now
socialde.pt
/
atp-client
3
fork
atom
Laravel AT Protocol Client (alpha & unstable)
3
fork
atom
overview
issues
pulls
pipelines
Merge branch 'refs/heads/dev'
Miguel Batres
3 months ago
defe9ff5
fbba6655
+2
-6
1 changed file
expand all
collapse all
unified
split
src
Client
Requests
Bsky
ActorRequestClient.php
+2
-6
src/Client/Requests/Bsky/ActorRequestClient.php
···
4
4
5
5
use SocialDept\AtpClient\Attributes\PublicEndpoint;
6
6
use SocialDept\AtpClient\Client\Requests\Request;
7
7
-
use SocialDept\AtpClient\Data\Record;
8
7
use SocialDept\AtpClient\Data\Responses\Bsky\Actor\GetProfilesResponse;
9
8
use SocialDept\AtpClient\Data\Responses\Bsky\Actor\GetSuggestionsResponse;
10
9
use SocialDept\AtpClient\Data\Responses\Bsky\Actor\SearchActorsResponse;
···
20
19
* @see https://docs.bsky.app/docs/api/app-bsky-actor-get-profile
21
20
*/
22
21
#[PublicEndpoint]
23
23
-
public function getProfile(string $actor): Record
22
22
+
public function getProfile(string $actor): ProfileViewDetailed
24
23
{
25
24
$response = $this->atp->client->get(
26
25
endpoint: BskyActor::GetProfile,
27
26
params: compact('actor')
28
27
);
29
28
30
30
-
return Record::fromArray(
31
31
-
data: $response->toArray(),
32
32
-
transformer: fn($value) => ProfileViewDetailed::fromArray($response->json('value'))
33
33
-
);
29
29
+
return ProfileViewDetailed::fromArray($response->toArray());
34
30
}
35
31
36
32
/**