GithubHelp home page GithubHelp logo

instagram-search-api-python's People

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  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  avatar

instagram-search-api-python's Issues

Syntax Error?

I have python 2.7.12 on Linux. When I run the script, I get a syntax error on Line 75:

File "./instagram_search.py", line 77
class HashTagSearch(metaclass=ABCMeta):
^
SyntaxError: invalid syntax

I'm an utter novice, so I can't troubleshoot it myself. I just wanted to mine Instagram tags. Please help?

Edit: Through hit and trial, I modified the line to "class HashTagSearch(ABCMeta)"

Now I get the error:

File "./instagram_search.py", line 283, in
HashTagSearchExample().extract_recent_tag("christmas")
TypeError: new() takes exactly 4 arguments (1 given)

Please help.

Issue getting next batch of results

Kudos for great scrapper. However, I stumbled upon an issue - on lines 123/124 when trying to extract query id from potential query ids - the post return HTTP-403 error. maybe insta-API changed ?

url = "https://www.instagram.com/graphql/query/?query_hash=%s&variables=%s" % (
potential_id, json.dumps(variables))

Also, do you think it is possible to alter it a little in order to scrap profile pages as well ?

404 Error when calling get_next_results

I'm getting a 404 when calling requests.post("https://www.instagram.com/query/", data=post_data, headers=headers).text inside the get_next_results method. I can't figure out why.

query id has different variable name

Hello,

I was having trouble with getting the correct (or in some case any) query_ids from:
def get_query_id(self, doc)

The query id was no longer to be found in c="", it can now be found in queryId:""
so just need to change line 177
for query_id in re.findall("(?<=c=\")[0-9]{1,}", text)
to
for query_id in re.findall("(?<queryId:\")[0-9]{1,}", text)

Once I change this everything worked again and I haven't had a:
ERROR:root:Could not extract Query Id, exiting

Soph

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.