public function createDeployement(string $ref, string $task = AbstractApi::TASK_DEPLOY, bool $autoMerge = true,
                                      array $requiredContexts = [], string $payload = '',
                                      string $environment = AbstractApi::ENVIRONMENT_PRODUCTION,
                                      string $description = ''): array
    {
        return $this->getApi()->request($this->getApi()->sprintf('/repos/:owner/:repo/deployments',
            $this->getRepositories()->getOwner(), $this->getRepositories()->getRepo()), Request::METHOD_POST, [
                'ref'               => $ref,
                'task'              => $task,
                'auto_merge'        => $autoMerge,
                'required_contexts' => $requiredContexts,
                'payload'           => $payload,
                'environment'       => $environment,
                'description'       => $description
            ]);
    }