From ea407052cc5080326b90b5d2068b2ef7bc7a551a Mon Sep 17 00:00:00 2001 From: Tiffany Date: Fri, 27 Feb 2026 11:50:29 -0500 Subject: [PATCH 1/2] Patched in session token info --- .../kobiton-cli/pages/cli-commands.adoc | 9 +++++- .../kobiton-cli/pages/use-the-cli.adoc | 32 +++++++++++++++---- 2 files changed, 33 insertions(+), 8 deletions(-) diff --git a/docs/modules/kobiton-cli/pages/cli-commands.adoc b/docs/modules/kobiton-cli/pages/cli-commands.adoc index 4d3572768..0a42678f3 100644 --- a/docs/modules/kobiton-cli/pages/cli-commands.adoc +++ b/docs/modules/kobiton-cli/pages/cli-commands.adoc @@ -1,7 +1,14 @@ = Kobiton Command Line Interface commands :navtitle: Kobiton CLI commands -These are the commands you can use with the Kobiton Command Line Interface (CLI) tool. +Commands that operate on an active CLI session require session context. + +Provide session context using one of the following: + +* Pass the session token with the command: `--session-token ` (or `-a `) +* Set the `KOBITON_SESSION_TOKEN` environment variable + +The `` value is returned when you create a CLI session. For details, see xref:use-the-cli.adoc[Start using Kobiton CLI]. == `app run` diff --git a/docs/modules/kobiton-cli/pages/use-the-cli.adoc b/docs/modules/kobiton-cli/pages/use-the-cli.adoc index e83b99e78..f2ec0fb54 100644 --- a/docs/modules/kobiton-cli/pages/use-the-cli.adoc +++ b/docs/modules/kobiton-cli/pages/use-the-cli.adoc @@ -3,7 +3,7 @@ Learn how to use Kobiton Command Line Interface to control and operate your private device lab. -== Before you start +== Before you begin * xref:set-up-cli.adoc[Set up] Kobiton CLI. @@ -62,20 +62,38 @@ set KOBITON_SESSION_TOKEN= -- ==== -Most CLI commands require either `SESSION_ID` or `KOBITON_SESSION_TOKEN`. See xref:cli-commands.adoc[this page,window=read-later] for the list of commands and their basic usage. +== Use session context consistently + +After creating a CLI session, you receive both a `` and a ``. [NOTE] ==== +The *session ID* identifies the session record. The *session token* authorizes and scopes CLI commands to that session. +==== + +Many commands that operate on an active CLI session require session context. Provide session context using one of the following methods: + +* Pass the session token explicitly: `--session-token ` (or `-a `) +* Set the `KOBITON_SESSION_TOKEN` environment variable + +The session token ensures each command is applied to the intended active session. + +If you are running multiple sessions concurrently, always provide the session context explicitly. This prevents commands from being applied to the wrong session when more than one session is active. + +For interactive use, set `KOBITON_SESSION_TOKEN` once per terminal session. + +For scripts or isolated commands, pass `--session-token` explicitly with each command. + -* For CLI sessions: +== Known limitations -** No Session Explorer available. +* Session Explorer is not available when using Kobiton CLI. -** Session video and logs are not available in Session Overview. +* Session video and logs are not available in Session Overview. -** Mixed sessions between manual and CLI are not supported. +* Mixed sessions between manual testing and CLI testing are not supported. -** CLI sessions time out after 10 minutes by default and can be configured for up to 2 hours. You can reset the timeout using the `kobiton session ping` command. +* By default, CLI sessions time out after 10 minutes. You can configure the timeout up to 2 hours using the `kobiton session ping` command. ==== From 5a256ccb8bc91410af4bdc419210b40dcd1ed5a3 Mon Sep 17 00:00:00 2001 From: Tung Manh Hoang Date: Fri, 6 Mar 2026 18:44:10 +0700 Subject: [PATCH 2/2] Fix issue with formatting --- docs/modules/kobiton-cli/pages/use-the-cli.adoc | 2 -- 1 file changed, 2 deletions(-) diff --git a/docs/modules/kobiton-cli/pages/use-the-cli.adoc b/docs/modules/kobiton-cli/pages/use-the-cli.adoc index f2ec0fb54..fdc8882b9 100644 --- a/docs/modules/kobiton-cli/pages/use-the-cli.adoc +++ b/docs/modules/kobiton-cli/pages/use-the-cli.adoc @@ -95,8 +95,6 @@ For scripts or isolated commands, pass `--session-token` explicitly with each co * By default, CLI sessions time out after 10 minutes. You can configure the timeout up to 2 hours using the `kobiton session ping` command. -==== - [#_troubleshooting] == Troubleshooting