User login automation, third party user login integration with Piwik

(sushilbajimaya) #1

I am making a web application which involves multiple profiles of users and I want to keep track of the visit of the profile. In the application, it should also be possible for users to view the profile visit statistics. For this, I want to automate the user login. Is there a way that I can call Piwik widgets into my application without physically logging into Piwik?

Also, I have a separate user authentication system. Can I use this system to authenticate user login in Piwik so that one active session will work for all?

I am willing to make changes to the database to match Piwik requirements.

Early responses are welcome!

Thank you in advance!


(Matthieu Aubry) #2

The UsersManager API lets you Manage Users and their permissions to access specific websites.
You can create users via “addUser”, update existing users via “updateUser” and delete users via “deleteUser”. There are many ways to list users based on their login “getUser” and “getUsers”, their email “getUserByEmail”, or which users have permission (view or admin) to access the specified websites “getUsersWithSiteAccess”.
Existing Permissions are listed given a login via “getSitesAccessFromUser”, or a website ID via “getUsersAccessFromSite”, or you can list all users and websites for a given permission via “getUsersSitesFromAccess”. Permissions are set and updated via the method “setUserAccess”. See also the documentation about Managing Users in Piwik.