This API creates a clone of a Forecast based on the given Forecast header ID.
Only forecast header and warehouses properties of the given Forecast are copied to the new Forecast.
Required Privilege: API_CREATE_FAHEADER
Headers
Header Name |
Description |
Required |
Values |
---|---|---|---|
Authorization |
Access token |
Required |
Bearer <access_token> |
Content-Type |
Request type format |
Required |
application/JSON |
Body
URL Format: POST https://{host}/Smat/v1/Projects(':project')/Disciplines(':discipline')/Nls(':language')/Forecasts({key})/Clone
Specify values for the project, discipline, language, and key parameter in the URL. The project, discipline, and language together, define the project environment. The key parameter defines the Forecast Id (FahId) that is getting cloned.
Sample Code
POST https://in-smatapi.ingrnet.com/API21/Smat/v1/Projects('M06_1188')/Disciplines('PIPE')/Nls('ENGLISH')/Forecasts(65330)/Clone
Success Response
Status: 200OK
{
"@odata.context":"https://in-smatapi.ingrnet.com/API21/SMAT/V1/$metadata#Projects('M06_1108')/Disciplines('PIPE')/Nls('ENGLISH')/Forecasts/$entity",
"FahId":65698,
"ProjId":"M06_1108",
"FahCode":"FAHCODE381",
"RunNumber":2,
"LstId":5046,
"Shortage":"2-Pass Optimized(Any)",
"SplitType":"PA",
"AllPositionsInd":"Y",
"SubstInd":"Y",
"BestQuantityInd":"Y",
"UseOnlySiteStatusInd":"Y",
"WeightInd":"Y",
"CostInd":"Y",
"HourInd":"Y",
"SplitResult":null,
"StatId":5626,
"AttrId":5571,
"StartDate":null,
"EndDate":null,
"AllocateLevel":"Shipped Items",
"DtpId":5701,
"Priority":"ISSUED FIRST",
"WeightAttrId":5130,
"SortOrder":"HeaviestLast",
"TagNoOption":"Ignore Tag Number",
"DdId":null,
"OnlyEndnodesInd":"Y",
"PositionsWithFullSiteQty":"Y",
"IgnoreNullDateInd":"Y",
"ExcludeMIRQtyInd":"Y",
"JobStatus":"NEW",
"JobStartDate":null,
"JobEndDate":null,
"ParentFahId":null,
"ListNodes":[]
"AutoAssignWhInd":"Y"
}
Element |
Description |
Type |
---|---|---|
FahId |
Unique ID of the newly created Forecast |
Integer |
ProjId |
Unique ID of the Project |
String |
FahCode |
Name of the Forecast and specifies what the Forecast does and is attached to a run number. |
String |
RunNumber |
Unique number attached to a FahCode |
Decimal |
LstId |
Unique ID of the list status |
Decimal |
FahType |
Type of the Forecast header |
String |
Shortage |
Specifies acceptable short quantities used in Bill of Materials allocation. Available values are:
|
String |
SplitType |
Defines Forecast Run split type. Availablevalues are:
|
String |
AllPositionsInd |
Available values are Y and N.
|
String |
SubstInd |
Indicates when the substitution/ transformation must be done automatically by the Forecast Run. Available values are Y, N, and A.
|
String |
BestQuantityInd |
Available values are Y and N.
|
String |
UseOnlySiteStatusInd |
Available values are Y and N.
|
String |
WeightInd |
Available values are Y and N.
|
String |
CostInd |
Available values are Y and N.
|
String |
HourInd |
Available values are Y and N.
|
String |
StatId |
Unique ID of the issue status |
Decimal |
AttrId |
Unique ID of the used attribute, when the split type is NA or PA |
Decimal |
StartDate |
Item shipments whose Promised on Site date is greater than this given start date are retrieved. |
Date Time Offset |
EndDate |
Item shipments whose Promised on Site date is smaller than this given end date are retrieved. |
Date Time Offset |
AllocateLevel |
Defines the pre-receiving level of a material that a Forecast Run should check.
|
String |
DtpId |
Unique ID of the delivery type |
Decimal |
Priority |
Type of the priority specified for the assigned nodes in the work packages of the Forecast Run. Available values are:
|
String |
WeightAttrId |
Unique ID of the weight attribute. Weight attribute |
Decimal |
SortOrder |
Allows you to calculate the weight of nodes assigned to a work package. Available values are:
|
String |
TagNoOption |
Tag number option. Available values are:
|
String |
DdId |
Unique ID of the delivery designation |
Decimal |
OnlyEndnodesInd |
Available values are Y and N.
|
String |
PositionsWithFullSiteQty |
Available values are Y and N.
|
String |
IgnoreNullDateInd |
Available values are Y and N.
|
String |
ExcludeMIRQtyInd |
Indicates whether the issued quantities on unposted MIRs Available values are Y and N.
|
String |
JobStatus |
Status of the job and job here is to run the Forecast header |
String |
JobStartDate |
Start date of the Forecast job |
Date Time Offset |
JobEndDate |
End date of the Forecast job |
Date Time Offset |
ParentFahId |
Unique ID of the parent Forecast header |
Integer |
WhId |
Unique ID of the warehouse |
Decimal |
WhCode |
Name or code of the warehouse |
String |
BnlCode |
Name or code of the bin location |
String |
OrderSeq |
Sequence of the warehouses considered while forecasting |
Decimal |
WpId |
Unique ID of the work package |
Decimal |
AttrSort |
If the priority for a work package is attribute, AttrSort controls the sort order |
String |
PriorityType |
Priority type specified for work package in the current Forecast Run. Available values are:
|
String |
AttrCode |
Name or code of the attribute |
String |
ROSDate |
Date and time when the work package is Required on Site |
Date Time Offset |
BOMPath |
BOM path of the list node |
String |
CommodityCode |
Name or code of the commodity |
String |
Size (1-5) |
Value of input (1-5) of the geometric details |
String |
AttrValue |
Value of the attribute |
String |
AutoAssignWhInd |
Auto assign warehouse to the header. Available values are Y and N.
|
String |
List Nodes |
Collection of the list node names |
Collection |