Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

ritechoice23's avatar

Unable to login in filament

Please help out on this issue, i am trying to log in to Filament, but instead of it to log in or show me a validation error I keep getting this error below.

The GET method is not supported for route api/v2/login. Supported methods: POST.

and in the previous time, it doesn't.

0 likes
6 replies
jaseofspades88's avatar

Do you have this on your User model?

    public function canAccessPanel(Panel $panel): bool
    {
        return true;
    }
ritechoice23's avatar

@jaseofspades88 yes I have this, the login endpoint is an API route to log in, the point here is that I don't why it is trying to call that route.

jaseofspades88's avatar

'it' in this context, is you, @horlatech... somewhere you're trying to make a GET request to a POST... the error is hardly cryptic

ritechoice23's avatar

@jaseofspades88 What I am saying is that this has been working before, all of a sudden it is just making a request to login route from the filament login page.

jaseofspades88's avatar

Trace it through the git history, find the last commit where it 'worked' and then compare the differences to now, @horlatech. Failing that delete your vendor files and reinstall everything... a good old off and on again!

jaseofspades88's avatar

It also looks like you're trying to hit a POST endpoint using a GET request.

Please or to participate in this conversation.