Appearance
DoCurious API Reference / types / XPTransaction
Interface: XPTransaction
Defined in: types/gamification.types.ts:173
Ledger-style XP transaction with running balance, used for audit and history views.
Remarks
Unlike XPEvent (which is display-oriented), XPTransaction tracks the running XP balance after each change and supports negative amounts (e.g., Dealer's Choice abandon penalty).
Extends
Properties
amount
amount:
number
Defined in: types/gamification.types.ts:177
XP change amount -- positive for gains, negative for penalties
badgeId?
optionalbadgeId:string
Defined in: types/gamification.types.ts:180
balanceAfter
balanceAfter:
number
Defined in: types/gamification.types.ts:185
Cumulative XP total after this transaction was applied
challengeId?
optionalchallengeId:string
Defined in: types/gamification.types.ts:179
createdAt
createdAt:
string
Defined in: types/common.types.ts:154
ISO 8601 datetime when the entity was created
Inherited from
description
description:
string
Defined in: types/gamification.types.ts:182
Human-readable description of what triggered this transaction
eventType
eventType:
XPEventType
Defined in: types/gamification.types.ts:175
id
id:
string
Defined in: types/common.types.ts:167
Inherited from
updatedAt
updatedAt:
string
Defined in: types/common.types.ts:156
ISO 8601 datetime when the entity was last modified
Inherited from
userId
userId:
string
Defined in: types/gamification.types.ts:174