\npip install tk or sudo apt-get install python3-tk\n<\/pre><\/div>\n\n\nNow write the code to create a GUI like the below image, however, you can design as per your requirement because I have just created a simple GUI for learning purposes, but you can add more features.<\/p>\n\n\n
\n
<\/figure><\/div>\n\n\nNow you can use the full source code below with implementation:<\/p>\n\n\n
\nfrom tkinter import *\nimport tkinter as tk\nimport requests\n\nroot = tk.Tk()\nroot.title("Instagram User Information")\nroot.geometry('450x350')\n\ndef searchProfile():\n user_name = user.get()\n url = f"https:\/\/www.instagram.com\/{user_name}\/?_a=1"\n data = requests.get(url).json()\n print(data)\n\n def profilePic():\n import webbrowser\n user_pic = data['graphql']['user']['profile_pic_url']\n webbrowser.open(user_pic)\n\n if details.get(1.0, END) != "":\n details.delete(1.0, END)\n details.insert(1.0, f"\\n User Name : {data['graphql']['user']['username']} \\n Followers : {['graphql']['user']['edge_followed_by']['count']} || Following : {data['graphql']['user']['edge_follow']['count']} \\n Full Name : {data['graphql']['user']['full_name']} \\n Total Post : {data['graphql']['user']['edge_owner_to_timeline_media']['count']} || Category : {data['graphql']['user']['category_enum']} \\n Bio-Link : {data['graphql']['user']['external_url']} || Private Account : {data['graphql']['user']['is_private']} \\n Verified Account : {data['graphql']['user']['is_verified']} || Bussiness Account : {data['graphql']['user']['is_bussiness_account']} \\n \\n \\n See Profile Picture")\n\n Button(frame2, text="Click to View", relief=RAISED, borderwidth=2, font=('verdana', 10, 'bold'), bg='#248aa2', fg="white", command=profilePic).place(x=150, y=190)\n\nframe1 = Frame(root, width=450, height=350, relief=RIDGE, borderwidth=5, bg='#FAD7A0')\nframe1.place(x=0, y=0)\n\nuser = Entry(frame1, width=20, relief=RIDGE, borderwidth=3, font=('verdana', 10))\nuser.place(x=70, y=10)\n\nsearch = Button(frame1, text="Search", relief=RAISED, borderwidth=2, font=('verdana', 10, 'bold'), bg='#248aa2', fg="white", command=searchProfile)\nsearch.place(x=270, y=8)\n\nframe2 = LabelFrame(frame1, width=420, height=290, relief=RIDGE, borderwidth=3, bg='#248aa2', highlightcolor="white", highlightbackground="white", highlightthickness=2)\nframe2.place(x=5, y=45)\n\nlabel = Label(frame2, text="User Details", highlightbackground="white", highlightcolor="white", highlightthickness=5, font=('verdana', 10, 'bold'))\nlabel.place(x=5, y=5)\n\ndetails = Text(frame2, height=13, width=48, relief=RIDGE, borderwidth=5, highlightbackground="white", highlightcolor="white", font=('verdana', 10, ''))\ndetails.place(x=5, y=40)\n\nroot.mainloop()\n<\/pre><\/div>\n\n\n