logger icon indicating copy to clipboard operation
logger copied to clipboard

Feature ms teams appender

Open aecoleman opened this issue 5 years ago • 2 comments
trafficstars

Closes #51

I tried to match the format that you used for the other appenders, but may not have done it quite right. In particular, I know that my httr::POST call will return a response object. I'm not sure whether it's within scope to handle cases where the response object reports a failure of some sort. There are rate limits involved, so I'm not sure if the best approach would be to handle that in the appender, or to trust the user to handle that in one way or another.

I'm not sure if it would be best to limit the webhook_url so that it must match the format teams uses. One the one hand, by not restricting it there's no chance that it will be incompatible with future formats (or current formats I'm not aware of). On the other hand, that makes this really more like appender_http_post.

aecoleman avatar Jun 28 '20 22:06 aecoleman

Codecov Report

Merging #52 into master will decrease coverage by 1.22%. The diff coverage is 0.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #52      +/-   ##
==========================================
- Coverage   78.85%   77.62%   -1.23%     
==========================================
  Files          10       10              
  Lines         506      514       +8     
==========================================
  Hits          399      399              
- Misses        107      115       +8     
Impacted Files Coverage Δ
R/appenders.R 55.55% <0.00%> (-3.27%) :arrow_down:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update cbe27a0...b059d2d. Read the comment docs.

codecov-commenter avatar Jun 28 '20 22:06 codecov-commenter

Thanks a lot for your contribution!

So far I preferred relying on external R packages for doing the API integrations -- eg the error handling should ideally happen there instead of maintaining that piece in logger as well. Any chance we could use eg https://cran.r-project.org/web/packages/teamr ?

daroczig avatar Aug 17 '20 21:08 daroczig