API Hub Integration


 

The API Hub client provides portal management capabilities as listed below. Tools for API Hub require an API_HUB_API_KEY.

Available Tools

list_portals

  • Purpose: Search for available portals within API Hub. Only portals where you have at least a designer role, either at the product level or organization level, are returned.
  • Returns: Paged list of portals with metadata including name, subdomain, status, and more.
  • Use case: Discovery of available portals.

get_portal

  • Purpose: Retrieve information about a specific portal.
  • Parameters: Portal UUID or subdomain (portalId).
  • Returns: Complete set of metadata properties for a specific portal.
  • Use case: Get full details on a specific portal configuration.

create_portal

  • Purpose: Create a new portal with API Hub.
  • Returns: Complete set of metadata properties for a specific portal.
  • Use case: Get full details on a specific portal configuration.
  • Parameters:
ParameterDescriptionTypeRequired
nameThe portal name.
Must be between 3 and 40 characters.
stringNo
subdomain

The subdomain to use for the portal. 

Must be between 3 and 20 characters.

stringYes
offlineIf set to true the portal will not be visible to customers.
Default: false
booleanNo
routingDetermines the routing strategy ('browser' or 'proxy').
Default: browser
stringNo
credentialsEnabledIndicates if credentials are enabled for the portal.
Default: true
booleanNo
swaggerHubOrganizationIdThe corresponding API Hub (formerly SwaggerHub) organization UUIDstring (uuid)Yes
openapiRenderer

Portal level setting for the OpenAPI renderer. 

  • SWAGGER_UI - Use the Swagger UI renderer
  • ELEMENTS - Use the Elements renderer
  • TOGGLE - Switch between the two renderers with elements set as the default

    Default: TOGGLE
stringNo
pageContentFormatDetermines the format of the page content (HTML or MARKDOWN or BOTH)
Default: HTML
stringNo

delete_portal

  • Purpose: Delete a portal.
  • Parameters: Portal UUID or subdomain (portalId).
  • Returns: No content on success.
  • Use case: Delete an existing portal from API Hub.

update_portal

  • Purpose: Update a specific portal's configuration.
  • Returns: Complete set of metadata properties for a specific portal.
  • Use case: Update configuration settings of existing API Hub portal.
  • Parameters:
ParameterDescriptionTypeRequired
nameThe portal name.
Must be between 3 and 40 characters.
stringNo
subdomain

Subdomain for this portal. Must be unique.

Must be between 3 and 20 characters.

stringNo
customDomain

Custom domain for this portal. Must be unique. 

If the value is explicitly set to null, the custom domain will be removed.

stringNo
offlineIf set to true the portal will not be visible to customers.
Default: false
booleanNo
gtmKeyThe Google Tag Manager key for this portal.stringNo
routingDetermines the routing strategy ('browser' or 'proxy').
Default: browser
stringNo
credentialsEnabledIndicates if credentials are enabled for the portal.
Default: true
booleanNo
swaggerHubOrganizationIdThe corresponding API Hub (formerly SwaggerHub) organization UUIDstring (uuid)Yes
openapiRenderer

Portal level setting for the OpenAPI renderer. 

  • SWAGGER_UI - Use the Swagger UI renderer
  • ELEMENTS - Use the Elements renderer
  • TOGGLE - Switch between the two renderers with elements set as the default

    Default: TOGGLE
stringNo
pageContentFormatDetermines the format of the page content (HTML or MARKDOWN or BOTH)
Default: HTML
stringNo

 

list_portal_products

  • Purpose: Get products for a specific portal.
  • Parameters: Portal UUID or subdomain (portalId).
  • Returns: Paged list of products for a portal.
  • Use case: Understanding the products that exist for a given portal.

get_portal_product

  • Purpose: Retrieve information about a specific product resource.
  • Parameters: Product UUID (productId).
  • Returns: Complete set of properties for a specific product.
  • Use case: Understanding the product information and status (both from a publishing and visibility perspective).

create_portal_product

  • Purpose: Create a new product within a specific portal.
  • Returns: Information about the newly created product.
  • Use case: Add a new product to a portal.
  • Parameters: 
ParameterDescriptionTypeRequired
portalId Portal UUID or subdomain.stringYes
createPortalArgs
typeThe mode of creation. new or copystringYes
 nameThe product name.
Must be between 3 and 40 characters.
stringYes
 slug

URL component for this product. Must be unique within the portal.

Must be between 3 and 22 characters.

stringYes
 description

The product description. 

Max length is 110 characters.

stringNo
 publicWhether this product is available to non-members of the organization.booleanNo
 hiddenIf set to true, this product will not be displayed on the landing page.booleanNo

update_portal_product

  • Purpose: Update an product within a specific portal.
  • Returns: Information about the update product.
  • Use case: Change information on an existing product.
  • Parameters: 
ParameterDescriptionTypeRequired
productId Identifier of product to update.stringYes
updatePortalArgs
nameThe product name.
Must be between 3 and 40 characters.
stringYes
 slug

URL component for this product. Must be unique within the portal.

Must be between 3 and 22 characters.

stringYes
 description

The product description. 

Max length is 110 characters.

stringNo
 publicWhether this product is available to non-members of the organization.booleanNo
 hiddenIf set to true, this product will not be displayed on the landing page.booleanNo

delete_portal_product

  • Purpose: Delete a product from a specific portal.
  • Parameters: Product UUID (productId).
  • Returns: No content on success.
  • Use case: Delete an existing product from an API Hub portal.