Required role: | VeoliaAdmin |
POST | /tender |
---|
import java.math.*;
import java.util.*;
import net.servicestack.client.*;
public class dtos
{
public static class AddTender extends TenderBase implements IPost
{
public ProcedureType ProcedureType = null;
public ProcedureType getProcedureType() { return ProcedureType; }
public AddTender setProcedureType(ProcedureType value) { this.ProcedureType = value; return this; }
}
public static class TenderBase
{
public String TenderIdentifier = null;
public TenderType TenderType = null;
public String Subject = null;
public String ProcurementContact = null;
public String ProcurementContactEmail = null;
public String ProcurementContactPhone = null;
public String ProfessionalContact = null;
public String ProfessionalContactEmail = null;
public String ProfessionalContactPhone = null;
public String Result = null;
public TenderStatus Status = null;
public String getTenderIdentifier() { return TenderIdentifier; }
public TenderBase setTenderIdentifier(String value) { this.TenderIdentifier = value; return this; }
public TenderType getTenderType() { return TenderType; }
public TenderBase setTenderType(TenderType value) { this.TenderType = value; return this; }
public String getSubject() { return Subject; }
public TenderBase setSubject(String value) { this.Subject = value; return this; }
public String getProcurementContact() { return ProcurementContact; }
public TenderBase setProcurementContact(String value) { this.ProcurementContact = value; return this; }
public String getProcurementContactEmail() { return ProcurementContactEmail; }
public TenderBase setProcurementContactEmail(String value) { this.ProcurementContactEmail = value; return this; }
public String getProcurementContactPhone() { return ProcurementContactPhone; }
public TenderBase setProcurementContactPhone(String value) { this.ProcurementContactPhone = value; return this; }
public String getProfessionalContact() { return ProfessionalContact; }
public TenderBase setProfessionalContact(String value) { this.ProfessionalContact = value; return this; }
public String getProfessionalContactEmail() { return ProfessionalContactEmail; }
public TenderBase setProfessionalContactEmail(String value) { this.ProfessionalContactEmail = value; return this; }
public String getProfessionalContactPhone() { return ProfessionalContactPhone; }
public TenderBase setProfessionalContactPhone(String value) { this.ProfessionalContactPhone = value; return this; }
public String getResult() { return Result; }
public TenderBase setResult(String value) { this.Result = value; return this; }
public TenderStatus getStatus() { return Status; }
public TenderBase setStatus(TenderStatus value) { this.Status = value; return this; }
}
public static enum TenderType
{
@SerializedName("0") Private(0),
@SerializedName("1") Public(1);
private final int value;
TenderType(final int intValue) { value = intValue; }
public int getValue() { return value; }
}
public static enum TenderStatus
{
@SerializedName("0") FirstRound(0),
@SerializedName("1") SecondRound(1),
@SerializedName("2") ThirdRound(2),
@SerializedName("3") Successful(3),
@SerializedName("4") UnSuccessful(4),
@SerializedName("5") Revoked(5);
private final int value;
TenderStatus(final int intValue) { value = intValue; }
public int getValue() { return value; }
}
public static enum ProcedureType
{
@SerializedName("0") Competition(0),
@SerializedName("1") Simplified(1);
private final int value;
ProcedureType(final int intValue) { value = intValue; }
public int getValue() { return value; }
}
public static class ModifyEntityResponse extends ResponseBase
{
public Integer Id = null;
public Integer getId() { return Id; }
public ModifyEntityResponse setId(Integer value) { this.Id = value; return this; }
}
public static class ResponseBase
{
public ResponseStatus ResponseStatus = null;
public ResponseStatus getResponseStatus() { return ResponseStatus; }
public ResponseBase setResponseStatus(ResponseStatus value) { this.ResponseStatus = value; return this; }
}
}
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 /tender HTTP/1.1
Host: szallitoiportal-be.veolia.hu
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length
{
ProcedureType: 0,
TenderIdentifier: String,
TenderType: 0,
Subject: String,
ProcurementContact: String,
ProcurementContactEmail: String,
ProcurementContactPhone: String,
ProfessionalContact: String,
ProfessionalContactEmail: String,
ProfessionalContactPhone: String,
Result: String,
Status: 0
}
HTTP/1.1 200 OK Content-Type: text/jsv Content-Length: length { Id: 0, ResponseStatus: { ErrorCode: String, Message: String, StackTrace: String, Errors: [ { ErrorCode: String, FieldName: String, Message: String, Meta: { String: String } } ], Meta: { String: String } } }