| POST | /{Workspace}/UserLocation/{ObjectId} |
|---|
import java.math.*;
import java.util.*;
import net.servicestack.client.*;
public class dtos
{
/**
* Service representing a UserLocation in a workspace.
*/
public static class UserLocation extends Location
{
public String Workspace = null;
public String ObjectId = null;
public String VersionId = null;
public String BasedOn = null;
public UserStatus UserStatus = null;
public String getWorkspace() { return Workspace; }
public UserLocation setWorkspace(String value) { this.Workspace = value; return this; }
public String getObjectId() { return ObjectId; }
public UserLocation setObjectId(String value) { this.ObjectId = value; return this; }
public String getVersionId() { return VersionId; }
public UserLocation setVersionId(String value) { this.VersionId = value; return this; }
public String getBasedOn() { return BasedOn; }
public UserLocation setBasedOn(String value) { this.BasedOn = value; return this; }
public UserStatus getUserStatus() { return UserStatus; }
public UserLocation setUserStatus(UserStatus value) { this.UserStatus = value; return this; }
}
public static class Location
{
public Double y = null;
public Double x = null;
public Double getY() { return y; }
public Location setY(Double value) { this.y = value; return this; }
public Double getX() { return x; }
public Location setX(Double value) { this.x = value; return this; }
}
public static enum UserStatus
{
NotStarted,
Driving,
InProgress,
Complete,
Blocked;
}
}
To override the Content-type in your clients, use the HTTP Accept Header, append the .json suffix or ?format=json
To embed the response in a jsonp callback, append ?callback=myCallback
The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.
POST /{Workspace}/UserLocation/{ObjectId} HTTP/1.1
Host: dev.fieldsquared.com
Accept: application/json
Content-Type: application/json
Content-Length: length
{"Workspace":"String","ObjectId":"String","VersionId":"String","BasedOn":"String","UserStatus":"NotStarted","y":0,"x":0}