Specifying the visibility of your Product

Detail who can view and subscribe to your Product.

About this task

The visibility section of your Product's YAML representation determines who can view and subscribe to your Product in IBM® API Connect.

Note: All keys and enumeration values that are specified in this topic are case-sensitive.

An example visibility section of a YAML representation of a Product can be found at the end of this topic. An example of a complete YAML representation of a Product can be found in An example YAML representation of a Product.

Procedure

To complete the visibility section of your Product description, complete the following steps:

  1. Title the section by adding visibility:
  2. Under visibility, specify who can view the Product; use the following syntax:
       view:
          enabled: View_Toggle
          type: View_Audience
          tags:
             - View_Tag_1
             - View_Tag_2
          orgs: View_Organizations
    where
    • View_Toggle determines whether the Product is visible to anybody or not. It must be true or false. If false, the Product will not be visible in the Developer Portal.
    • View_Audience must be public, in which case the Product is visible to anybody who uses the Developer Portal, authenticated, in which case the Product is visible to anybody registered through the Developer Portal, or custom, in which case the Product is visible to a specified group of users.
    • The View_Tag variables are strings that contains any tags that you want to attach to your Product's view status. Each tag must be on a new line and preceded with a dash. If you do not want to use any tags, do not include tags:.
    • View_Organizations specifies the organizations that can view the Product if View_Audience is set to custom. If View_Audience is not set to custom, do not include orgs:. If View_Audience is custom, specify organizations in the following manner:
            orgs:
               - Organization 1
               - Organization 2
      where the Organization variables are the names of the organizations that are to be allowed to view the Product.
  3. Under visibility, specify who can subscribe to your Product's Plans; use the following syntax:
    
       subscribe:
          enabled: Subscribe_Toggle
          type: Subscribe_Audience
          tags:
             - Subscribe_Tag_1
             - Subscribe_Tag_2
          orgs: Subscribe_Organizations
    where:
    • Subscribe_Toggle must be true or false. If false, no developers will be able to subscribe to the Product.
    • Subscribe_Audience must be authenticated, in which case the Product's Plans can be subscribed to by anybody who is registered through the Developer Portal, or custom, in which case the Product's Plans can be subscribed to by a specified group of users.
    • The Subscribe_Tag variables are strings that contains any tags you want to attach to your Product. Each tag must be on a new line and preceded by a dash.
    • Subscribe_Organizations specifies the organizations that can subscribe to the Product's Plans if Subscribe_Audience is set to custom. If Subscribe_Audience is not set to custom, omit it or set as []. If Subscribe_Audience is custom, specify organizations in the following manner:
            orgs:
               - Organization 1
               - Organization 2
      where the Organization variables are the names of the organizations that are to be allowed to subscribe to the Product.
      Note: If a Product is to be available for subscription, it must already be visible. As a result, for the subscription audience to be authenticated, the view audience cannot be custom.

Results

You have completed the visibility section of your Product's YAML representation. It should have the following form:

visibility:
   view:
      enabled: View_Toggle
      type: View_Audience
      tags:
         - View_Tag_1
         - View_Tag_2 
      orgs:
         - Organization_1
         - Organization_2

   subscribe:
      enabled: Subscribe_Toggle
      type: Subscribe_Audience
      tags:
         - Subscribe_Tag_1
         - Subscribe_Tag_2
      orgs: 
         - Organization_1
         - Organization_2

where all variables are as described in previously in this topic. The indentation must be as in the example.

What to do next

You can also define the visibility of a Product at a Catalog or Space level. For more information, see Configuring Product visibility in a Catalog.