export interface TicketDefinition { /** Ticket definition ID. */ id?: string; /** Ticket price. */ price?: Money; /** Whether the ticket is free (read only). */ free?: boolean; /** Ticket name. */ name?: string; /** Ticket description. */ description?: string; /** * Limit of tickets that can be purchased per checkout. * Set to 20 for unlimited ticket definition. */ limitPerCheckout?: number; /** Custom sort index. */ orderIndex?: number; /** Policy information plain text block, as printed on the ticket. */ policy?: string; /** Sensitive dashboard data. */ dashboard?: Dashboard; /** Event ID associated with the ticket. */ eventId?: string; /** * Configuration of the fixed-rate Wix service fee that is applied at checkout to each ticket sold. * @readonly */ wixFeeConfig?: WixFeeConfig; /** Ticket sale period. */ salePeriod?: TicketSalePeriod; /** * Ticket sale status. * @readonly */ saleStatus?: TicketSaleStatus; /** Ticket state. */ state?: TicketDefinitionStateEnumState[]; /** Ticket pricing. */ pricing?: TicketPricing; } export interface Money { /** * *Deprecated:** Use `value` instead. * @deprecated */ amount?: string; /** ISO 4217 format of the currency e.g., `USD`. */ currency?: string; /** Monetary amount. Decimal string with a period as a decimal separator (e.g., 3.99). Optionally, starts with a single (-), to indicate that the amount is negative. */ value?: string | null; } export interface Dashboard { /** Whether ticket is hidden and cannot be sold. */ hidden?: boolean; /** * Number of tickets sold and reserved. * @deprecated */ sold?: number; /** Whether the ticket has limited quantity. */ limited?: boolean; /** Ticket limit. `NULL` for unlimited ticket definitions. */ quantity?: number | null; /** Number of unsold tickets. `NULL` for unlimited ticket definitions. */ unsold?: number | null; /** Number of tickets sold. */ ticketsSold?: number; /** Number of tickets reserved. */ ticketsReserved?: number; } export interface WixFeeConfig { /** Fee calculation method. */ type?: FeeType; } export declare enum FeeType { /** Fee is added to the ticket price at checkout. */ FEE_ADDED = "FEE_ADDED", /** Seller absorbs the fee. It is deducted from the ticket price. */ FEE_INCLUDED = "FEE_INCLUDED", /** Fee is added to the ticket price at checkout. */ FEE_ADDED_AT_CHECKOUT = "FEE_ADDED_AT_CHECKOUT" } export interface TicketSalePeriod { /** Ticket sale start timestamp. */ startDate?: Date | null; /** Ticket sale end timestamp. */ endDate?: Date | null; /** Whether to hide this ticket if it's not on sale */ hideNotOnSale?: boolean; } export declare enum TicketSaleStatus { /** Ticket sale is scheduled to start. */ SALE_SCHEDULED = "SALE_SCHEDULED", /** Ticket sale has started. */ SALE_STARTED = "SALE_STARTED", /** Ticket sale has ended. */ SALE_ENDED = "SALE_ENDED" } export declare enum TicketDefinitionStateEnumState { INCLUDE_HIDDEN_NOT_ON_SALE = "INCLUDE_HIDDEN_NOT_ON_SALE" } export interface TicketPricing extends TicketPricingPriceOneOf { /** Ticket price which is read only. */ fixedPrice?: Money; /** Min price per ticket, customizable. */ minPrice?: Money; /** Ticket pricing options. */ pricingOptions?: PricingOptions; /** * Ticket pricing type. * @readonly */ pricingType?: Type; } /** @oneof */ export interface TicketPricingPriceOneOf { /** Ticket price which is read only. */ fixedPrice?: Money; /** Min price per ticket, customizable. */ minPrice?: Money; /** Ticket pricing options. */ pricingOptions?: PricingOptions; } export interface PricingOptions { /** Multiple ticket pricing options. */ options?: PricingOption[]; } export interface PricingOption { /** Ticket pricing option ID. */ id?: string | null; /** Ticket pricing option name. */ name?: string | null; /** Ticket pricing option price. */ price?: Money; } export declare enum Type { STANDARD = "STANDARD", DONATION = "DONATION" } export interface QueryTicketDefinitionsRequest { /** Offset. See [Pagination](https://dev.wix.com/api/rest/getting-started/pagination). */ offset?: number; /** Limit. See [Pagination](https://dev.wix.com/api/rest/getting-started/pagination). */ limit?: number; /** Set of fields to return in the response. See [fieldsets](https://dev.wix.com/api/rest/wix-events/wix-events/fieldset#wix-events_wix-events_fieldset_ticket-definition-fieldset). */ fieldset?: TicketDefinitionFieldset[]; /** Filter. See [supported fields and operators](https://dev.wix.com/api/rest/wix-events/wix-events/filter-and-sort#wix-events_wix-events_filter-and-sort_query-ticket-definitions). */ filter?: Record | null; /** * Sort order. Defaults to: "created:asc". * See [supported fields](https://dev.wix.com/api/rest/wix-events/wix-events/filter-and-sort#wix-events_wix-events_filter-and-sort_query-ticket-definitions). */ sort?: string; /** * Filter facets to include in the response. * See [supported facets](https://dev.wix.com/api/rest/wix-events/wix-events/filter-and-sort#wix-events_wix-events_filter-and-sort_query-ticket-definitions). */ facet?: string[]; } export declare enum TicketDefinitionFieldset { /** Include `policy` in the response. */ POLICY = "POLICY", /** Include `dashboard` in the response. */ DASHBOARD = "DASHBOARD" } export interface QueryTicketDefinitionsResponse { /** Total ticket definitions matching the given filters. */ total?: number; /** Offset. */ offset?: number; /** Limit. */ limit?: number; /** Ticket definitions. */ definitions?: TicketDefinition[]; /** Filter facets. */ facets?: Record; } export interface FacetCounts { /** Facet counts aggregated per value. */ counts?: Record; } export interface QueryTicketDefinitionsV2Request { /** Query request object. */ query?: QueryV2; } export interface QueryV2 extends QueryV2PagingMethodOneOf { /** Paging options to limit and skip the number of items. */ paging?: Paging; /** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */ cursorPaging?: CursorPaging; /** * Filter object. * * Learn more about the [filter section](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#the-filter-section). */ filter?: Record | null; /** * Sort object. * * Learn more about the [sort section](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language#the-sort-section). */ sort?: Sorting[]; /** Array of projected fields. A list of specific field names to return. If `fieldsets` are also specified, the union of `fieldsets` and `fields` is returned. */ fields?: string[]; /** Array of named, predefined sets of projected fields. A array of predefined named sets of fields to be returned. Specifying multiple `fieldsets` will return the union of fields from all sets. If `fields` are also specified, the union of `fieldsets` and `fields` is returned. */ fieldsets?: string[]; } /** @oneof */ export interface QueryV2PagingMethodOneOf { /** Paging options to limit and skip the number of items. */ paging?: Paging; /** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */ cursorPaging?: CursorPaging; } export interface Sorting { /** Name of the field to sort by. */ fieldName?: string; /** Sort order. */ order?: SortOrder; } export declare enum SortOrder { ASC = "ASC", DESC = "DESC" } export interface Paging { /** Number of items to load. */ limit?: number | null; /** Number of items to skip in the current sort order. */ offset?: number | null; } export interface CursorPaging { /** Maximum number of items to return in the results. */ limit?: number | null; /** * Pointer to the next or previous page in the list of results. * * Pass the relevant cursor token from the `pagingMetadata` object in the previous call's response. * Not relevant for the first request. */ cursor?: string | null; } export interface QueryTicketDefinitionsV2Response { /** Ticket definitions. */ definitions?: TicketDefinition[]; /** Paging metadata definitions. */ metadata?: PagingMetadataV2; } export interface PagingMetadataV2 { /** Number of items returned in the response. */ count?: number | null; /** Offset that was requested. */ offset?: number | null; /** Total number of items that match the query. Returned if offset paging is used and the `tooManyToCount` flag is not set. */ total?: number | null; /** Flag that indicates the server failed to calculate the `total` field. */ tooManyToCount?: boolean | null; /** Cursors to navigate through the result pages using `next` and `prev`. Returned if cursor paging is used. */ cursors?: Cursors; } export interface Cursors { /** Cursor string pointing to the next page in the list of results. */ next?: string | null; /** Cursor pointing to the previous page in the list of results. */ prev?: string | null; } export interface ListTicketDefinitionsRequest { /** Event ID. */ eventId?: string[]; /** Offset. See [Pagination](https://dev.wix.com/api/rest/getting-started/pagination). */ offset?: number; /** Limit. See [Pagination](https://dev.wix.com/api/rest/getting-started/pagination). */ limit?: number; /** Set of fields to return in the response. See [Fieldsets](https://dev.wix.com/api/rest/wix-events/wix-events/fieldset#wix-events_wix-events_fieldset_ticket-definition-fieldset) */ fieldset?: TicketDefinitionFieldset[]; /** Event creator id filter, by default any. */ eventCreatorId?: string[]; /** Filters by ticket definition state. */ state?: State[]; /** * Sort order. Defaults to: "created:asc". * See [supported fields](https://dev.wix.com/api/rest/wix-events/wix-events/filter-and-sort#wix-events_wix-events_filter-and-sort_list-ticket-definitions). */ sort?: string; /** Ticket sale status. */ saleStatus?: TicketSaleStatus[]; /** * Filter facets to include in the response. * See [supported facets](https://dev.wix.com/api/rest/wix-events/wix-events/filter-and-sort#wix-events_wix-events_filter-and-sort_list-ticket-definitions). */ facet?: string[]; } export declare enum State { /** The ticket is available for purchase. */ VISIBLE = "VISIBLE", /** The ticket is unavailable for purchase. */ HIDDEN = "HIDDEN", /** The ticket price is 0. */ FREE = "FREE", /** The ticket price is greater than 0. */ PAID = "PAID" } export declare enum GroupBy { /** No grouping. */ NONE = "NONE", /** Groups by event created date with descending sorting. */ EVENT_CREATED_DESC = "EVENT_CREATED_DESC", /** Groups by event created date with ascending sorting. */ EVENT_CREATED_ASC = "EVENT_CREATED_ASC" } export interface ListTicketDefinitionsResponse { /** Meta data. */ metaData?: ResponseMetaData; /** Retrieved ticket definitions. */ definitions?: TicketDefinition[]; /** Filter facets. */ facets?: Record; } export interface ResponseMetaData { /** Number of items in the response. */ count?: number; /** Offset of items. */ offset?: number; /** Total number of matching items. */ total?: number; } export interface GetTicketDefinitionRequest { /** Ticket definition ID. */ definitionId: string; /** Set of fields to return in the response. See [Fieldsets](https://dev.wix.com/api/rest/wix-events/wix-events/fieldset#wix-events_wix-events_fieldset_ticket-definition-fieldset) */ fieldset?: TicketDefinitionFieldset[]; } export interface GetTicketDefinitionResponse { /** Retrieved ticket definition. */ definition?: TicketDefinition; } export interface CreateTicketDefinitionRequest { /** Event ID. */ eventId: string; /** Ticket definition data. */ definition: TicketDefinitionData; } export interface TicketDefinitionData { /** Ticket name. */ name?: string | null; /** Ticket price. */ price?: Money; /** Ticket description. */ description?: string | null; /** Whether this ticket type is limited in quantity. */ limited?: boolean; /** * Limit for this ticket type. * * `NULL` for unlimited. */ quantity?: number | null; /** Custom sort index for manual tickets ordering implementation. */ orderIndex?: number; /** Policy information in plain text (as listed on the ticket). */ policy?: string | null; /** Whether this ticket type is hidden to customers and cannot be purchased. */ hidden?: boolean; /** * Configuration of the fixed-rate Wix service fee that is applied to each ticket sold. * * Default: `FEE_ADDED_AT_CHECKOUT`. */ wixFeeConfig?: WixFeeConfig; /** Ticket sale period. */ salePeriod?: TicketSalePeriod; /** Ticket pricing. */ pricing?: TicketPricing; } export interface CreateTicketDefinitionResponse { /** Created ticket definition. */ definition?: TicketDefinition; } export interface TicketDefinitionCreated { /** Ticket Definition created timestamp in ISO UTC format. */ timestamp?: Date | null; /** Ticket Definition ID. */ ticketDefinitionId?: string; /** Event ID. */ eventId?: string; /** Originated from. */ originatedFrom?: OriginatedFrom; } export interface OriginatedFrom { /** Instance ID. Indicates the original app instance which current entity originated from. */ instanceId?: string; /** Event ID. Indicates the original event which current entity originated from. */ eventId?: string; /** Event ID. Indicates the original entity which current entity originated from. */ entityId?: string; } export interface UpdateTicketDefinitionRequest { /** Event ID. */ eventId: string; /** Ticket definition ID. */ definitionId: string; /** Ticket definition data. */ definition?: TicketDefinitionData; /** Set of field paths, specifying which parts of ticket definition to update. */ fields?: string[]; } export interface UpdateTicketDefinitionResponse { /** Updated ticket definition. */ definition?: TicketDefinition; } export interface TicketDefinitionUpdated { /** Ticket definition updated timestamp in ISO UTC format. */ timestamp?: Date | null; /** Ticket definition ID. */ ticketDefinitionId?: string; /** Event ID. */ eventId?: string; } export interface DeleteTicketDefinitionRequest extends DeleteTicketDefinitionRequestDeleteOneOf { /** Ticket definitions to delete. */ byId?: ById; /** Whether to delete all event tickets. */ all?: boolean; /** Event ID. */ eventId: string; } /** @oneof */ export interface DeleteTicketDefinitionRequestDeleteOneOf { /** Ticket definitions to delete. */ byId?: ById; /** Whether to delete all event tickets. */ all?: boolean; } export interface ById { /** Ticket definition IDs. */ definitionId?: string[]; } export interface DeleteTicketDefinitionResponse { } export interface TicketDefinitionDeleted { /** Ticket definition deleted timestamp in ISO UTC format. */ timestamp?: Date | null; /** Ticket definition ID. */ ticketDefinitionId?: string; /** Event ID. */ eventId?: string; } export interface ChangeCurrencyRequest { /** Event ID. */ eventId?: string; /** Event currency, in 3-letter [ISO-4217 alphabetic](https://en.wikipedia.org/wiki/ISO_4217#Active_codes) format. */ currency: string; } export interface ChangeCurrencyResponse { } export interface BulkCopyTicketDefinitionsByEventIdRequest { /** Origin instance ID. */ originInstanceId?: string | null; /** Origin Event ID. */ originEventId?: string; /** Target Event ID. */ targetEventId?: string; } export interface BulkCopyTicketDefinitionsByEventIdResponse { /** Copied ticket definitions. */ definitions?: CopiedTicketDefinition[]; } export interface CopiedTicketDefinition { /** Origin Ticket definition ID. */ originTicketDefinitionId?: string; /** Ticket definition ID. */ ticketDefinitionId?: string; } export interface PaidTicketDefinitionExistsRequest { } export interface PaidTicketDefinitionExistsResponse { /** Paid exists. */ paidExists?: boolean; } export interface MessageEnvelope { /** App instance ID. */ instanceId?: string | null; /** Event type. */ eventType?: string; /** The identification type and identity data. */ identity?: IdentificationData; /** Stringify payload. */ data?: string; } export interface IdentificationData extends IdentificationDataIdOneOf { /** ID of a site visitor that has not logged in to the site. */ anonymousVisitorId?: string; /** ID of a site visitor that has logged in to the site. */ memberId?: string; /** ID of a Wix user (site owner, contributor, etc.). */ wixUserId?: string; /** ID of an app. */ appId?: string; /** @readonly */ identityType?: WebhookIdentityType; } /** @oneof */ export interface IdentificationDataIdOneOf { /** ID of a site visitor that has not logged in to the site. */ anonymousVisitorId?: string; /** ID of a site visitor that has logged in to the site. */ memberId?: string; /** ID of a Wix user (site owner, contributor, etc.). */ wixUserId?: string; /** ID of an app. */ appId?: string; } export declare enum WebhookIdentityType { UNKNOWN = "UNKNOWN", ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR", MEMBER = "MEMBER", WIX_USER = "WIX_USER", APP = "APP" } interface MoneyNonNullableFields { amount: string; currency: string; } interface DashboardNonNullableFields { hidden: boolean; sold: number; limited: boolean; ticketsSold: number; ticketsReserved: number; } interface WixFeeConfigNonNullableFields { type: FeeType; } interface TicketSalePeriodNonNullableFields { hideNotOnSale: boolean; } interface PricingOptionNonNullableFields { price?: MoneyNonNullableFields; } interface PricingOptionsNonNullableFields { options: PricingOptionNonNullableFields[]; } interface TicketPricingNonNullableFields { fixedPrice?: MoneyNonNullableFields; minPrice?: MoneyNonNullableFields; pricingOptions?: PricingOptionsNonNullableFields; pricingType: Type; } interface TicketDefinitionNonNullableFields { id: string; price?: MoneyNonNullableFields; free: boolean; name: string; description: string; limitPerCheckout: number; orderIndex: number; policy: string; dashboard?: DashboardNonNullableFields; eventId: string; wixFeeConfig?: WixFeeConfigNonNullableFields; salePeriod?: TicketSalePeriodNonNullableFields; saleStatus: TicketSaleStatus; state: TicketDefinitionStateEnumState[]; pricing?: TicketPricingNonNullableFields; } export interface QueryTicketDefinitionsResponseNonNullableFields { total: number; offset: number; limit: number; definitions: TicketDefinitionNonNullableFields[]; } export interface QueryTicketDefinitionsV2ResponseNonNullableFields { definitions: TicketDefinitionNonNullableFields[]; } interface ResponseMetaDataNonNullableFields { count: number; offset: number; total: number; } export interface ListTicketDefinitionsResponseNonNullableFields { metaData?: ResponseMetaDataNonNullableFields; definitions: TicketDefinitionNonNullableFields[]; } export interface GetTicketDefinitionResponseNonNullableFields { definition?: TicketDefinitionNonNullableFields; } export interface CreateTicketDefinitionResponseNonNullableFields { definition?: TicketDefinitionNonNullableFields; } export interface UpdateTicketDefinitionResponseNonNullableFields { definition?: TicketDefinitionNonNullableFields; } export {};