Python

Python request method The "endpoint" parameter must be a valid type

get

https://neko-love.xyz/api/v1/:endpoint
Request
Response
Request
Path Parameters
Parameter Type
required
string
The "endpoint" parameter must be a valide type
Response
200: OK
"https://neko-love.xyz/v1/neko/neko-love_54.jpg"
import requests
def nekoGET(endpoint):
r = requests.get("https://neko-love.xyz/api/v1/" + endpoint)
if r.status_code != 200:
print("An error has occurred")
else:
print(r.json()["url"])
nekoGET("neko")