{"id":41758982,"url":"https://github.com/ream88/simple_postmark","last_synced_at":"2026-01-25T02:05:44.665Z","repository":{"id":1675275,"uuid":"2402306","full_name":"ream88/simple_postmark","owner":"ream88","description":"A simple way to use Postmark™ with your Rails app.","archived":false,"fork":false,"pushed_at":"2015-02-12T22:43:16.000Z","size":403,"stargazers_count":27,"open_issues_count":0,"forks_count":4,"subscribers_count":2,"default_branch":"master","last_synced_at":"2026-01-13T06:53:53.423Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ream88.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2011-09-16T22:10:37.000Z","updated_at":"2019-08-06T13:39:46.000Z","dependencies_parsed_at":"2022-08-21T01:20:40.062Z","dependency_job_id":null,"html_url":"https://github.com/ream88/simple_postmark","commit_stats":null,"previous_names":["haihappen/simple_postmark"],"tags_count":15,"template":false,"template_full_name":null,"purl":"pkg:github/ream88/simple_postmark","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ream88%2Fsimple_postmark","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ream88%2Fsimple_postmark/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ream88%2Fsimple_postmark/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ream88%2Fsimple_postmark/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ream88","download_url":"https://codeload.github.com/ream88/simple_postmark/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ream88%2Fsimple_postmark/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28741649,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-25T01:40:51.112Z","status":"online","status_checked_at":"2026-01-25T02:00:06.841Z","response_time":113,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2026-01-25T02:05:44.603Z","updated_at":"2026-01-25T02:05:44.657Z","avatar_url":"https://github.com/ream88.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"# simple_postmark [![Build Status](https://travis-ci.org/haihappen/simple_postmark.png)](https://travis-ci.org/haihappen/simple_postmark)\n\nsimple_postmark makes it easy to send mails via [Postmark](http://postmarkapp.com)™ using Rails's ActionMailer.\n\n## Table of Contents\n\n* [About](#about)\n* [Installation](#installation)\n* [Usage](#usage)\n* [Configuration](#configuration)\n* [Testing](#testing)\n* [Contributing](#contributing)\n* [Copyright](#copyright)\n\n## About\n\nsimple_postmark was created because of the lack of the proper Rails API support in the official [postmark-gem](https://github.com/wildbit/postmark-gem). This was back in 2011, the postmark-gem was [updated](https://github.com/wildbit/postmark-rails/issues/17#issuecomment-13761405) to support the Rails API since then. I recently decided to deprecate this gem in favor of the official gem. However, this gem will continue to support all Rails versions until `5.0`.\n\nTested against Ruby version `\u003e= 1.9.3` up to `=\u003c 2.2.0` and Rails versions `~\u003e 3.0.0` up to `~\u003e 4.1.0`.\n\n## Installation\n\nIn your `Gemfile`:\n\n```ruby\ngroup :production do\n  gem 'simple_postmark'\nend\n```\n\nIn your `config/environments/production.rb`:\n\n```ruby\nconfig.action_mailer.delivery_method = :simple_postmark\nconfig.action_mailer.simple_postmark_settings = { api_key: '********-****-****-****-************' }\n```\n\n## Usage\n\nJust use your standard Rails Mailer:\n\n```ruby\nclass NotificationMailer \u003c ActionMailer::Base\n  def notification\n    mail(to: 'ted@himym.tld', from: 'barney@himym.tld', subject: \"I'm your bro!\") do\n      # ...\n    end\n  end\nend\n```\n\nAnd of course you can use standard attachment calls and [Postmark's tags](http://developer.postmarkapp.com/developer-build.html#message-format):\n\n```ruby\nclass NotificationMailer \u003c ActionMailer::Base\n  def notification\n    attachments['thebrocode.pdf'] = File.read('thebrocode.pdf')\n\n    mail(to: 'ted@himym.tld', from: 'barney@himym.tld', subject: \"I'm your bro!\", tag: 'with-attachment') do\n      # ...\n    end\n  end\nend\n```\n\n## Configuration\n\n* `api_key`: Your Postmark API key. Go to [your Rack](https://postmarkapp.com/servers),\nselected the one you want to use and then go to the **Credentials** tab to find your API key.\n\n* `return_response`: In order to receive the response from the Postmark API\n– for example, if you want to store ErrorCode or MessageID -\nset it to `true`. ([Mail](https://github.com/mikel/mail) which is the base of simple_postmark\nexpects this option.)\n\nExample how the ErrorCode, MessageID and other values can be received from Postmark:\n\n```ruby\n# config/environments/production.rb\nconfig.action_mailer.simple_postmark_settings = { api_key: '********-****-****-****-************', return_response: true }\n\n# your_mailer.rb\nresponse = YourMailer.email.deliver!.parsed_response\n\nresponse['MessageID']\n  # =\u003e \"b7bc2f4a-e38e-4336-af7d-e6c392c2f817\"\nresponse['ErrorCode']\n  # =\u003e 0\n```\n\n## Testing\n\nTesting simple_postmark is, well, simple. ;)\n\n```ruby\n# config/environments/test.rb\nconfig.action_mailer.simple_postmark_settings = { api_key: 'POSTMARK_API_TEST', return_response: true }\n```\n\nWith this setup, it will actually trigger a connection to the Postmark API, but Postmark will never send any emails and nothing will be delivered to your recipients.\n\n## Contributing\n\n1. Fork it\n2. Create your feature branch (`git checkout -b my-new-feature`)\n3. Commit your changes (`git commit -am 'Added some feature'`)\n4. Push to the branch (`git push origin my-new-feature`)\n5. Create new Pull Request\n\n## Copyright\n\n(The MIT license)\n\nCopyright (c) 2011-2015 Mario Uher\n\nPermission is hereby granted, free of charge, to any person obtaining\na copy of this software and associated documentation files (the\n\"Software\"), to deal in the Software without restriction, including\nwithout limitation the rights to use, copy, modify, merge, publish,\ndistribute, sublicense, and/or sell copies of the Software, and to\npermit persons to whom the Software is furnished to do so, subject to\nthe following conditions:\n\nThe above copyright notice and this permission notice shall be\nincluded in all copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND,\nEXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\nMERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND\nNONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE\nLIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION\nOF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION\nWITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fream88%2Fsimple_postmark","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fream88%2Fsimple_postmark","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fream88%2Fsimple_postmark/lists"}