Auto-register Apigee proxies

This page applies to Apigee and Apigee hybrid.

This page describes how to automatically register Apigee proxies in API hub. API hub lets you to register deployed proxies from both Apigee and Apigee hybrid runtime projects directly into API hub. This auto-registration process enables API hub to register API resources from multiple API gateways.

How auto-registration works

When you attach an Apigee runtime project to API hub, information such as the proxy's name, environment and deployment details, and the type of Apigee instance (Apigee or Apigee hybrid) is automatically registered.

Auto-register APIs from multiple API gateways
Figure 1. Auto-register APIs from Apigee and Apigee hybrid.

Project associations and plugins

When you provision API hub as part of Apigee provisioning, it automatically identifies and attaches any associated Apigee runtime projects. This automatically creates an Apigee and hybrid plugin instance by default in API hub and ingests any deployed API proxies from Apigee.

If you manually attach any additional Apigee runtime projects (Apigee or Apigee hybrid), API hub offers an option to import additonal API metadata. When this option is selected, API hub automatically creates the necessary plugin instance to manage the metadata import. These plugin instances are key to managing the connection and data ingestion for the auto-registration process.

Auto-discovery of OpenAPI specs from Apigee proxies

To simplify API documentation and maintain synchronization with your Apigee proxy deployments, API hub automatically discovers and ingests valid OpenAPI specifications (OAS) when they are included in your Apigee API proxy resources.

When a proxy is deployed in your Apigee runtime project (Apigee or Apigee hybrid), API hub automatically detects the presence of a valid OpenAPI spec in the proxy's resources folder. API hub then ingests and parses the spec, runs linting for validation, and uses the spec to populate the API's documentation, including its operations. This ensures that the API definition in API hub is always consistent with the deployed proxy in your Apigee runtime project.

Note: Auto-discovery of OAS happens irrespective of whether you attach an Apigee runtime project to API hub or if your Apigee runtime project is automatically attached to API hub as part of Apigee provisioning.

Project associations scheduler

API hub periodically (once in six hours) runs a scheduler that connects to your Apigee project, and gets the latest proxy definitions. For the projects that are newly attached, the scheduler gets all the proxy definitions, and then registers them in API hub. And for the existing projects, the scheduler gets only the changes made to the proxy definitions, and then accordingly updates the proxy information in API hub.

Attach a runtime project

Before you begin

To attach an runtime project to API hub, do the following steps:

  1. In the Google Cloud console, go to the API hub page.

    Go to API hub

  2. Click Settings from the left navigation menu to open the Settings page.
  3. Go to the Project associations tab and click Attach runtime project. This displays the Select a resource pane.
  4. Click the Google Cloud project where your runtime project is provisioned.
  5. In the Project association settings pane, select the API assets to automatically import checkbox.
  6. Click Attach.

Edit project association settings

You can edit the project association settings to change the API assets which are automatically imported. To edit the project association settings, do the following steps:

  1. In the Google Cloud console, go to the API hub page.

    Go to API hub

  2. Click Settings from the left navigation menu to open the Settings page.
  3. Go to the Project associations tab to view the list of attached projects.
  4. Click Edit settings for the desired project.
  5. In the Project association settings pane, edit the API assets to automatically import checkbox selection.
  6. Click Save to apply your changes.

Detach a runtime project

To detach a runtime project from API hub, do the following steps:

  1. In the Google Cloud console, go to the API hub page.

    Go to API hub

  2. Click Settings from the left navigation menu to open the Settings page.
  3. Go to the Project associations tab to view the list of attached projects.
  4. Click Detach project for the project you want to detach.

Considerations

Consider the following when attempting to attach Apigee runtime projects:

  • All endpoints imported from Apigee will be given an https:// prefix by default.
  • Proxies that aren't deployed in any environment, aren't fetched from the project.
  • Only proxies that are deployed in an environment are fetched. And the environment must be a part of an environment group.
  • Additional attributes representing the Apigee instance type (Apigee X and Hybrid Environment and Apigee X and Hybrid Organization) are automatically created and added to any proxy API deployments that are imported.
  • API hub doesn't support VPC Service Controls. Hence, if you have enabled VPC Service Control for your Apigee runtime project, API hub can't access the project.
  • If the Apigee API isn't enabled for a runtime project, API hub can't auto-register or import the API proxies.

Limitations

What's next