Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

JSON API for listing messages and their metadata #89

Closed
wants to merge 4 commits into from

Conversation

kmarsh
Copy link

@kmarsh kmarsh commented Jul 12, 2018

Adds a JSON API for listing messages and their metadata:

GET /letter_opener.json

[
  {
    "from": "App <notifications@example.com>",
    "id": "1531326085_772435_3ec1a42",
    "subject": "Retailer accepted your invitation!",
    "to": "Rebekah_Borer@gmail.com"
  },
  {
    "from": "App <notifications@example.com>",
    "id": "1531326065_158782_e7bf42c",
    "subject": "You have been invited to participate!",
    "to": "Laurie18@yahoo.com"
  }
]

Also:

  • Adds an optional /raw parameter to LettersController#show access a message without letter_opener's iframe wrapper.
  • Fixes some Rubocop errors (not in my changes) that were preventing a push

This was adding to make end-to-end testing with Cypress, etc. easier.

@kmarsh kmarsh changed the title JSON API for listing messages JSON API for listing messages and their metadata Jul 12, 2018
@kmarsh
Copy link
Author

kmarsh commented Jul 12, 2018

Looks like this build is failing on Ruby 2.1 because Rubocop doesn't support it. That's a pretty old version of Ruby, no longer supported. Should I remove it from Travis?

@fgrehm
Copy link
Owner

fgrehm commented Feb 18, 2020

Hey @kmarsh! Sorry for the silence but what's the use case here? You mentioned end to end testing with cypress but I wonder how you plan to use it.

I've personally only used this gem in development environments. I know some people use it on staging envs but it's the first time I hear about usage for tests!

cc @pseudomuto in case you have any thoughts too

@fgrehm fgrehm added the waiting label Feb 18, 2020
@kmarsh
Copy link
Author

kmarsh commented Feb 18, 2020

I was using it to verify emails were sent during an integration test. I ended up rolling off that particular project but I still think it’d be useful for that use case and would be happy to get the PR into shape once Travis is fixed.

@fgrehm
Copy link
Owner

fgrehm commented Feb 18, 2020

once Travis is fixed.

Master is currently green 😄

@fgrehm
Copy link
Owner

fgrehm commented Nov 6, 2021

Hi @kmarsh! CI has been fixed and moved over to github actions and we now have a 2.0 release, if you or anyone else is interested in pursuing this please open up a new PR and I'll be more than happy to help review and release!

In any case, thanks for the PR and interest in contributing with the project!

@fgrehm fgrehm closed this Nov 6, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants