API Models
A data model defines how information is stored and retrieved to support a solution.
The following list will help you identify what the app can offer to the end user.
Browse API Models
ProductModel
| Property | Type | Description |
|---|---|---|
| catalogueId | string | The guid of the Catalogue on which the voucher belongs to |
| name | string | The voucher's name |
| venueName | string | The name of the venue |
| price | Money? | The price of the voucher |
| isPrivate | bool | This indicates if the voucher is private |
| limitedAvailability | int? | Available number of vouchers |
| marketingDescription | string | Text for the marketing description |
| detailedDescription | string | Text for detailed description |
| terms | string | Terms and conditions |
| reservationEmail | string | Reservation email |
| reservationPhone | string | Reservation phone |
| images | string[] | List of images |
| tags | list of strings | List of tags |
| validity | ProductValidity | Voucher's validity |
| version | long | Version |
| parentPath | string[] | Parent path which is a list of guids |
| id | string | The voucher's guid |
Money
| Property | Type | Description |
|---|---|---|
| amount | decimal | The amount of the currency |
| currency | Currency | Currency object |
PeriodValidity
| Property | Type | Description |
|---|---|---|
| validMonths | int | Number of valid months |
RangeValidity
| Property | Type | Description |
|---|---|---|
| startDate | dateTime? | Start date |
| endDate | dateTime | End date |
Basket API Models
BasketModel
| Property | Type | Description |
|---|---|---|
| basketId | string | The Id of the current basket |
| basketVersion | number | Basket version number |
| items | ItemModel[] | List of items of in the basket |
| promoCode | string | The promo code applied to the basket |
| deliveries | DeliveryModel[] | An array containing types of delivery (Postal, Email, OnSite) |
| deliveryOptions | DeliveryOption[] | An array containing types of delivery options |
| paymentOptions | PaymentOptionShortModel[] | An array containing the payment options |
ItemModel
| Property | Type | Description |
|---|---|---|
| lineItemId | string | The guid of the item in the basket |
| productId | string | The voucher's guid |
| productName | string | Name of the product |
| imageUrl | string | Url of the product's image |
| personalMessage | PersonalMessage | Personal Message |
| quotedPrice | Money | Quoted price |
| retailPrice | Money | Retail price |
| deliveryId | string | Delivery guid |
| availableDeliveryOptions | string[] | List of delivery options guids |
DeliveryModel
| Property | Type | Description |
|---|---|---|
| deliveryId | string | Delivery Id |
| deliveryOptionId | string | Delivery option Id |
| quotedPrice | Money | Quoted price |
PostalDeliveryModel : DeliveryModel
| Property | Type | Description |
|---|---|---|
| address | ServerSideAddress | Address |
| firstName | string | First name |
| lastName | string | Last name |
EmailDeliveryModel : DeliveryModel
| Property | Type | Description |
|---|---|---|
| string |
DeliveryOption
| Property | Type | Description |
|---|---|---|
| deliveryOptionId | string | Delivery option guid |
| excludeCountries | string[] | List of excluded countries |
| includeCountries | string[] | List of included countries |
| kind | DeliveryKind enum | Kind (possible values: 'OnSite' |
| name | string | Name |
| retailPrice | Money | Retail price |
ServerSideAddress
| Property | Type | Description |
|---|---|---|
| line1 | string | Line 1 |
| line2 | string | Line 2 |
| city | string | City |
| postcode | string | Postcode |
| region | string | Region |
| country | string | Country |
PaymentOptionShortModel
| Property | Type | Description |
|---|---|---|
| id | string | Guid |
| kind | PaymentOptionKind enum | Kind (possible values: 'SagePay' |
PersonalMessage
| Property | Type | Description |
|---|---|---|
| to | string | Message to |
| message | string | Message text |
OrderModel
| Property | Type | Description |
|---|---|---|
| orderId | string | Guid |
| orderNumber | int | Order number |
| orderVersion | long | Order version |
| status | Status enum | Status (possible values: 'Placed' |
| firstName | string | Buyer's first name |
| lastName | string | Buyer's last name |
| string | Buyer's email | |
| phoneNumber | string | Buyer's phone number |
| billingAddress | PostalAddress | Buyer's billing address |
| deliveries | DeliveryModel[] | List of deliveries |
| amountToCharge | Money | Amount to charge |
| orderTotal | Money | Order total |
PostalAddress
| Property | Type | Description |
|---|---|---|
| line1 | string | Line 1 |
| line2 | string | Line 2 (usually city) |
| postcode | string | Postcode |
| region | string | Region |
| country | string | Country - 2 Letter ISO 3166-1 alpha-2 country code |