It is maintained by the Infrared Data Association but has also been adopted by the Bluetooth Special Interest Group and the SyncML wing of the Open Mobile Alliance (OMA).
Although OBEX was initially designed for infrared, it has now been adopted by Bluetooth, and is also used over RS-232, USB, WAP and in devices such as Livescribe smartpens.
This example shows a single GET command and its response, the only headers involved being connection id, name and end-of-body.
For example, SyncML does not use SETPATH, while an OBEX push is made of just CONNECT (without a TARGET header), PUT and an optional DISCONNECT.
[1] OpenObex is an open-source implementation of OBEX in C. It provides functions for connecting over IrDA, Bluetooth, USB and TCP/IP, building objects and handling received data.
The callback function can determine whether the response has been completely received, and therefore whether the main program can exit from the while loop it is executing.