components:
  schemas:

    CreatePayment:
      type: object
      required:
        - class_id

      properties:
        class_id:
          type: string
          format: uuid
          description: ID of the class to be paid for
          example: "018f22d5-4b3a-7c21-b93f-9a5aefc1b847"
        
        creditCardToken:
          type: string
          nullable: true
          description: Token of a previously saved credit card (use this for saved cards)
          example: "card_018f22d5-4b3a-7c21-b93f-9a5aefc1b847"
        
        creditCard:
          type: object
          nullable: true
          description: Credit card details for one-time payment (without saving the card)
          properties:
            number:
              type: string
              description: Credit card number
              example: "4111111111111111"
            expiryDate:
              type: string
              description: Credit card expiration date in 'YYYY-MM' format
              pattern: '^\d{4}-\d{2}$'
              example: "2026-12"
            ccv:
              type: string
              description: Credit card verification code (CVV)
              example: "123"
