From 460d917774c0def18e9ca9a576131f5d3214396b Mon Sep 17 00:00:00 2001 From: Tom Limoncelli Date: Wed, 17 Apr 2019 11:34:02 -0400 Subject: [PATCH] NAMEDOTCOM: Improve docs about errors related to typos (#465) * named.com.md: Improve headings --- docs/_providers/name.com.md | 29 ++++++++++++++++++++++++----- 1 file changed, 24 insertions(+), 5 deletions(-) diff --git a/docs/_providers/name.com.md b/docs/_providers/name.com.md index b2e0e4910..1728349f9 100644 --- a/docs/_providers/name.com.md +++ b/docs/_providers/name.com.md @@ -58,21 +58,40 @@ D("example.tld", REG_NAMECOM, DnsProvider(R53), ## Activation In order to activate API functionality on your Name.com account, you must apply to the API program. The application form is [located here](https://www.name.com/reseller/apply). It usually takes a few days to get a response. After you are accepted, you should receive your API token via email. -## Tips: +## Tips and error messages -When running integration tests, this error: +### invalid character '<' ``` integration_test.go:140: api returned unexpected response: invalid character '<' looking for beginning of value ``` -Means you are setting `export NAMEDOTCOM_URL='api.name.com/api'` and need to remove the `/api`. +This error means an invalid URL is being used to reach the API +endpoint. It usually means a setting is `api.name.com/api` when +`api.name.com` is correct (i.e. remove the `/api`). + +In integration tests: + + * Wrong: `export NAMEDOTCOM_URL='api.name.com/api'` + * Right: `export NAMEDOTCOM_URL='api.name.com'` + +In production, the `apiurl` setting in creds.json is wrong. You can +simply leave this option out and use the default, which is correct. + +TODO(tlim): Improve the error message. (Volunteer needed!) -When running integration tests, this error: +### dial tcp: lookup https: no such host ``` integration_test.go:81: Failed getting nameservers Get https://https//api.name.com/api/v4/domains/stackosphere.com?: dial tcp: lookup https: no such host ``` -It means you included the `https://` in the `NAMEDOTCOM_URL` variable. You meant to do something like `export NAMEDOTCOM_URL='api.name.com' instead. +When running integration tests, this error +means you included the `https://` in the `NAMEDOTCOM_URL` variable. +You meant to do something like `export NAMEDOTCOM_URL='api.name.com' instead. + +In production, the `apiurl` setting in creds.json needs to be +adjusted. You can simply leave this option out and use the default, +which is correct. If you are using the EO&T system, leave the +protocol (`http://`) off the URL.