Appearance
DoCurious API Reference / types / ChallengeInstance
Interface: ChallengeInstance
Defined in: types/challenge.types.ts:99
A specific offering of a challenge template with its own schedule, location, and capacity.
Remarks
Maps to the SQL challenge_instances table. A single Challenge can have many instances -- for example, a pottery class offered on different days or at different venues. Each instance independently tracks difficulty, seats, and provisions.
Example
ts
const instance: ChallengeInstance = {
id: 'inst-001',
createdAt: '2025-06-01T00:00:00Z',
updatedAt: '2025-06-01T00:00:00Z',
challengeId: 'ch-042',
difficulty: 'beginner',
disabilityFriendly: true,
consentRequired: false,
status: 'active',
totalSeats: 12,
city: 'Portland',
state: 'OR',
}Extends
Properties
affiliateUrl?
optionalaffiliateUrl:string
Defined in: types/challenge.types.ts:104
Affiliate tracking URL for this specific instance
apartmentNo?
optionalapartmentNo:string
Defined in: types/challenge.types.ts:147
availableDates?
optionalavailableDates:string[]
Defined in: types/challenge.types.ts:139
Specific ISO date strings when this instance is available
challengeId
challengeId:
string
Defined in: types/challenge.types.ts:101
Parent challenge template this instance belongs to
city?
optionalcity:string
Defined in: types/challenge.types.ts:143
consentRequired
consentRequired:
boolean
Defined in: types/challenge.types.ts:128
Whether parental/guardian consent is required to participate
country?
optionalcountry:string
Defined in: types/challenge.types.ts:146
createdAt
createdAt:
string
Defined in: types/common.types.ts:154
ISO 8601 datetime when the entity was created
Inherited from
customerProvisions?
optionalcustomerProvisions:Record<string,unknown>
Defined in: types/challenge.types.ts:120
Items the customer must bring (e.g., safety gear, supplies)
difficulty
difficulty:
DifficultyLevel
Defined in: types/challenge.types.ts:115
disabilityFriendly
disabilityFriendly:
boolean
Defined in: types/challenge.types.ts:126
Whether the venue and activity are accessible for participants with disabilities
duration?
optionalduration:number
Defined in: types/challenge.types.ts:114
Duration in minutes
equipment?
optionalequipment:string
Defined in: types/challenge.types.ts:108
Equipment description the participant needs to bring
id
id:
string
Defined in: types/common.types.ts:167
Inherited from
languages?
optionallanguages:string[]
Defined in: types/challenge.types.ts:124
ISO language codes this instance is offered in
lat?
optionallat:number
Defined in: types/challenge.types.ts:148
level?
optionallevel:number
Defined in: types/challenge.types.ts:110
Minimum skill level required (numeric)
lng?
optionallng:number
Defined in: types/challenge.types.ts:149
points?
optionalpoints:number
Defined in: types/challenge.types.ts:112
XP points awarded for completing this instance
postalCode?
optionalpostalCode:string
Defined in: types/challenge.types.ts:145
schedule?
optionalschedule:InstanceSchedule[]
Defined in: types/challenge.types.ts:137
Recurring schedule slots for this instance
startingAt?
optionalstartingAt:string
Defined in: types/challenge.types.ts:132
ISO datetime when this instance starts
state?
optionalstate:string
Defined in: types/challenge.types.ts:144
status
status:
ChallengeInstanceStatus
Defined in: types/challenge.types.ts:133
streetAddress?
optionalstreetAddress:string
Defined in: types/challenge.types.ts:142
totalSeats?
optionaltotalSeats:number
Defined in: types/challenge.types.ts:135
Maximum number of participants allowed
updatedAt
updatedAt:
string
Defined in: types/common.types.ts:156
ISO 8601 datetime when the entity was last modified
Inherited from
vendorProvisions?
optionalvendorProvisions:Record<string,unknown>
Defined in: types/challenge.types.ts:118
Items the vendor will provide (e.g., materials, tools)