Lewati ke konten

List stock batches (lots)

GET
/api/dash/{orgId}/outlets/{outletId}/stock/batches
curl --request GET \
--url 'https://api.medivy.id/api/dash/example/outlets/example/stock/batches?page=1&size=20&expiry=expired&groupBy=product&sort=expiryDate&order=asc' \
--header 'x-api-key: <x-api-key>'
orgId
required
string

Your organization ID. The API key must belong to this organization.

outletId
required
string

Outlet ID. The key’s user must be assigned to this outlet.

page
number | null
default: 1
size
number | null
default: 20
search
string
variantId
string
outletId
string
status
string
expiringWithinDays
number | null
expiry
string
Allowed values: expired 7d 30d 90d
groupBy
string
Allowed values: product
sort
string
Allowed values: expiryDate createdAt batchNo productName remainingQty unitCost
order
string
Allowed values: asc desc

OK

Media typeapplication/json

Example generated

example

Missing, invalid, disabled or expired API key.

Media typeapplication/json
object
ok
message
string

Example

{
"ok": false
}

The key belongs to another organization, the request came from an IP outside the key’s allowlist, or the key’s user lacks the permission.

Media typeapplication/json
object
ok
message
string

Example

{
"ok": false
}

Too many requests from this organization.

Media typeapplication/json
object
ok
message
string

Example

{
"ok": false
}