Skip to content

Commit c0e2701

Browse files
Update giphy_trending.py
1 parent fef8549 commit c0e2701

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

consuming-apis-python/giphy_trending.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,11 +7,13 @@
77

88
# In the query parameters you can define:
99
# 1. The number of GIFs to return using the `limit` parameter.
10-
# 2. The accepted rating of the GIFs returned using the `rating` parameter: https://developers.giphy.com/docs/optional-settings#rating
10+
# 2. The accepted rating of the GIFs returned using the `rating` parameter
11+
# https://developers.giphy.com/docs/optional-settings#rating
1112
params = {"api_key": API_KEY, "limit": 3, "rating": "g"}
1213

1314
# The response will contain a list with all the GIFs that match your query.
14-
# For each of those, you want to get the `title`, `url` and the `trending_datetime` fields.
15+
# For each of those, you want to get the `title`, `url` and the
16+
# `trending_datetime` fields.
1517
response = requests.get(endpoint, params=params).json()
1618
for gif in response["data"]:
1719
title = gif["title"]

0 commit comments

Comments
 (0)