File

src/orderbook/orderbook.interface.ts

Index

Properties

Properties

orderDto
orderDto: ForceOrderRedemptionDto
Type : ForceOrderRedemptionDto
type
type: OrderType
Type : OrderType
userJwt
userJwt: UserJwtPayload
Type : UserJwtPayload
import type { UserJwtPayload } from "./../common/interfaces/SharedTypes";
import { LeanDocument } from "mongoose";
import type {
  AuthRequest,
  IFundQuery,
  IOrder,
  IOrderBookQuery,
  OrderType,
} from "src/common/interfaces";
import type { OrderDto } from "./dto/create-order.dto";
import type { OrderConfirmDto } from "./dto/confirm-order.dto";
import type { ForceOrderRedemptionDto } from "./dto/force-order.dto";
import type { OrderSettleDto } from "./dto/settle-order.dto";
import type { OrderCancelDto } from "./dto/cancel-order.dto";
import type { OrderLockDto } from "./dto/lock-order.dto";
import type { Instrument } from "src/security/schemas/instrument.schema";
import type { FundDocument } from "src/security/schemas/fund.schema";
import type { UserWithOnChainFields } from "src/user/user.interface";
import type { FilterOrderDto } from "./dto/filter-order.dto";
import type { User } from "src/user/schemas/user.schema";

export interface ICreateOrder {
  request: AuthRequest;
  orderDto: OrderDto;
  type: OrderType;
}
export interface IOrderDetails {
  orderDto: OrderConfirmDto;
  type: OrderType;
}

export interface ICancelOrder {
  orderDto: OrderCancelDto;
  request: AuthRequest;
}

export interface IGetMyOrders extends FilterOrderDto {
  request: AuthRequest;
}
export interface IGetInvestorOrders extends FilterOrderDto {
  investorId: string;
}

export interface IGetOrderById extends IGetMyOrders {
  orderId: string;
}

export interface IConfirmOrder {
  request: AuthRequest;
  type: OrderType;
  orderDto: OrderConfirmDto;
}

export interface ILockOrder {
  request: AuthRequest;
  orderDto: OrderLockDto;
}
export interface ISettleOrders {
  request: AuthRequest;
  orderDto: OrderSettleDto;
  type: OrderType;
}

export interface IForceRedemptionOrder {
  userJwt: UserJwtPayload;
  orderDto: ForceOrderRedemptionDto;
  type: OrderType;
}

export interface OrderDetailsInfo {
  fund: LeanDocument<FundDocument>;
  instrument: Instrument;
  investor: User;
  dealer: User;
  orderDetails: IOrder;
}
export interface IOrderWithInvestor extends IOrder {
  onBehalf: {
    id: string;
    associatedDealer: {
      id: string;
    };
  } & UserWithOnChainFields;
}

export interface IOrderBookWithInvestor extends IOrderBookQuery {
  orders: IOrderWithInvestor[];
}
export interface IGetOrderBookWithInvestor {
  orderBooks: IOrderBookWithInvestor[];
}

export interface IGetSettlementApproval {
  orderbookId: string;
  fundId?: string;
  userJwt: UserJwtPayload;
}

export interface IApproveSettlement {
  userJwt: UserJwtPayload;
  fundId: string;
  orderbookId: string;
  orderId: string;
}

export interface IOrderBookWithFundName extends IOrderBookQuery {
  fund: IFundQuery & { title: string };
}

export interface IOrderWithFundName extends IOrder {
  orderBook: IOrderBookWithFundName;
}

results matching ""

    No results matching ""