Skip to main content

TechDocsClient

Home > @backstage/plugin-techdocs > TechDocsClient

API to talk to techdocs-backend.

Signature:

class TechDocsClient implements TechDocsApi 

Implements: TechDocsApi

Constructors

ConstructorModifiersDescription
(constructor)(options)Constructs a new instance of the TechDocsClient class

Properties

PropertyModifiersTypeDescription
configApiConfig
discoveryApiDiscoveryApi

Methods

MethodModifiersDescription
getApiOrigin()
getCookie()
getEntityMetadata(entityId)

Retrieve metadata about an entity.

This method requests techdocs-backend which uses the catalog APIs to respond with filtered information required here.

getTechDocsMetadata(entityId)

Retrieve TechDocs metadata.

When docs are built, we generate a techdocs_metadata.json and store it along with the generated static files. It includes necessary data about the docs site. This method requests techdocs-backend which retrieves the TechDocs metadata.