Trendsic Platform Service

<back to all web services

LeaderboardRequest

The following routes are available for this service:
POST,OPTIONS/v1/Leaderboard
GET,OPTIONS/v1/Leaderboard/{LeaderboardType}/{StartDate}/{EndDate}
import java.math.*;
import java.util.*;
import java.io.InputStream;
import net.servicestack.client.*;

public class dtos
{

    public static class LeaderboardRequest
    {
        public String StartDate = null;
        public String EndDate = null;
        public String LeaderboardType = null;
        
        public String getStartDate() { return StartDate; }
        public LeaderboardRequest setStartDate(String value) { this.StartDate = value; return this; }
        public String getEndDate() { return EndDate; }
        public LeaderboardRequest setEndDate(String value) { this.EndDate = value; return this; }
        public String getLeaderboardType() { return LeaderboardType; }
        public LeaderboardRequest setLeaderboardType(String value) { this.LeaderboardType = value; return this; }
    }

    public static class LeaderboardResponse
    {
        public ResponseStatus ResponseStatus = null;
        public ArrayList<Leaderboard> AllData = new ArrayList<Leaderboard>();
        public ArrayList<Leaderboard> MVP = new ArrayList<Leaderboard>();
        public ArrayList<Leaderboard> AVP = new ArrayList<Leaderboard>();
        public ArrayList<Leaderboard> RVP = new ArrayList<Leaderboard>();
        public ArrayList<Leaderboard> Agents = new ArrayList<Leaderboard>();
        
        public ResponseStatus getResponseStatus() { return ResponseStatus; }
        public LeaderboardResponse setResponseStatus(ResponseStatus value) { this.ResponseStatus = value; return this; }
        public ArrayList<Leaderboard> getAllData() { return AllData; }
        public LeaderboardResponse setAllData(ArrayList<Leaderboard> value) { this.AllData = value; return this; }
        public ArrayList<Leaderboard> getMvp() { return MVP; }
        public LeaderboardResponse setMvp(ArrayList<Leaderboard> value) { this.MVP = value; return this; }
        public ArrayList<Leaderboard> getAvp() { return AVP; }
        public LeaderboardResponse setAvp(ArrayList<Leaderboard> value) { this.AVP = value; return this; }
        public ArrayList<Leaderboard> getRvp() { return RVP; }
        public LeaderboardResponse setRvp(ArrayList<Leaderboard> value) { this.RVP = value; return this; }
        public ArrayList<Leaderboard> getAgents() { return Agents; }
        public LeaderboardResponse setAgents(ArrayList<Leaderboard> value) { this.Agents = value; return this; }
    }

    public static class Leaderboard
    {
        public Integer Position = null;
        public String Name = null;
        public String Location = null;
        public BigDecimal LifeCashFlow = null;
        public BigDecimal AnnuityCashFlow = null;
        public BigDecimal TotalCashFlow = null;
        public BigDecimal PremiumLife = null;
        public BigDecimal PremiumAnnuity = null;
        public BigDecimal PointsLife = null;
        public BigDecimal PointsAnnuity = null;
        public BigDecimal TotalPoints = null;
        public Boolean IsMVP = null;
        public Boolean IsRVP = null;
        public Boolean IsAVP = null;
        public Boolean IsAgent = null;
        public String Phone = null;
        public String Upline1Name = null;
        public String Upline2Name = null;
        
        public Integer getPosition() { return Position; }
        public Leaderboard setPosition(Integer value) { this.Position = value; return this; }
        public String getName() { return Name; }
        public Leaderboard setName(String value) { this.Name = value; return this; }
        public String getLocation() { return Location; }
        public Leaderboard setLocation(String value) { this.Location = value; return this; }
        public BigDecimal getLifeCashFlow() { return LifeCashFlow; }
        public Leaderboard setLifeCashFlow(BigDecimal value) { this.LifeCashFlow = value; return this; }
        public BigDecimal getAnnuityCashFlow() { return AnnuityCashFlow; }
        public Leaderboard setAnnuityCashFlow(BigDecimal value) { this.AnnuityCashFlow = value; return this; }
        public BigDecimal getTotalCashFlow() { return TotalCashFlow; }
        public Leaderboard setTotalCashFlow(BigDecimal value) { this.TotalCashFlow = value; return this; }
        public BigDecimal getPremiumLife() { return PremiumLife; }
        public Leaderboard setPremiumLife(BigDecimal value) { this.PremiumLife = value; return this; }
        public BigDecimal getPremiumAnnuity() { return PremiumAnnuity; }
        public Leaderboard setPremiumAnnuity(BigDecimal value) { this.PremiumAnnuity = value; return this; }
        public BigDecimal getPointsLife() { return PointsLife; }
        public Leaderboard setPointsLife(BigDecimal value) { this.PointsLife = value; return this; }
        public BigDecimal getPointsAnnuity() { return PointsAnnuity; }
        public Leaderboard setPointsAnnuity(BigDecimal value) { this.PointsAnnuity = value; return this; }
        public BigDecimal getTotalPoints() { return TotalPoints; }
        public Leaderboard setTotalPoints(BigDecimal value) { this.TotalPoints = value; return this; }
        public Boolean getIsMVP() { return IsMVP; }
        public Leaderboard setIsMVP(Boolean value) { this.IsMVP = value; return this; }
        public Boolean getIsRVP() { return IsRVP; }
        public Leaderboard setIsRVP(Boolean value) { this.IsRVP = value; return this; }
        public Boolean getIsAVP() { return IsAVP; }
        public Leaderboard setIsAVP(Boolean value) { this.IsAVP = value; return this; }
        public Boolean getIsAgent() { return IsAgent; }
        public Leaderboard setIsAgent(Boolean value) { this.IsAgent = value; return this; }
        public String getPhone() { return Phone; }
        public Leaderboard setPhone(String value) { this.Phone = value; return this; }
        public String getUpline1Name() { return Upline1Name; }
        public Leaderboard setUpline1Name(String value) { this.Upline1Name = value; return this; }
        public String getUpline2Name() { return Upline2Name; }
        public Leaderboard setUpline2Name(String value) { this.Upline2Name = value; return this; }
    }

}

Java LeaderboardRequest DTOs

To override the Content-type in your clients, use the HTTP Accept Header, append the .jsv suffix or ?format=jsv

HTTP + JSV

The following are sample HTTP requests and responses. The placeholders shown need to be replaced with actual values.

POST /v1/Leaderboard HTTP/1.1 
Host: api.dev.dynamics.trendsic.com 
Accept: text/jsv
Content-Type: text/jsv
Content-Length: length

{
	StartDate: String,
	EndDate: String,
	LeaderboardType: String
}
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
		}
	},
	AllData: 
	[
		{
			Position: 0,
			Name: String,
			Location: String,
			LifeCashFlow: 0,
			AnnuityCashFlow: 0,
			TotalCashFlow: 0,
			PremiumLife: 0,
			PremiumAnnuity: 0,
			PointsLife: 0,
			PointsAnnuity: 0,
			TotalPoints: 0,
			IsMVP: False,
			IsRVP: False,
			IsAVP: False,
			IsAgent: False,
			Phone: String,
			Upline1Name: String,
			Upline2Name: String
		}
	],
	MVP: 
	[
		{
			Position: 0,
			Name: String,
			Location: String,
			LifeCashFlow: 0,
			AnnuityCashFlow: 0,
			TotalCashFlow: 0,
			PremiumLife: 0,
			PremiumAnnuity: 0,
			PointsLife: 0,
			PointsAnnuity: 0,
			TotalPoints: 0,
			IsMVP: False,
			IsRVP: False,
			IsAVP: False,
			IsAgent: False,
			Phone: String,
			Upline1Name: String,
			Upline2Name: String
		}
	],
	AVP: 
	[
		{
			Position: 0,
			Name: String,
			Location: String,
			LifeCashFlow: 0,
			AnnuityCashFlow: 0,
			TotalCashFlow: 0,
			PremiumLife: 0,
			PremiumAnnuity: 0,
			PointsLife: 0,
			PointsAnnuity: 0,
			TotalPoints: 0,
			IsMVP: False,
			IsRVP: False,
			IsAVP: False,
			IsAgent: False,
			Phone: String,
			Upline1Name: String,
			Upline2Name: String
		}
	],
	RVP: 
	[
		{
			Position: 0,
			Name: String,
			Location: String,
			LifeCashFlow: 0,
			AnnuityCashFlow: 0,
			TotalCashFlow: 0,
			PremiumLife: 0,
			PremiumAnnuity: 0,
			PointsLife: 0,
			PointsAnnuity: 0,
			TotalPoints: 0,
			IsMVP: False,
			IsRVP: False,
			IsAVP: False,
			IsAgent: False,
			Phone: String,
			Upline1Name: String,
			Upline2Name: String
		}
	],
	Agents: 
	[
		{
			Position: 0,
			Name: String,
			Location: String,
			LifeCashFlow: 0,
			AnnuityCashFlow: 0,
			TotalCashFlow: 0,
			PremiumLife: 0,
			PremiumAnnuity: 0,
			PointsLife: 0,
			PointsAnnuity: 0,
			TotalPoints: 0,
			IsMVP: False,
			IsRVP: False,
			IsAVP: False,
			IsAgent: False,
			Phone: String,
			Upline1Name: String,
			Upline2Name: String
		}
	]
}