- getWorkset, input parms: Scenario Key, Workset Key; output: success/fail
- populateWorksetCache, input parms: Scenario Key, Workset Key, output: success/fail
- deleteWorksetCache, input parms: Scenario, output: success/fail
- addExpenseLine,POST, input parms, scenarioKey, worksetKey, GLCat, Name (default:GlCat), startDate, endDate, rollsOff [Y|N], amortize [Y|N],[Cokey:Val, CoKey2:val2....], returns speculationId (expense line key)
- upDateExpenseLine PUT, input parms, speculationId,scenarioKey, worksetKey, GLCat, Name (default:GlCat), startDate, endDate, rollsOff [Y|N], amortize [Y|N],[Cokey:Val, CoKey2:val2....],, returns status
- deleteExpenseLine, DELETE, speculationId, returns status
getExpenseLines : input parms: Scenario, Budget, Workset, GL category, startDate,endDate, output: array of expense line
Call:
rest/v2/newEndpointTBD/forecast_id/glcategory/glcategory_id/speculation?startDate=date3&endDate=date
Sample:
rest/v2/newEndpointTBD/KDOODYSHAREDCOSTOBJECTC1443501001FORECAST-324790329-004/glcategory/CRAFT-2/speculation?startDate=07%2F01%2F2013&endDate=06%2F30%2F2014
Response:
{ data:
"HEADER":[
{COST_COLLECTOR_ID_WITH_TYPE: "P6923933",
COST_COLLECTOR_KEY: "P6923933-001",
COST_COLLECTOR_NAME: "Computing On Encrypted Data: Theory And"
},
{
COST_COLLECTOR_ID_WITH_TYPE: "P6923932",
COST_COLLECTOR_KEY: "P6923932-001",
COST_COLLECTOR_NAME: "Nonparametric Representations For Integr"
},
{
COST_COLLECTOR_ID_WITH_TYPE: "P6926990",
COST_COLLECTOR_KEY: "P6926990-001",
COST_COLLECTOR_NAME: "Fabricated Equipment - Robot Movement Sy"
}
],
"RESULT":[
{
"LVL1":"ForecastData",
"LVL2":"blocks",
"LVL3":"CRAFT-2",
"LVL4":"actuals",
"LVL5":null,
"speculationId":"C1443501-001420226-001",
"speculationName":"Materials and Services",
"glAccountKey":"420226-001",
"glAccountName":"Materials and Services",
"GLCAT_KEY":"CRAFT-2",
"GLCAT_TITLE":"Materials and Services",
"DAYS":"1",
"costObjects": [{COST_COLLECTOR_KEY: "P6923933-001", cost: "5,000"},
{COST_COLLECTOR_KEY: "P6926990-001", cost: "0"},
{COST_COLLECTOR_KEY: "P6923932-001", cost: "12,087"},
}],
"PER_DAY":"131.94",
"startDate":"08\/26\/2013",
"endDate":"10\/18\/2013",
"isRestricted":"Y",
"rollOff":"N",
"description":null,
"DISP":"ACT",
"isDirty":"N"
},
{
"LVL1":"ForecastData",
"LVL2":"blocks",
"LVL3":"CRAFT-2",
"LVL4":"actuals",
"LVL5":null,
"speculationId":"C1443501-001420890-001",
"speculationName":"Subscriptions",
"glAccountKey":"420890-001",
"glAccountName":"Subscriptions",
"GLCAT_KEY":"CRAFT-2",
"GLCAT_TITLE":"Materials and Services",
"DAYS":"1",
"costObjects": [{COST_COLLECTOR_KEY: "P6923933-001", cost: "0"},
{COST_COLLECTOR_KEY: "P6926990-001", cost: "0"},
{COST_COLLECTOR_KEY: "P6923932-001", cost: "0"},
}],
"PER_DAY":"471.9",
"startDate":"09\/01\/2013",
"endDate":"09\/01\/2013",
"isRestricted":"Y",
"rollOff":"N",
"description":null,
"DISP":"ACT",
"isDirty":"N"
},
{
"LVL1":"ForecastData",
"LVL2":"blocks",
"LVL3":"CRAFT-2",
"LVL4":"forecasts",
"LVL5":null,
"speculationId":"C1443501-001421827-001",
"speculationName":"Equip\/Furniture-Minor",
"glAccountKey":"421827-001",
"glAccountName":"Equip\/Furniture-Minor",
"GLCAT_KEY":"CRAFT-2",
"GLCAT_TITLE":"Materials and Services",
"DAYS":"0",
"cost":"0.00",
"PER_DAY":"1893",
"startDate":"11\/04\/2013",
"endDate":"11\/04\/2013",
"isRestricted":"Y",
"rollOff":"N",
"description":null,
"DISP":"COMM",
"isDirty":"N"
},
{
"LVL1":"ForecastData",
"LVL2":"blocks",
"LVL3":"CRAFT-2",
"LVL4":"forecasts",
"LVL5":null,
"speculationId":"KDOODYKDOODYSHAREDCOSTOBJECTC1443501001FORECAST-324790329-004C1443501-001E2014031327090808722522000",
"speculationName":"worms",
"glAccountKey":"420226-001",
"glAccountName":"Materials and Services",
"GLCAT_KEY":"CRAFT-2",
"GLCAT_TITLE":"Materials and Services",
"DAYS":"121",
"costObjects": [{COST_COLLECTOR_KEY: "P6923933-001", cost: "15,000"},
{COST_COLLECTOR_KEY: "P6926990-001", cost: "0"},
{COST_COLLECTOR_KEY: "P6923932-001", cost: "0"},
}],
"PER_DAY":"65.57377049180327868852459016393442622951",
"startDate":"03\/01\/2014",
"endDate":"06\/30\/2014",
"isRestricted":"Y",
"rollOff":"Y",
"description":null,
"DISP":"FORC",
"isDirty":"Y"
}
],
"meta":{
"statusCode":0,
"message":"Success",
"hasData":true
}
}
- commitWorksetForecast, input parms: scenarioKey, worksetKey, scenarioName, scenarioDescription) returns status
- createForecast(meta) (Not needed for May)
- updateForecast(meta) (Not needed for May)
- deleteForecast(meta) (Not needed for May)
- getExpenseSummary, input parms: Scenario, Budget, Workset, startDate, endDate, output: array of summary lines for All Expenses tab, 1 line per GL Cat
- getExpenseSubtotal, input parms: Scenario, Budget, Workset, GL category, startDate (optional, defaults to workset start Date), endDate (optional, defaults to workset end date), output: array of subtotals, Auth total line only appears when dates are workset begin and end date (because calculated total is based on Auth total minus subtotal lines = calc total )
- getExpenseBalance, input parms: Scenario, Budget, Workset, GL category, startDate (optional, defaults to workset start Date), endDate (optional, defaults to workset end date), output: one map of balances