Trend → BDS → Auto. One call returns all three harvest regimes (Heavy / Medium / Light), each with its selected trees, residual stand, logging damage, and a 30-year projection.
/v3/bds/compartments and
/v3/bds/years endpoints, and the user reaches this page from
/v3/bds/simulation (BDS Page 1). See the Overview.
| # | Page / screen | What the user does | Endpoint(s) |
|---|---|---|---|
| 0 | Setup | Pick Hectare + Year. | GET /v3/bds/compartmentsGET /v3/bds/years |
| 1 | BDS Simulation (Pre-Felling) | Reviews PF inventory, then taps Auto calculate. | GET /v3/bds/simulation |
| 2 | Auto result — Heavy / Medium / Light | Toggles between the three regimes; reads harvest list, residual stand, logging damage, and the 30-yr chart. | GET /v3/bds/auto-selection (all three regimes in one response) |
Auto Calculate Tree Selection — returns all three regimes (Heavy / Medium / Light) in one response. Each regime block has the harvest list, totals row, Immediate Implication (residual stand), Logging Damage breakdown, and the 30-year Future Implication chart data.
| Name | Type | Required | Description |
|---|---|---|---|
year | integer | required | Census year, e.g. 2021. Get valid values from /v3/bds/years. |
compartment_hectare | integer | required | 2 or 50 |
| Rule | Value |
|---|---|
| Heavy regime target | 20 trees/ha × compartment_hectare |
| Medium regime target | 16 trees/ha × compartment_hectare |
| Light regime target | 12 trees/ha × compartment_hectare |
| Selection order | Candidate trees sorted by DBH descending; take top N |
| Logging damage (+60cm) | 20% of remaining trees in class removed |
| Logging damage (45-60cm) | 30% removed |
| Logging damage (30-45cm) | 40% removed |
| Logging damage (15-30cm) | 50% removed (skipped in practice — PF residual is DBH≥30) |
| LD selection within class | Smallest-DBH trees dropped first |
| Future projection | 30 years, every 5 years (6 data points) |
curl "https://api.wildvine.kotaksakti.com/v3/bds/auto-selection?year=2021&compartment_hectare=2"
{
"regimes": {
"heavy": RegimeBlock, // 20 trees/ha
"medium": RegimeBlock, // 16 trees/ha
"light": RegimeBlock // 12 trees/ha
},
"meta": {
"compartment_hectare": integer,
"year": integer,
"updated_at": "ISO-8601 string"
}
}
RegimeBlock = {
"config": {
"regime": "heavy" | "medium" | "light",
"trees_per_ha": integer, // 20 / 16 / 12
"target_total": integer, // trees_per_ha * compartment_hectare
"actually_selected": integer // capped by candidate pool size
},
// ─── Per-tree harvest list (drives the table on the Auto page) ───
"selected_trees": [
{
"tag": string,
"scientific_name": string,
"species_group": string,
"dbh_cm": float,
"basal_area_m2": float,
"volume_m3": float,
"biomass_t": float,
"carbon_tC": float,
"price_rm": float
}
],
// ─── Totals row at the bottom of selected_trees ───
"selected_total": {
"tree_count": integer,
"basal_area_m2": float,
"basal_area_m2_per_ha": float,
"volume_m3": float,
"volume_m3_per_ha": float,
"total_biomass_t": float,
"total_biomass_t_per_ha": float,
"total_carbon_tC": float,
"total_carbon_tC_per_ha": float,
"price_rm": float
},
// ─── Right-side "Immediate Implication / Residual Stand" panel ───
"residual_stand": {
"tree_density": integer,
"tree_density_per_ha": float,
"volume_m3_per_ha": float,
"basal_area_m2_per_ha": float,
"total_biomass_t_per_ha": float,
"total_carbon_tC_per_ha": float
},
// ─── Logging Damage breakdown (diagnostic) ───
"logging_damage": {
"by_dbh_class": [
{ "class": "+60cm", "removed_pct": 20, "trees_removed": integer },
{ "class": "45-60cm", "removed_pct": 30, "trees_removed": integer },
{ "class": "30-45cm", "removed_pct": 40, "trees_removed": integer },
{ "class": "15-30cm", "removed_pct": 50, "trees_removed": integer }
],
"total_trees_removed": integer
},
// ─── "Future Implication" 5-year line charts (next 30 years) ───
"future_implication": {
"years": integer[6], // [year+5, +10, +15, +20, +25, +30]
"tree_density_per_ha": float[6],
"volume_m3_per_ha": float[6],
"basal_area_m2_per_ha": float[6],
"biomass_t_per_ha": float[6],
"carbon_tC_per_ha": float[6]
}
}
{
"regimes": {
"heavy": {
"config": {
"regime": "heavy",
"trees_per_ha": 20,
"target_total": 40,
"actually_selected": 32
},
"selected_trees": [
{
"tag": "3010",
"scientific_name": "Koompassia malaccensis",
"species_group": "Non-dipterocarp",
"dbh_cm": 119.6,
"basal_area_m2": 1.12359,
"volume_m3": 14.60669,
"biomass_t": 24.12313,
"carbon_tC": 11.33787,
"price_rm": 464.83
},
{
"tag": "2378",
"scientific_name": "Sarcotheca griffithii",
"species_group": "Non-dipterocarp",
"dbh_cm": 112.4,
"basal_area_m2": 0.99238,
"volume_m3": 12.90096,
"biomass_t": 20.82428,
"carbon_tC": 9.78741,
"price_rm": 414.83
}
// ... up to actually_selected rows
],
"selected_total": {
"tree_count": 32,
"basal_area_m2": 15.39787,
"basal_area_m2_per_ha": 7.69893,
"volume_m3": 176.38323,
"volume_m3_per_ha": 88.19161,
"total_biomass_t": 288.74247,
"total_biomass_t_per_ha": 144.37124,
"total_carbon_tC": 135.70896,
"total_carbon_tC_per_ha": 67.85448,
"price_rm": 16026.44
},
"residual_stand": {
"tree_density": 97,
"tree_density_per_ha": 48.5,
"volume_m3_per_ha": 58.1,
"basal_area_m2_per_ha": 7.9,
"total_biomass_t_per_ha": 122.31,
"total_carbon_tC_per_ha": 57.49
},
"logging_damage": {
"by_dbh_class": [
{ "class": "+60cm", "removed_pct": 20, "trees_removed": 4 },
{ "class": "45-60cm", "removed_pct": 30, "trees_removed": 12 },
{ "class": "30-45cm", "removed_pct": 40, "trees_removed": 42 },
{ "class": "15-30cm", "removed_pct": 50, "trees_removed": 0 }
],
"total_trees_removed": 58
},
"future_implication": {
"years": [2026, 2031, 2036, 2041, 2046, 2051],
"tree_density_per_ha": [43.55, 39.16, 35.63, 33.00, 31.14, 29.90],
"volume_m3_per_ha": [61.20, 63.80, 66.10, 68.00, 69.50, 70.70],
"basal_area_m2_per_ha": [8.57, 8.62, 8.70, 8.81, 8.93, 9.01],
"biomass_t_per_ha": [130.20, 135.40, 139.80, 143.50, 146.70, 149.20],
"carbon_tC_per_ha": [61.20, 63.60, 65.70, 67.40, 68.90, 70.10]
}
},
"medium": { /* same shape, 16 trees/ha target */ },
"light": { /* same shape, 12 trees/ha target */ }
},
"meta": {
"compartment_hectare": 2,
"year": 2021,
"updated_at": "2026-06-04T08:00:00Z"
}
}
Last updated 2026-06-09 · Hosted on Cloudflare Pages