getEntitiesSample
is used to get a random sample of published entities matching an optional query argument.
interface PublishedDossierClient {
getEntitiesSample(
query?: PublishedEntitySharedQuery,
options?: EntitySamplingOptions,
): PromiseResult<
EntitySamplingPayload,
"BadRequest" | "NotAuthorized" | "Generic"
>;
}
interface PublishedEntitySharedQuery {
authKeys?: string[];
entityTypes?: string[];
componentTypes?: string[];
linksTo?: EntityReference;
linksFrom?: EntityReference;
boundingBox?: BoundingBox;
text?: string;
}
interface EntitySamplingOptions {
seed?: number;
count?: number;
}
interface EntitySamplingPayload {
seed: number;
totalCount: number;
items: PublishedEntity[];
}