TicketUserServices

<back to all web services

CalculateDiscountPricesRequest

Requires Authentication
Requires any of the roles:Admin, TeamAdmin, MobileAppRequires the permission:ReadData
The following routes are available for this service:
GET POST/ticketOrder/CalculatePrices

export class TicketDetails
{
    public id?: number;
    public ticketId?: number;
    public eventSeriesTicketType?: number;
    public eventSeriesOwnerTicketType?: number;
    public ticketPrice?: number;
    public totalPrice?: number;
    public count?: number;
    public ticketColor?: string;
    public showUsedTickets?: boolean;
    public ticketName?: string;
    public ticketDisplayString?: string;
    public ticketDetailsTransferredFrom?: number;
    public teamPassId?: number;
    public isSpecialTicket?: boolean;
    public specialTicketId?: string;
    public justChangedBySQL?: boolean;
    public sqlJustChangedTimeStamp?: string;
    public currency?: string;
    public discountCode?: string;
    public totalDiscount?: number;
    public totalAmountBeforeDiscount?: number;
    public ticketPriceBeforeDiscount?: number;

    public constructor(init?: Partial<TicketDetails>) { (Object as any).assign(this, init); }
}

export class CalculateDiscountPricesRequest
{
    public discountCode?: string;
    public fullPhoneNumber?: string;
    public eventId?: number;
    public orderDetails?: TicketDetails[];

    public constructor(init?: Partial<CalculateDiscountPricesRequest>) { (Object as any).assign(this, init); }
}

export class CalculateDiscountPricesResult
{
    public orderDetails?: TicketDetails[];
    public statusCode?: number;
    public message?: string;

    public constructor(init?: Partial<CalculateDiscountPricesResult>) { (Object as any).assign(this, init); }
}

TypeScript CalculateDiscountPricesRequest DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .csv suffix or ?format=csv

HTTP + CSV

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

POST /ticketOrder/CalculatePrices HTTP/1.1 
Host: stubbur-app.azurewebsites.net 
Accept: text/csv
Content-Type: text/csv
Content-Length: length

{"discountCode":"String","fullPhoneNumber":"String","eventId":0,"orderDetails":[{"id":0,"ticketId":0,"eventSeriesTicketType":0,"eventSeriesOwnerTicketType":0,"ticketPrice":0,"totalPrice":0,"count":0,"ticketColor":"String","showUsedTickets":false,"ticketName":"String","ticketDisplayString":"String","ticketDetailsTransferredFrom":0,"teamPassId":0,"isSpecialTicket":false,"specialTicketId":"String","justChangedBySQL":false,"sqlJustChangedTimeStamp":"0001-01-01T00:00:00.0000000","currency":"String","discountCode":"String","totalDiscount":0,"totalAmountBeforeDiscount":0,"ticketPriceBeforeDiscount":0}]}
HTTP/1.1 200 OK
Content-Type: text/csv
Content-Length: length

{"orderDetails":[{"id":0,"ticketId":0,"eventSeriesTicketType":0,"eventSeriesOwnerTicketType":0,"ticketPrice":0,"totalPrice":0,"count":0,"ticketColor":"String","showUsedTickets":false,"ticketName":"String","ticketDisplayString":"String","ticketDetailsTransferredFrom":0,"teamPassId":0,"isSpecialTicket":false,"specialTicketId":"String","justChangedBySQL":false,"sqlJustChangedTimeStamp":"0001-01-01T00:00:00.0000000","currency":"String","discountCode":"String","totalDiscount":0,"totalAmountBeforeDiscount":0,"ticketPriceBeforeDiscount":0}],"statusCode":0,"message":"String"}