isRegistryStored
isRegistryStored(
registryUri
):Promise
<boolean
>
Checks whether a registry is stored in the CORD blockchain.
This function queries the chain for the existence of a registry using the provided
registry URI. It returns true
if the registry exists; otherwise, it returns false
.
Parameters
• registryUri: `registry:cord:${string}`
The URI of the registry to check for existence.
Returns
Promise
<boolean
>
A promise that resolves to a boolean indicating whether the registry exists.
Throws
If an error occurs while querying the registry storage.
Example
// Example: Checking if a registry existsconst registryExists = await isRegistryStored('space:cord:example_registry_uri');console.log('Registry exists:', registryExists);