Creating a Guest User Profile for Your Community

In many circumstances, you’ll want your community to display content to users who aren’t logged in. For this reason, you need to create a user profile that will act as the guest user profile in your community, with the right permissions.

For more information on why this needs to be done, see Understanding How the Coveo for Salesforce Free Edition Uses the JWT Flow.

Create the Guest User from a Contact

  1. Log in to Salesforce with an administrator account.

  2. Ensure that your user has a Role, as you’ll need to add a role to create a community user (see Assign Users to Roles).

  3. In your Contacts tabs, either select an existing contact to act as your guest user or create a new one.

  4. Ensure that your contact is associated to an Account. You may need to create a new one specifically for your guest user.

  5. On your contact page, select Manage External User > Enable Customer User.

    You should now access the New User page to create the user.

  6. Under Username, choose a unique username for your guest user.

    Ensure that your username is unique to your community and to all Salesforce organizations. Not doing so may lead the JWT flow to fail, which prevents your anonymous search from working.

  7. Once you have entered all of the necessary information, select Save to create your user.

Create a New Profile for Your Guest User

By default, when created from a contact, your user is assigned the Customer Portal Manager Standard profile, which can’t be edited. Since you’ll want to change a few things in the profile, you’re encouraged to clone it so it becomes customizable.

You can ensure that you’re cloning the right profile by accessing the User section and looking at which profile your guest user is assigned.

  1. In Salesforce, under Setup, search for and select Profiles (Administer > Manage Users > Profiles).

  2. Next to the Customer Portal Manager Standard profile (or the one currently associated to your designated guest user), select Clone.

  3. On the Clone Profile page, next to Profile Name, choose a name for your guest user profile, and select Save.

  4. Ensure this profile has API Enabled and has all the rights necessary to allow anonymous access to your community (see Granting Users Access to Your Coveo Lightning Component).

  5. Assign your custom profile to your guest user.

    1. In Setup, search for and select Profiles (Administer > Manage Users > Profiles).

    2. Next to your guest user, select Edit.

    3. In Profile, select your new custom profile.

    4. Select Save.

Assign the Guest User as the Default User of Your Community

  1. Ensure that your guest user is a member of your community (see Add Members to Your Community).

  2. In Setup, search for and select All Communities (Build > Customize > Communities > All Communities).

  3. Next to your community, select Builder.

  4. Find and select a Coveo component in your community.

    If you followed the previous steps, you added the Coveo Search component on the Search page and the Coveo Case Creation component on the Contact Support page.

  5. Access the Advanced Lightning Configuration.

    With Coveo for Salesforce v3.25+ With Coveo for Salesforce V3 With Coveo for Salesforce V2
  6. In Advanced Server-Side Configuration, under Anonymous User, enter the guest user you have created.

  7. Save your modification by clicking Save.
  8. Repeat the same steps for every Coveo component in your community.

Remember to allow your users access to the Coveo Lightning components, as they otherwise won’t be able to access them (see Granting Users Access to Your Coveo Lightning Component).

What's Next for Me?