Files
muninn/app/Http/Resources/SocialAccountResource.php
T
Doar MihaiandClaude Sonnet 5 5c24b6fbe0 feat: add read-only Social Accounts API
Add GET /api/accounts (list with optional ?network= and ?type= filters) and
GET /api/accounts/{socialAccount} (show) endpoints. Include plain-text password
field for AI agent consumption.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-07-18 15:25:56 +03:00

24 lines
587 B
PHP

<?php
namespace App\Http\Resources;
use Illuminate\Http\Request;
use Illuminate\Http\Resources\Json\JsonResource;
class SocialAccountResource extends JsonResource
{
public function toArray(Request $request): array
{
return [
'id' => $this->id,
'network' => $this->network,
'username' => $this->username,
'email' => $this->email,
'password' => $this->password,
'type' => $this->type,
'created_at' => $this->created_at,
'updated_at' => $this->updated_at,
];
}
}