Skip to main content

Usage

phala status [options]

Options

FlagShortDefaultDescription
--json-jfalseOutput in JSON format
--debug-dfalseEnable debug output
--api-token <token>Override API token for this command

Examples

Check authentication status

$ phala status
 Authenticated as user@example.com
Workspace: my-workspace
Profile: default

JSON output

$ phala status --json
{
  "authenticated": true,
  "username": "user@example.com",
  "workspace": "my-workspace",
  "profile": "default"
}

Check authentication in scripts

$ phala status --json | jq -e '.authenticated' > /dev/null
$ if [ $? -eq 0 ]; then
    echo "Authenticated"
  else
    echo "Not authenticated"
  fi

Override API token

$ phala status --api-token phak_abc123...
 Authenticated as other@example.com

Exit Codes

  • 0 - Authenticated successfully
  • 1 - Not authenticated or error occurred