GithubHelp home page GithubHelp logo

isabella232 / brightlocal-api-helper Goto Github PK

View Code? Open in Web Editor NEW

This project forked from webpagefx/brightlocal-api-helper

0.0 0.0 0.0 32 KB

BrightLocal API Code Examples & Related Code

Home Page: /

PHP 100.00%

brightlocal-api-helper's Introduction

BrightLocal API

A basic PHP wrapper to make using the BrightLocal API a little easier. It takes care of authentication so you just need to specify which method you want to call and pass parameters.

Installation

It's easiest to install and use the library via Composer.

Step 1: Add to the requires section of your composer.json file.

"require": {
    "brightlocal/api": "0.*"
}

Step 2: Install

composer install

Examples

<?php
require 'BrightLocal/Api.php';

$api = new BrightLocal\Api('YOUR_API_KEY', 'YOUR_API_SECRET');

// get a list of clients
print_r($api->call('/v2/clients/get-all'));

// get a client
print_r($api->call('/v2/clients/get', array(
    'client-id' => 1059
)));

// get LSRC report list
print_r($api->call('/v2/lsrc/get-all'));

// get LSRC report
print_r($api->call('/v2/lsrc/get', array(
    'campaign-id' => 50
)));

// get CT report list
print_r($api->call('/v2/ct/get-all'));

// get a CT report
print_r($api->call('/v2/ct/get', array(
    'report-id' => 259
)));

Example Scripts

Example scripts can be found in /Examples. We'll be adding to these scripts over time.

brightlocal-api-helper's People

Contributors

dmytro-vovk avatar ejeliot avatar svanhorne avatar

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.