Git Product home page Git Product logo

Comments (5)

smunuswami avatar smunuswami commented on July 17, 2024

Hi @garek007,

Please use UniqueClicks and UniqueOpens property. More information can be found at
https://developer.salesforce.com/docs/atlas.en-us.noversion.mc-apis.meta/mc-apis/send.htm

from fuelsdk-php.

garek007 avatar garek007 commented on July 17, 2024

I am using that, but I'd like both. Is it not available?

from fuelsdk-php.

smunuswami avatar smunuswami commented on July 17, 2024

Can you please post sample request you are sending?

from fuelsdk-php.

garek007 avatar garek007 commented on July 17, 2024
require('ET_Client.php');
try {
	$myclient = new ET_Client();
	$today = idate('d');

	switch($today){
		case 31:
		case 30:
		case 1:
		case 2:$retrieveDate = strtotime('- 1 days');echo "need to get past full month. code not written yet";break;
		default;$retrieveDate = strtotime('- 30 days');break;

	}


	$getSend = new ET_Send();
	$getSend->authStub = $myclient;
	$getSend->props = array("ID","PartnerKey","CreatedDate","ModifiedDate","Client.ID","Client.PartnerClientKey","Email.ID","Email.PartnerKey","SendDate","FromAddress","FromName","Duplicates","InvalidAddresses","ExistingUndeliverables","ExistingUnsubscribes","HardBounces","SoftBounces","OtherBounces","ForwardedEmails","UniqueClicks","UniqueOpens","NumberSent","NumberDelivered","NumberTargeted","NumberErrored","NumberExcluded","Unsubscribes","MissingAddresses","Subject","PreviewURL","SentDate","EmailName","Status","IsMultipart","SendLimit","SendWindowOpen","SendWindowClose","IsAlwaysOn","Additional","BCCEmail","EmailSendDefinition.ObjectID","EmailSendDefinition.CustomerKey");
	$getSend->filter = array('Property' => 'SendDate','SimpleOperator' => 'greaterThan','DateValue' => $retrieveDate);
	$getSend->getSinceLastBatch = false;
	$getResponse = $getSend->get();

	$_SESSION['results'] = $getResponse->results;
	echo "<table border=\"1\" cellpadding=\"5\">";
	echo "<tr><td>Email Name</td><td>Unsubscribes</td><td>Sent</td><td>Delivered</td><td>Date Sent</td><td>Unique Opens</td><td>Unique Clicks</td></tr>";

	foreach($getResponse->results as $results){
		if($results->NumberSent > 0){


			$date = date_create($results->SendDate);
			echo "<tr><td>".$results->EmailName . "</td><td>" . number_format($results->Unsubscribes) . "</td><td>" . number_format($results->NumberSent) . "</td><td>" . number_format($results->NumberDelivered) . "</td><td>" . $date->format('M d Y') . "</td><td>" . number_format($results->UniqueOpens) . "</td><td>" . number_format($results->UniqueClicks) . "</td></tr>";
		}
	}
	echo "</table>"

from fuelsdk-php.

garek007 avatar garek007 commented on July 17, 2024

I didn't include closing brackets for the try statement, but it's there

from fuelsdk-php.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.