import { factory } from '../../../factory'; import type { AssetTransactionRepo } from '../../../repo/assetTransaction'; import type { AuthorizationRepo } from '../../../repo/authorization'; import type { EventRepo } from '../../../repo/event'; import type { EventOfferRepo } from '../../../repo/eventOffer'; import type { EventSeriesRepo } from '../../../repo/eventSeries'; import type { IssuerRepo } from '../../../repo/issuer'; import type { MemberRepo } from '../../../repo/member'; import type { MemberProgramRepo } from '../../../repo/memberProgram'; import type { OfferRepo } from '../../../repo/offer/unitPriceInCatalog'; import type { OfferCatalogRepo } from '../../../repo/offerCatalog'; import type { OfferCatalogItemRepo } from '../../../repo/offerCatalogItem'; import type { PaymentServiceRepo } from '../../../repo/paymentService'; import { SeatRepo } from '../../../repo/place/seat'; import type { PriceSpecificationRepo } from '../../../repo/priceSpecification'; import type { ProductRepo } from '../../../repo/product'; import type { OfferRateLimitRepo } from '../../../repo/rateLimit/offer'; import type { SettingRepo } from '../../../repo/setting'; import type { IntegrationSettingRepo } from '../../../repo/setting/integration'; import type { StockHolderRepo } from '../../../repo/stockHolder'; import type { TaskRepo } from '../../../repo/task'; import type { TicketRepo } from '../../../repo/ticket'; interface IStartOperationRepos { authorization: AuthorizationRepo; stockHolder: StockHolderRepo; event: EventRepo; eventOffer: EventOfferRepo; eventSeries: EventSeriesRepo; issuer: IssuerRepo; member: MemberRepo; memberProgram: MemberProgramRepo; offer: OfferRepo; offerCatalog: OfferCatalogRepo; offerCatalogItem: OfferCatalogItemRepo; offerRateLimit: OfferRateLimitRepo; paymentService: PaymentServiceRepo; product: ProductRepo; priceSpecification: PriceSpecificationRepo; seat: SeatRepo; setting: SettingRepo; integrationSetting: IntegrationSettingRepo; task: TaskRepo; ticket: TicketRepo; assetTransaction: AssetTransactionRepo; } type IStartOperation = (repos: IStartOperationRepos) => Promise; type IObjectSubReservation = factory.assetTransaction.reserve.IObjectSubReservation; type IStartParams = factory.assetTransaction.reserve.IStartParamsWithoutDetail & { /** * add(2025-02-17~) */ instrument: factory.assetTransaction.reserve.IInstrument[]; /** * 承認アクションを介した場合に検索済のイベント * discontinue preSearchedEvent(2024-07-17~) */ /** * 承認アクションを介した場合に検索済のオファーリスト */ preSearchedTicketOffers?: factory.product.ITicketOffer[]; /** * 承認アクションを介した場合に検索済の単価オファーリスト */ preSearchedUnitPriceOffers?: factory.unitPriceOffer.IUnitPriceOffer[]; /** * 販売アプリケーション */ availableAtOrFrom?: { id?: string; }; /** * イベントの販売期間を検証するかどうか */ validateEventOfferPeriod: boolean; /** * イベントのオファー(最大予約座席数)を検証するかどうか */ validateEvent: boolean; validateAppliesToMovieTicket: boolean; }; /** * 取引開始 */ declare function start(params: IStartParams & {}, options: { /** * 最大n日前から予約可能 */ maxReservationGracePeriodInDays: number; }): IStartOperation<{ transaction: Pick, 'id'>; objectSubReservations: IObjectSubReservation[]; issuedThrough: factory.assetTransaction.reserve.IIssuedThrough; reservationFor: factory.assetTransaction.reserve.IReservationFor; }>; export { start };