Skip to content

Instantly share code, notes, and snippets.

View mescortes's full-sized avatar

Marcelo Cortes mescortes

  • Square Inc
  • Toronto
View GitHub Profile
/*
* Copyright 2013 Square Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
@mescortes
mescortes / MailgunEmail.java
Created December 22, 2016 15:51
OkHttp + Mailgun
import java.util.LinkedList;
import java.util.List;
import okhttp3.MultipartBody;
import okhttp3.RequestBody;
import org.joda.time.DateTime;
import org.joda.time.format.DateTimeFormat;
import org.joda.time.format.DateTimeFormatter;
import static com.google.common.base.Preconditions.checkNotNull;
import static com.google.common.base.Preconditions.checkState;