isChainSpaceStored
isChainSpaceStored(
spaceUri):Promise<boolean>
Checks the existence of a Chain Space on the CORD blockchain.
Parameters
Section titled “Parameters”• spaceUri: `space:cord:${string}`
The URI of the Chain Space to be checked.
Returns
Section titled “Returns”Promise<boolean>
A promise resolving to true if the Chain Space exists, or false otherwise.
Remarks
Section titled “Remarks”Queries the blockchain to determine if a Chain Space with the given URI exists, returning true if it does, and false otherwise.
Example
Section titled “Example”const spaceUri = 'space:example_uri';isChainSpaceStored(spaceUri).then(exists => { console.log(`Chain Space ${exists ? 'exists' : 'does not exist'} on the blockchain.`);}).catch(error => { console.error('Error querying Chain Space existence:', error);});Throws
Section titled “Throws”- Thrown on error during the blockchain query.