Let the platform do the work

/Forecasts/reportees/:user_id GET

ForecastsApi Reportees

Summary:

This endpoint is used to return the json Data for an array of users and their state for the forecasts users tree filter

Query Parameters:

Param Description Optional
user_id Show for a specific user, defaults to current user if not defined Optional
level Level of child notes, defaults to 1, -1 for all levels Optional

Input Example:

{ 'user_id':'seed_max_id' }

Output Example:

{ "attr":{ "id":"jstree_node_jim", "rel":"root" }, "children":[ { "attr":{ "id":"jstree_node_myopps_jim", "rel":"my_opportunities" }, "children":[ ], "data":"Opportunities (Jim Brennan)", "metadata":{ "first_name":"Jim", "full_name":"Jim Brennan", "id":"seed_jim_id", "last_name":"Brennan", "level":"1", "reports_to_id":"", "user_name":"jim" }, "state":"" }, { "attr":{ "id":"jstree_node_will", "rel":"manager" }, "children":[ ], "data":"Will Westin", "metadata":{ "first_name":"Will", "full_name":"Will Westin", "id":"seed_will_id", "last_name":"Westin", "level":"2", "reports_to_id":"seed_jim_id", "user_name":"will" }, "state":"closed" }, { "attr":{ "id":"jstree_node_sarah", "rel":"manager" }, "children":[ ], "data":"Sarah Smith", "metadata":{ "first_name":"Sarah", "full_name":"Sarah Smith", "id":"seed_sarah_id", "last_name":"Smith", "level":"2", "reports_to_id":"seed_jim_id", "user_name":"sarah" }, "state":"closed" } ], "data":"Jim Brennan", "metadata":{ "first_name":"Jim", "full_name":"Jim Brennan", "id":"seed_jim_id", "last_name":"Brennan", "level":"1", "reports_to_id":"", "user_name":"jim" }, "state":"open" }