mirror of
https://github.com/Tria-plc/edr-platform.git
synced 2026-08-29 16:28:12 +00:00
31 lines
895 B
TypeScript
31 lines
895 B
TypeScript
import { ApiPropertyOptional } from "@nestjs/swagger";
|
|
import { IsIn, IsOptional, IsString } from "class-validator";
|
|
|
|
/** Gateway options for paying an invoice from the customer portal. */
|
|
export class PayInvoiceDto {
|
|
@ApiPropertyOptional({ description: "Payment method (defaults to TELEBIRR)." })
|
|
@IsOptional()
|
|
@IsString()
|
|
method?: string;
|
|
|
|
@ApiPropertyOptional({ enum: ["web", "mobile"], default: "web" })
|
|
@IsOptional()
|
|
@IsIn(["web", "mobile"])
|
|
platform?: "web" | "mobile";
|
|
|
|
@ApiPropertyOptional({ description: "Payer account / phone, for wallet methods." })
|
|
@IsOptional()
|
|
@IsString()
|
|
payerAccount?: string;
|
|
|
|
@ApiPropertyOptional({ description: "Browser redirect URL on success." })
|
|
@IsOptional()
|
|
@IsString()
|
|
returnUrl?: string;
|
|
|
|
@ApiPropertyOptional({ description: "Browser redirect URL on failure." })
|
|
@IsOptional()
|
|
@IsString()
|
|
failureUrl?: string;
|
|
}
|