Edit unit image

To assign the image to unit, use the command unit/update_image:

Same as at the other (e.g. when you copy unit)

svc=unit/update_image&params={"itemId":<long>,
			      "oldItemId":<long>}

From library:

svc=unit/update_image&params={"itemId":<long>,
			      "libId":<long>,
			      "path":<text>}

Parameters

Name Description
itemId new unit ID
oldItemId old unit ID
libId ID of resource with image (for default library – 0)
path image file location

Response

{}	/* empty object if execution successful, if not - error code */