BokaMera.API.Host

<back to all web services

CreateBookings

The following routes are available for this service:
POST/bookings/repeatCreate new bookingsCreate new bookings if you are authorized to do so.
import java.math.*
import java.util.*
import net.servicestack.client.*


@ApiResponse(Description="You were unauthorized to call this service", StatusCode=401)
open class CreateBookings : CreateBookingBase()
{
    /**
    * Set the dates you want to book and it's quantities. It's an array of dates and quantities.
    */
    @ApiMember(DataType="List<DatesToRepeat>", Description="Set the dates you want to book and it's quantities. It's an array of dates and quantities.", IsRequired=true)
    var DatesToRepeat:ArrayList<DatesToRepeat> = ArrayList<DatesToRepeat>()
}

open class CreateBookingBase
{
    /**
    * The company id, if empty will use the company id for the user you are logged in with.
    */
    @ApiMember(Description="The company id, if empty will use the company id for the user you are logged in with.")
    var CompanyId:UUID? = null

    /**
    * If you want to book on an existing customer instead of CustomerToBook info set the CustomerId here. Set Empty Guid (00000000-0000-0000-0000-000000000000) if you want to book without any customer, this is only allowed by admin. The customer id is shown in the customer list named as id. When booking as customer (no admin) leave this field blank.
    */
    @ApiMember(Description="If you want to book on an existing customer instead of CustomerToBook info set the CustomerId here. Set Empty Guid (00000000-0000-0000-0000-000000000000) if you want to book without any customer, this is only allowed by admin. The customer id is shown in the customer list named as id. When booking as customer (no admin) leave this field blank.")
    var CustomerId:UUID? = null

    /**
    * If company requires to be authenticated or a pin code entered to book on a specific customer, enter it here.
    */
    @ApiMember(Description="If company requires to be authenticated or a pin code entered to book on a specific customer, enter it here.")
    var PinCode:String? = null

    /**
    * If you want to book with customer information instead of the Customer Id send the customer information here. Note: If customer profile already exists with the same email the information will not be changed, instead the provided information will be added as BookingsComments if it differs from the ordinairy profile. 
    */
    @ApiMember(Description="If you want to book with customer information instead of the Customer Id send the customer information here. Note: If customer profile already exists with the same email the information will not be changed, instead the provided information will be added as BookingsComments if it differs from the ordinairy profile. ")
    var Customer:CustomerToHandle? = null

    /**
    * The service to be booked
    */
    @ApiMember(Description="The service to be booked", IsRequired=true)
    var ServiceId:Int? = null

    /**
    * If you want to add comments to a booking you can add them here, this comments are never shared with the customer
    */
    @ApiMember(Description="If you want to add comments to a booking you can add them here, this comments are never shared with the customer")
    var BookedComments:String? = null

    /**
    * If you want to add comments to the booking that is sent to the customer, you can add them here. Comments will be sent in the booking confirmation
    */
    @ApiMember(Description="If you want to add comments to the booking that is sent to the customer, you can add them here. Comments will be sent in the booking confirmation")
    var CommentsToCustomer:String? = null

    var Resources:ArrayList<ResourceToBook> = ArrayList<ResourceToBook>()
    /**
    * Rebate codes applied to booking
    */
    @ApiMember(Description="Rebate codes applied to booking")
    var RebateCodeIds:ArrayList<Int> = ArrayList<Int>()

    /**
    * If you want to send Email reminder
    */
    @ApiMember(Description="If you want to send Email reminder")
    var SendEmailReminder:Boolean? = null

    /**
    * If you want to send SMS reminder
    */
    @ApiMember(Description="If you want to send SMS reminder")
    var SendSmsReminder:Boolean? = null

    /**
    * If you want to send SMS confirmation
    */
    @ApiMember(Description="If you want to send SMS confirmation")
    var SendSmsConfirmation:Boolean? = null

    /**
    * Only admins are allowed to not send an email confirmation. Default is true
    */
    @ApiMember(Description="Only admins are allowed to not send an email confirmation. Default is true")
    var SendEmailConfirmation:Boolean? = null

    /**
    * If payment is enabled and you're an administrator, optional to choose payment option, if empty then the default settings will be used. Following payment options exists. DefaultSetting = 0, BookWithoutPayment = 1 (will be direcyly booked without payment), BookWithPaymentMessageToCustomer = 2 (will set status AwaitingPayment and send payment instructions to customer), BookWithManualPayment = 3 (Will set status AwaitingPaymentNoTimeLimit and Admin will need to manually mark the booking as payed when recieved payment).
    */
    @ApiMember(Description="If payment is enabled and you're an administrator, optional to choose payment option, if empty then the default settings will be used. Following payment options exists. DefaultSetting = 0, BookWithoutPayment = 1 (will be direcyly booked without payment), BookWithPaymentMessageToCustomer = 2 (will set status AwaitingPayment and send payment instructions to customer), BookWithManualPayment = 3 (Will set status AwaitingPaymentNoTimeLimit and Admin will need to manually mark the booking as payed when recieved payment).")
    var PaymentOption:PaymentOptions? = null

    /**
    * If Custom Fields are added to the booking, here you will send the id and the value for each custom field to be saved
    */
    @ApiMember(Description="If Custom Fields are added to the booking, here you will send the id and the value for each custom field to be saved")
    var CustomFields:ArrayList<AddCustomField> = ArrayList<AddCustomField>()

    /**
    * If Custom Fields are added to the customer, here you will send the id and the value for each custom field to be updated
    */
    @ApiMember(Description="If Custom Fields are added to the customer, here you will send the id and the value for each custom field to be updated")
    var CustomerCustomFields:ArrayList<AddCustomField> = ArrayList<AddCustomField>()

    /**
    * If want to allow to book outside the service schedules. This means you can book a time after the schedule opening hours as long as the resource are available. This is only allowed by administrators
    */
    @ApiMember(Description="If want to allow to book outside the service schedules. This means you can book a time after the schedule opening hours as long as the resource are available. This is only allowed by administrators")
    var AllowBookingOutsideSchedules:Boolean? = null
}

open class CustomerToHandle
{
    var CustomerId:UUID? = null
    var Firstname:String? = null
    var Lastname:String? = null
    var Email:String? = null
    var Phone:String? = null
    var SubscribedToNewsletter:Boolean? = null
}

open class ResourceToBook
{
    var ResourceTypeId:Int? = null
    var ResourceId:Int? = null
}

enum class PaymentOptions
{
    DefaultSetting,
    BookWithoutPayment,
    BookWithPaymentMessageToCustomer,
    BookWithManualPayment,
}

open class AddCustomField
{
    var Id:Int? = null
    var Value:String? = null
}

open class DatesToRepeat : IInterval
{
    /**
    * Booking start
    */
    @ApiMember(Description="Booking start")
    var From:Date? = null

    /**
    * Booking end
    */
    @ApiMember(Description="Booking end")
    var To:Date? = null

    /**
    * Set the number of spots you want to book. You add number of spots per price category. Multiple spots require that the service has GroupBooking enabled. Default is one spot.
    */
    @ApiMember(Description="Set the number of spots you want to book. You add number of spots per price category. Multiple spots require that the service has GroupBooking enabled. Default is one spot.")
    var Quantities:ArrayList<QuantityToBook>? = null
}

open class QuantityToBook
{
    /**
    * If service has a price, enter the price id for that price. If no price exists for the service set 0 as PriceId. If you put 0 and a price exists, it will use that price (only works if just one price exists for the current selected date to book)
    */
    @ApiMember(Description="If service has a price, enter the price id for that price. If no price exists for the service set 0 as PriceId. If you put 0 and a price exists, it will use that price (only works if just one price exists for the current selected date to book)", IsRequired=true)
    var PriceId:Int? = null

    /**
    * Set the number of spots or resources you want to book on the specific price category
    */
    @ApiMember(Description="Set the number of spots or resources you want to book on the specific price category", IsRequired=true)
    var Quantity:Int? = null

    /**
    * If the quantity you add should occupy a spot. Default is true. If no it will only be a row that includes price information.
    */
    @ApiMember(Description="If the quantity you add should occupy a spot. Default is true. If no it will only be a row that includes price information.")
    var OccupiesSpot:Boolean? = null
}

open class CreateBookingsResponse
{
    /**
    * The datetime you want to end the booking.
    */
    @ApiMember(Description="The datetime you want to end the booking.", IsRequired=true)
    var Created:ArrayList<BookingQueryResponse> = ArrayList<BookingQueryResponse>()

    /**
    * The dates that didn't work to book.
    */
    @ApiMember(Description="The dates that didn't work to book.", IsRequired=true)
    var Failed:ArrayList<FailedBookings> = ArrayList<FailedBookings>()

    var ResponseStatus:ResponseStatus? = null
}

open class BookingQueryResponse
{
    var Id:Int? = null
    var CompanyId:UUID? = null
    var From:Date? = null
    var To:Date? = null
    var Status:BookingStatusEnum? = null
    var StatusId:Int? = null
    var StatusName:String? = null
    var StatusInfo:BookingStatusQueryResponse? = null
    var SendEmailReminder:Boolean? = null
    var SendSmsReminder:Boolean? = null
    var SendSmsConfirmation:Boolean? = null
    var SendEmailConfirmation:Boolean? = null
    var LastTimeToUnBook:Date? = null
    var CustomFields:ArrayList<CustomFieldConfigData> = ArrayList<CustomFieldConfigData>()
    var CustomFieldValues:ArrayList<CustomFieldDataResponse> = ArrayList<CustomFieldDataResponse>()
    var BookedResourceTypes:ArrayList<BookedResourceType> = ArrayList<BookedResourceType>()
    var Company:BookedCompany? = null
    var Customer:BookedCustomer? = null
    var Quantities:ArrayList<BookedQuantity> = ArrayList<BookedQuantity>()
    var Service:ServiceInfoResponse? = null
    var PaymentExpiration:Date? = null
    var Log:ArrayList<BookingLogQueryResponse> = ArrayList<BookingLogQueryResponse>()
    var PaymentLog:ArrayList<BookingPaymentLogQueryResponse> = ArrayList<BookingPaymentLogQueryResponse>()
    var CheckoutLog:ArrayList<BookingCheckoutQueryResponse> = ArrayList<BookingCheckoutQueryResponse>()
    var ExternalReference:ArrayList<ExternalReferenceResponse> = ArrayList<ExternalReferenceResponse>()
    var ResponseStatus:ResponseStatus? = null
    var CalendarExportStatus:BookingCalendarExportStatus? = null
    var LengthInMinutes:Int? = null
    var BookedBy:String? = null
    var BookedComments:String? = null
    var UnbookedComments:String? = null
    var CommentsToCustomer:String? = null
    var CreatedDate:Date? = null
    var UpdatedDate:Date? = null
    var UnbookedOn:Date? = null
    var CancellationCode:String? = null
    var RatingCode:String? = null
}

enum class BookingStatusEnum(val value:Int)
{
    Booked(1),
    Unbooked(2),
    Reserved(3),
    Canceled(4),
    AwaitingPayment(5),
    AwaitingPaymentNoTimeLimit(6),
    Payed(7),
    AwaitingPaymentRequestFromAdmin(8),
    AwaitingPaymentFromProvider(9),
    Invoiced(10),
}

open class BookingStatusQueryResponse
{
    var Id:Int? = null
    var Name:String? = null
    var Description:String? = null
    var Icon:String? = null
    var Color:String? = null
}

open class CustomFieldConfigData
{
    /**
    * Custom field id
    */
    @ApiMember(Description="Custom field id")
    var Id:Int? = null

    /**
    * Configuration name. Example: 'Number of persons'.
    */
    @ApiMember(Description="Configuration name. Example: 'Number of persons'.")
    var Name:String? = null

    /**
    * Custom field description. Example: 'For how many persons is this booking?'
    */
    @ApiMember(Description="Custom field description. Example: 'For how many persons is this booking?'")
    var Description:String? = null

    /**
    * Field width. Example: 20 for 20px
    */
    @ApiMember(Description="Field width. Example: 20 for 20px")
    var Width:Int? = null

    /**
    * Data field of custom field. Valid values are: TextBox, ... Example: 'TextBox'
    */
    @ApiMember(Description="Data field of custom field. Valid values are: TextBox, ... Example: 'TextBox'")
    var DataType:String? = null

    /**
    * Default value of the field. Example: '3'
    */
    @ApiMember(Description="Default value of the field. Example: '3'")
    var DefaultValue:String? = null

    /**
    * Determines if the field is required to have a value or not
    */
    @ApiMember(Description="Determines if the field is required to have a value or not")
    var IsMandatory:Boolean? = null

    /**
    * Error message shown to the user if the field data is required but not entered
    */
    @ApiMember(Description="Error message shown to the user if the field data is required but not entered")
    var MandatoryErrorMessage:String? = null

    /**
    * Max lenght of the field
    */
    @ApiMember(Description="Max lenght of the field")
    var MaxLength:Int? = null

    /**
    * If the field should have multiple lines
    */
    @ApiMember(Description="If the field should have multiple lines")
    var MultipleLineText:Boolean? = null

    /**
    * Regular expression used for validation of the field
    */
    @ApiMember(Description="Regular expression used for validation of the field")
    var RegEx:String? = null

    /**
    * Error message shown if the regular expression validation failed
    */
    @ApiMember(Description="Error message shown if the regular expression validation failed")
    var RegExErrorMessage:String? = null

    /**
    * The values to select from if Datatype is DropDown for this custom field
    */
    @ApiMember(Description="The values to select from if Datatype is DropDown for this custom field")
    var Values:ArrayList<CustomFieldValueResponse> = ArrayList<CustomFieldValueResponse>()
}

open class CustomFieldValueResponse
{
    var Value:String? = null
}

open class CustomFieldDataResponse
{
    var Id:Int? = null
    var Column:String? = null
    var Name:String? = null
    var Description:String? = null
    var Value:String? = null
    /**
    * Data field of custom field. Valid values are: TextBox, ... Example: 'TextBox'
    */
    @ApiMember(Description="Data field of custom field. Valid values are: TextBox, ... Example: 'TextBox'")
    var DataType:String? = null
}

open class BookedResourceType
{
    /**
    * The resource type id
    */
    @ApiMember(Description="The resource type id")
    var Id:Int? = null

    /**
    * The resource type name
    */
    @ApiMember(Description="The resource type name")
    var Name:String? = null

    /**
    * The resources inside resource type
    */
    @ApiMember(Description="The resources inside resource type")
    var Resources:ArrayList<BookedResource> = ArrayList<BookedResource>()
}

open class BookedResource
{
    var Id:Int? = null
    var Name:String? = null
    var Color:String? = null
    var ImageUrl:Uri? = null
    var Email:String? = null
    var MobilePhone:String? = null
    var AccessGroup:String? = null
    var EmailNotification:Boolean? = null
    var SMSNotification:Boolean? = null
    var EmailReminder:Boolean? = null
    var SMSReminder:Boolean? = null
}

open class BookedCompany
{
    var Id:UUID? = null
    var Name:String? = null
    var LogoType:Uri? = null
    var Category:String? = null
    var Street1:String? = null
    var Street2:String? = null
    var ZipCode:String? = null
    var City:String? = null
    var CountryId:String? = null
    var Longitude:String? = null
    var Latitude:String? = null
    var Phone:String? = null
    var Email:String? = null
    var HomePage:String? = null
    var SitePath:String? = null
    var IsFavorite:Boolean? = null
    var PaymentProviderId:Int? = null
}

open class BookedCustomer
{
    var Id:UUID? = null
    var Firstname:String? = null
    var Lastname:String? = null
    var Email:String? = null
    var Phone:String? = null
    var FacebookUserName:String? = null
    var ImageUrl:String? = null
    var CorporateIdentityNumber:String? = null
    var InvoiceAddress1:String? = null
    var InvoiceAddress2:String? = null
    var InvoiceCity:String? = null
    var InvoicePostalCode:String? = null
    var InvoiceCountryCode:String? = null
}

open class BookedQuantity
{
    /**
    * The quantity Id
    */
    @ApiMember(Description="The quantity Id")
    var Id:Int? = null

    /**
    * The quantity for booked on this price category
    */
    @ApiMember(Description="The quantity for booked on this price category")
    var Quantity:Int? = null

    /**
    * The price
    */
    @ApiMember(Description="The price")
    var Price:Double? = null

    /**
    * The price bofore rebate codes
    */
    @ApiMember(Description="The price bofore rebate codes")
    var PriceBeforeRebate:Double? = null

    /**
    * The price currency
    */
    @ApiMember(Description="The price currency")
    var CurrencyId:String? = null

    /**
    * The price sign
    */
    @ApiMember(Description="The price sign")
    var PriceSign:String? = null

    /**
    * The price category
    */
    @ApiMember(Description="The price category")
    var Category:String? = null

    /**
    * The price VAT in percent
    */
    @ApiMember(Description="The price VAT in percent")
    var VAT:BigDecimal? = null

    /**
    * The price text to display
    */
    @ApiMember(Description="The price text to display")
    var PriceText:String? = null

    /**
    * If the quantity you add should occupy a spot. Default is true. If no it will only be a row that includes price information.
    */
    @ApiMember(Description="If the quantity you add should occupy a spot. Default is true. If no it will only be a row that includes price information.")
    var OccupiesSpot:Boolean? = null
}

open class ServiceInfoResponse
{
    var Id:Int? = null
    var Name:String? = null
    var Description:String? = null
    var ImageUrl:Uri? = null
    var LengthInMinutes:Int? = null
    var MaxNumberOfSpotsPerBooking:Int? = null
    var MinNumberOfSpotsPerBooking:Int? = null
    var GroupBooking:GroupBookingSettings? = null
    var MultipleResource:MultipleResourceSettings? = null
    var IsGroupBooking:Boolean? = null
    var IsPaymentEnabled:Boolean? = null
}

open class GroupBookingSettings
{
    var Active:Boolean? = null
    var Min:Int? = null
    var Max:Int? = null
}

open class MultipleResourceSettings
{
    var Active:Boolean? = null
    var Min:Int? = null
    var Max:Int? = null
}

open class BookingLogQueryResponse
{
    /**
    * The booking log id
    */
    @ApiMember(Description="The booking log id")
    var Id:Int? = null

    /**
    * The booking id
    */
    @ApiMember(Description="The booking id")
    var BookingId:Int? = null

    /**
    * The type of event
    */
    @ApiMember(Description="The type of event")
    var EventTypeId:Int? = null

    /**
    * The type of event
    */
    @ApiMember(Description="The type of event")
    var EventType:BookingLogEventTypeResponse? = null

    /**
    * Comments that could be added to the event log item
    */
    @ApiMember(Description="Comments that could be added to the event log item")
    var Comments:String? = null

    /**
    * The user created the event
    */
    @ApiMember(Description="The user created the event")
    var UserName:String? = null

    /**
    * Then date when the event occured
    */
    @ApiMember(Description="Then date when the event occured")
    var Created:Date? = null
}

open class BookingLogEventTypeResponse
{
    /**
    * The event type id
    */
    @ApiMember(Description="The event type id")
    var Id:Int? = null

    /**
    * The event type name
    */
    @ApiMember(Description="The event type name")
    var Name:String? = null

    /**
    * The event type description
    */
    @ApiMember(Description="The event type description")
    var Description:String? = null
}

open class BookingPaymentLogQueryResponse
{
    /**
    * The booking payment log id
    */
    @ApiMember(Description="The booking payment log id")
    var Id:Int? = null

    /**
    * The booking id
    */
    @ApiMember(Description="The booking id")
    var BookingId:Int? = null

    /**
    * The payment reference id
    */
    @ApiMember(Description="The payment reference id")
    var PaymentReferenceId:String? = null

    /**
    * The payment order item reference id
    */
    @ApiMember(Description="The payment order item reference id")
    var OrderItemReferenceId:String? = null

    /**
    * The payment reference id
    */
    @ApiMember(Description="The payment reference id")
    var PaymentProviderId:Int? = null

    /**
    * The payment amount
    */
    @ApiMember(Description="The payment amount")
    var Amount:Double? = null

    /**
    * The payment VAT in percent
    */
    @ApiMember(Description="The payment VAT in percent")
    var VAT:BigDecimal? = null

    /**
    * The payment amount that is credited
    */
    @ApiMember(Description="The payment amount that is credited")
    var AmountCredited:Double? = null

    /**
    * The payment currency id
    */
    @ApiMember(Description="The payment currency id")
    var CurrencyId:String? = null

    /**
    * The payment currency info
    */
    @ApiMember(Description="The payment currency info")
    var CurrencyInfo:CurrencyInfoResponse? = null

    /**
    * Comments that could be added to the event log item
    */
    @ApiMember(Description="Comments that could be added to the event log item")
    var Comments:String? = null

    /**
    * The date when the payment items was created
    */
    @ApiMember(Description="The date when the payment items was created")
    var Created:Date? = null

    /**
    * The date when the payment items was update
    */
    @ApiMember(Description="The date when the payment items was update")
    var Updated:Date? = null
}

open class CurrencyInfoResponse
{
    /**
    * The currency id
    */
    @ApiMember(Description="The currency id")
    var Id:String? = null

    /**
    * The currency id
    */
    @ApiMember(Description="The currency id")
    var Name:String? = null

    /**
    * The currency id
    */
    @ApiMember(Description="The currency id")
    var CurrencySign:String? = null
}

open class BookingCheckoutQueryResponse
{
    /**
    * The checkout id
    */
    @ApiMember(Description="The checkout id")
    var Id:UUID? = null

    /**
    * The booking id
    */
    @ApiMember(Description="The booking id")
    var BookingId:Int? = null

    /**
    * The purchase id
    */
    @ApiMember(Description="The purchase id")
    var PurchaseId:Int? = null

    /**
    * The payment checkout expiration datetime
    */
    @ApiMember(Description="The payment checkout expiration datetime")
    var ExpirationTime:Date? = null

    /**
    * The payment snippet code
    */
    @ApiMember(Description="The payment snippet code")
    var Snippet:String? = null

    /**
    * The payment status
    */
    @ApiMember(Description="The payment status")
    var Status:String? = null

    /**
    * Log message
    */
    @ApiMember(Description="Log message")
    var Message:String? = null

    /**
    * When the checkout log item was created
    */
    @ApiMember(Description="When the checkout log item was created")
    var Created:Date? = null

    /**
    * When the checkout log item was updated
    */
    @ApiMember(Description="When the checkout log item was updated")
    var Updated:Date? = null
}

open class ExternalReferenceResponse
{
    var CompanyId:UUID? = null
    var Id:UUID? = null
    var OwnerId:UUID? = null
    var ReferenceType:String? = null
    var ExternalData:String? = null
    var CreatedBy:String? = null
    var Updated:Date? = null
    var Created:Date? = null
}

open class BookingCalendarExportStatus
{
    var CalendarId:String? = null
    var BookingId:Int? = null
    var Synced:Boolean? = null
}

open class FailedBookings
{
    var From:Date? = null
    var To:Date? = null
    var Reason:String? = null
    /**
    * Set the number of spots you want to book. You add number of spots per price category. Multiple spots require that the service has GroupBooking enabled. Default is one spot.
    */
    @ApiMember(Description="Set the number of spots you want to book. You add number of spots per price category. Multiple spots require that the service has GroupBooking enabled. Default is one spot.")
    var Quantities:ArrayList<QuantityToBook>? = null
}

Kotlin CreateBookings DTOs

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

HTTP + XML

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

POST /bookings/repeat HTTP/1.1 
Host: api.bokamera.se 
Accept: application/xml
Content-Type: application/xml
Content-Length: length

<CreateBookings xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/BokaMera.API.ServiceModel.Dtos">
  <AllowBookingOutsideSchedules>false</AllowBookingOutsideSchedules>
  <BookedComments>String</BookedComments>
  <CommentsToCustomer>String</CommentsToCustomer>
  <CompanyId>00000000-0000-0000-0000-000000000000</CompanyId>
  <CustomFields>
    <AddCustomField>
      <Id>0</Id>
      <Value>String</Value>
    </AddCustomField>
  </CustomFields>
  <Customer>
    <CustomerId>00000000-0000-0000-0000-000000000000</CustomerId>
    <Email>String</Email>
    <Firstname>String</Firstname>
    <Lastname>String</Lastname>
    <Phone>String</Phone>
    <SubscribedToNewsletter>false</SubscribedToNewsletter>
  </Customer>
  <CustomerCustomFields>
    <AddCustomField>
      <Id>0</Id>
      <Value>String</Value>
    </AddCustomField>
  </CustomerCustomFields>
  <CustomerId>00000000-0000-0000-0000-000000000000</CustomerId>
  <PaymentOption>DefaultSetting</PaymentOption>
  <PinCode>String</PinCode>
  <RebateCodeIds xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
    <d2p1:int>0</d2p1:int>
  </RebateCodeIds>
  <Resources>
    <ResourceToBook>
      <ResourceId>0</ResourceId>
      <ResourceTypeId>0</ResourceTypeId>
    </ResourceToBook>
  </Resources>
  <SendEmailConfirmation>false</SendEmailConfirmation>
  <SendEmailReminder>false</SendEmailReminder>
  <SendSmsConfirmation>false</SendSmsConfirmation>
  <SendSmsReminder>false</SendSmsReminder>
  <ServiceId>0</ServiceId>
  <DatesToRepeat>
    <DatesToRepeat>
      <From>0001-01-01T00:00:00</From>
      <Quantities>
        <QuantityToBook>
          <OccupiesSpot>false</OccupiesSpot>
          <PriceId>0</PriceId>
          <Quantity>0</Quantity>
        </QuantityToBook>
      </Quantities>
      <To>0001-01-01T00:00:00</To>
    </DatesToRepeat>
  </DatesToRepeat>
</CreateBookings>
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length

<CreateBookingsResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/BokaMera.API.ServiceModel.Dtos">
  <Created>
    <BookingQueryResponse>
      <BookedBy>String</BookedBy>
      <BookedComments>String</BookedComments>
      <BookedResourceTypes>
        <BookedResourceType>
          <Id>0</Id>
          <Name>String</Name>
          <Resources>
            <BookedResource>
              <AccessGroup>String</AccessGroup>
              <Color>String</Color>
              <Email>String</Email>
              <EmailNotification>false</EmailNotification>
              <EmailReminder>false</EmailReminder>
              <Id>0</Id>
              <ImageUrl i:nil="true" />
              <MobilePhone>String</MobilePhone>
              <Name>String</Name>
              <SMSNotification>false</SMSNotification>
              <SMSReminder>false</SMSReminder>
            </BookedResource>
          </Resources>
        </BookedResourceType>
      </BookedResourceTypes>
      <CalendarExportStatus>
        <BookingId>0</BookingId>
        <CalendarId>String</CalendarId>
        <Synced>false</Synced>
      </CalendarExportStatus>
      <CancellationCode>String</CancellationCode>
      <CheckoutLog>
        <BookingCheckoutQueryResponse>
          <BookingId>0</BookingId>
          <Created>0001-01-01T00:00:00</Created>
          <ExpirationTime>0001-01-01T00:00:00</ExpirationTime>
          <Id>00000000-0000-0000-0000-000000000000</Id>
          <Message>String</Message>
          <PurchaseId>0</PurchaseId>
          <Snippet>String</Snippet>
          <Status>String</Status>
          <Updated>0001-01-01T00:00:00</Updated>
        </BookingCheckoutQueryResponse>
      </CheckoutLog>
      <CommentsToCustomer>String</CommentsToCustomer>
      <Company>
        <Category>String</Category>
        <City>String</City>
        <CountryId>String</CountryId>
        <Email>String</Email>
        <HomePage>String</HomePage>
        <Id>00000000-0000-0000-0000-000000000000</Id>
        <IsFavorite>false</IsFavorite>
        <Latitude>String</Latitude>
        <LogoType i:nil="true" />
        <Longitude>String</Longitude>
        <Name>String</Name>
        <PaymentProviderId>0</PaymentProviderId>
        <Phone>String</Phone>
        <SitePath>String</SitePath>
        <Street1>String</Street1>
        <Street2>String</Street2>
        <ZipCode>String</ZipCode>
      </Company>
      <CompanyId>00000000-0000-0000-0000-000000000000</CompanyId>
      <CreatedDate>0001-01-01T00:00:00</CreatedDate>
      <CustomFieldValues>
        <CustomFieldDataResponse>
          <Column>String</Column>
          <DataType>String</DataType>
          <Description>String</Description>
          <Id>0</Id>
          <Name>String</Name>
          <Value>String</Value>
        </CustomFieldDataResponse>
      </CustomFieldValues>
      <CustomFields>
        <CustomFieldConfigData>
          <DataType>String</DataType>
          <DefaultValue>String</DefaultValue>
          <Description>String</Description>
          <Id>0</Id>
          <IsMandatory>false</IsMandatory>
          <MandatoryErrorMessage>String</MandatoryErrorMessage>
          <MaxLength>0</MaxLength>
          <MultipleLineText>false</MultipleLineText>
          <Name>String</Name>
          <RegEx>String</RegEx>
          <RegExErrorMessage>String</RegExErrorMessage>
          <Values>
            <CustomFieldValueResponse>
              <Value>String</Value>
            </CustomFieldValueResponse>
          </Values>
          <Width>0</Width>
        </CustomFieldConfigData>
      </CustomFields>
      <Customer>
        <CorporateIdentityNumber>String</CorporateIdentityNumber>
        <Email>String</Email>
        <FacebookUserName>String</FacebookUserName>
        <Firstname>String</Firstname>
        <Id>00000000-0000-0000-0000-000000000000</Id>
        <ImageUrl>String</ImageUrl>
        <InvoiceAddress1>String</InvoiceAddress1>
        <InvoiceAddress2>String</InvoiceAddress2>
        <InvoiceCity>String</InvoiceCity>
        <InvoiceCountryCode>String</InvoiceCountryCode>
        <InvoicePostalCode>String</InvoicePostalCode>
        <Lastname>String</Lastname>
        <Phone>String</Phone>
      </Customer>
      <ExternalReference>
        <ExternalReferenceResponse>
          <CompanyId>00000000-0000-0000-0000-000000000000</CompanyId>
          <Created>0001-01-01T00:00:00</Created>
          <CreatedBy>String</CreatedBy>
          <ExternalData>String</ExternalData>
          <Id>00000000-0000-0000-0000-000000000000</Id>
          <OwnerId>00000000-0000-0000-0000-000000000000</OwnerId>
          <ReferenceType>String</ReferenceType>
          <Updated>0001-01-01T00:00:00</Updated>
        </ExternalReferenceResponse>
      </ExternalReference>
      <From>0001-01-01T00:00:00</From>
      <Id>0</Id>
      <LastTimeToUnBook>0001-01-01T00:00:00</LastTimeToUnBook>
      <LengthInMinutes>0</LengthInMinutes>
      <Log>
        <BookingLogQueryResponse>
          <BookingId>0</BookingId>
          <Comments>String</Comments>
          <Created>0001-01-01T00:00:00</Created>
          <EventType>
            <Description>String</Description>
            <Id>0</Id>
            <Name>String</Name>
          </EventType>
          <EventTypeId>0</EventTypeId>
          <Id>0</Id>
          <UserName>String</UserName>
        </BookingLogQueryResponse>
      </Log>
      <PaymentExpiration>0001-01-01T00:00:00</PaymentExpiration>
      <PaymentLog>
        <BookingPaymentLogQueryResponse>
          <Amount>0</Amount>
          <AmountCredited>0</AmountCredited>
          <BookingId>0</BookingId>
          <Comments>String</Comments>
          <Created>0001-01-01T00:00:00</Created>
          <CurrencyId>String</CurrencyId>
          <CurrencyInfo>
            <CurrencySign>String</CurrencySign>
            <Id>String</Id>
            <Name>String</Name>
          </CurrencyInfo>
          <Id>0</Id>
          <OrderItemReferenceId>String</OrderItemReferenceId>
          <PaymentProviderId>0</PaymentProviderId>
          <PaymentReferenceId>String</PaymentReferenceId>
          <Updated>0001-01-01T00:00:00</Updated>
          <VAT>0</VAT>
        </BookingPaymentLogQueryResponse>
      </PaymentLog>
      <Quantities>
        <BookedQuantity>
          <Category>String</Category>
          <CurrencyId>String</CurrencyId>
          <Id>0</Id>
          <OccupiesSpot>false</OccupiesSpot>
          <Price>0</Price>
          <PriceBeforeRebate>0</PriceBeforeRebate>
          <PriceSign>String</PriceSign>
          <PriceText>String</PriceText>
          <Quantity>0</Quantity>
          <VAT>0</VAT>
        </BookedQuantity>
      </Quantities>
      <RatingCode>String</RatingCode>
      <ResponseStatus xmlns:d4p1="http://schemas.servicestack.net/types">
        <d4p1:ErrorCode>String</d4p1:ErrorCode>
        <d4p1:Message>String</d4p1:Message>
        <d4p1:StackTrace>String</d4p1:StackTrace>
        <d4p1:Errors>
          <d4p1:ResponseError>
            <d4p1:ErrorCode>String</d4p1:ErrorCode>
            <d4p1:FieldName>String</d4p1:FieldName>
            <d4p1:Message>String</d4p1:Message>
            <d4p1:Meta xmlns:d7p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
              <d7p1:KeyValueOfstringstring>
                <d7p1:Key>String</d7p1:Key>
                <d7p1:Value>String</d7p1:Value>
              </d7p1:KeyValueOfstringstring>
            </d4p1:Meta>
          </d4p1:ResponseError>
        </d4p1:Errors>
        <d4p1:Meta xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
          <d5p1:KeyValueOfstringstring>
            <d5p1:Key>String</d5p1:Key>
            <d5p1:Value>String</d5p1:Value>
          </d5p1:KeyValueOfstringstring>
        </d4p1:Meta>
      </ResponseStatus>
      <SendEmailConfirmation>false</SendEmailConfirmation>
      <SendEmailReminder>false</SendEmailReminder>
      <SendSmsConfirmation>false</SendSmsConfirmation>
      <SendSmsReminder>false</SendSmsReminder>
      <Service>
        <Description>String</Description>
        <GroupBooking>
          <Active>false</Active>
          <Max>0</Max>
          <Min>0</Min>
        </GroupBooking>
        <Id>0</Id>
        <ImageUrl i:nil="true" />
        <IsGroupBooking>false</IsGroupBooking>
        <IsPaymentEnabled>false</IsPaymentEnabled>
        <LengthInMinutes>0</LengthInMinutes>
        <MaxNumberOfSpotsPerBooking>0</MaxNumberOfSpotsPerBooking>
        <MinNumberOfSpotsPerBooking>0</MinNumberOfSpotsPerBooking>
        <MultipleResource>
          <Active>false</Active>
          <Max>0</Max>
          <Min>0</Min>
        </MultipleResource>
        <Name>String</Name>
      </Service>
      <Status>Booked</Status>
      <StatusId>0</StatusId>
      <StatusInfo>
        <Color>String</Color>
        <Description>String</Description>
        <Icon>String</Icon>
        <Id>0</Id>
        <Name>String</Name>
      </StatusInfo>
      <StatusName>String</StatusName>
      <To>0001-01-01T00:00:00</To>
      <UnbookedComments>String</UnbookedComments>
      <UnbookedOn>0001-01-01T00:00:00</UnbookedOn>
      <UpdatedDate>0001-01-01T00:00:00</UpdatedDate>
    </BookingQueryResponse>
  </Created>
  <Failed>
    <FailedBookings>
      <From>0001-01-01T00:00:00</From>
      <Quantities>
        <QuantityToBook>
          <OccupiesSpot>false</OccupiesSpot>
          <PriceId>0</PriceId>
          <Quantity>0</Quantity>
        </QuantityToBook>
      </Quantities>
      <Reason>String</Reason>
      <To>0001-01-01T00:00:00</To>
    </FailedBookings>
  </Failed>
  <ResponseStatus xmlns:d2p1="http://schemas.servicestack.net/types">
    <d2p1:ErrorCode>String</d2p1:ErrorCode>
    <d2p1:Message>String</d2p1:Message>
    <d2p1:StackTrace>String</d2p1:StackTrace>
    <d2p1:Errors>
      <d2p1:ResponseError>
        <d2p1:ErrorCode>String</d2p1:ErrorCode>
        <d2p1:FieldName>String</d2p1:FieldName>
        <d2p1:Message>String</d2p1:Message>
        <d2p1:Meta xmlns:d5p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
          <d5p1:KeyValueOfstringstring>
            <d5p1:Key>String</d5p1:Key>
            <d5p1:Value>String</d5p1:Value>
          </d5p1:KeyValueOfstringstring>
        </d2p1:Meta>
      </d2p1:ResponseError>
    </d2p1:Errors>
    <d2p1:Meta xmlns:d3p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
      <d3p1:KeyValueOfstringstring>
        <d3p1:Key>String</d3p1:Key>
        <d3p1:Value>String</d3p1:Value>
      </d3p1:KeyValueOfstringstring>
    </d2p1:Meta>
  </ResponseStatus>
</CreateBookingsResponse>