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.
GET /services HTTP/1.1
Host: api.4spaces.io
Accept: application/xml
HTTP/1.1 200 OK
Content-Type: application/xml
Content-Length: length
<ServicesResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/Viviot.Api.ServiceModel.Api.Business">
<ResponseStatus xmlns:d2p1="http://schemas.servicestack.net/types" xmlns="http://schemas.datacontract.org/2004/07/Viviot.Api.ServiceModel.Api.Base">
<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>
<Data xmlns:d2p1="http://schemas.datacontract.org/2004/07/Viviot.Api.ServiceModel.Views.Shared.Service">
<d2p1:ServiceView>
<d2p1:Addons xmlns:d4p1="http://schemas.datacontract.org/2004/07/Viviot.Infrastructure.Dto.Service">
<d4p1:ServiceAddonDto>
<d4p1:ExternalId>String</d4p1:ExternalId>
<d4p1:Id>00000000-0000-0000-0000-000000000000</d4p1:Id>
<d4p1:MaxQuantity>0</d4p1:MaxQuantity>
<d4p1:Name>String</d4p1:Name>
<d4p1:UnitPrice>0</d4p1:UnitPrice>
<d4p1:VATPercentage>0</d4p1:VATPercentage>
</d4p1:ServiceAddonDto>
</d2p1:Addons>
<d2p1:Currency xmlns:d4p1="http://schemas.datacontract.org/2004/07/Integrations.Payment.Responses">
<d4p1:Code>String</d4p1:Code>
<d4p1:Id>00000000-0000-0000-0000-000000000000</d4p1:Id>
<d4p1:Name>String</d4p1:Name>
<d4p1:Symbol>String</d4p1:Symbol>
</d2p1:Currency>
<d2p1:Description>String</d2p1:Description>
<d2p1:Id>00000000-0000-0000-0000-000000000000</d2p1:Id>
<d2p1:ImageUrl>String</d2p1:ImageUrl>
<d2p1:IsPublic>false</d2p1:IsPublic>
<d2p1:Latitude>0</d2p1:Latitude>
<d2p1:Longitude>0</d2p1:Longitude>
<d2p1:Name>String</d2p1:Name>
<d2p1:Organization xmlns:d4p1="http://schemas.datacontract.org/2004/07/Viviot.Infrastructure.Dto.Organization">
<d4p1:Code>String</d4p1:Code>
<d4p1:Id>00000000-0000-0000-0000-000000000000</d4p1:Id>
</d2p1:Organization>
<d2p1:OrganizationId>00000000-0000-0000-0000-000000000000</d2p1:OrganizationId>
<d2p1:PersonOption xmlns:d4p1="http://schemas.datacontract.org/2004/07/Viviot.Infrastructure.Dto.Service">
<d4p1:AdultPriceMultiplier>0</d4p1:AdultPriceMultiplier>
<d4p1:CanSelectChildren>false</d4p1:CanSelectChildren>
<d4p1:ChildPriceMultiplier>0</d4p1:ChildPriceMultiplier>
<d4p1:Id>00000000-0000-0000-0000-000000000000</d4p1:Id>
<d4p1:MaxAdultCount>0</d4p1:MaxAdultCount>
<d4p1:MaxChildrenCount>0</d4p1:MaxChildrenCount>
</d2p1:PersonOption>
<d2p1:Products>
<d2p1:ServiceProductView>
<d2p1:Description>String</d2p1:Description>
<d2p1:ExternalData xmlns:d6p1="http://schemas.datacontract.org/2004/07/Viviot.Infrastructure.Dto.Service">
<d6p1:Id>00000000-0000-0000-0000-000000000000</d6p1:Id>
<d6p1:Latitude>0</d6p1:Latitude>
<d6p1:Longitude>0</d6p1:Longitude>
<d6p1:Rating>0</d6p1:Rating>
<d6p1:ServiceUrl>String</d6p1:ServiceUrl>
</d2p1:ExternalData>
<d2p1:ExternalId xmlns:d6p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
<d6p1:string>String</d6p1:string>
</d2p1:ExternalId>
<d2p1:Id>00000000-0000-0000-0000-000000000000</d2p1:Id>
<d2p1:ImageUrl>String</d2p1:ImageUrl>
<d2p1:MinimalPrice>0</d2p1:MinimalPrice>
<d2p1:Name>String</d2p1:Name>
<d2p1:RequestData xmlns:d6p1="http://schemas.datacontract.org/2004/07/Viviot.Infrastructure.Dto.Service">
<d6p1:AllowComments>false</d6p1:AllowComments>
<d6p1:ApprovedTemplate>String</d6p1:ApprovedTemplate>
<d6p1:DeniedTemplate>String</d6p1:DeniedTemplate>
<d6p1:Id>00000000-0000-0000-0000-000000000000</d6p1:Id>
<d6p1:Options xmlns:d7p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
<d7p1:string>String</d7p1:string>
</d6p1:Options>
<d6p1:ProcessingTemplate>String</d6p1:ProcessingTemplate>
</d2p1:RequestData>
<d2p1:ReservationData xmlns:d6p1="http://schemas.datacontract.org/2004/07/Viviot.Infrastructure.Dto.Service">
<d6p1:AccessTemplateGroupId>00000000-0000-0000-0000-000000000000</d6p1:AccessTemplateGroupId>
<d6p1:AccessTemplateId>00000000-0000-0000-0000-000000000000</d6p1:AccessTemplateId>
<d6p1:AutoAssignAccessTemplate>false</d6p1:AutoAssignAccessTemplate>
<d6p1:Id>00000000-0000-0000-0000-000000000000</d6p1:Id>
</d2p1:ReservationData>
<d2p1:TicketData xmlns:d6p1="http://schemas.datacontract.org/2004/07/Viviot.Infrastructure.Dto.Service">
<d6p1:AccessTemplateId>00000000-0000-0000-0000-000000000000</d6p1:AccessTemplateId>
<d6p1:Id>00000000-0000-0000-0000-000000000000</d6p1:Id>
</d2p1:TicketData>
<d2p1:UnitPrice>0</d2p1:UnitPrice>
<d2p1:VATPercentage>0</d2p1:VATPercentage>
</d2p1:ServiceProductView>
</d2p1:Products>
<d2p1:Providers xmlns:d4p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays">
<d4p1:KeyValueOfstringguid>
<d4p1:Key>String</d4p1:Key>
<d4p1:Value>00000000-0000-0000-0000-000000000000</d4p1:Value>
</d4p1:KeyValueOfstringguid>
</d2p1:Providers>
<d2p1:RequireConfirmation>false</d2p1:RequireConfirmation>
<d2p1:RequirePayment>false</d2p1:RequirePayment>
<d2p1:ServiceType>Reservation</d2p1:ServiceType>
<d2p1:SubTitle>String</d2p1:SubTitle>
<d2p1:TimeOption xmlns:d4p1="http://schemas.datacontract.org/2004/07/Viviot.Infrastructure.Dto.Service">
<d4p1:DailyOptions>
<d4p1:Checkin>PT0S</d4p1:Checkin>
<d4p1:Checkout>PT0S</d4p1:Checkout>
</d4p1:DailyOptions>
<d4p1:Id>00000000-0000-0000-0000-000000000000</d4p1:Id>
<d4p1:TimespanOptions>
<d4p1:Increment>0</d4p1:Increment>
<d4p1:IncrementPriceMultiplier>0</d4p1:IncrementPriceMultiplier>
<d4p1:MaxDuration>0</d4p1:MaxDuration>
<d4p1:MinDuration>0</d4p1:MinDuration>
</d4p1:TimespanOptions>
<d4p1:Type>Daily</d4p1:Type>
</d2p1:TimeOption>
<d2p1:VATPercentage>0</d2p1:VATPercentage>
</d2p1:ServiceView>
</Data>
</ServicesResponse>