add fungible token registry example

This commit is contained in:
Jason Dreyzehner
2023-04-15 00:38:13 -04:00
parent e89183bda9
commit 373322b988
4 changed files with 94 additions and 6 deletions
+8 -3
View File
@@ -512,7 +512,7 @@ export type IdentitySnapshot = {
* zero UTC (denoted by `Z`). Note, this is the format returned by ECMAScript
* `Date.toISOString()`.
*/
migrated?: number | string;
migrated?: string;
/**
* If this identity is a type of token, a data structure indicating how tokens
@@ -637,7 +637,7 @@ export type ChainSnapshot = Omit<IdentitySnapshot, 'migrated' | 'token'> & {
* ```
*/
export type RegistryTimestampKeyedValues<T> = {
[timestamp: number | string]: T;
[timestamp: string]: T;
};
/**
@@ -692,6 +692,11 @@ export type ChainHistory = RegistryTimestampKeyedValues<ChainSnapshot>;
*/
export type IdentityHistory = RegistryTimestampKeyedValues<IdentitySnapshot>;
export type OffChainRegistryIdentity = Pick<
IdentitySnapshot,
'name' | 'description' | 'uris' | 'tags' | 'extensions'
>;
/**
* A Bitcoin Cash Metadata Registry is an authenticated JSON file containing
* metadata about tokens, identities, contract applications, and other on-chain
@@ -767,7 +772,7 @@ export type Registry = {
* support on-chain resolution/authentication, and the contained
* `IdentitySnapshot` can only be authenticated via DNS/HTTPS.
*/
registryIdentity: IdentitySnapshot | string;
registryIdentity: OffChainRegistryIdentity | string;
/**
* A mapping of authbases to the `IdentityHistory` for that identity.