$schema: https://json-schema.org/draft/2020-12/schema
$id: OppTimeline.yaml
type: object
properties:
  postDate:
    $ref: Event.yaml
    description: The date (and time) at which the opportunity is posted
  closeDate:
    $ref: Event.yaml
    description: The date (and time) at which the opportunity closes
  otherDates:
    $ref: '#/$defs/RecordEvent'
    description: |-
      An optional map of other key dates or events in the opportunity timeline

      Examples might include a deadline for questions, anticipated award date, etc.
unevaluatedProperties:
  not: {}
examples:
  - postDate:
      name: Opportunity posted date
      eventType: singleDate
      date: '2024-01-15T00:00:00.000Z'
      description: Opportunity is posted publicly
    closeDate:
      name: Opportunity close date
      eventType: singleDate
      date: '2024-12-31T00:00:00.000Z'
      time: '17:00:00'
      description: Opportunity closes for all applications
    otherDates:
      anticipatedAward:
        name: Anticipated award date
        eventType: singleDate
        date: '2025-03-15T00:00:00.000Z'
        description: When we expect to announce awards for this opportunity.
      applicationPeriod:
        name: Application period
        eventType: dateRange
        startDate: '2024-01-01T00:00:00.000Z'
        endDate: '2024-01-31T00:00:00.000Z'
        endTime: '17:00:00'
        description: Primary application period for the grant opportunity
      performancePeriod:
        name: Period of Performance
        eventType: dateRange
        startDate: '2024-01-01T00:00:00.000Z'
        endDate: '2024-12-31T00:00:00.000Z'
        description: Period of performance for the grant
      infoSessions:
        name: Info sessions
        eventType: other
        details: Every other Tuesday
        description: Info sessions for the opportunity
description: Key dates and events in the opportunity's timeline, such as when the opportunity is posted and closes
$defs:
  RecordEvent:
    type: object
    properties: {}
    unevaluatedProperties:
      $ref: Event.yaml
