public function status($wait = false, $syncResponse = null) {
    $syncResponse = $this->getResponse('sync', $syncResponse);
    $uri = trim($syncResponse['uri'], '/');

    do {
      $status = $this->get($uri);
    } while ($wait and $this->isWaitingStatus($status) and sleep(1) === 0);

    return $this->setResponse('status', $status);
  }