_debug "Full Challenge Domain is: $fullchallengedomain"
@ -49,7 +49,7 @@ dns_japi_add() {
_debug txtvalue "$txtvalue"
#_err "Not implemented!"
response="$(_post "{\"domain\":\"$domain\",\"update\": {\"type\":\"TXT\",\"name\":\"$fullchallengedomain\",\"content\":\"$txtvalue\",\"ttl\":0}}"$apiendpoint"" POST "application/json")"
response="$(_post "{\"domain\":\"$domain\",\"update\": {\"type\":\"TXT\",\"name\":\"$fullchallengedomain\",\"content\":\"$txtvalue\",\"ttl\":0}}"$JAPIendpoint"" POST "application/json")"
if ! printf"%s""$response"| grep \"code\":0>/dev/null;then
_err "There was an error updating the TXT record..."
_err "DNS Exit API response: $response"
@ -63,7 +63,7 @@ dns_japi_add() {
dns_japi_rm(){
fulldomain=$1
txtvalue=$2
apiendpoint="https://api.dnsexit.com/dns/"
JAPIendpoint="https://api.dnsexit.com/dns/"
#_debug "Domain being used with custom script is: $domain"
response="$(_post "{\"domain\":\"$domain\",\"delete\": {\"type\":\"TXT\",\"name\":\"$fullchallengedomain\",\"content\":\"$txtvalue\",\"ttl\":0}}"$apiendpoint"" POST "application/json")"
response="$(_post "{\"domain\":\"$domain\",\"delete\": {\"type\":\"TXT\",\"name\":\"$fullchallengedomain\",\"content\":\"$txtvalue\",\"ttl\":0}}"$JAPIendpoint"" POST "application/json")"
if ! printf"%s""$response"| grep \"code\":0>/dev/null;then
_err "There was an error deleting the TXT record..."