定制 seregazhuk/pinterest-bot 二次开发

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

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

seregazhuk/pinterest-bot

最新稳定版本:v5.9.1

Composer 安装命令:

composer require seregazhuk/pinterest-bot

包简介

PHP library for Pintrest

README 文档

README

Pinterest PHP Bot

Build Status Code Climate Scrutinizer Code Quality Test Coverage StyleCI 68747470733a2f2f706f7365722e707567782e6f72672f7365726567617a68756b2f70696e7465726573742d626f742f762f737461626c65 Total Downloads

A PHP library to help you work with your Pinterest account without API credentials.

The Pinterest API is painful: receiving an access token involves registering a developer account, registering an application, then waiting for confirmation. Not to mention, the public API itself is poorly implemented and has a limited set of features.

This library offers the full functionality available on Pinterest's website, with no need to register an application to receive an access token. All that's needed is your account login information (but even this is not required if you don't plan on creating pins, writing comments or sending messages)!

Installation

Dependencies

Library requires CURL extension and PHP 7.0 or above.

The recommended way to install this library is via Composer. New to Composer?

composer require seregazhuk/pinterest-bot

Quick Start

// You may need to amend this path to locate Composer's autoloader
require('vendor/autoload.php'); 

use seregazhuk\PinterestBot\Factories\PinterestBot;

$bot = PinterestBot::create();

// Login
$bot->auth->login('mypinterestlogin', 'mypinterestpassword');

// Get lists of your boards
$boards = $bot->boards->forUser('yourUserName');

// Create a pin
$bot->pins->create('http://exmaple.com/image.jpg', $boards[0]['id'], 'Pin description');

Note: Some methods (e.g. get user followers/following, pins likes/dislikes, search and other feed queries) use Pinterest navigation through results (with bookmarks). This means that for every batch of results, a call is made to Pinterest and a Pagination object with Pinterest API results is returned.

How to avoid ban

To avoid being banned by Pinterest, do not aggressively pin or write comments (e.g. creating hundreds of pins in a single minute). Do this by inserting timeouts (sleep($seconds)) with calls.

Examples

These articles provide examples of common tasks that can be performed with the bot:

How can I thank you?

Why not star this GitHub repo? I'd love the attention! Or, you can donate to my project on PayPal:

Support me with some coffee

Thanks!

统计信息

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

GitHub 信息

  • Stars: 404
  • Watchers: 48
  • Forks: 125
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2015-08-22