diff --git a/src/ddo/DDO.ts b/src/ddo/DDO.ts index cdace66f..118d4b0e 100644 --- a/src/ddo/DDO.ts +++ b/src/ddo/DDO.ts @@ -5,6 +5,7 @@ import { PublicKey } from './interfaces/PublicKey' import { Service, ServiceType } from './interfaces/Service' import Web3Provider from '../datatokens/Web3Provider' import { BestPrice } from './interfaces/BestPrice' +import { DataTokenInfo } from './interfaces/DataTokenInfo' /** * DID Descriptor Object. * Contains all the data related to an asset. @@ -54,6 +55,8 @@ export class DDO { public price: BestPrice + public dataTokenInfo?: DataTokenInfo + public constructor(ddo: Partial = {}) { Object.assign(this, ddo, { created: (ddo && ddo.created) || new Date().toISOString().replace(/\.[0-9]{3}/, '') diff --git a/src/ddo/interfaces/DataTokenInfo.ts b/src/ddo/interfaces/DataTokenInfo.ts new file mode 100644 index 00000000..db198fcf --- /dev/null +++ b/src/ddo/interfaces/DataTokenInfo.ts @@ -0,0 +1,11 @@ +export interface DataTokenInfo { + address: string + name: string + symbol: string + blob: string + decimals: number + totalSupply: number + cap: number + minter: string + minterBalance: number +}