# command.CommandResult.request_id

- **Module:** command.CommandResult
- **Package:** libtmux
- **Language:** Rust
- **Kind:** method
- **Source:** https://github.com/libtmux/libtmux-rs/blob/f0e37052c232636b61d095817046e6bfc8f2ca40/crates/libtmux/src/command.rs#L994
- **Page:** https://libtmux.org/en/rs/latest/reference/command-commandresult-request_id/

```
command.CommandResult.request_id(self) -> u64
```

Return the Core-scoped dispatch-request identity.

The Core allocates this value before validation, so an error can expose
an ID even when no process was spawned. Clones of one [`crate::Server`]
share the allocating Core. The ID is not globally unique, a process ID,
an internal attempt ID, or a control-mode protocol-block ID.

## Example

```rust
let server = libtmux::Server::builder().socket_path("/tmp/libtmux-rs-test/result-id.sock").build()?;
let result = server.cmd(libtmux::Command::new("list-sessions")).await?;
assert!(result.request_id() > 0);
server.shutdown().await?;
```
