$response->toArray()
Converts all relevant response attributes to an associative array for debugging, testing or whatever.
$response->toArray(): array
Return type
array
This method modifies the existing $response
object it is applied to and returns it again.