This API creates a Flat Configuration (FLC) header in Smart Materials.
Required Privilege: API_FLC
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’)/FlatConfigurations
Specify values for the project, discipline, and language in the URL. The project, discipline, and language together, define the project environment in which the Flat Configuration header is created.
Element |
Description |
Type |
Required |
Notes |
---|---|---|---|---|
FlcCode |
Unique code or name of the Flat Configuration |
String |
Required |
Maximum allowed length is 20. |
FlcComment |
Description of the Flat Configuration |
String |
Optional |
Maximum allowed length is 80. |
FlcDelimiter |
Column separator. Example: “/”, “,”, “%”, and so on. |
String |
Optional |
Maximum allowed length is 3. |
SumPosInd |
Indicates whether the equal Allowed values are Y and N. Default value is N. |
String |
Optional |
If value Y is passed, ClsId must be Null. |
FlcLengthUnitId |
Assigns a length unit to the BOM |
Integer |
Optional |
Only those units that belong |
FlcQtyUnitId |
Assigns a quantity unit to the BOM flat config import, if no unit is imported |
Integer |
Optional |
Only those units that |
SkipLines |
Number of lines to skip in a FLC load |
Integer |
Optional |
Maximum allowed value is 999. |
ClsId |
Class system ID |
Integer |
Optional |
|
DpId |
Unique ID of the Discipline in which the FLC header is created |
Integer |
Optional |
Maximum allowed length is 12. |
Sample Code
POST https://{host}/Smat/V1/Projects(‘M06_1158’)/Disciplines(‘PIPING’)/Nls(‘English’)/FlatConfigurations
{ "FlcCode":"KVFLC",
"FlcComment":"Sample FLC",
"FlcLengthUnitId":502262,
"FlcQtyUnitId":556694,
"FlcDelimiter":";",
"SkipLines":2,
"SumPosInd":"N",
"ClsId":null
}
Success Response
Status: 201 Created
{
"@odata.context": "https://localhost:56158/SMAT/V1/$metadata#Projects('M06_1158')/Disciplines('PIPING')/Nls('English')/FlatConfigurations/$entity",
"FlcId":10000007066,
"DpId":5020,
"FlcCode":"KVFLC",
"FlcComment":"Sample FLC",
"FlcLengthUnitId":502262,
"FlcQtyUnitId":556694,
"FlcDelimiter":";",
"SkipLines":2,
"SumPosInd":"N",
"ClsId":null
}
Element |
Description |
Type |
Notes |
---|---|---|---|
FlcId |
Unique ID of the Flat Configuration header |
Integer |