def METHOD_NAME(self, token, notif):
    msg = {
        "token": token,
        # Specify the various formats (we use android only)
        "android": {
            # TTL is a duration string e.g. ("60s")
            "ttl": str(int(notif.get("ttl", 0)))+"s",
            "data": notif.get("data_message")
        },
    }
    # Wrap up the whole thing in a "message" tag.
    return {"message": msg}