定制 evoluted/feefo 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

evoluted/feefo

最新稳定版本:1.0.2

Composer 安装命令:

composer require evoluted/feefo

包简介

A generic Feefo PHP SDK package.

README 文档

README

A framework agnostic library for working with the Feefo API for E-commerce sales reviews.

Installation

This project can be installed via Composer:

$ composer require evoluted/feefo

Usage

Using the Feefo api package is fairly easy. Once you've loaded the library via Composer, you can initialise it as follows, remembering to add your Feefo credentials:

$feefo = new Evoluted\Feefo\Feefo(
	'', // Merchant identifier
	'' // API Key
);

Once initialised you are able to retrieve the latest reviews with:

$feefo->reviews();

You can optionally increase or decrease the number of results from the default of 5 like so:

$feefo->reviews(10);

Custom Calls

You can make custom calls for additional information using the generic get or post request handlers.

Retrieving product ratings

$feefo->get('10/products/ratings', [
    'merchant_identifier' => $feefo->merchantIdentifier,
    'review_count' => '10',
    'since' => 'year',
]);

Adding Sales

$sale = $feefo->post('entersaleremotely', [
    'apikey' => $feefo->apiKey,
    'merchantidentifier' => $feefo->merchantIdentifier,
    'email' => 'customer@example.com',
    'name' => 'John Smith',
    'date' => '2016-11-25',
    'description' => 'Our Product',
    'productsearchcode' => '123456',
    'orderref' => 'ORDER123456',
    'amount' => '123.45',
    'productlink' => 'http://www.example.com/product/123456',
    'customerref' => '987654',
]);

For an example of the above implementation, see the included example file.

Resources

统计信息

  • 总下载量: 7.85k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 4
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 4
  • Watchers: 5
  • Forks: 5
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2016-11-25