CachingClientCreateCachedContentAsync Method

Asynchronously creates a new cached content resource.

Definition

Namespace: GenerativeAI.Clients
Assembly: GenerativeAI (in GenerativeAI.dll) Version: 2.0.2+aa51399cad6d90cc71158d589a6268608b3c1893
C#
public Task<CachedContent> CreateCachedContentAsync(
	CachedContent cachedContent,
	CancellationToken cancellationToken = default
)

Parameters

cachedContent  CachedContent
The cached content to be created.
cancellationToken  CancellationToken  (Optional)
Optional token to monitor for cancellation requests.

Return Value

TaskCachedContent
The created cached content resource.

See Also