Inputs and Binary File Uploads shows you how this works:
POST /services/data/v42.0/chatter/users/me/photo HTTP/1.1
Authorization: OAuth 00DD0000000Jhd2!AQIAQC.lh4qTQcBhOPm4TZom5IaOOZLVPVK4wI_rPYJvmE8r2VW8XA.
OZ7S29JEM_7Ctq1lst2dzoV.owisJc0KacUbDxyae
User-Agent: Jakarta Commons-HttpClient/3.0.1
Host: ***instance_name***
Content-Length: 543
Content-Type: multipart/form-data; boundary=a7V4kRcFA8E79pivMuV2tukQ85cmNKeoEgJgq
Accept: application/json
--a7V4kRcFA8E79pivMuV2tukQ85cmNKeoEgJgq
Content-Type: application/json; charset=UTF-8
Content-Disposition: form-data; name="json"
{
"cropX" : "0",
"cropY" : "0",
"cropSize" : "200"
}
--a7V4kRcFA8E79pivMuV2tukQ85cmNKeoEgJgq
Content-Disposition: form-data; name="fileUpload"; filename="myPhoto.jpg"
Content-Type: application/octet-stream; charset=ISO-8859-1
...contents of myPhoto.jpg...
--a7V4kRcFA8E79pivMuV2tukQ85cmNKeoEgJgq--
It's a normal multipart/form-data upload mechanism. However, since you need to upload binary data, you will likely be unable to directly use Workbench to accomplish this task.
You can use something like CURL, as also mentioned in the documentation:
curl -H "X-PrettyPrint: 1" -F 'json={"cropX": "0", "cropY": "0", "cropSize": "200"};type=application/json'
-F "[email protected];type=application/octet-stream"
-X POST https://***instance_name***/services/data/v42.0/chatter/users/me/photo
-H 'Authorization: OAuth 00DRR0000000N0g!ARoAQFRi_gBqZhajAX22MNuLrrE2Xk...'
--insecure