CL Receive POST API

Clovertech Forums Cloverleaf CL Receive POST API

Tagged: 

  • Creator
    Topic
  • #120609
    MiDo
    Participant

      We are working on a new interface from that would send patient info and Order info to Cloverleaf via POST API  They want us to accept them via HTTP Post.  It looks to me like Cloverleaf can SEND messages this way using the HTTP Client protocol or PROTOCOL:java/ws-rawclient and selecting the method of POST.  However, I’m not sure how Cloverleaf could receive like this.

      URL
      http://ipaddress:port/

      Method
      POST

      HTTP Header
      Content-type: application/json

      Body
      The body contains a JSON object that represents the date for worklist
      Sample JSON body
      {
      “required”: {
      “Message_ID”: “Maximum 20 characters”,
      “Action”: “NW/CA/XO”,
      “Patient_ID”: “Maximum 64 characters”,
      “Patient_Name”: “Lastname^Firstname^Middlename^Prefix^Suffix”,
      “Date_of_Birth”: “YYYY-MM-DD”,
      “Accession_Number”: “Maximum 16 characters”,
      “Requested_Procedure_ID”: “Maximum 16 characters “,
      “Scheduled_AE_Station”: “Maximum 16 characters”,
      “Modality”: “Maximum 16 characters”,
      “Scheduled_Start_Date”: “YYYY-MM-DD”,
      “Scheduled_Start_Time”: “HH:mm”
      },
      “optional”: {
      “Patient_Sex”: “M”,
      “Study_Instance_UID”: “”,
      “Additional_Patient_History”: “Maximmum 10240 characters”,
      “Referring_Physician_Name”: “Lastname^Firstname^Middlename^Prefix^Suffix”,
      “Requesting_Physician_Name”: “Lastname^Firstname^Middlename^Prefix^Suffix”,
      “Requested_Procedure_Description”: “Maximum 64 characters”,
      “Requested_Procedure_Priority”: “Maximum 16 characters”,
      “Performing_Physician_Name”: “Lastname^Firstname^Middlename^Prefix^Suffix”,
      “Scheduled_Procedure_ID”: “Maximum 16 characters”,
      “Scheduled_Procedure_Description”: “Maximum 64 characters”,
      “Scheduled_Procedure_Location”: “Maximum 16 characters “,
      “Scheduled_Procedure_PreMedication”: “Maximum 64 characters”,
      “Scheduled_Procedure_Contrast_Agent”: “Maximum 64 characters”,
      “Procedure_Code_Value”: “Maximum 16 characters”,
      “Procedure_Code_Meaning”: “Maximum 64 characters”,
      “Procedure_Code_Scheme”: “Maximum 16 characters”,
      “Procedure_Code_Scheme_Version”: “Maximum 16 characters”,
      “Protocol_Code_Value”: “Maximum 16 characters “,
      “Protocol_Code_Meaning”: “Maximum 64 characters”,
      “Protocol_Code_Scheme”: “Maximum 16 characters”,
      “Protocol_Code_Scheme_Version”: “Maximum 16 characters”
      }
      }

      Returns

      200 – Successful
      400 – Failed

    Viewing 5 reply threads
    • Author
      Replies
      • #120610
        John Mercogliano
        Participant

          You will want to use the ws-server protocol with the Raw handler. You can create a reply message with a blank body.  Add the httpResponseCode with a 200 or 400 code in the userdata.

          Hopefully this is for getting data from another application in your network otherwise you will have some additional security work.

          I would recommend looking at the ws_more_samples box cloverleaf provides.  This is located in CAA/ws/samples/ directory.

          Other than adding security I didn’t make any changes to the protocol setup.

           

           

          John Mercogliano
          Sentara Healthcare
          Hampton Roads, VA

        • #120611
          MiDo
          Participant

            thanks John

            so far the application is on the same network as my cloverleaf so i a less concerned about security work right now but this is good to consider in another installations as well

            i actually went to CAA/ws/samples/ directory but i was not able to deploy Box , as box manager cannot reach this destination , and by copying the content (Box files) to the box folder itself i could not also see them ..

            is there any Guidance I can find anywhere on how to deploy

            thanks

          • #120615
            John Mercogliano
            Participant

              The samples are delivered with the client install.  You need to open up the box manager and select import from the BOX menu.  you can then browse to the directory.

              John Mercogliano
              Sentara Healthcare
              Hampton Roads, VA

            • #120620
              MiDo
              Participant

                thanks Again John

                I managed to deploy “ws_more_samples”and have done some tests on “web_form_server” however what i noticed that the “web_form_server” listener side is very fragile the slightest change i do on the config it got into panic mode and i am not able to recover then the only solution is to redeploy again in new side

                slightest change like setting the hostname or changing the port after restart only goes to panic mode

                i need to at least se the hostname ” not to localhost root”

                see attached log

                Attachments:
                You must be logged in to view attached files.
              • #120623
                John Mercogliano
                Participant

                  This line in the log “http://MyWebservice:80/json:4784/dummyServerToStartPortForRawServer”

                  would seem to indicate you placed something in the host line on the server config which you don’t need to do.  The localhost is just for testing purposes when connecting from a client on the same machine for ease, but from the client you can use the actual dns name of the web server or any dns entry that points to the server ip address.  With out the host, it just says to listen on the requested port for any traffic.  I’ve never actually tried to use the host field so cannot say how it actually works as I never found a need.

                  I did not mess with the form paradigm just the trxid one as that is how I set mine up to work but it seems that both servers are setup essentially the same.

                   

                  John Mercogliano
                  Sentara Healthcare
                  Hampton Roads, VA

                • #120916
                  MiDo
                  Participant

                    thanks to all

                    instruction was really clear and help a lot

                     

                Viewing 5 reply threads
                • You must be logged in to reply to this topic.