| PUT | /Appointment |
|---|
using System;
using System.Collections;
using System.Collections.Generic;
using System.Runtime.Serialization;
using ServiceStack;
using ServiceStack.DataAnnotations;
using Eras2Amw.Service.Server.ServiceModel.Eras2Client.Order;
using Eras2Amw.Service.Server.ServiceModel.Common;
namespace Eras2Amw.Service.Server.ServiceModel.Common
{
[DataContract]
public partial class Appointment
{
[DataMember(Name="Guid")]
public virtual Guid Guid { get; set; }
[DataMember(Name="Von")]
public virtual DateTime From { get; set; }
[DataMember(Name="Bis")]
public virtual DateTime To { get; set; }
[DataMember(Name="Monteure")]
public virtual IList<AppointmentStoreUser> AppointmentStoreUsers { get; set; }
[DataMember(Name="Nutzeinheiten")]
public virtual IList<AppointmentNutzeinheit> AppointmentNutzeinheiten { get; set; }
}
[DataContract]
public partial class AppointmentNutzeinheit
{
[DataMember(Name="NutzeinheitGuid")]
public virtual Guid NutzeinheitGuid { get; set; }
}
[DataContract]
public partial class AppointmentStoreUser
{
[DataMember(Name="MonteurGuid")]
public virtual Guid StoreUserId { get; set; }
}
}
namespace Eras2Amw.Service.Server.ServiceModel.Eras2Client.Order
{
[DataContract]
public partial class UpdateAppointment
{
[DataMember(Name="Appointment")]
public virtual Appointment Appointment { get; set; }
}
public partial class UpdateAppointmentResponse
{
public virtual ResponseStatus ResponseStatus { get; set; }
}
}
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.
PUT /Appointment HTTP/1.1
Host: demo-servamw.eras-online.de
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length
{
Appointment:
{
Guid: 00000000000000000000000000000000,
Von: 0001-01-01T00:00:00Z,
Bis: 0001-01-01T00:00:00Z
}
}
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length
{
responseStatus:
{
errorCode: String,
message: String,
stackTrace: String,
errors:
[
{
errorCode: String,
fieldName: String,
message: String,
meta:
{
String: String
}
}
],
meta:
{
String: String
}
}
}