/**
 * Signing Result Response DTO
 */

import { ApiProperty, ApiPropertyOptional } from '@nestjs/swagger';

export class SigningResultDto {
  @ApiProperty({
    description: 'Full signature (hex)',
    example: '0x1234...abcd',
  })
  signature: string;

  @ApiProperty({
    description: 'R component of signature (hex)',
    example: '0x1234567890abcdef...',
  })
  r: string;

  @ApiProperty({
    description: 'S component of signature (hex)',
    example: '0xabcdef1234567890...',
  })
  s: string;

  @ApiPropertyOptional({
    description: 'Recovery parameter (0 or 1)',
    example: 0,
  })
  v?: number;

  @ApiProperty({
    description: 'Message hash that was signed',
    example: '0x1a2b3c4d5e6f7890abcdef1234567890abcdef1234567890abcdef1234567890',
  })
  messageHash: string;

  @ApiProperty({
    description: 'Public key used for signing',
    example: '03abcdef1234567890...',
  })
  publicKey: string;

  @ApiProperty({
    description: 'Session ID',
  })
  sessionId: string;

  @ApiProperty({
    description: 'Party ID',
  })
  partyId: string;
}

export class SigningAcceptedDto {
  @ApiProperty({
    description: 'Status message',
    example: 'Signing participation started',
  })
  message: string;

  @ApiProperty({
    description: 'Session ID',
  })
  sessionId: string;

  @ApiProperty({
    description: 'Party ID',
  })
  partyId: string;
}
