From 381b4585f1589b43fa3112c33b730b7ea97f72e2 Mon Sep 17 00:00:00 2001 From: Nick Muerdter Date: Fri, 18 Sep 2015 19:38:10 -0400 Subject: [PATCH] Update default config for error variable changes. This is part of https://github.com/18F/api.data.gov/issues/285 The associated changes are on the gatekeeper project's 6d2e6574998ff0478481d7ff7f0b327019006e05 commit. --- config/default.yml | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/config/default.yml b/config/default.yml index f0a81a5..c4c33fe 100644 --- a/config/default.yml +++ b/config/default.yml @@ -201,6 +201,9 @@ apiSettings: error_data: + common: + signup_url: "{{base_url}}" + contact_url: "{{base_url}}/contact/" not_found: status_code: 404 code: NOT_FOUND @@ -208,35 +211,35 @@ apiSettings: api_key_missing: status_code: 403 code: API_KEY_MISSING - message: No api_key was supplied. Get one at {{baseUrl}} + message: No api_key was supplied. Get one at {{signup_url}} api_key_invalid: status_code: 403 code: API_KEY_INVALID - message: An invalid api_key was supplied. Get one at {{baseUrl}} + message: An invalid api_key was supplied. Get one at {{signup_url}} api_key_disabled: status_code: 403 code: API_KEY_DISABLED - message: The api_key supplied has been disabled. Contact us at {{baseUrl}}/contact for assistance + message: The api_key supplied has been disabled. Contact us at {{contact_url}} for assistance api_key_unverified: status_code: 403 code: API_KEY_UNVERIFIED - message: The api_key supplied has not been verified yet. Please check your e-mail to verify the API key. Contact us at {{baseUrl}}/contact for assistance + message: The api_key supplied has not been verified yet. Please check your e-mail to verify the API key. Contact us at {{contact_url}} for assistance api_key_unauthorized: status_code: 403 code: API_KEY_UNAUTHORIZED - message: The api_key supplied is not authorized to access the given service. Contact us at {{baseUrl}}/contact for assistance + message: The api_key supplied is not authorized to access the given service. Contact us at {{contact_url}} for assistance over_rate_limit: status_code: 429 code: OVER_RATE_LIMIT - message: You have exceeded your rate limit. Try again later or contact us at {{baseUrl}}/contact for assistance + message: You have exceeded your rate limit. Try again later or contact us at {{contact_url}} for assistance internal_server_error: status_code: 500 code: INTERNAL_SERVER_ERROR - message: An unexpected error has occurred. Try again later or contact us at {{baseUrl}}/contact for assistance + message: An unexpected error has occurred. Try again later or contact us at {{contact_url}} for assistance https_required: status_code: 400 code: HTTPS_REQUIRED - message: "Requests must be made over HTTPS. Try accessing the API at: {{httpsUrl}}" + message: "Requests must be made over HTTPS. Try accessing the API at: {{https_url}}" ban: user_agents: ips: