AIM Web Services

<back to all web services

C2BGetDistrictInfoRequest

C2BGetDistrictInfo
Requires active-e Contracts Service.

The following routes are available for this service:
POST, GET/api/C2BGetDistrictInfo
import java.math.*;
import java.util.*;
import net.servicestack.client.*;

public class dtos
{

    /**
    * C2BGetDistrictInfoRequires active-e Contracts Service.
    */
    @DataContract
    public static class C2BGetDistrictInfoRequest extends BaseRequest
    {
        /**
        * If sent, only districts with schools of the sent plan code will be returned.
        */
        @DataMember
        @ApiMember(DataType="string", Description="If sent, only districts with schools of the sent plan code will be returned.", Format="date", Name="PlanCode", ParameterType="query")
        public String PlanCode = null;

        /**
        * ID of the Instrument record. Optional.
        */
        @DataMember
        @ApiMember(DataType="integer", Description="ID of the Instrument record. Optional.", Format="int64", Name="RinPk", ParameterType="query")
        public Long RinPk = null;

        /**
        * Optional Request Type. Valid values are Contract and Shipping.
        */
        @DataMember
        @ApiMember(DataType="string", Description="Optional Request Type. Valid values are Contract and Shipping.", Name="RequestType", ParameterType="query")
        public String RequestType = null;
        
        public String getPlanCode() { return PlanCode; }
        public C2BGetDistrictInfoRequest setPlanCode(String value) { this.PlanCode = value; return this; }
        public Long getRinPk() { return RinPk; }
        public C2BGetDistrictInfoRequest setRinPk(Long value) { this.RinPk = value; return this; }
        public String getRequestType() { return RequestType; }
        public C2BGetDistrictInfoRequest setRequestType(String value) { this.RequestType = value; return this; }
    }

    @DataContract
    public static class BaseRequest
    {
        /**
        * This is your AIM API Key provided by Tri-Tech
        */
        @DataMember
        @ApiMember(DataType="string", Description="This is your AIM API Key provided by Tri-Tech", IsRequired=true, Name="ApiKey", ParameterType="header")
        public String ApiKey = null;

        @DataMember
        @ApiMember(DataType="string", Name="OAuthToken", ParameterType="header")
        public String OAuthToken = null;
        
        public String getApiKey() { return ApiKey; }
        public BaseRequest setApiKey(String value) { this.ApiKey = value; return this; }
        public String getOAuthToken() { return OAuthToken; }
        public BaseRequest setOAuthToken(String value) { this.OAuthToken = value; return this; }
    }

    @DataContract
    public static class C2BGetDistrictInfoResponse extends BaseResponse
    {
        @DataMember
        public ArrayList<C2BDistrictGeneric> Districts = null;

        @DataMember
        public Boolean TeacherTableExists = null;
        
        public ArrayList<C2BDistrictGeneric> getDistricts() { return Districts; }
        public C2BGetDistrictInfoResponse setDistricts(ArrayList<C2BDistrictGeneric> value) { this.Districts = value; return this; }
        public Boolean isTeacherTableExists() { return TeacherTableExists; }
        public C2BGetDistrictInfoResponse setTeacherTableExists(Boolean value) { this.TeacherTableExists = value; return this; }
    }

    @DataContract
    public static class BaseResponse
    {
        /**
        * 
        */
        @DataMember
        @ApiMember(DataType="BaseResponseResult", Description="", Name="Status", ParameterType="body")
        public BaseResponseResult Status = null;
        
        public BaseResponseResult getStatus() { return Status; }
        public BaseResponse setStatus(BaseResponseResult value) { this.Status = value; return this; }
    }

    @DataContract
    public static class BaseResponseResult
    {
        /**
        * 
        */
        @DataMember
        @ApiMember(DataType="string", Description="", Name="StatusCode", ParameterType="body")
        public String StatusCode = null;

        /**
        * 
        */
        @DataMember
        @ApiMember(DataType="string", Description="", Name="Login", ParameterType="body")
        public String Login = null;

        /**
        * 
        */
        @DataMember
        @ApiMember(DataType="string", Description="", Name="ErrorCode", ParameterType="body")
        public String ErrorCode = null;

        /**
        * 
        */
        @DataMember
        @ApiMember(DataType="string", Description="", Name="ErrorDisplayText", ParameterType="body")
        public String ErrorDisplayText = null;

        /**
        * 
        */
        @DataMember
        @ApiMember(DataType="string", Description="", Name="ErrorMessage", ParameterType="body")
        public String ErrorMessage = null;

        /**
        * 
        */
        @DataMember
        @ApiMember(DataType="string", Description="", ExcludeInSchema=true, Name="DomainName", ParameterType="body")
        public String DomainName = null;

        /**
        * 
        */
        @DataMember
        @ApiMember(DataType="string", Description="", ExcludeInSchema=true, Name="IPAddress", ParameterType="body")
        public String IpAddress = null;
        
        public String getStatusCode() { return StatusCode; }
        public BaseResponseResult setStatusCode(String value) { this.StatusCode = value; return this; }
        public String getLogin() { return Login; }
        public BaseResponseResult setLogin(String value) { this.Login = value; return this; }
        public String getErrorCode() { return ErrorCode; }
        public BaseResponseResult setErrorCode(String value) { this.ErrorCode = value; return this; }
        public String getErrorDisplayText() { return ErrorDisplayText; }
        public BaseResponseResult setErrorDisplayText(String value) { this.ErrorDisplayText = value; return this; }
        public String getErrorMessage() { return ErrorMessage; }
        public BaseResponseResult setErrorMessage(String value) { this.ErrorMessage = value; return this; }
        public String getDomainName() { return DomainName; }
        public BaseResponseResult setDomainName(String value) { this.DomainName = value; return this; }
        public String getIpAddress() { return IpAddress; }
        public BaseResponseResult setIpAddress(String value) { this.IpAddress = value; return this; }
    }

    @DataContract
    public static class C2BDistrictGeneric
    {
        @DataMember
        public String DistrictName = null;

        @DataMember
        public Integer SchoolCount = null;

        @DataMember
        public Integer TeacherCount = null;

        @DataMember
        public String Topic = null;

        @DataMember
        public Long Id = null;
        
        public String getDistrictName() { return DistrictName; }
        public C2BDistrictGeneric setDistrictName(String value) { this.DistrictName = value; return this; }
        public Integer getSchoolCount() { return SchoolCount; }
        public C2BDistrictGeneric setSchoolCount(Integer value) { this.SchoolCount = value; return this; }
        public Integer getTeacherCount() { return TeacherCount; }
        public C2BDistrictGeneric setTeacherCount(Integer value) { this.TeacherCount = value; return this; }
        public String getTopic() { return Topic; }
        public C2BDistrictGeneric setTopic(String value) { this.Topic = value; return this; }
        public Long getId() { return Id; }
        public C2BDistrictGeneric setId(Long value) { this.Id = value; return this; }
    }

}

Java C2BGetDistrictInfoRequest DTOs

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

HTTP + JSON

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

POST /api/C2BGetDistrictInfo HTTP/1.1 
Host: active-ewebservice.biz 
Accept: application/json
Content-Type: application/json
Content-Length: length

{"PlanCode":"String","RinPk":0,"RequestType":"String","ApiKey":"String","OAuthToken":"String"}
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length

{"Districts":[{}],"TeacherTableExists":false,"Status":{"StatusCode":"String","Login":"String","ErrorCode":"String","ErrorDisplayText":"String","ErrorMessage":"String","DomainName":"String","IpAddress":"String"}}