i'm a begginer programmer and i'm having troubles with my twitter bot. The idea of the bot is tweet an daily verse of bible everyday, and that's what I got so far:
import tweepy
import requests
api = tweepy.Client(
consumer_key='',
consumer_secret='',
access_token='-',
access_token_secret='',
)
response = requests.get("https://www.biblegateway.com/votd/get/?format=json&version=NVI-PT")
verse_of_the_day = response.json()["votd"]["text"]
try:
tweet=api.create_tweet(text=("Aqui está o versículo do dia: \n") + verse_of_the_day)
print(tweet)
except:
print("something is wrong")
the problem is that some characters appear as HTML entity and not as the "character itself" and what I hope is to fix these characters that are in html entity
source https://stackoverflow.com/questions/74915764/how-can-i-convert-html-entities-in-my-twitter-bot
Comments
Post a Comment