Skip to content

jonathan-kosgei/postmark

Repository files navigation

postmark

Postmark makes sending and receiving email incredibly easy.

This Python package is automatically generated by the Swagger Codegen project:

  • API version: 1.0.0
  • Package version: 1.0.0
  • Build package: io.swagger.codegen.languages.PythonClientCodegen

Requirements.

Python 2.7 and 3.4+

Installation & Usage

pip install

If the python package is hosted on Github, you can install directly from Github

pip install git+https://github.com/jonathan-kosgei/postmark.git

(you may need to run pip with root permission: sudo pip install git+https://github.com/jonathan-kosgei/postmark.git)

Then import the package:

import postmark 

Setuptools

Install via Setuptools.

python setup.py install --user

(or sudo python setup.py install to install the package for all users)

Then import the package:

import postmark

Getting Started

Please follow the installation procedure and then run the following:

from __future__ import print_function
import time
import postmark
from postmark.rest import ApiException
from pprint import pprint
# create an instance of the API class
api_instance = postmark.BouncesAPIApi()
x_postmark_server_token = 'x_postmark_server_token_example' # str | The token associated with the Server on which this request will operate.
bounceid = 789 # int | The ID of the Bounce to activate.

try:
    # Activate a bounce
    api_response = api_instance.activate_bounce(x_postmark_server_token, bounceid)
    pprint(api_response)
except ApiException as e:
    print("Exception when calling BouncesAPIApi->activate_bounce: %s\n" % e)

Documentation for API Endpoints

All URIs are relative to https://api.postmarkapp.com

Class Method HTTP request Description
BouncesAPIApi activate_bounce PUT /bounces/{bounceid}/activate Activate a bounce
BouncesAPIApi bounces_bounceid_dump_get GET /bounces/{bounceid}/dump Get bounce dump
BouncesAPIApi get_bounced_tags GET /bounces/tags Get bounced tags
BouncesAPIApi get_bounces GET /bounces Get bounces
BouncesAPIApi get_delivery_stats GET /deliverystats Get delivery stats
BouncesAPIApi get_single_bounce GET /bounces/{bounceid} Get a single bounce
InboundRulesAPIApi create_inbound_rule POST /triggers/inboundrules Create an inbound rule trigger
InboundRulesAPIApi delete_inbound_rule DELETE /triggers/inboundrules/{triggerid} Delete a single trigger
InboundRulesAPIApi list_inbound_rules GET /triggers/inboundrules List inbound rule triggers
MessagesAPIApi bypass_rules_for_inbound_message PUT /messages/inbound/{messageid}/bypass Bypass rules for a blocked inbound message
MessagesAPIApi get_inbound_message_details GET /messages/inbound/{messageid}/details Inbound message details
MessagesAPIApi get_opens_for_single_outbound_message GET /messages/outbound/opens/{messageid} Retrieve Message Opens
MessagesAPIApi get_outbound_message_details GET /messages/outbound/{messageid}/details Outbound message details
MessagesAPIApi get_outbound_message_dump GET /messages/outbound/{messageid}/dump Outbound message dump
MessagesAPIApi retry_inbound_message_processing PUT /messages/inbound/{messageid}/retry Retry a failed inbound message for processing
MessagesAPIApi search_inbound_messages GET /messages/inbound Inbound message search
MessagesAPIApi search_opens_for_outbound_messages GET /messages/outbound/opens Opens for a single message
MessagesAPIApi search_outbound_messages GET /messages/outbound Outbound message search
SendingAPIApi send_email POST /email Send a single email
SendingAPIApi send_email_batch POST /email/batch Send a batch of emails
SendingAPIApi send_email_with_template POST /email/withTemplate Send an email using a Template
ServerConfigurationAPIApi edit_current_server_configuration PUT /server Edit Server Configuration
ServerConfigurationAPIApi get_current_server_configuration GET /server Get Server Configuration
StatsAPIApi get_bounce_counts GET /stats/outbound/bounces Get bounce counts
StatsAPIApi get_outbound_click_counts GET /stats/outbound/clicks Get click counts
StatsAPIApi get_outbound_click_counts_by_browser_family GET /stats/outbound/clicks/browserfamilies Get browser usage by family
StatsAPIApi get_outbound_click_counts_by_location GET /stats/outbound/clicks/location Get clicks by body location
StatsAPIApi get_outbound_click_counts_by_platform GET /stats/outbound/clicks/platforms Get browser plaform usage
StatsAPIApi get_outbound_open_counts GET /stats/outbound/opens Get email open counts
StatsAPIApi get_outbound_open_counts_by_email_client GET /stats/outbound/opens/emailclients Get email client usage
StatsAPIApi get_outbound_open_counts_by_platform GET /stats/outbound/opens/platforms Get email platform usage
StatsAPIApi get_outbound_open_counts_by_reading_time GET /stats/outbound/opens/readtimes Get email read times
StatsAPIApi get_outbound_overview_statistics GET /stats/outbound Get outbound overview
StatsAPIApi get_sent_counts GET /stats/outbound/sends Get sent counts
StatsAPIApi get_spam_complaints GET /stats/outbound/spam Get spam complaints
StatsAPIApi get_tracked_email_counts GET /stats/outbound/tracked Get tracked email counts
TagTriggersAPIApi create_tag_trigger POST /triggers/tags Create a trigger for a tag
TagTriggersAPIApi delete_tag_trigger DELETE /triggers/tags/{triggerid} Delete a single trigger
TagTriggersAPIApi edit_tag_trigger PUT /triggers/tags/{triggerid} Edit a single trigger
TagTriggersAPIApi get_single_tag_trigger GET /triggers/tags/{triggerid} Get a single trigger
TagTriggersAPIApi searcg_tag_triggers GET /triggers/tags Search triggers
TemplatesAPIApi delete_template DELETE /templates/{templateid} Delete a Template
TemplatesAPIApi get_single_template GET /templates/{templateid} Get a Template
TemplatesAPIApi list_templates GET /templates Get the Templates associated with this Server
TemplatesAPIApi send_email_with_template POST /email/withTemplate Send an email using a Template
TemplatesAPIApi templates_post POST /templates Create a Template
TemplatesAPIApi test_template_content POST /templates/validate Test Template Content
TemplatesAPIApi update_template PUT /templates/{templateid} Update a Template

Documentation For Models

Documentation For Authorization

All endpoints do not require authorization.

Author