for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
declare(strict_types=1);
namespace UMA\JsonRpc;
final class Success extends Response
{
/**
* @var mixed|null
*/
private $result;
* @param int|string|null $id
* @param mixed $result
public function __construct($id, $result = null)
$this->id = $id;
$this->result = $result;
}
public function jsonSerialize(): array
return [
'jsonrpc' => '2.0',
'result' => $this->result,
'id' => $this->id
];