Send the request with specified data

@param  mixed $data The data to send
@return ResponseInterface
516447
public function sendData($subscriptionId)
    {
        $response = $this->braintree->subscription()->cancel($subscriptionId);

        return $this->response = new SubscriptionResponse($this, $response);
    }
1125196
public function sendData($data)
    {
        if (isset($data['result'])) {
            $request = new AopVerifyAppPayReturnRequest($this->httpClient, $this->httpRequest);
            $request->initialize($this->parameters->all());
            $request->setEndpoint($this->getEndpoint());
            $request->setResult($data['result']);
            $request->setAlipayPublicKey($this->getAlipayPublicKey());
            $data = $request->send()->getData();
        } else {
            $request = new AopNotifyRequest($this->httpClient, $this->httpRequest);
            $request->initialize(['params' => $data]);
            $request->setEndpoint($this->getEndpoint());
            $request->setAlipayPublicKey($this->getAlipayPublicKey());
            $data = $request->send()->getData();

            if (! array_get($data, 'trade_status')) {
                $tn = array_get($data, 'trade_no');

                $request = new AopTradeQueryRequest($this->httpClient, $this->httpRequest);
                $request->initialize($this->getParameters());
                $request->setEndpoint($this->getEndpoint());
                $request->setBizContent(['trade_no' => $tn]);
                $request->setPrivateKey($this->getPrivateKey());

                /**
                 * @var AopTradeQueryResponse $response
                 */
                $response = $request->send();

                $tradeStatus = $response->getAlipayResponse('trade_status');

                $data['trade_status'] = $tradeStatus;
            }
        }

        return $this->response = new AopCompletePurchaseResponse($this, $data);
    }
122431
public function sendData($data)
    {
        $data = $this->httpRequest('back', $data);

        $env        = $this->getEnvironment();
        $rootCert   = $this->getRootCert();
        $middleCert = $this->getMiddleCert();

        $data['verify_success'] = ResponseVerifyHelper::verify($data, $env, $rootCert, $middleCert);

        return $this->response = new WtzBackOpenResponse($this, $data);
    }
583108
private function send($data)
	{
		$rawMessage = json_encode($data);
		$payload = new WebsocketPayload;
		$payload->setOpcode(WebsocketPayload::OPCODE_TEXT)
				->setMask(TRUE)
				->setPayload($rawMessage);
		$encoded = $payload->encodePayload();
		fwrite($this->fd, $encoded);

		return $this;
	}
1343973
public function sendData($data)
    {
        $response = $this->gocardless->customerBankAccounts()->disable($this->getBankAccountReference());

        return $this->response = new BankAccountResponse($this, $response);
    }
793255
public function sendData($data)
    {
        $data = parent::sendData($data);

        return $this->response = new AopTradeOrderSettleResponse($this, $data);
    }
846528
public function sendData($data)
    {
        $url = $this->getEndpoint() . '?' . http_build_query($data);
        $httpResponse = $this->httpClient->get($url)->send();

        $xml = $httpResponse->xml();
        return $this->createResponse($xml);
    }
1109306
public function sendData($data)
    {
        $httpResponse = $this->sendRequest('GET', '/gateways', json_encode($data));

        $this->response = new RestFetchPaymentMethodsResponse(
            $this,
            json_decode($httpResponse->getBody()->getContents(), true)
        );

        return $this->response;
    }
263010
public function sendData($data)
    {
        $data = parent::sendData($data);

        return $this->response = new AopTransferToAccountQueryResponse($this, $data);
    }
45161
public function sendData($data)
    {
        $response = $this->gocardless->payments()->cancel($this->getPaymentId());

        return $this->response = new PaymentResponse($this, $response);
    }
539827
public function sendData($data)
    {
        $response = $this->braintree->transaction()->refund($data['transactionReference'], $data['amount']);

        return $this->createResponse($response);
    }
691017
public function sendData($data)
    {
        $response = $this->braintree->transaction()->find($data['transactionReference']);

        return $this->createResponse($response);
    }
1219144
public function sendData($data)
    {
        $response = $this->gocardless->customers()->create($data);

        return $this->response = new CustomerResponse($this, $response);
    }
456318
public function sendData($data)
    {
        $headers  = $this->getHeaders();
        $gge4Date = $this->getGge4Date();
        $endpoint = $this->getEndpoint();

        $url = parse_url($endpoint);

        $contentDigest = sha1(json_encode($data));

        $hashString = $this->buildHashString($contentDigest, $gge4Date, $url['path']);

        $authString = $this->buildAuthString($hashString);

        $headers["X-GGe4-Content-SHA1"] = $contentDigest;
        $headers["X-GGe4-Date"]         = $gge4Date;
        $headers["Authorization"]       = $authString;

        $httpResponse = $this->httpClient->request(
            self::METHOD_POST,
            $endpoint,
            $headers,
            json_encode($data)
        );

        return $this->createResponse($httpResponse->getBody()->getContents());
    }
357004
public function send($data = [])
    {
        if (is_array($data)) {
            $data = json_encode($data);
        }

        $this->getBody()->write($data);

        return $this;
    }
1298690
public function sendData($data)
    {
        $httpResponse = $this->httpClient->post($data['url'], null, $data['params'])->send();

        // The body is a string.
        $body = $httpResponse->getBody();

        // Split into lines.
        $data = json_decode($body);

        return $this->response = new OAuthConfirmResponse($this, $data);
    }
1175638
public function sendData($data)
    {
        $data = parent::sendData($data);

        return $this->response = new AopTransferToAccountResponse($this, $data);
    }