I got the results error but it seems working

Tell us what’s happening:
It says,
A request to /api/whoami should return a JSON object with your IP address in the ipaddress key.
A request to /api/whoami should return a JSON object with your preferred language in the language key.
A request to /api/whoami should return a JSON object with your software in the software key.

but my website(https://wyrlv.xyz/api/whoami) is exactly json object.
I’m using Laravel(PHP Framework).
Here is my code:

Route::get('/whoami', function(){
    return response()->json( [
        'ipaddress' => $_SERVER['REMOTE_ADDR'],
        'language' => $_SERVER['HTTP_ACCEPT_LANGUAGE'],
        'software' => $_SERVER['HTTP_USER_AGENT']
    ]);
});

Challenge: Request Header Parser Microservice

Link to the challenge:

Hello there.

Do you have a question?

If so, please edit your post to include it in the Tell us what’s happening section.

Learning to describe problems is hard, but it is an important part of learning how to code.

Also, the more information you give us, the more likely we are to be able to help.

I’m new user here that I’m trying to claim certification. Sorry for my bad English.

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.