Skip to content

Command 102 — Accept ordersrework

V1 packed both actions into one call with a flag and a list of orders. V2 has one endpoint per action, one call per order part.

API V1API V2
AcceptOrder=1 (accept)POST /order/{orderGID}/num/{orderGPartNum}/accept
AcceptOrder=0 (back to pending)No direct equivalent — see halt below.
ordersGIDs[]=1,0 · ordersGIDs[]=1,1one call per pair (orderGID, orderGPartNum)

V2 checks an app permission on every call — V1 checked none — and a call whose permission is missing answers 400 with errorCode 15, the same status as an invalid payload (see 4.4). Grant these to the API user before porting the command; the names are the ones of the permission tree in flowww.

CallPermission
POST /order/{orderGID}/num/{orderGPartNum}/acceptStock Control - Orders → Accept
GET /order/{orderGID}/num/{orderGPartNum}Stock Control - Orders → See
GET /orderStock Control - Orders → List
API V1 — one request for the whole batch
curl --location 'https://euapi.flowww.net/v1/fwa_external_get.asp?cmd=102&doctor=USER_LOGIN&pass=USER_PASS&country=ES&key=SYSTEM_KEY&ClinicID=1' \
--data-urlencode 'AcceptOrder=1' \
--data-urlencode 'ordersGIDs[]=25,0' \
--data-urlencode 'ordersGIDs[]=25,1'
API V2 — one request per order part
curl --location --request POST 'https://api.flowww.net/v2/order/25/num/0/accept?clinicID=1' \
--header 'Authorization: Bearer <api_key>'
curl --location --request POST 'https://api.flowww.net/v2/order/25/num/1/accept?clinicID=1' \
--header 'Authorization: Bearer <api_key>'
TopicAPI V1API V2
BatchAll or nothing: if one order could not be accepted, none was (108010).Each call stands alone.
PreconditionsOnly orders already sent by the clinic and not yet shipped could be accepted.Not checked. accept sets the order to accepted whatever its state — even one already shipped. Read it first (GET /order/{orderGID}/num/{orderGPartNum}) and only accept orders that are sent (OrderGReady: true) and PENDING.
All partsOmitting the part number accepted every part of the order.One call per part: list the parts with GET /order.

POST …/halt withdraws an order sent by the clinic: it returns to the clinic as not sent, but it does not undo a command 102 acceptance or a shipment, and it does not move stock. For orders, GET …/send sends to the purchasing centre and POST …/send ships from it (commands 39 and 103).

AnswerMeaning
400 248The order part does not exist.
404 246 (halt)Nothing to withdraw: the order part does not exist or was not sent.
400 (errorCode 15)The API user lacks Orders → Accept / Stop order.