@prismicio/client
Version:
The official JavaScript + TypeScript client library for Prismic
13 lines (12 loc) • 481 B
TypeScript
/**
* Get a repository's Prismic Rest API V2 endpoint.
*
* @typeParam RepositoryName - Name of the Prismic repository.
*
* @param repositoryName - Name of the repository.
*
* @returns The repository's Prismic Rest API V2 endpoint
*
* @throws {@link Error} Thrown if an invalid repository name is provided.
*/
export declare const getRepositoryEndpoint: <RepositoryName extends string>(repositoryName: RepositoryName) => `https://${RepositoryName}.cdn.prismic.io/api/v2`;