Ninja v5 fresh install forbidden api

Hi,

I have install the last v5 Ninja because I want to try the future :smiley:

I have installed the release precompiled version, I can setup without problem but after login, I choose anything to edit and save like settings and when click on save I get an error :frowning: : Error: please check that Invoice Ninja v5 is installed on the server

Impossible to understand where are from the error.

I have tried to git pull without success form GUI, I make it with manual try after stash changes (I don’t know why I need to stash work because I don’t edit the code). After a git pull request succeed, I try to save but I get the same error.

Hmm, okay, I try to scratch and reinstall Ninja but I git pull request before start setup. No changes.

App log file indicate no problem, just with Email and SMTP (Mailer.php…etc…). Ok, It’s the next problem, first I can’t save updates :laughing:.

I verify all permissions, but I don’t see what my mistake is ! InvoiceNinja folder have g+s and storage have 775.

Into error console of browser, I see a way to resolve the problem, but I haven’t the necessary skills…

I see that: Failed to load resource: the server responded with a status of 403 (Forbidden) https://#DOMAIN_NAME/api/v1/companies/VolejRejNm?

It’s funny because I had just check all permissions before.

If anyone can help me, thanks you in advance !

What is your environment? apache? nginx?

Oh sorry, I didn’t receive any notification about your answer…
I use LinuxCloud and I downloaded the precompiled zip file.

It sounds like the URL isn’t correct.

can you try hitting

http://url.com/api/v1/ping you should get a JSON response.

i’m think that your system may be expecting http://url.com/public/api/v1/ping

I installed the latest version (v5.0.41-C35).

I tried to update the company settings (languages) and company details (name). Same message.
I managed to create a user in Settings > User Management. Works.

You can see the ping API response here. I tried with “public” and without “public” in the url (rewriting is enabled).

ping

can you paste a screenshot of the exact error in the console please?

For sure !

This is console errors when saving changes of company details :

And this is error when pign the api :

Hey David !

Thanks you a lot for your patience with my problems !

@hillel have resolve my problem !

I desactivate Modsec on the v5 app and v4. Now its perfectly works ! Yhea !