Skip to content

Instantly share code, notes, and snippets.

@gaonkar-adi
Created November 11, 2020 15:11
Show Gist options
  • Save gaonkar-adi/3a52ff1ca8b92e08214a9be623b32d7a to your computer and use it in GitHub Desktop.
Save gaonkar-adi/3a52ff1ca8b92e08214a9be623b32d7a to your computer and use it in GitHub Desktop.
Constants File to pass error messages to API.js
module.exports = Object.freeze({
ACTION_UNAUTHORIZED: 'The user is unauthorized',
ACTION_NOT_FOUND: 'Resource Not Found',
ACTION_INTERNAL_SERVER: 'Internal Server Error',
ACTION_BAD_GATEWAY: 'Bad Gateway',
ACTION_SERVICE_UNAVAILABLE: 'The service is unavailable',
ACTION_REQUEST_TIMED_OUT: 'Request Timed Out',
ACTION_TOO_MANY: 'Too Many Requests',
ACTION_INSUFFICIENT_STORAGE: 'Insuffucient Storage',
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment