Content Access Control on Developer Portal using Content Access

You may want to read the content access overview before reading this document.

Often times our customers ask about configuring the Developer portal with a section into which they can publish information about their internal APIs or any other confidential information, and only the developers in the company can access this section. Here are the simple steps to accomplish this on our developer portal. We use "Content Access module" for this.

Why use Content Access module instead of Drupal's default access control system?

The Content Access module is a layer on top of Drupal's access control system, but it provides more fine-grained access control (node-level or content type level), greater usability and more options. So instead of ticking/un-ticking the checkboxes on Drupal's permissions page, you go to the node or content type whose visibility you want to control and change its access control settings.

Basic Usage

Our Developer portal is packaged with Content access module, but it is be disabled. Login as portal administrator and enable the module from “Modules” menu. Once you enable this module, follow the instructions on https://www.drupal.org/node/1195000 to enable the access control at section level. If you enable a permissions module you need to rebuild permissions. In Drupal 7 you can find Rebuild permission settings here:
Admin > Report > status report > rebuild (admin/reports/status/rebuild).

Comments
DChiesa
Staff

@sudheendra1 - very valuable. How would one apply this, for example, in restricting access to the API documentation to only those developers who are logged-in ?

sudheendras
Staff

You group your developers into various roles as internal, partner and external developer and assign them privileges (options are provided by Drupal). You can put them into these groups when they sign-up. When you publish content on your portal, you can define what role is needed to view or edit the block.

Marsh
Staff

Since the tags for methods in an API model are set as the taxonomy of a node in Drupal, I'd recommend using taxonomy access control as the mechanism for controlling access to SmartDocs pages, see (TAC or TAC Lite).

Not applicable

This was very helpful! Thanks.

Not applicable

Can you use the Content Access module to show / hide API Products on the app registration page?

chrisnovak
Staff

If you want to show/hide API products, turn on the "DevConnect Limit API Product by Role" module. You will then be able to limit products by role by going to Dev Portal > API Product Role Access in the admin bar.

Version history
Last update:
‎03-24-2015 10:10 AM
Updated by: