...
Tip | |||||||
---|---|---|---|---|---|---|---|
Before you begin,
|
...
Info |
---|
|
...
- Open a terminal and navigate to the
<EI_HOME>/wso2/msf4j/bin
directory. Start the runtime by executing the MSF4J startup script as shown below.
Panel borderColor #542989 bgColor #ffffff borderWidth 1 Localtabgroup Localtab title On MacOS/Linux/CentOS Open a terminal and execute the following command:
wso2ei-6.4.0-msf4jCode Block Code Block sh carbon.sh
Localtab title On Windows Go to Start Menu -> Programs -> WSO2 -> Enterprise Integrator 6.4.0 MSF4J. This will open a terminal and start the MSF4J profile. Code Block carbon.bat
The Healthcare service is now active and you can start sending requests to the service.
...
Create a JSON file named
request.json
with the following request payload.Code Block { "name": "John Doe", "dob": "1940-03-19", "ssn": "234-23-525", "address": "California", "phone": "8770586755", "email": "johndoe@gmail.com", "doctor": "thomas collins", "hospital": "grand oak community hospital", "cardNo": "7844481124110331", "appointment_date": "2025-04-02" }
Open a command line terminal and execute the following command from the location where the
request.json
file was saved:Code Block curl -v -X POST --data @request.json http://localhost:8280/healthcare/categories/surgery/reserve --header "Content-Type:application/json"
Info This is derived from the URI-Template defined when creating the API resource.
http://<host>:<port>/categories/{category}/reserve
You will see the response as follows:
Code Block { "appointmentNo":1, "doctorName":"thomas collins", "patient":"John Doe", "actualFee":7000.0, "discount":20, "discounted":5600.0, "paymentID":"480fead2-e592-4791-941a-690ad1363802", "status":"Settled" }
...