| GET | /api/v1/utils/animal-purpose | ||
|---|---|---|---|
| GET | /api/v1/utils/animal-purposes |
import java.math.*;
import java.util.*;
import net.servicestack.client.*;
public class dtos
{
public static class GetAnimalPurposes implements IGet
{
}
public static class GetAnimalPurposesResponse extends BaseResponse
{
public ArrayList<AnimalPurpose> animalPurposes = null;
public ArrayList<AnimalPurpose> getAnimalPurposes() { return animalPurposes; }
public GetAnimalPurposesResponse setAnimalPurposes(ArrayList<AnimalPurpose> value) { this.animalPurposes = value; return this; }
}
public static class BaseResponse
{
public Status status = null;
public Status getStatus() { return status; }
public BaseResponse setStatus(Status value) { this.status = value; return this; }
}
public static class Status
{
public String message = null;
public Integer statusCode = null;
public String getMessage() { return message; }
public Status setMessage(String value) { this.message = value; return this; }
public Integer getStatusCode() { return statusCode; }
public Status setStatusCode(Integer value) { this.statusCode = value; return this; }
}
public static class AnimalPurpose
{
public Integer id = null;
@Required()
@StringLength(50)
public String name = null;
public Integer order = null;
public Integer getId() { return id; }
public AnimalPurpose setId(Integer value) { this.id = value; return this; }
public String getName() { return name; }
public AnimalPurpose setName(String value) { this.name = value; return this; }
public Integer getOrder() { return order; }
public AnimalPurpose setOrder(Integer value) { this.order = 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.
GET /api/v1/utils/animal-purpose HTTP/1.1 Host: pecuario-backend.develsystems.com Accept: text/jsv
HTTP/1.1 200 OK
Content-Type: text/jsv
Content-Length: length
{
animalPurposes:
[
{
id: 0,
name: String,
order: 0
}
]
}