Jump to content

Single Sign-On user_id cannot be null


qualia

Recommended Posts

I'm attempting to utilise single sign on in WHMCS, but get a PDO error "Uncaught exception 'PDOException' with message 'SQLSTATE[23000]: Integrity constraint violation: 1048 Column 'user_id' cannot be null' in /whmcs/vendor/illuminate/database/Connection.php:444". I have the correct request parameters as described here: http://docs.whmcs.com/API:CreateOAuthCredential. The params I'm using are:

 

username:xxxxxxxx

password:xxxxxxxxx

action:CreateOAuthCredential

grantType:single_sign_on

scope:clientarea:sso clientarea:profile

description:Test SSO

serviceId:<USER ID HERE>

responsetype:json

 

I put some logging in Connection.php and it appears WHMCS is attempting to insert into `tbloauthserver_clients`, but there is no user_id. How do I pass user_id as a parameter? What am I doing wrong?

Link to comment
Share on other sites

  • 2 years later...

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated