These sample requests are autogenerated by the OpenAPI spec.
import requests# You can find this key in your API requests page:# https://buttondown.email/requestsBUTTONDOWN_API_KEY = "your-api-key-here"headers = {"Authorization": f"Token {BUTTONDOWN_API_KEY}",}BASE_URL = "https://api.buttondown.email"ENDPOINT = "/emails/{id}"METHOD = "GET"response = requests.request(METHOD, f"{BASE_URL}/v1{ENDPOINT}", headers=headers)
Sample responses
The IDs and values referenced in these responses are fake; please only rely on these responses for overall structure.
{"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08","included_tags": null,"excluded_tags": null,"creation_date": "2000-01-01T00:00:00+00:00","modification_date": "2000-01-01T00:00:00+00:00","publish_date": "2000-01-01T00:00:00+00:00","attachments": [],"subject": "Welcome to the newsletter","canonical_url": "","image": "","description": "","source": "app","body": "I hope you really enjoy it!","secondary_id": null,"email_type": "public","slug": "welcome-to-the-newsletter","status": "sent","metadata": {},"should_send_teaser": false,"is_comments_disabled": false,"custom_teaser": "","absolute_url": "http://127.0.0.1:8000/sheinhardt/archive/welcome-to-the-newsletter/","filters": [],"analytics": null,"template": null}