feat: access team workspace collections and environments from the CLI

This commit is contained in:
jamesgeorge007
2024-05-25 15:25:19 +05:30
parent 4bd23a8f4c
commit 4dc9030559
8 changed files with 382 additions and 40 deletions

View File

@@ -82,6 +82,15 @@ export const handleError = <T extends HoppErrorCode>(error: HoppError<T>) => {
case "TESTS_FAILING":
ERROR_MSG = error.data;
break;
case "TOKEN_EXPIRED":
ERROR_MSG = `Token is expired: ${error.data}`;
break;
case "TOKEN_INVALID":
ERROR_MSG = `Token is invalid/removed: ${error.data}`;
break;
case "INVALID_ID":
ERROR_MSG = `The collection/environment is not valid/not accessible to the user: ${error.data}`;
break;
}
if (!S.isEmpty(ERROR_MSG)) {