These credentials do not match our records when customer tries to access portal

Using 4.5.16 Invoice Ninja Free, Self Hosted. Everything works perfectly fine from the app perspective and the site, with the exception that when the customer attempts to access their invoice via the link in the Invoice Email which points them to the login page, and they are presented with the Login Page, entering their email address and password I have placed in the Client Record. they recieve and error that "These credentials do not match our records ". I have no idea why this should not be working. I also trying to have them click in the Forgot Password Link and when they use their email as is set in their client profile, it says “We can’t find a user with that e-mail address.”

Can some one please give me some idea about what to look at because there should be no reason this isnt working. I have followed all steps to setup the self hosted version, and everything about the setup is working perfectly except this. I don’t know why.

I have the .env pointing to the configured document root specifies the /var/www/html/invoiceninja/public so there is no need for me to set the URL to the app to /public. I saw another issue where this could cause a problem but this is not an issue with my setup. I don’t know how to valudate users or how to see what kind of error could be occurring. There is no errors in the apache2 logs so this must be an application level issue.

Check in /invoiceninja/storage/logs/laravel-error.log. To keep from having to paste the entire log, try logging in as a client and then you should only need the last few lines.

Oddly, I am seeing no errors there accept for an error I filed a few days ago with the db credentials, however, after doing some more digging and process of elimination, I noticed that the problem appears to be with the URL that is bring displayed in the Email that my Client Receives.

The problem with the invalid credentials was because the URL in the Invoice email is sometimes caused in the wwb page to display the User Account Login page ie where i would go to login. So of course this would result in Credentials error… However after looking into this further, I believe my real problem has to do with the way the URL is bring generated for the Client in their Email.

From my testing the link that allows the client to login is
This will allow to client to enter their email addr and password as set in their Client config.

The link that is in the Email shows which is causing the page to load to the User Login not the Client Login <–This results in a Invald Session Token or it loads straight to the standard User Login (where I login)

However, notice the URL? If I take this URL and modify it to the following, there by correcting the syntax error, <—This will work and request the customers Password.

The link provided in the App / Invoice / "View in Portal"link:

So, the question is, why is the URL that the system is placing into the Email for the client Syntactically wrong? And how do I fix this?

It looks like you need to clear the URL you’ve set on Settings > Client Portal, it’s only needed if you plan to show the invoice in an iframe on your site.

After doing even more research on this, and happening across and unrelated issue, but one that had to do with the Link, it would appear that the Help files could be a little more clear about settings. It turns out the problem with the URL happened to be because I was actually setting the URL in the Settings / Client Portal URL. Apparently my lack of understanding that this was to only be set if you planned to use IFrames (which I am not even clear what I frames are at this moment), so I just assumed, since there was nothing in the help advising me against setting this. Infact in some setup guides I had looked at, this was advised to set.

It might be helpful to add some additional info to this option inside the Settings that specifies that using this option without a custom iframes html file, setting this option will break your client portal links.

Can you please share the link to the guide which recommends setting this value, we’ll make sure it’s corrected.

I got nailed by this. I have been trying to figure this issue out for days. A note on the page where you input the url that clearly states, “This will break client passwords” would have been so SO helpful. At least then I would have known to check the documentation.

While I am unable to find the document that I had used to setup and configure Invoice Ninja that caused my confusion, I can say that even reading the release notes / installation guide that you provide, does leave this open for the incorrect assumptions of what this field is for. According to the Installation Guide:

16.1 Settings
The Settings box has three sections – Link, Navigation and Custom CSS. Click on the tab to open the section you
16.1.1 Link
• Domain: Select your preferred domain name for the client portal and invoice emails.
• Customize: Customize the portal URL with a subdomain name or display the invoice on your own website. To
add a subdomain, check Subdomain and enter the name in the field. To add your own website, check Website
and enter the URL of your website in the field.

For someone familiar with IFrames, or just this kind of development, this may be self explanatory, however, for me, and I know others that have made this same mistake, this guide does not make it clear (without looking at further resources) that this setting is for configuring another website (not the Self Hosted /Invoice Ninja site) with this setting configured so that your other website can load the clients Invoice into your other website.

Now if I was using the Invoice Ninja Cloud / Hosted plan, this may have made more sense, however, since I was setting up my own Self Hosted installation of Invoice Ninja on my own VPS server, where the guide states “To add your own website, check Website and enter the URL of your website in the field.” I misunderstood this to mean my Self Hosted Invoice Ninja Website URL.

Since I don’t know anything about IFrames, I was under the impression that this was a configuration needed get the Invoices to load on my installation thinking that on a Self Hosted installation, we could have different paths / sub-domains / URLS based on our Servers, and there for this was a required congratulation if we wanted the invoices to display properly for our unique Invoice Ninja Installation of our own Web Servers, especially if we were using a URL or Aliases that different from that of the default which for me, I was not using the Web Server installation directory of /var/www/html/nvoiceninja instead, I am not using a directory at all, even though the installation instructions recommend using the default, but I wanted to use the base directory so there would be no domain/sub-directory.

I hope you are able to see now how this could be misinterpreted and that you can make a note in the settings or at the very least the installation guide that this setting is NOT for basic invoice Ninja Setup for either Cloud or Self Hosted installations. As well, a note as the last person commented, making it clear that by setting this value in the Settings you will break the ability for anyone to login to you Client Portal if you point this setting to the URL of your Invoice Ninja Installation Client Portal. This is only to be set if you have setup a custom website separate from the Invoice Ninja Server Installation where you intent to have that custom site to display your clients Invoices.

While I realize no one wants to see the installation guide nor the Invoice Ninja Settings be updated with what I typed above verbatim, I wanted to make it clear how and why there have been a number of people who have made the assumption that this was a required field in order to allow access to the Client Portal mostly if you are running Invoice Ninja on your own Self Hosted Server. It’s very easy to misinterpret what the guide refers to saying
display the invoice on your own website" to me, the Self Hosted Installation of Invoice Ninja was what you meant when you stated “your own website”. I didn’t realize that actually means another separate website completely different from Invoice Ninja.

Cheers, and sorry for the lengthy reply.

100% agreed, the help text will be clarified in our next release.

Thank you for your feedback, sorry for the confusion this has caused!

Thank you so much Hillel! My apologies for taking so long to get back to replying to this. I greatly appreciate your willingness to correct this going forward. Chhers!