Skip to content

Instantly share code, notes, and snippets.

@BeyondEvil
Created March 21, 2020 16:11
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save BeyondEvil/92c52af74eb5e67a94edb8949e05826c to your computer and use it in GitHub Desktop.
Save BeyondEvil/92c52af74eb5e67a94edb8949e05826c to your computer and use it in GitHub Desktop.
import requests
def main():
timeout=None
print(f"Timeout is: {timeout}")
response = requests.get(
"https://shootnscoreit.com/api/ipsc/match/<some match ID>/",
auth=("<user email>", "<user password>"),
headers={
"Content-Type": "application/json",
"X_REQUESTED_WITH": "XMLHttpRequest",
"Accept": "JSON",
},
timeout=timeout,
)
print(response.json()[0]["name"])
if __name__ == "__main__":
main()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment