DCB Borrowing_PickUp Flow Details

Purpose:

This page provides the steps for end to end transaction flow in Borrowing_Pickup library.

Steps:

1:- CREATE TRANSACTION

  URL : https://folio-dev-volaris-edge.ci.folio.org/dcbService/transactions/12345?apiKey=eyJzIjoieHFpNzNjNEZzOSIsInQiOiJkaWt1IiwidSI6ImRpa3VfYWRtaW4ifQ==

  Note:

    1:-API key should change based on tenant.

  HTTP Method : Post

  Request Body :

  {
    "item": {
        "id": "e58ca7a7-7674-44e5-8a1c-cdb22d0f87ce",
        "title": "Test",
        "barcode": "18",
        "materialType": "book",
        "lendingLibraryCode": "KU"
      },
    "patron": {
        "id": "e58ca3a7-7674-44e5-8a1c-cdb22d0f87ce",
        "barcode": "user2"
    },
    "pickup": {
        "servicePointId": "3a40852d-49fd-4df2-a1f9-6e2641a6e91f"
    },
    "role": "BORROWING-PICKUP"
}

  • Note - In the above payload the fields mentioned and the values are required for the "role": "BORROWING-PICKUP".

  Note:

    1:-The patron should be already exist before making this call.

  The success response will do below activities

    1:- An item will be created in mod-circulation-item schema with  item details provided in payload .

        Note:- Prerequisite for creating an item Instance, Holding location... etc will be created at the time of enabling tenant for DCB.

    2:- A Service point will be created with pickup details in payload.

    3:- A hold request will be created in mod-circulation with status as OPEN-not yet filled.

    4:- A transaction record will be created in DCB schema with status as CREATED and role as BorrowingPickup.

  Note:-

    1:-Once transaction is created for Borrowing_Pickup library, DCB will create a similar transaction manually in Lending library also with role as LENDER and status as CREATED.(DCB Lending Flow Details)

    2:-Once transaction is created in Lending library , The next step , item will be checked in manually in Lending library, This will do below activities

        2.1:- item status will be changed to checkedIn and transaction status in DCB will be changed to OPEN.


2:- UPDATE  TRANSACTION

 Note:-

     DCB will keep on polling the status of Lending Transaction , if its changed from CREATED to OPEN, then DCB will send PUT request also to change the request from CREATED to OPEN for Borrowing_Pickup role.

 URL :-

    https://folio-dev-volaris-edge.ci.folio.org/dcbService/transactions/12345/status?apiKey=eyJzIjoieHFpNzNjNEZzOSIsInQiOiJkaWt1IiwidSI6ImRpa3VfYWRtaW4ifQ==

HTTP Method : PUT

   Request Body : 

  {
    "status" : "OPEN"
  }


3:- GET TRANSACTION STATUS

    To poll/get the status of the transaction, call the below API.

  URL : https://folio-dev-volaris-edge.ci.folio.org/dcbService/transactions/12345/status?apiKey=eyJzIjoieHFpNzNjNEZzOSIsInQiOiJkaWt1IiwidSI6ImRpa3VfYWRtaW4ifQ== 

  HTTP Method : GET


4:- Once the status of Borrowing transaction is OPEN . One needs to checkIn item manually via UI ,this will do below activity:

       4.1:- Item status will be changed to AWAITING_PICKUP

       4.2:- Transaction status for borrowing_PickUp library also changed to AWAITING_PICKUP.

       Note:- Transaction status and item status will only be changed if the service points are same while checkIn the item . if different then there will be no change in item and transaction status.

5:- Once the status of Borrowing_PickUp transaction is AWAITING_PICKUP . One needs to checkOut item manually via UI ,this will do below activity:

       5.1:- Item status will be changed to checked_out

       5.2:- Transaction status for borrowing_PickUp library also changed to ITEM_CHECKED_OUT.

       5.3:- Hold request which was create previously ,will be updated to close-filled.

       5.4:- Loan will be created for patron 

       Note:- Transaction statuses will be in sync with Lending library. For more info about Lending flow(DCB Lending Flow Details

6:- CHECK_IN  ITEM

       One needs to checkIn item . This will do below activities:-

       6.1:- Loan for the patron will be closed

       6.2:- Item status will be updated from checked_out to checked_In .

       6.3:- Transaction status in Borrowing_PickUp library will be changed to ITEM_CHECKED_IN

       Note:- In lending library the transaction status will be closed . DCB will poll the status and if it is CLOSED in Lending library then it will send a PUT request(as mentioned in STEP-2) to changed the status to CLOSED in Borrowing_PickUp library,