---
title: customer_id
summary: The customer ID of the Fastly customer account to which the currently executing service belongs.
url: https://www.fastly.com/documentation/reference/compute/sdks/rust/fastly/compute_runtime/fn.customer_id/
---

**Kind:** Function  
**Module:** [compute_runtime](https://www.fastly.com/documentation/reference/compute/sdks/rust/fastly/compute_runtime/)  
**Package:** fastly 0.13.1  
**Source:** https://docs.rs/crate/fastly/0.13.1/source/src/compute_runtime.rs#143

```rust
fn customer_id() -> &'static str
```

The customer ID of the Fastly customer account to which the currently executing service
belongs.

Equivalent to the "FASTLY_CUSTOMER_ID" environment variable and to [`req.customer_id`](https://www.fastly.com/documentation/reference/vcl/variables/miscellaneous/req-customer-id/) in VCL.

**Returns**

`&str`
