| POST | /growplans_boxes |
|---|
import java.math.*;
import java.util.*;
import net.servicestack.client.*;
public class dtos
{
@DataContract
public static class GrowplansBoxesAdd
{
@DataMember(Order=2)
@Validate(Validator="NotNull")
public Long growplansUsersId = null;
@DataMember(Order=3)
public String name = null;
@DataMember(Order=4)
@Validate(Validator="NotNull")
public Integer xAxis = null;
@DataMember(Order=5)
@Validate(Validator="NotNull")
public Integer yAxis = null;
@DataMember(Order=6)
@Validate(Validator="NotNull")
public Long growplansOutcomesId = null;
@DataMember(Order=7)
@Validate(Validator="NotNull")
public Integer months = null;
@DataMember(Order=8)
public Date startDate = null;
public Long getGrowplansUsersId() { return growplansUsersId; }
public GrowplansBoxesAdd setGrowplansUsersId(Long value) { this.growplansUsersId = value; return this; }
public String getName() { return name; }
public GrowplansBoxesAdd setName(String value) { this.name = value; return this; }
public Integer getXAxis() { return xAxis; }
public GrowplansBoxesAdd setXAxis(Integer value) { this.xAxis = value; return this; }
public Integer getYAxis() { return yAxis; }
public GrowplansBoxesAdd setYAxis(Integer value) { this.yAxis = value; return this; }
public Long getGrowplansOutcomesId() { return growplansOutcomesId; }
public GrowplansBoxesAdd setGrowplansOutcomesId(Long value) { this.growplansOutcomesId = value; return this; }
public Integer getMonths() { return months; }
public GrowplansBoxesAdd setMonths(Integer value) { this.months = value; return this; }
public Date getStartDate() { return startDate; }
public GrowplansBoxesAdd setStartDate(Date value) { this.startDate = value; return this; }
}
public static class GrowplansBoxesAddResponse
{
@DataMember(Order=2)
public Long growplansUsersId = null;
@DataMember(Order=3)
public String name = null;
@DataMember(Order=4)
public Integer xAxis = null;
@DataMember(Order=5)
public Integer yAxis = null;
@DataMember(Order=6)
public Long growplansOutcomesId = null;
@DataMember(Order=7)
public Integer months = null;
@DataMember(Order=8)
public Date startDate = null;
@DataMember(Order=10)
public ResponseStatus responseStatus = null;
public Long getGrowplansUsersId() { return growplansUsersId; }
public GrowplansBoxesAddResponse setGrowplansUsersId(Long value) { this.growplansUsersId = value; return this; }
public String getName() { return name; }
public GrowplansBoxesAddResponse setName(String value) { this.name = value; return this; }
public Integer getXAxis() { return xAxis; }
public GrowplansBoxesAddResponse setXAxis(Integer value) { this.xAxis = value; return this; }
public Integer getYAxis() { return yAxis; }
public GrowplansBoxesAddResponse setYAxis(Integer value) { this.yAxis = value; return this; }
public Long getGrowplansOutcomesId() { return growplansOutcomesId; }
public GrowplansBoxesAddResponse setGrowplansOutcomesId(Long value) { this.growplansOutcomesId = value; return this; }
public Integer getMonths() { return months; }
public GrowplansBoxesAddResponse setMonths(Integer value) { this.months = value; return this; }
public Date getStartDate() { return startDate; }
public GrowplansBoxesAddResponse setStartDate(Date value) { this.startDate = value; return this; }
public ResponseStatus getResponseStatus() { return responseStatus; }
public GrowplansBoxesAddResponse setResponseStatus(ResponseStatus value) { this.responseStatus = value; return this; }
}
}
To override the Content-type in your clients, use the HTTP Accept Header, append the .other suffix or ?format=other
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /growplans_boxes HTTP/1.1
Host: sfgboxapi.dev.scadsoftware.com
Accept: text/jsonl
Content-Type: text/jsonl
Content-Length: length
{"growplansUsersId":0,"name":"String","xAxis":0,"yAxis":0,"growplansOutcomesId":0,"months":0,"startDate":"\/Date(-62135596800000-0000)\/"}
HTTP/1.1 200 OK
Content-Type: text/jsonl
Content-Length: length
{"growplansUsersId":0,"name":"String","xAxis":0,"yAxis":0,"growplansOutcomesId":0,"months":0,"startDate":"\/Date(-62135596800000-0000)\/","responseStatus":{"errorCode":"String","message":"String","stackTrace":"String","errors":[{"errorCode":"String","fieldName":"String","message":"String","meta":{"String":"String"}}],"meta":{"String":"String"}}}