From f27d195964d533528cb27db4ccb3a38c39ecd54b Mon Sep 17 00:00:00 2001 From: Robert Date: Tue, 11 Aug 2020 14:07:12 +0200 Subject: [PATCH] Added Header information to requests --- README.md | 7 +++++-- utils/jisho.py | 4 ++++ 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 5f330ef..f236012 100644 --- a/README.md +++ b/README.md @@ -28,5 +28,8 @@ Clone this repo, create a `config.json` in the root directory with the following { "key": Your discord bot token, - "prefix": Your prefix - } \ No newline at end of file + "prefix": Your prefix, + } + + +If there a re questions or requests you can find me on discord: `Lauchmelder#1234` \ No newline at end of file diff --git a/utils/jisho.py b/utils/jisho.py index 88707f5..801d6be 100644 --- a/utils/jisho.py +++ b/utils/jisho.py @@ -3,6 +3,10 @@ import urllib.parse import json TEMPLATE_URL = "https://jisho.org/api/v1/search/words?keyword={0}" +HEADER = { + "User-Agent": "Jisho Bot", + "From": "https://github.com/Lauchmelder23/JishoBot" +} class JishoSenses(): def __init__(self, sense):