Skip to content

Denormalized, indexed record powering the server-side collection-index query (filter/sort/search/facets/paginate over Mongo). ONE doc per (collection × indexed…

Defined in: packages/bitbadgesjs-sdk/src/api-indexer/docs-types/docs.ts:173

Denormalized, indexed record powering the server-side collection-index query (filter/sort/search/facets/paginate over Mongo). ONE doc per (collection × indexed standard); _docId = ${collectionId}:${standard}``. A collection declaring N indexable standards has N rows. Maintained in real time by the indexer's tx-handlers from the standards-info builder projections, so the client derives nothing. The /pay dashboard is the first consumer (scopes by standard); prediction-market/auction/etc. dashboards reuse the same shape.

Extends

Type Parameters

T

T extends NumberType

Implements

Constructors

Constructor

new CollectionIndexDoc<T>(data): CollectionIndexDoc<T>

Defined in: packages/bitbadgesjs-sdk/src/api-indexer/docs-types/docs.ts:194

Parameters

data

iCollectionIndexDoc<T>

Returns

CollectionIndexDoc<T>

Overrides

BaseNumberTypeClass.constructor

Properties

_docId

_docId: string

Defined in: packages/bitbadgesjs-sdk/src/api-indexer/docs-types/docs.ts:174

A unique stringified document ID

Implementation of

iCollectionIndexDoc._docId


_id?

optional _id?: string

Defined in: packages/bitbadgesjs-sdk/src/api-indexer/docs-types/docs.ts:175

A unique document ID (Mongo DB ObjectID)

Implementation of

iCollectionIndexDoc._id


amountStr?

optional amountStr?: string

Defined in: packages/bitbadgesjs-sdk/src/api-indexer/docs-types/docs.ts:184

Headline money amount (exact bigint string), denom paired below — for display.

Implementation of

iCollectionIndexDoc.amountStr


collectionId

collectionId: string

Defined in: packages/bitbadgesjs-sdk/src/api-indexer/docs-types/docs.ts:176

The collection ID (this row is one of the collection's indexed standards).

Implementation of

iCollectionIndexDoc.collectionId


createdBlock

createdBlock: T

Defined in: packages/bitbadgesjs-sdk/src/api-indexer/docs-types/docs.ts:190

Creation block (cursor sort key, mirrors createdTokens).

Implementation of

iCollectionIndexDoc.createdBlock


createdBy

createdBy: string

Defined in: packages/bitbadgesjs-sdk/src/api-indexer/docs-types/docs.ts:177

Creator bech32 address — dashboards scope per-creator.

Implementation of

iCollectionIndexDoc.createdBy


createdTimestamp

createdTimestamp: T

Defined in: packages/bitbadgesjs-sdk/src/api-indexer/docs-types/docs.ts:191

Creation timestamp (unix ms).

Implementation of

iCollectionIndexDoc.createdTimestamp


denom?

optional denom?: string

Defined in: packages/bitbadgesjs-sdk/src/api-indexer/docs-types/docs.ts:185

Headline denom (invoice/sub price/product 'from'/vault backing).

Implementation of

iCollectionIndexDoc.denom


endTime?

optional endTime?: number

Defined in: packages/bitbadgesjs-sdk/src/api-indexer/docs-types/docs.ts:186

Deadline in unix ms (0/absent = none); used for the query-time expiry rule.

Implementation of

iCollectionIndexDoc.endTime


extras?

optional extras?: unknown

Defined in: packages/bitbadgesjs-sdk/src/api-indexer/docs-types/docs.ts:189

The standard's full computed standardsInfo blob, carried for display.

Implementation of

iCollectionIndexDoc.extras


image

image: string

Defined in: packages/bitbadgesjs-sdk/src/api-indexer/docs-types/docs.ts:182

Collection image URI (for the dashboard avatar; '' until metadata lands).

Implementation of

iCollectionIndexDoc.image


lastSyncedBlock

lastSyncedBlock: T

Defined in: packages/bitbadgesjs-sdk/src/api-indexer/docs-types/docs.ts:192

Block this record was last rebuilt at (reorg/idempotency guard).

Implementation of

iCollectionIndexDoc.lastSyncedBlock


name

name: string

Defined in: packages/bitbadgesjs-sdk/src/api-indexer/docs-types/docs.ts:180

Collection display name (from metadata; '' until the async fetch lands).

Implementation of

iCollectionIndexDoc.name


nameLower

nameLower: string

Defined in: packages/bitbadgesjs-sdk/src/api-indexer/docs-types/docs.ts:181

Lowercased name for case-insensitive search/sort.

Implementation of

iCollectionIndexDoc.nameLower


payerAddress?

optional payerAddress?: string

Defined in: packages/bitbadgesjs-sdk/src/api-indexer/docs-types/docs.ts:187

Counterparty addresses (e.g. PaymentRequest payer/recipient) for role filtering.

Implementation of

iCollectionIndexDoc.payerAddress


recipientAddress?

optional recipientAddress?: string

Defined in: packages/bitbadgesjs-sdk/src/api-indexer/docs-types/docs.ts:188

Implementation of

iCollectionIndexDoc.recipientAddress


standard

standard: string

Defined in: packages/bitbadgesjs-sdk/src/api-indexer/docs-types/docs.ts:178

THE standard this row represents (the row's primary filter key).

Implementation of

iCollectionIndexDoc.standard


standards

standards: string[]

Defined in: packages/bitbadgesjs-sdk/src/api-indexer/docs-types/docs.ts:179

ALL standards the collection declares (for "is also an X" cross-filtering).

Implementation of

iCollectionIndexDoc.standards


status?

optional status?: string

Defined in: packages/bitbadgesjs-sdk/src/api-indexer/docs-types/docs.ts:183

Durable, tx-derived status enum (per standard). Clock-only transitions (e.g. PaymentRequest pendingexpired past its deadline) are NOT persisted here — they are applied at query time from endTime + the standard's expiry rule so they never go stale without a tx.

Implementation of

iCollectionIndexDoc.status

Methods

clone()

clone(): CollectionIndexDoc

Defined in: packages/bitbadgesjs-sdk/src/common/base.ts:151

Deep copies the object and returns a new instance.

Returns

CollectionIndexDoc

Inherited from

BaseNumberTypeClass.clone


convert()

convert<U>(convertFunction, options?): CollectionIndexDoc<U>

Defined in: packages/bitbadgesjs-sdk/src/api-indexer/docs-types/docs.ts:223

Converts the object to a different NumberType equivalent.

Type Parameters

U

U extends NumberType

Parameters

convertFunction

(val) => U

options?

ConvertOptions

Returns

CollectionIndexDoc<U>

Overrides

BaseNumberTypeClass.convert


equals()

equals<U>(other, normalizeNumberTypes?): boolean

Defined in: packages/bitbadgesjs-sdk/src/common/base.ts:147

Compares this object's fields to another object's fields for equality. Equality is determined by comparing the JSON representations of the objects.

If normalizeNumberTypes is true, then all number types will be compared as strings (i.e. "1n" === "1" === 1). Else, they will be compared as their native types (i.e. 1n !== 1 !== "1").

Type Parameters

U

U extends CustomType<U>

Parameters

other

CustomType<U> | null | undefined

normalizeNumberTypes?

boolean

Returns

boolean

Inherited from

BaseNumberTypeClass.equals


getNumberFieldNames()

getNumberFieldNames(): string[]

Defined in: packages/bitbadgesjs-sdk/src/api-indexer/docs-types/docs.ts:219

Internal helper method to convert the number fields of the object to a different NumberType equivalent.

Returns

string[]

Overrides

BaseNumberTypeClass.getNumberFieldNames


hasNumberFields()

hasNumberFields(): boolean

Defined in: packages/bitbadgesjs-sdk/src/common/base.ts:161

Checks if the object has number fields.

Returns

boolean

Inherited from

BaseNumberTypeClass.hasNumberFields


toJson()

toJson(): JsonObject

Defined in: packages/bitbadgesjs-sdk/src/common/base.ts:139

Converts the object to a JSON object with all primitive types.

Returns

JsonObject

Inherited from

BaseNumberTypeClass.toJson


toJsonString()

toJsonString(): string

Defined in: packages/bitbadgesjs-sdk/src/common/base.ts:143

Converts the object to a JSON string.

Returns

string

Inherited from

BaseNumberTypeClass.toJsonString

Edit this page on GitHub