Documentation

RouteSongs
in package

Table of Contents

filterRoute()  : mixed
listRoute()  : string
Get list of songs filtered by a single field
searchRoute()  : mixed

Methods

filterRoute()

public filterRoute(mixed $request, mixed $response, mixed $args) : mixed
Parameters
$request : mixed
$response : mixed
$args : mixed
Tags
OA\Post

( path="/{game_route}/songs/filter", summary="Returns a list of songs", description="Returns a list of songs", operationId="songsFilterRoute", tags={"Songs"}, @OA\Parameter( ref="#/components/parameters/song_data_type" ), @OA\Parameter( ref="#/components/parameters/genre" ), @OA\Parameter( ref="#/components/parameters/fullband" ), @OA\Parameter( ref="#/components/parameters/instrument" ), @OA\Parameter( ref="#/components/parameters/tierinstrument" ), @OA\Parameter( ref="#/components/parameters/tier" ), @OA\Parameter( ref="#/components/parameters/reductions" ), @OA\Parameter( ref="#/components/parameters/decade" ), @OA\Parameter( ref="#/components/parameters/vocals" ), @OA\Parameter( ref="#/components/parameters/source" ), @OA\Parameter( ref="#/components/parameters/audio" ), @OA\Parameter( ref="#/components/parameters/rating" ), @OA\Parameter( ref="#/components/parameters/gender" ), @OA\Parameter( ref="#/components/parameters/game_route" ), @OA\Response( response=200, description="OK", @OA\JsonContent( type="object", @OA\Property(
property="status", ref="#/components/schemas/RGWRequestStatus" ), @OA\Property( property="data", type="object", @OA\Property( property="authors", ref="#/components/schemas/Author" ), @OA\Property( property="authors_info", type="object", @OA\Property( property="total_published", type="int", description="Number of authors with at least one file available to download. Use the /authors/published route to restrict the selection." ) ), @OA\Property( property="pagination", ref="#/components/schemas/RGWResponsePagination" ), @OA\Property( property="records", ref="#/components/schemas/RGWResponseCount" ) ), @OA\Examples(example="Success", value={"status": "success","data": {"records": {"total_available": 7538,"total_filtered": 7538,"returned": 20},"pagination": {"start": 0,"records": "20","page": 1},"artists": {{"id": "10-year-old-nolan","name": "10 Year Old Nolan","songs": 1},{"id": "10-years","name": "10 Years","songs": 5},{"id": "100-gecs","name": "100 gecs","songs": 14},"..."}}}, summary="List of artists"), @OA\Examples(example="Error, no artist found", value={"status": "error", "error": {"message": "No artist found" }}, summary="No artist found"), @OA\Examples(example="Error, invalid parameter", value={"status": "error", "error": {"message": "Parameter 'text' is not accepted at this path" }}, summary="Invalid parameter sent") ) ) )

Return values
mixed

listRoute()

Get list of songs filtered by a single field

public listRoute(mixed $request, mixed $response, mixed $args) : string
Parameters
$request : mixed
$response : mixed
$args : mixed
Tags
vars

data array : The array of addition parameters you can pass to filter and trim

data

start int OPTIONAL : Starting record for the dataset to be returned

data

records int OPTIONAL : Total number of records to return Defaults to Config::$api_default_records Capped at Config::$api_max_records

data

total bool : TRUE if you want the total number of available records to be returned Use with caution, potentially taxing

data

data_type string OPTIONAL : bare|song|file|full What kind of data you need in return (defaults to bare) bare : only IDs { "id": 101177, "song_id": 32769, "record_id": "you-never-know-32769", "user": "efrainsonic101", "song_owner": 22864 }

Return values
string

searchRoute()

public searchRoute(mixed $request, mixed $response, mixed $args) : mixed
Parameters
$request : mixed
$response : mixed
$args : mixed
Return values
mixed

Search results