@villedemontreal/general-utils
Version:
General utilities library
81 lines • 2.07 kB
TypeScript
/**
* Montreal Global constants
*/
export declare class GlobalConstants {
/**
* Endpoint type roots.
*
* Those roots should probably never be changed, since some
* of our operation components (Nginx / Kong / etc.) are
* configured for them.
*/
get EnpointTypeRoots(): {
API: string;
DOCUMENTATION: string;
DIAGNOSTICS: string;
};
/**
* Known environment types
*/
get Environments(): {
LOCAL: string;
DEV: string;
ACCEPTATION: string;
LAB: string;
/**
* "production" seems to be the standard Node label, not "prod".
*/
PROD: string;
};
/**
* Errors related constants
*/
get errors(): {
/**
* General API errors
*/
apiGeneralErrors: {
codes: {
GENERIC_ERROR: string;
NOT_FOUND: string;
INVALID_PARAMETER: string;
INVALID_JSON_BODY: string;
DUPLICATE_KEY: string;
NOT_IMPLEMENTED: string;
UNAUTHORIZED: string;
UNPROCESSABLE_ENTITY: string;
FORBIDDEN: string;
};
};
};
/**
* Environment variables
*/
get envVariables(): {
/**
* Environment type. The possible values are defined
* in "Environments"
* Do not change this :
* https://github.com/lorenwest/node-config/wiki/Configuration-Files#default-node_env
*/
ENV_TYPE: string;
NODE_APP_INSTANCE: string;
};
/**
* Known app instances
*/
get appInstances(): {
/**
* App instance name to use when running local tests
* in an API.
* This allows local configs to be picked.
*/
TESTS: string;
};
/**
* Currently in testing mode?
*/
get testingMode(): boolean;
}
export declare const globalConstants: GlobalConstants;
//# sourceMappingURL=globalConstants.d.ts.map