function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Thai HuynhThai Huynh 

Retrieving Agent Information

I'm building a simple application that will be used by our internal people. However, this application is being setup as a SF Site because I want to use UrlRewriter. There will be a custom login page where the user can login using their SF login credential. My question is, how do I retrieve the user's information since this user will not have a Customer Portal Profile? Here is an example flow:

 

1. Agent authenticate and login to the app

2. Clicks on Get My Recent Cases. This will make a call to http://app.domain.com/my-cases -> this will be rewrite to /apex/MyCases page that will fetch cases and return as JSON data. 

3. Since this is setup as a site, how can I tell if the person making the request is authenticated?

SammyComesHereSammyComesHere

Please Refer this link. It might help

 

http://wiki.developerforce.com/page/Authenticating_Users_on_Force.com_Sites

 

May be this as well.

 

http://www.salesforce.com/us/developer/docs/apexcode/Content/apex_classes_sites.htm

 

this class has inbuild method for authentication and loggin

 

login and authenticate