lib/AmazonSNS.php
public function publishToEndpoint($deviceArn, $message) {
		if (empty($deviceArn) || empty($message)) {
			throw new InvalidArgumentException('Must supply DeviceArn and Message');
		}

		$resultXml = $this->_request('Publish', array(
			'TargetArn' => $deviceArn,
			'Message' => $message)
		);

		return strval($resultXml->PublishResult->MessageId);
	}
public function publishToEndpoint($deviceArn, $message) {
		if (empty($deviceArn) || empty($message)) {
			throw new InvalidArgumentException('Must supply DeviceArn and Message');
		}

		$resultXml = $this->_request('Publish', array(
			'TargetArn' => $deviceArn,
			'Message' => $message)
		);

		return strval($resultXml->PublishResult->MessageId);
	}
Publish a message to an Endpoint

@link http://docs.amazonwebservices.com/sns/latest/api/API_Publish.html
@param string $deviceArn
@param string $message
@return string
@throws InvalidArgumentException