python request module

technical talkiess
0

 Python requests module:- 

import requests

r = requests.get("https://pixabay.com/api/?key={ KEY }&q=yellow+flowers&image_type=photo")

# isse aap text print kar sakte ho

print(r.text)

# status code get karne ke liye use karte hai

print(r.status_code)



# aise post se data send karte hai


# url = 'www.xyz.com'

# data = {

#     "a":1,

#     "b":2

# }

# r1 = requests.post(url:url,data:data)


Tags

Post a Comment

0Comments

Thanks you for commenting your questions. I will see question and respond you.

Post a Comment (0)