curl --request POST \
--url https://api.eka.care/ipd/v1/service/dawakhana/orders/{order_id}/dispatch \
--header 'Content-Type: application/json' \
--header 'auth: <auth>' \
--data '
{
"lines": [
{
"itemId": "66f1cd07e4b0a1b2c3d4ef0b",
"fulfilledQty": 10,
"rate": 4.5
}
],
"note": "Handed over at nursing station"
}
'import requests
url = "https://api.eka.care/ipd/v1/service/dawakhana/orders/{order_id}/dispatch"
payload = {
"lines": [
{
"itemId": "66f1cd07e4b0a1b2c3d4ef0b",
"fulfilledQty": 10,
"rate": 4.5
}
],
"note": "Handed over at nursing station"
}
headers = {
"auth": "<auth>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {auth: '<auth>', 'Content-Type': 'application/json'},
body: JSON.stringify({
lines: [{itemId: '66f1cd07e4b0a1b2c3d4ef0b', fulfilledQty: 10, rate: 4.5}],
note: 'Handed over at nursing station'
})
};
fetch('https://api.eka.care/ipd/v1/service/dawakhana/orders/{order_id}/dispatch', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.eka.care/ipd/v1/service/dawakhana/orders/{order_id}/dispatch",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'lines' => [
[
'itemId' => '66f1cd07e4b0a1b2c3d4ef0b',
'fulfilledQty' => 10,
'rate' => 4.5
]
],
'note' => 'Handed over at nursing station'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"auth: <auth>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.eka.care/ipd/v1/service/dawakhana/orders/{order_id}/dispatch"
payload := strings.NewReader("{\n \"lines\": [\n {\n \"itemId\": \"66f1cd07e4b0a1b2c3d4ef0b\",\n \"fulfilledQty\": 10,\n \"rate\": 4.5\n }\n ],\n \"note\": \"Handed over at nursing station\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("auth", "<auth>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.eka.care/ipd/v1/service/dawakhana/orders/{order_id}/dispatch")
.header("auth", "<auth>")
.header("Content-Type", "application/json")
.body("{\n \"lines\": [\n {\n \"itemId\": \"66f1cd07e4b0a1b2c3d4ef0b\",\n \"fulfilledQty\": 10,\n \"rate\": 4.5\n }\n ],\n \"note\": \"Handed over at nursing station\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.eka.care/ipd/v1/service/dawakhana/orders/{order_id}/dispatch")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["auth"] = '<auth>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"lines\": [\n {\n \"itemId\": \"66f1cd07e4b0a1b2c3d4ef0b\",\n \"fulfilledQty\": 10,\n \"rate\": 4.5\n }\n ],\n \"note\": \"Handed over at nursing station\"\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"id": "66f1cd07e4b0a1b2c3d4ef0a",
"admissionId": "a1b2c3d4-5678-90ab-cdef-1234567890ab",
"kind": "order",
"orderNumber": "DW-7Q2K9F3M",
"status": "DISPATCHED",
"createdBy": "161467756044203",
"isCollected": false,
"provider": "dawakhana",
"billedTotal": 45,
"fulfilmentType": "FULL",
"dispatchNote": "Handed over at nursing station",
"dispatchedBy": "161467756044204",
"dispatchedByName": "Meena Iyer",
"dispatchedAt": "2026-10-07T12:40:00.000Z",
"createdAt": "2026-10-07T12:10:00.000Z",
"updatedAt": "2026-10-07T12:40:00.000Z",
"lines": [
{
"id": "66f1cd07e4b0a1b2c3d4ef0b",
"medicineId": "med-paracetamol-500",
"name": "Paracetamol 500mg Tablet",
"orderedQty": 10,
"fulfilledQty": 10,
"rate": 4.5,
"amount": 45,
"lineStatus": "FULFILLED"
}
]
}
}{
"success": false,
"error": "Only a pending order can be dispatched"
}{
"message": "<string>"
}{
"success": false,
"error": "Order not found"
}Dispatch Dawakhana Order
Overview
This API dispatches a pending Dawakhana order of your workspace: for each order line, send the quantity actually given (fulfilledQty) and the price per unit (rate). Only an order in status CREATED can be dispatched.
For each line sent, amount is fulfilledQty × rate and the line status becomes FULFILLED (full quantity), PARTIAL (less than ordered) or UNAVAILABLE (fulfilledQty of 0). Lines are matched by their id from Get Dawakhana Order; lines that are not sent stay PENDING.
The order moves to DISPATCHED, with billedTotal set to the sum of line amounts and fulfilmentType set to FULL only when every line is FULFILLED (otherwise PARTIAL). The fulfilled medicines are added to the admission’s bill. The user making the request is recorded in dispatchedBy, dispatchedByName and dispatchedAt.
curl --request POST \
--url https://api.eka.care/ipd/v1/service/dawakhana/orders/{order_id}/dispatch \
--header 'Content-Type: application/json' \
--header 'auth: <auth>' \
--data '
{
"lines": [
{
"itemId": "66f1cd07e4b0a1b2c3d4ef0b",
"fulfilledQty": 10,
"rate": 4.5
}
],
"note": "Handed over at nursing station"
}
'import requests
url = "https://api.eka.care/ipd/v1/service/dawakhana/orders/{order_id}/dispatch"
payload = {
"lines": [
{
"itemId": "66f1cd07e4b0a1b2c3d4ef0b",
"fulfilledQty": 10,
"rate": 4.5
}
],
"note": "Handed over at nursing station"
}
headers = {
"auth": "<auth>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {auth: '<auth>', 'Content-Type': 'application/json'},
body: JSON.stringify({
lines: [{itemId: '66f1cd07e4b0a1b2c3d4ef0b', fulfilledQty: 10, rate: 4.5}],
note: 'Handed over at nursing station'
})
};
fetch('https://api.eka.care/ipd/v1/service/dawakhana/orders/{order_id}/dispatch', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.eka.care/ipd/v1/service/dawakhana/orders/{order_id}/dispatch",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'lines' => [
[
'itemId' => '66f1cd07e4b0a1b2c3d4ef0b',
'fulfilledQty' => 10,
'rate' => 4.5
]
],
'note' => 'Handed over at nursing station'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"auth: <auth>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.eka.care/ipd/v1/service/dawakhana/orders/{order_id}/dispatch"
payload := strings.NewReader("{\n \"lines\": [\n {\n \"itemId\": \"66f1cd07e4b0a1b2c3d4ef0b\",\n \"fulfilledQty\": 10,\n \"rate\": 4.5\n }\n ],\n \"note\": \"Handed over at nursing station\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("auth", "<auth>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.eka.care/ipd/v1/service/dawakhana/orders/{order_id}/dispatch")
.header("auth", "<auth>")
.header("Content-Type", "application/json")
.body("{\n \"lines\": [\n {\n \"itemId\": \"66f1cd07e4b0a1b2c3d4ef0b\",\n \"fulfilledQty\": 10,\n \"rate\": 4.5\n }\n ],\n \"note\": \"Handed over at nursing station\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.eka.care/ipd/v1/service/dawakhana/orders/{order_id}/dispatch")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["auth"] = '<auth>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"lines\": [\n {\n \"itemId\": \"66f1cd07e4b0a1b2c3d4ef0b\",\n \"fulfilledQty\": 10,\n \"rate\": 4.5\n }\n ],\n \"note\": \"Handed over at nursing station\"\n}"
response = http.request(request)
puts response.read_body{
"success": true,
"data": {
"id": "66f1cd07e4b0a1b2c3d4ef0a",
"admissionId": "a1b2c3d4-5678-90ab-cdef-1234567890ab",
"kind": "order",
"orderNumber": "DW-7Q2K9F3M",
"status": "DISPATCHED",
"createdBy": "161467756044203",
"isCollected": false,
"provider": "dawakhana",
"billedTotal": 45,
"fulfilmentType": "FULL",
"dispatchNote": "Handed over at nursing station",
"dispatchedBy": "161467756044204",
"dispatchedByName": "Meena Iyer",
"dispatchedAt": "2026-10-07T12:40:00.000Z",
"createdAt": "2026-10-07T12:10:00.000Z",
"updatedAt": "2026-10-07T12:40:00.000Z",
"lines": [
{
"id": "66f1cd07e4b0a1b2c3d4ef0b",
"medicineId": "med-paracetamol-500",
"name": "Paracetamol 500mg Tablet",
"orderedQty": 10,
"fulfilledQty": 10,
"rate": 4.5,
"amount": 45,
"lineStatus": "FULFILLED"
}
]
}
}{
"success": false,
"error": "Only a pending order can be dispatched"
}{
"message": "<string>"
}{
"success": false,
"error": "Order not found"
}Headers
Path Parameters
Id of the Dawakhana order to dispatch.
Body
The fulfilled quantity and rate per line.
Was this page helpful?

