This API updates an existing progress pay event details in the given project of Smart Materials.
-
You can update a progress pay event by PO only.
-
You cannot update a progress pay event if the agreement is already approved.
-
If the Locked Indicator is set to Y, then you cannot update the following fields : OrderSeq, PpeCode, ShortDesc, Description, PlanCompletionDate, PaymentPercent, CostValue, PaymentWeeks, PaymentDate, ManualInd and DeliveryInd.
Required Privilege: API_AGREEMENT
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’)/PurchaseOrders({key})/CreateUpdateProgressPayEvents
Specify the values for the project, discipline, and language in the URL. The project, discipline, and language together, define the project environment where the purchase order/agreement is updated. The key parameter specifies the purchase order ID (PohId).
If you have passed two progress pay events and if one does not exists, then API will
update the existing one and create a new one also.
Element |
Description |
Type |
Required |
Notes |
---|---|---|---|---|
AttpId |
Unique ID of the attribute property of the progress pay event. |
Integer |
Required |
|
OrderSeq |
Order sequence |
Integer |
Required |
Maximum allowed value is 99999 |
PpeId |
Unique ID of the progress pay event. |
Integer |
Optional |
|
PpeCode |
Name (code) of the progress pay event. |
Integer |
Required |
Maximum allowed length is 10 |
PaymentPercent |
Payment percentage associated with the progress pay event. It is related to the payment weeks.
|
Integer |
Required/ Optional |
Default value is 0. |
PaymentWeeks |
Refers to the number of weeks for payment related to the progress pay event. |
Integer |
Optional |
|
CostValue |
The cost value of the progress pay event. It provides information about the financial value associated with the PPE.
|
Integer |
Required/ Optional |
|
PlanCompletiondate |
Planned completion date for the progress pay event. |
DateTimeOffset |
Optional |
|
PaymentDate |
Represents the date when the payment for the progress pay event is scheduled or made.
|
DateTimeOffset |
Optional |
|
LockedInd |
Indicates whether the progress pay event is locked or not. Available values are Y and N and default value is N. |
String |
Optional |
|
DeliveryInd |
Indicates whether the progress pay event is successfully delivered or not. Available values are Y and N and default value is N. |
String |
Optional |
|
ManualInd |
Indicates whether the progress pay event is manually managed or automated. Available values are Y and N and default value is N.
|
String |
Optional |
|
ShortDescription |
Language dependent short description of progress pay event.
|
String |
Optional |
|
Description |
Language dependent description of the progress pay event.
|
String |
Optional |
Maximum allowed length is 500. |
ActualPaymentDate |
The actual date when the payment for the pay event will be made. |
DateTimeOffset |
Optional |
|
PaidInd |
Indicates whether the progress pay event is paid or not. Available values are Y and N and default value is N.
|
String |
Optional |
Sample Body
POST
http://localhost:63180/SMAT/V1/Projects('RS')/Disciplines('PIPING')/Nls('English')/PurchaseOrders(8042)/CreateUpdateProgressPayEvents
{
"PPE":
[
{
"AttpId":10000143788,
"OrderSeq": 4,
"PpeCode": "FOUND",
"PaymentPercent":0,
"CostValue": 0,
"PlanCompletionDate": null,
"PaymentWeeks": null,
"PaymentDate": null,
"LockedInd": "N",
"DeliveryInd": "N",
"PaidInd":"N"
},
{
"AttpId":10000144376,
"OrderSeq": 5,
"PpeCode": "H-2",
"PaymentPercent":15,
"CostValue": 0,
"PlanCompletionDate": null,
"PaymentWeeks": null,
"PaymentDate": null,
"LockedInd": "N",
"DeliveryInd": "N",
"PaidInd":"Y"
}
]
}
Success Response
Status: 200OK
{
"@odata.context": "http://localhost:57101/SMAT/V1/$metadata#bindingParamater",
"value": [
{
"AttpId": 10000143785,
"PohId": 8042,
"DpId": 5020,
"ProjId": "RS",
"OrderSeq": 1,
"PpeId": 10000005555,
"PpeCode": "PPE1",
"ShortDesc": null,
"Description": null,
"PlanCompletionDate": null,
"PaymentPercent": 50,
"PaymentWeeks": null,
"CostValue": 426,
"PaymentDate": null,
"LockedInd": "N",
"ManualInd": "N",
"DeliveryInd": "N",
"ActualPaymentDate": null,
"PaidInd": "N"
},
{
"AttpId": 10000143786,
"PohId": 8042,
"DpId": 5020,
"ProjId": "RS",
"OrderSeq": 2,
"PpeId": 5323,
"PpeCode": "H-1",
"ShortDesc": "H-1",
"Description": "H-1",
"PlanCompletionDate": null,
"PaymentPercent": 20,
"PaymentWeeks": null,
"CostValue": 170.4,
"PaymentDate": null,
"LockedInd": "N",
"ManualInd": "N",
"DeliveryInd": "Y",
"ActualPaymentDate": "2024-01-10T00:00:00+05:30",
"PaidInd": "Y"
},
{
"AttpId": 10000143787,
"PohId": 8042,
"DpId": 5020,
"ProjId": "RS",
"OrderSeq": 3,
"PpeId": 5204,
"PpeCode": "INSTALL",
"ShortDesc": "Installation",
"Description": "Installation completed",
"PlanCompletionDate": null,
"PaymentPercent": 0,
"PaymentWeeks": null,
"CostValue": 0,
"PaymentDate": null,
"LockedInd": "N",
"ManualInd": "N",
"DeliveryInd": "Y",
"ActualPaymentDate": "2023-10-10T00:00:00+05:30",
"PaidInd": "Y"
},
{
"AttpId": 10000143788,
"PohId": 8042,
"DpId": 5020,
"ProjId": "RS",
"OrderSeq": 4,
"PpeId": 5202,
"PpeCode": "FOUND",
"ShortDesc": "Foundation",
"Description": "Foundation completed",
"PlanCompletionDate": null,
"PaymentPercent": 0,
"PaymentWeeks": null,
"CostValue": 0,
"PaymentDate": null,
"LockedInd": "N",
"ManualInd": "N",
"DeliveryInd": "N",
"ActualPaymentDate": null,
"PaidInd": "N"
},
{
"AttpId": 10000144376,
"PohId": 8042,
"DpId": 5020,
"ProjId": "RS",
"OrderSeq": 5,
"PpeId": 5324,
"PpeCode": "H-2",
"ShortDesc": "H-2",
"Description": "H-2",
"PlanCompletionDate": null,
"PaymentPercent": 15,
"PaymentWeeks": null,
"CostValue": 127.8,
"PaymentDate": null,
"LockedInd": "N",
"ManualInd": "N",
"DeliveryInd": "N",
"ActualPaymentDate": "2024-01-18T08:42:49+05:30",
"PaidInd": "Y"
},
{
"AttpId": 10000144536,
"PohId": 8042,
"DpId": 5020,
"ProjId": "RS",
"OrderSeq": 6,
"PpeId": 10000006795,
"PpeCode": "PPEDEMO",
"ShortDesc": null,
"Description": null,
"PlanCompletionDate": null,
"PaymentPercent": 15,
"PaymentWeeks": null,
"CostValue": 127.8,
"PaymentDate": null,
"LockedInd": "N",
"ManualInd": "N",
"DeliveryInd": "N",
"ActualPaymentDate": "2024-01-18T08:11:57+05:30",
"PaidInd": "Y"
}
]
}