- Print
- DarkLight
- PDF
Article summary
Did you find this summary helpful?
Thank you for your feedback
Create resources
/v1/resources
Maintain Resources
Example for calling:
http://server/v1/resources
See Request Body below.
Allowed Methods:
[POST]
API Controller: Resources
Description:
Resources can only be created .
Request Fields:
Name | Type | Description |
---|---|---|
RowId | integer | identifying a row in this request that lines up with the response |
name | Varchar(100) | Resource code/name |
description | Varchar(100) | Resource description [Optional] |
resource_set_id | integer | Relation to Resource set (this is not network id, but resource set id) |
resource_type | tinyint | Resource type (1=qty,2=cost) [SAP -> 1] |
cost_rate | float | Unit cost rate for resource type=1 [Optional] |
parent | integer | used for hierarchical structure [Optional] |
Response Fields:
Table with response for each row in the request:
Name | Type | Description | Notes |
---|---|---|---|
RowId | integer | corresponds to the RowID in the request | |
Result | byte | S(uccess) or F(ail) indicating if the requested action was successfully executed | |
Message | string | Empty if success; error message if the requested action failed. | |
MessageId | integer | MessageId: Identifies error message | |
seq | integer | Safran Resource ID | |
name | string | Safran Resource name |
Request Body
[
{
"RowID": 1,
"name": "RD-0010",
"description": "primary resource",
"resource_set_id": 6,
"resource_type": 1,
"cost_rate": 1,
"parent": null
},
{
"RowID": 2,
"name": "RD-0011",
"description": "secondary resource",
"resource_set_id": 5,
"resource_type": 1,
"cost_rate": 1,
"parent": 3
}
]
Was this article helpful?