Bånder

ArtistController extends Controller
in package

Attributes
#[Middleware]
['auth:sanctum', 'ability:' . \App\Models\TokenAbility::ACCESS_API->value, 'force.json']
#[Prefix]
'/libraries/{library}/artists'

Table of Contents

Methods

index()  : AnonymousResourceCollection
Get a paginated collection of artists from a specific library
show()  : ArtistResource
Get a specific artist with detailed information
denyWithStatus()  : mixed
gateCheckExecuteJob()  : mixed
gateCheckViewDashboard()  : mixed
noContent()  : mixed

Methods

index()

Get a paginated collection of artists from a specific library

public index(Library $library, ArtistIndexRequest $request) : AnonymousResourceCollection

Returns a filtered and paginated list of artists from the specified library. Supports field selection and relation inclusion for optimized queries.

Parameters
$library : Library

The library to retrieve artists from

$request : ArtistIndexRequest

Request with filtering and pagination parameters

Tags
response

AnonymousResourceCollection<JsonPaginator<ArtistResource>>

Attributes
#[Get]
'/'
'api.artists.index'
Return values
AnonymousResourceCollection

show()

Get a specific artist with detailed information

public show(Library $library, Artist $artist) : ArtistResource

Retrieves a single artist from the specified library with comprehensive information including albums, songs, and other related data.

Parameters
$library : Library

The library containing the artist

$artist : Artist

The artist to retrieve

Tags
throws
ModelNotFoundException

When an artist is not found in the library

response

ArtistResource

Attributes
#[Get]
'{artist}'
'api.artists.show'
Return values
ArtistResource

denyWithStatus()

protected denyWithStatus(string $message, int $status) : mixed
Parameters
$message : string
$status : int

gateCheckExecuteJob()

protected gateCheckExecuteJob() : mixed

gateCheckViewDashboard()

protected gateCheckViewDashboard() : mixed

        
On this page

Search results