> echo hash('sha256', 'bla-bla-bla');
> e29256c37ac614866b41c51eb8bf013d2f0b208988a21016e0abf6e81fc99c58
$salt = "21x1231";
$code = file_get_contetns('api...');
$code = json_decode($code);
$token = $code->token;
$hash = strtolower(md5($token.$salt));
$data = file_get_contents('url?param='.$token.'&tok='.$hash);
echo 'sha384-' . base64_encode(hash_file('sha384', 'path-to-file', true));
// или
echo 'sha384-' . base64_encode(hash('sha384', file_get_contents('path-to-file'), true));