Coder Social home page Coder Social logo

juanmicl / instaresponder Goto Github PK

View Code? Open in Web Editor NEW
52.0 7.0 17.0 36 KB

Instagram Auto DM responder with DialogFlow 🔥

Home Page: https://juanmicl.github.io/InstaResponder/

License: GNU Affero General Public License v3.0

PHP 100.00%
instagram instagram-bot dialogflow chatbot bot php

instaresponder's Introduction

Logo Insta Responder Logo2

Instagram Direct Message Auto Responder with DialogFlow!

video

What does InstaResponder do?

Main features:

  • Auto reply DMs.
  • Connect your IG inbox with DialogFlow. And much more to develop...

Installation

Using Composer

composer require mgp25/instagram-php
composer require juanmicl/dummiesflow

I don't have Composer

You can download it here.

Warning about moving data to a different server

Composer checks your system's capabilities and selects libraries based on your current machine (where you are running the composer command). So if you run Composer on machine A to install this library, it will check machine A's capabilities and will install libraries appropriate for that machine (such as installing the PHP 7+ versions of various libraries). If you then move your whole installation to machine B instead, it will not work unless machine B has the exact same capabilities (same or higher PHP version and PHP extensions)! Therefore, you should always run the Composer-command on your intended target machine instead of your local machine.

Config and Run

1º Open core/config.php and edit IG config.

2º fill "agentName", you can find it here:

1

*you need to enable "Web Demo" feature

3º Open your terminal/console and run

php bot.php

Legal

This code is in no way affiliated with, authorized, maintained, sponsored or endorsed by Instagram and Google or any of its affiliates or subsidiaries. This is an independent and unofficial API. Use at your own risk.

Credits

Thanks to mgp25 for instagram-php api!

instaresponder's People

Contributors

juanmicl avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

instaresponder's Issues

Error starting installation

Unfortunately this is not happening, I try to start more of the failure.

C:\composer\InstaResponder>composer require mgp25/instagram-php
Using version ^7.0 for mgp25/instagram-php
./composer.json has been updated
Loading composer repositories with package information
Updating dependencies (including require-dev)
Your requirements could not be resolved to an installable set of packages.

  Problem 1
    - symfony/process v4.2.7 requires php ^7.1.3 -> your PHP version (5.6.31) does not satisfy that requirement.
    - symfony/process v4.2.7 requires php ^7.1.3 -> your PHP version (5.6.31) does not satisfy that requirement.
    - Installation request for symfony/process (locked at v4.2.7) -> satisfiable by symfony/process[v4.2.7].


Installation failed, reverting ./composer.json to its original content.
C:\composer\InstaResponder>php bot.php

Warning: require(C:\composer\InstaResponder\core/../vendor/autoload.php): failed to open stream: No such file or directory in C:\composer\InstaResponder\core\config.php on line 3

Fatal error: require(): Failed opening required 'C:\composer\InstaResponder\core/../vendor/autoload.php' (include_path='.;C:\php\pear') in C:\composer\InstaResponder\core\config.php on line 3

¿Como colaboro con el proyecto?

Creé un rama localmente, developer, e hice commit en esa rama, pero no sé como hacer el pull request. No se si es por falta de permisos, aunque tampoco comprendo bien cual sería el proceso, my skype es: danielarango90, si quieres conversamos, vivo en Colombia (creo que estamos a varias horas de diferencia). (Colombia = GTM-5)

Aceptar links

Hola Juan, gracias por este proyecto, lo usé y funcionó muy bien, apliqué una nueva funcionalidad dentro del proyecto local para permitir links:

en core/functions.php

} elseif ($thread->items{0}->item_type == 'link') {
	$response = $dflow->query($thread->thread_id, $thread->last_permanent_item->link->text);
	$ig->direct->sendText(array(
		'thread' => $thread->thread_id),
		$response
	);
	
}

Espero puedas aplicarlo en el proyecto actual, a muchas personas beneficia, saludos.

ERROR AL INICIAR

Hola hace unos meses probe tu script y estaba Genial pero, ahorita lo estoy intentando usar y no me funciona sale el cliente en error al ponerlo debug

Notice: Undefined property: stdClass::$inbox in C:\laragon\www\insta\InstaResponder\bot.php on line 21

Notice: Trying to get property 'threads' of non-object in C:\laragon\www\insta\InstaResponder\bot.php on line 21

Warning: Invalid argument supplied for foreach() in C:\laragon\www\insta\InstaResponder\bot.php on line 21
GET: https://i.instagram.com/api/v1/direct_v2/pending_inbox/?persistentBadging=true&use_unified_inbox=true

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.