def METHOD_NAME(self):
    access_token = PostlogisticsWebService.get_access_token(self)
    if not access_token:
        # Error has already been risen
        return
    message = {
        "type": "ir.actions.client",
        "tag": "display_notification",
        "params": {
            "title": _("Validated"),
            "message": _("The credential is valid."),
            "sticky": False,
        },
    }
    return message