| Requires any of the roles: | Admin, TeamAdmin, MobileApp | Required permission: | Tickets.Add |
| POST | /DiscountCode/Search |
|---|
export class DiscountCode
{
public id?: number;
public discountCodeType?: number;
public code?: string;
public isMultiUse?: boolean;
public maxTickets?: number;
public isSingleUse?: boolean;
public isForPhoneNumberOnly?: boolean;
public fullPhoneNumber?: string;
public isUsed?: boolean;
public isValid?: boolean;
public constructor(init?: Partial<DiscountCode>) { (Object as any).assign(this, init); }
}
export class DiscountCodesResult
{
public items?: DiscountCode[];
public statusCode?: number;
public message?: string;
public constructor(init?: Partial<DiscountCodesResult>) { (Object as any).assign(this, init); }
}
export class DiscountCodesSearchRequest
{
public discountCodeType?: number;
public constructor(init?: Partial<DiscountCodesSearchRequest>) { (Object as any).assign(this, init); }
}
TypeScript DiscountCodesSearchRequest DTOs
To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /DiscountCode/Search HTTP/1.1
Host: stubbur-app.azurewebsites.net
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length
{
discountCodeType: 0
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length
{
items:
[
{
id: 0,
discountCodeType: 0,
code: String,
isMultiUse: False,
maxTickets: 0,
isSingleUse: False,
isForPhoneNumberOnly: False,
fullPhoneNumber: String,
isUsed: False,
isValid: False
}
],
statusCode: 0,
message: String
}