Cancel a Requisition Header or Line

You can use cancel a custom action on the Purchase Requisitions REST resource for a requisition or a requisition line that is not associated with any downstream document such as a purchase order, transfer order, or a negotiation. Cancelling all the lines in a requisition cancels the requisition.

You can't cancel a requisition that is in Incomplete status. Both external and internal purchase requisitions can be cancelled using this operation. After cancellation, the requisition status changes to Cancelled and the document history is updated.

You should have the Preparer or the Procurement REST Service Duty role to cancel a requisition.

Let's discuss these scenarios:
  • Cancel a requisition that is not associated with a purchase order.

  • Cancel a Budgetary Control and Encumbrance Accounting (BCEA) requisition line that is not associated with a purchase order. This is driven by a profile option, POR_ALLOW_REST_CANCEL_ON_BCEA_FAILURE, if funds can't be released on cancelling the requisition or line.

Cancel a Requisition Not Associated with a Purchase Order

Let's consider that Jim Kenworthy, who is a preparer in an organization, submitted a requisition. But his manager, rejected it asking for some clarification. Jim then realized that he created the requisition for an incorrect item and decided to cancel it. He can achieve this using the Cancel custom action.

cURL Command
curl -u username:password -X POST -H "Content-Type: application/vnd.oracle.adf.action+json" -d 'request payload'
"https://servername/fscmRestApi/resources/version/purchaseRequisitions/RequisitionHeaderId"

Example Request

Here's an example of the request body in JSON format:
{

"name":"cancel",

"parameters": [{"cancelReason":"Cancelled via REST"}]

}

Example Response

Here's an example of the response body in JSON format:

{

  "result": {

    "STATUS": [

      {

        "CODE": "SUCCESS"

      }

    ]

  }

}

Cancel a BCEA Requisition Not Associated with a Purchase Order

Let's consider that John Phill, who is a preparer, has created a requisition for a requester, Erik. The requisition is approved and funds are reserved. But Erik has left the organization. So John wants to cancel the requisition and release the funds.

He can cancel this requisition just as he would any non-BCEA requisition. Then the requisition would be cancelled and the funds status would be Not Reserved.

If for some reason, the funds can't be released after cancellation, he can choose to go ahead with cancellation or refrain from cancelling the requisition. This can be done by setting up the profile option POR_ALLOW_REST_CANCEL_ON_BCEA_FAILURE.

In such cases, if this profile option is set to Yes, then you can cancel the requisition even if funds can't be released. If it is set to No, you will not be allowed to cancel the requisition and an error would occur upon cancelling. The default value is null, which is considered as No.

Let's consider a scenario where the profile option is set to Yes.

By the time John decides to cancel the requisition, the budget period is closed. In such a case the requisition can be cancelled but the funds can't be released.

cURL Command
curl -u username:password -X POST -H "Content-Type: application/vnd.oracle.adf.action+json" -d 'request payload'"https://servername/fscmRestApi/resources/version/purchaseRequisitions/RequisitionHeaderId"

Example Request

Here's an example of the request body in JSON format:

{

"name":"cancel",

"parameters": [{"cancelReason":"Cancelled via REST"}]

}

Example Response

Here's an example of the response body in JSON format:

{ 

"result": {   

"STATUS": [     

{        

"CODE": "PARTIAL_SUCCESS"     

}    

],    

"RETURN_MESSAGES": [     

{        

"MESSAGE_TYPE": "WARNING",       

"MESSAGE": "The requisition or the requisition line is canceled, but funds couldn't be released. View the requisition to check the funds status details."     

}    

]  

}

}