Policy creation workflow for Gateway Published API

book

Article ID: 192219

calendar_today

Updated On:

Products

CA API Gateway CA API Developer Portal

Issue/Introduction

What happens when an Gateway Published API is created from Policy Manager? Which tables are updated in the Portal and Gateway ssg databases.

Environment

API Developer Portal 3.5

Resolution

  1. Service is created on the gateway using Policy Manager
  2. 'Set as Portal Managed' assertion is added to policy for the service
  3. A custom module on the gateway watches for policies containing 'Set as Portal Managed' assertion and creates records in generic_entity table with classname = 'com.l7tech.external.assertions.apiportalintegration.server.PortalManagedService' as needed
  4. Portal page /dashboard/apis calls /portalman/1/apis to get a list of services with 'Set as Portal Managed' assertion. This service reads from generic_entity table
  5. When API is enabled on the portal, an XML document is created on the portal which stores the API ID of the service (attribute of 'Set as Portal Managed Service assertion) and other metadata only used by the portal
  6. When an application is added on the portal with a set of APIs. This invokes the gateway service /api/keys/generate to generate a key/secret, adds records to lrsapplication and lrsapikey tables, and then invokes the gateway service /api/keys/register to register the key with the apis. /api/keys/register adds records to generic_entity table with classname = 'com.l7tech.external.assertions.apiportalintegration.server.apikey.manager.ApiKey'
  7. When an organization is assigned an account plan, the gateway service /portalman/1/account/plans is invoked to store the organization ids associated with the account plan. This information is stored in generic_entity with classname = 'com.l7tech.external.assertions.apiportalintegration.server.accountplan.AccountPlan' with the ids XML having the ids of the associated orgs
  8. Account plans are stored as XML documents on portal. id and rate limits are sent to the gateway using /portalman/1/account/plans and are stored in generic_entity table with classname = 'com.l7tech.external.assertions.apiportalintegration.server.accountplan.AccountPlan'
  9. API Plans are stored as XML documents on portal. id and rate limits are sent to the gateway using /portalman/1/api/plans and are stored in generic_entity table with classname = ' com.l7tech.external.assertions.apiportalintegration.server.apiplan.ApiPlan'
  10. Organizations are stored in cmsorganization table on the portal. Only the orgid is transmitted to the gateway.
  11. Users are stored in cmsusers table on the portal. This is not transmitted to the gateway.