New

Just launched: Vueblocks, a brand-new search engine for Vue packages! Explore Vueblocks →

infusionweb/laravel-marketo-rest-api

Provides a Laravel 5 service provider and facade for Marketo REST API Client.
271,651
Install
composer require infusionweb/laravel-marketo-rest-api
Latest Version:0.1.1
PHP:>=5.5.9
Laravel:5
License:MIT
Last Updated:Aug 14, 2019
Links: GitHub  ·  Packagist
Maintainer: rkeppner

Laravel 5 Marketo REST API Provider

Latest Stable Version Total Downloads Latest Unstable Version License

An enhanced wrapper for using Marketo REST API Client package in Laravel

This package provides a Laravel 5 service provider and facade for dchesterton/marketo-rest-api, which is a Composer package that serves as an "unofficial PHP client for the Marketo.com REST API."

When enabled and configured, this package allows a more convenient use of the Marketo REST API Client functionality, through a Laravel facade, as well as adding some configuration options for added ease of use.

Installation

Step 1: Composer

Via Composer command line:

$ composer require infusionweb/laravel-marketo-rest-api

Or add the package to your composer.json:

{
    "require": {
        "infusionweb/laravel-marketo-rest-api": "~0.1.0"
    }
}

Step 2: Register the Service Provider

Add the service provider to your config/app.php:

'providers' => [
    //
    InfusionWeb\Laravel\Marketo\MarketoClientProvider::class,
];

Step 3: Enable the Facade

Add the facade to your config/app.php:

'aliases' => [
    //
    'Marketo' => InfusionWeb\Laravel\Marketo\MarketoClientFacade::class,
];

Step 4: Publish the package config file

$ php artisan vendor:publish --provider="InfusionWeb\Laravel\Marketo\MarketoClientProvider"

You may now setup Marketo authentication and other preferences by editing the config/marketo.php file.

Usage Example

<?php

use Marketo;

$fields = [
    'email' => 'email@example.com',
    'firstName' => 'Example',
    'lastName' => 'User',
];

try {
    $result = Marketo::createOrUpdateLead($fields);
}
catch(\InfusionWeb\Laravel\Marketo\Exceptions\MarketoClientException $e) {
    die('We couldn’t save your information!');
}

For additional API documentation, see the original Marketo REST API Client documentation, as well as Marketo's own REST API documentation.

Credits

License

The MIT License (MIT). Please see License File for more information.

Related Packages

nebo15/lumen.rest

Components for fast building REST API for Lumen

3,759 1
wisoot/jwt-guard

Laravel Guard Driver using JSON Web Token (JWT)

703 6
lujo/lumen-rest

Lumen package for creating simple REST API

97 1
izupet/laravel-api

Laravel REST api helpers

63 6
mleczek/laravel-rest

Laravel package with a set of helpful tools for building REST API.

59 5

Version History

Version Released PHP Laravel License
0.1.1 >=5.5.9 ~5.0 MIT
0.1.0 >=5.5.9 ~5.0 MIT