Download the PHP package eyefi/marketo without Composer

On this page you can find all versions of the php package eyefi/marketo. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package marketo

Marketo

A PHP client for the Marketo SOAP API.

Installation

Add following line to your composer.json require:

And the following to you composer.json repositories:

Usage

Authentication

The first thing you'll want to do is include the marketo class and create a new instance of the client.

You will need your SOAP user id and SOAP encryption key as well as the hostname for your Marketo API endpoint. These can be found in the Admin -> SOAP section when logged into app.marketo.com.

If you store configuration in the environment you would create a new instance like:

The credentials are passed directly to the class rather than looking for constants or keys stored in superglobals so you can connect to multiple Marketo instances.

Getting a lead

You can get a lead using the get_lead_by($type, $value) method.

Arguments

$type - The type of ID you would like to look up the lead by. This can be one of the following:

$value - The value for the key. For example if the $type is email the $value should be and email address

Examples

This will return an array of lead objects or FALSE if not found. The result will always be an array whether there are one or more leads found.

Creating or updating a lead

You can create or update a lead using the sync_lead($lead, $lead_key = NULL, $cookie = NULL) method.

Arguments

$lead - Associative array of lead attributes

$lead_key - Optional, The key being used to identify the lead, this can be either an email or Marketo ID

$cookie - Optional, The entire _mkto_trk cookie the lead will be associated with

Examples

When no $lead_key or $cookie is given a new lead will be created

When a $lead_key or $cookie is specified, Marketo will attempt to identify the lead and update it. Sending the _mkto_trk cookie is important for associating the lead you're syncing with any information Marketo collected when the lead was anonymous.

This will return the updated or created lead object.

Adding leads to campaigns

You can add leads to a campaign using the add_to_campaign($campaign_key, $leads) method.

Arguments

$campaign_key - Either the campaign id or the campaign name. You can get these from get_campaigns().

$leads - An associative array with a key of lead id type and the corresponding value. This can also be an array of associative arrays. The available id types are:

Examples

Add one lead to a campaign

Add multiple leads to a campaign with mixed id types

Returns TRUE if successful FALSE if not

Getting campaigns

You can get available campaigns using the get_campaigns($campaign = NULL) method.

Arguments

$name - Optional, the exact name of the campaign to get

You would usually use this to figure out what campaigns are available when calling add_to_campaign().

Returns an object containing all the campaigns that are available to the API. Campaigns are only available to the API if they have a Campaign is Requested trigger where the Source is Web Service API.

Examples


All versions of marketo with dependencies

PHP Build Version
Package Version
No informations.
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package eyefi/marketo contains the following files

Loading the files please wait ....