Skip to content

Commit

Permalink
post request for titan spreadsheet
Browse files Browse the repository at this point in the history
  • Loading branch information
Gr8z committed Aug 26, 2018
1 parent 2e05351 commit e534fb2
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion warbattles/info.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,6 @@
"SHORT" : "Announce war attack wins in a channel for one or more clans.",
"DESCRIPTION" : "Clash Royale Clan War Attack log.",
"TAGS" : ["royaleapi", "clashroyale", "clanwar", "warlog", "wins","war"],
"REQUIREMENTS" : ["clashroyale"],
"REQUIREMENTS" : ["clashroyale","requests"],
"HIDDEN" : false
}
6 changes: 6 additions & 0 deletions warbattles/warbattles.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@
import clashroyale
import time
from datetime import datetime
import requests
import json

try:
from cogs.deck import Deck
Expand Down Expand Up @@ -131,6 +133,10 @@ async def warbattles(self, ctx):

await self.bot.send_message(discord.Object(id=channel), embed=embed)

if clankey == "titan":
url = 'https://script.google.com/macros/s/AKfycbx8idfEQE2ochft4vKg7um0VVZ16_li5AnRvDQZHhyLimJjvlw/exec'
requests.post(url, data=json.dumps(battledata))

card_keys = await self.deck.decklink_to_cards(battledata["deckLink"])
newctx = ctx
newctx.message.channel = discord.Object(id=channel)
Expand Down

0 comments on commit e534fb2

Please sign in to comment.