download Method

Download a Thumbnail.

download(requestContext: AuthorizedClientRequestContext, iModelId: string, thumbnail: Thumbnail | TipThumbnail): Promise<string>

throws Error if a successful server response contains no content.

throws IModelHubClientError with IModelHubStatus.UndefinedArgumentError or IModelHubStatus.InvalidArgumentError if one of the arguments is undefined or has an invalid value.

throws ResponseError if a network issue occurs.

Parameter Type Description
requestContext AuthorizedClientRequestContext The client request context.
iModelId string Id of the iModel. See HubIModel.
thumbnail Thumbnail | TipThumbnail Small, Large or Tip thumbnail. Use ThumbnailHandler.get to get a SmallThumbnail or LargeThumbnail instance or provide Tip thumbnail information by constructing a TipThumbnail instance.

Returns - Promise<string>

Base64 encoded string containing the PNG image.

Defined in

Last Updated: 11 June, 2024