trustcafe-api-wrapper/jobs/post/get.py
2026-03-31 10:33:30 +01:00

13 lines
No EOL
395 B
Python

def get(API, post_slug: str,) -> dict:
"""
Fetches the post data from the API.
Args:
post_slug (str): Slug of the post to fetch data for.
Returns:
dict: The post data.
"""
print(f"Fetching post from slug: {post_slug}")
post_data = API.make_request("GET", "content", f"post/id/{post_slug}", authenticate=True)
return post_data