All checks were successful
		
		
	
	Check usage of free licenses / check-licenses (pull_request) Successful in 1m38s
				
			Add copyright notice / copyright_notice (pull_request) Successful in 3m16s
				
			Run unit tests / unit_tests (pull_request) Successful in 5m31s
				
			Build Nginx-based docker image / build-static-assets (pull_request) Successful in 41m31s
				
			
		
			
				
	
	
		
			55 lines
		
	
	
		
			1.4 KiB
		
	
	
	
		
			Ruby
		
	
	
	
	
	
			
		
		
	
	
			55 lines
		
	
	
		
			1.4 KiB
		
	
	
	
		
			Ruby
		
	
	
	
	
	
# Copyright (C) 2024-2025 LibreWeddingPlanner contributors
 | 
						|
 | 
						|
# frozen_string_literal: true
 | 
						|
 | 
						|
module Swagger
 | 
						|
  module Schema
 | 
						|
    USER = {
 | 
						|
      id: { type: :string, format: :uuid },
 | 
						|
      email: { type: :string, format: :email },
 | 
						|
      created_at: SwaggerResponseHelper::TIMESTAMP,
 | 
						|
      updated_at: SwaggerResponseHelper::TIMESTAMP
 | 
						|
    }.freeze
 | 
						|
 | 
						|
    ID = { # rubocop:disable Style/MutableConstant -- rswag modifies in: :path parameters
 | 
						|
      name: 'id',
 | 
						|
      in: :path,
 | 
						|
      type: :string,
 | 
						|
      format: :uuid
 | 
						|
    }
 | 
						|
 | 
						|
    GROUP = {
 | 
						|
      name: { type: :string },
 | 
						|
      icon: { type: :string, example: 'pi pi-crown', description: 'The CSS classes used by the icon' },
 | 
						|
      parent_id: { type: :string, format: :uuid },
 | 
						|
      color: { type: :string, pattern: '^#(?:[0-9a-fA-F]{3}){1,2}$' }
 | 
						|
    }.freeze
 | 
						|
 | 
						|
    EXPENSE = {
 | 
						|
      name: { type: :string },
 | 
						|
      amount: { type: :number, minimum: 0 },
 | 
						|
      pricing_type: { type: :string, enum: Expense.pricing_types.keys }
 | 
						|
    }.freeze
 | 
						|
 | 
						|
    SLUG = { # rubocop:disable Style/MutableConstant -- rswag modifies in: :path parameters
 | 
						|
      name: 'slug',
 | 
						|
      in: :path,
 | 
						|
      type: :string,
 | 
						|
      pattern: Wedding::SLUG_REGEX,
 | 
						|
      example: :default,
 | 
						|
      description: 'Wedding slug'
 | 
						|
    }
 | 
						|
 | 
						|
    CAPTCHA = {
 | 
						|
      captcha: {
 | 
						|
        type: :object,
 | 
						|
        required: %i[id answer],
 | 
						|
        properties: {
 | 
						|
          id: { type: :string, format: :uuid },
 | 
						|
          answer: { type: :string }
 | 
						|
        }
 | 
						|
      }
 | 
						|
    }.freeze
 | 
						|
  end
 | 
						|
end
 |