#!/usr/bin/python3
"""Takes your Github credentials (username and password) and uses the Github
API to display your id
Usage: ./10-my_github.py <username> <password>"""

import sys
import requests
from requests.auth import HTTPBasicAuth

if __name__ == "__main__":

    url = "https://api.github.com/user"
    username = sys.argv[1]
    token = sys.argv[2]
    login = requests.get(url, auth=HTTPBasicAuth(username, token))
    print(login.json().get("id"))

eaca6ed510cf570e614ac12f102a4d2d0eeb8584
<mask token>

<mask token>
if __name__ == '__main__':
    url = 'https://api.github.com/user'
    username = sys.argv[1]
    token = sys.argv[2]
    login = requests.get(url, auth=HTTPBasicAuth(username, token))
    print(login.json().get('id'))

<mask token>
import sys
import requests
from requests.auth import HTTPBasicAuth
if __name__ == '__main__':
    url = 'https://api.github.com/user'
    username = sys.argv[1]
    token = sys.argv[2]
    login = requests.get(url, auth=HTTPBasicAuth(username, token))
    print(login.json().get('id'))

#!/usr/bin/python3
"""Takes your Github credentials (username and password) and uses the Github
API to display your id
Usage: ./10-my_github.py <username> <password>"""

import sys
import requests
from requests.auth import HTTPBasicAuth

if __name__ == "__main__":

    url = "https://api.github.com/user"
    username = sys.argv[1]
    token = sys.argv[2]
    login = requests.get(url, auth=HTTPBasicAuth(username, token))
    print(login.json().get("id"))
