Cdn Public Collector's Pricing Guide (CPG) API V2

<back to all web services

GetNodeChildrenRequest

Catalog

Retrieve node children for a given node

The following routes are available for this service:
GET/GetNodeChildrenRequestThis will return no data for those nodes with collectible children. There is no advanced APi version for this call.
import java.math.*;
import java.util.*;
import java.io.InputStream;
import net.servicestack.client.*;

public class dtos
{

    /**
    * Retrieve node children for a given node
    */
    @Api(Description="Retrieve node children for a given node")
    public static class GetNodeChildrenRequest
    {
        public Long NodeId = null;
        
        public Long getNodeId() { return NodeId; }
        public GetNodeChildrenRequest setNodeId(Long value) { this.NodeId = value; return this; }
    }

    public static class NodeResponse extends BaseResponse
    {
        public ArrayList<NodeDto> Data = null;
        
        public ArrayList<NodeDto> getData() { return Data; }
        public NodeResponse setData(ArrayList<NodeDto> value) { this.Data = value; return this; }
    }

    public static class BaseResponse
    {
        public Integer Total = null;
        public Integer OpCode = null;
        public String ErrorText = null;
        public String RequestTime = null;
        public String ResponseTime = null;
        public String TotalExecutionTime = null;
        public Boolean CachedResponse = null;
        public Boolean PermitAccess = null;
        public String AccessDeniedMessage = null;
        
        public Integer getTotal() { return Total; }
        public BaseResponse setTotal(Integer value) { this.Total = value; return this; }
        public Integer getOpCode() { return OpCode; }
        public BaseResponse setOpCode(Integer value) { this.OpCode = value; return this; }
        public String getErrorText() { return ErrorText; }
        public BaseResponse setErrorText(String value) { this.ErrorText = value; return this; }
        public String getRequestTime() { return RequestTime; }
        public BaseResponse setRequestTime(String value) { this.RequestTime = value; return this; }
        public String getResponseTime() { return ResponseTime; }
        public BaseResponse setResponseTime(String value) { this.ResponseTime = value; return this; }
        public String getTotalExecutionTime() { return TotalExecutionTime; }
        public BaseResponse setTotalExecutionTime(String value) { this.TotalExecutionTime = value; return this; }
        public Boolean isCachedResponse() { return CachedResponse; }
        public BaseResponse setCachedResponse(Boolean value) { this.CachedResponse = value; return this; }
        public Boolean isPermitAccess() { return PermitAccess; }
        public BaseResponse setPermitAccess(Boolean value) { this.PermitAccess = value; return this; }
        public String getAccessDeniedMessage() { return AccessDeniedMessage; }
        public BaseResponse setAccessDeniedMessage(String value) { this.AccessDeniedMessage = value; return this; }
    }

    public static class NodeDto
    {
        public Long Id = null;
        public String Name = null;
        public String Description = null;
        public String FeaturedImageUrl = null;
        public String FeaturedImageAttribution = null;
        public String FlagCode = null;
        public String CountryName = null;
        public Integer SortingPosition = null;
        public Integer NodeChildrenCountLive = null;
        public Integer CollectibleChildrenCountLive = null;
        public Long ParentNode_Id = null;
        public Long RootNode_Id = null;
        public ArrayList<NodeDto> ChildNodes = null;
        
        public Long getId() { return Id; }
        public NodeDto setId(Long value) { this.Id = value; return this; }
        public String getName() { return Name; }
        public NodeDto setName(String value) { this.Name = value; return this; }
        public String getDescription() { return Description; }
        public NodeDto setDescription(String value) { this.Description = value; return this; }
        public String getFeaturedImageUrl() { return FeaturedImageUrl; }
        public NodeDto setFeaturedImageUrl(String value) { this.FeaturedImageUrl = value; return this; }
        public String getFeaturedImageAttribution() { return FeaturedImageAttribution; }
        public NodeDto setFeaturedImageAttribution(String value) { this.FeaturedImageAttribution = value; return this; }
        public String getFlagCode() { return FlagCode; }
        public NodeDto setFlagCode(String value) { this.FlagCode = value; return this; }
        public String getCountryName() { return CountryName; }
        public NodeDto setCountryName(String value) { this.CountryName = value; return this; }
        public Integer getSortingPosition() { return SortingPosition; }
        public NodeDto setSortingPosition(Integer value) { this.SortingPosition = value; return this; }
        public Integer getNodeChildrenCountLive() { return NodeChildrenCountLive; }
        public NodeDto setNodeChildrenCountLive(Integer value) { this.NodeChildrenCountLive = value; return this; }
        public Integer getCollectibleChildrenCountLive() { return CollectibleChildrenCountLive; }
        public NodeDto setCollectibleChildrenCountLive(Integer value) { this.CollectibleChildrenCountLive = value; return this; }
        public Long getParentNodeId() { return ParentNode_Id; }
        public NodeDto setParentNodeId(Long value) { this.ParentNode_Id = value; return this; }
        public Long getRootNodeId() { return RootNode_Id; }
        public NodeDto setRootNodeId(Long value) { this.RootNode_Id = value; return this; }
        public ArrayList<NodeDto> getChildNodes() { return ChildNodes; }
        public NodeDto setChildNodes(ArrayList<NodeDto> value) { this.ChildNodes = value; return this; }
    }

}

Java GetNodeChildrenRequest 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.

GET /GetNodeChildrenRequest HTTP/1.1 
Host: cpgpublicapiv2dev.greysheet.com 
Accept: application/json
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: length

{"Data":[{"Id":0,"Name":"String","Description":"String","FeaturedImageUrl":"String","FeaturedImageAttribution":"String","FlagCode":"String","CountryName":"String","SortingPosition":0,"NodeChildrenCountLive":0,"CollectibleChildrenCountLive":0,"ParentNode_Id":0,"RootNode_Id":0,"ChildNodes":[{"Id":0,"Name":"String","Description":"String","FeaturedImageUrl":"String","FeaturedImageAttribution":"String","FlagCode":"String","CountryName":"String","SortingPosition":0,"NodeChildrenCountLive":0,"CollectibleChildrenCountLive":0,"ParentNode_Id":0,"RootNode_Id":0,"ChildNodes":[{"Id":0,"Name":"String","Description":"String","FeaturedImageUrl":"String","FeaturedImageAttribution":"String","FlagCode":"String","CountryName":"String","SortingPosition":0,"NodeChildrenCountLive":0,"CollectibleChildrenCountLive":0,"ParentNode_Id":0,"RootNode_Id":0}]}]}],"Total":0,"OpCode":0,"ErrorText":"String","RequestTime":"String","ResponseTime":"String","TotalExecutionTime":"String","CachedResponse":false,"PermitAccess":false,"AccessDeniedMessage":"String"}