email-proxy

==========

All the calls to email-proxy are forwarded to the email microservice.

Build Status Download

API

Method Path Description
POST email-proxy/<domain>/email Sends request to email m/s

POST email-proxy/<domain>/email

Sends a request to the email m/s via the email-proxy

Request format

See email microservice for json body format.

Note: the email-proxy will convert the body to json but will do no other validation, all other errors will be supplied by the connected email m/s.

Response

Response of 2xx should be treated as ok all others as an exception

Status Message
202 Success - request was submitted to email to send an email
400 Invalid json format or rejected by email m/s
404 If endpoint is not reachable
502 Could not contact email m/s

Response body

Only returned in the case of an exception response (status code >= 400)

{
    "statusCode": 400,
    "message": "Template NNN does not exist"
}

Run the tests and sbt fmt before raising a PR

Format:

sbt fmt

Then run the tests and coverage report:

sbt clean coverage test coverageReport

If your build fails due to poor test coverage, DO NOT lower the test coverage threshold, instead inspect the generated report located here on your local repo: /target/scala-2.12/scoverage-report/index.html

Then run the integration tests:

sbt it:test

License

This code is open source software licensed under the Apache 2.0 License