> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.one.mtxsci.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.one.mtxsci.com/_mcp/server.

# Customers

GET https://one.mtxsci.com/api/1.1/wf/customers-v2

## List customers

Retrieve the customers the authenticated user can access. Select the customer for the intended division or plant before making customer-scoped requests.

**Request:** `GET https://one.mtxsci.com/api/1.1/wf/customers-v2`

**Authentication:** `Authorization: Bearer <token>`, using `response.token` from **authenticate-v2**.

**Success:** `200 OK` with a JSON body recorded as `text/plain;charset=utf-8`.

**Request body:** None.

### Query parameters

| Parameter | Format                  | Requirement and usage           |
| --------- | ----------------------- | ------------------------------- |
| `page`    | Integer in query string | Page to retrieve; start at `1`. |

This discovery request does not take `customer_id`. Use each returned `customer_id` in subsequent catalog, sample, results, and submission requests. Keep the mapping to your own division or plant identifiers in your system.

### Response envelope

| Field         | Type             | Description                              |
| ------------- | ---------------- | ---------------------------------------- |
| `page`        | String           | Returned page number, for example `"1"`. |
| `hasNextPage` | Boolean          | Whether another page is available.       |
| `customers`   | Array of objects | Records in this page.                    |

Keep the customer and filters unchanged while paging. Increment `page` while `hasNextPage` is `true`; stop when it is `false`.

### Customer fields

| Field          | Type   | Description                                      |
| -------------- | ------ | ------------------------------------------------ |
| `company_name` | String | Company name.                                    |
| `division`     | String | Division or plant associated with this customer. |
| `customer_id`  | String | Authorized Matrix customer identifier.           |
| `lab`          | String | Laboratory associated with this customer.        |

### Saved example

The attached `200 OK` example preserves the documented field names, nesting, and types using generic placeholders. Use the actual `hasNextPage` flag to determine whether another page is available.

Reference: https://docs.one.mtxsci.com/ms-cp-customer-api/customers

## Authentication

- `Authorization` header (bearer token, required) — Use response.token from authenticate-v2. response.expires is the lifetime in seconds (86400 = 24 hours).

## Request

### Query parameters

- `page` (integer, optional, default: 1) — Returned page number, for example `"1"`.

## Response

### 200

OK

## Examples

**Response**

```json
{
  "customers": [
    {
      "company_name": "string",
      "customer_id": "string",
      "division": "string",
      "lab": "string"
    },
    {
      "company_name": "string",
      "customer_id": "string",
      "division": "string",
      "lab": "string"
    }
  ],
  "hasNextPage": false,
  "page": "1"
}
```

**SDK Code**

```python customers_example
import requests

url = "https://one.mtxsci.com/api/1.1/wf/customers-v2"

querystring = {"page":"1"}

headers = {"Authorization": "Bearer <token>"}

response = requests.get(url, headers=headers, params=querystring)

print(response.json())
```

```javascript customers_example
const url = 'https://one.mtxsci.com/api/1.1/wf/customers-v2?page=1';
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go customers_example
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "https://one.mtxsci.com/api/1.1/wf/customers-v2?page=1"

	req, _ := http.NewRequest("GET", url, nil)

	req.Header.Add("Authorization", "Bearer <token>")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby customers_example
require 'uri'
require 'net/http'

url = URI("https://one.mtxsci.com/api/1.1/wf/customers-v2?page=1")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'

response = http.request(request)
puts response.read_body
```

```java customers_example
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.get("https://one.mtxsci.com/api/1.1/wf/customers-v2?page=1")
  .header("Authorization", "Bearer <token>")
  .asString();
```

```php customers_example
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('GET', 'https://one.mtxsci.com/api/1.1/wf/customers-v2?page=1', [
  'headers' => [
    'Authorization' => 'Bearer <token>',
  ],
]);

echo $response->getBody();
```

```csharp customers_example
using RestSharp;

var client = new RestClient("https://one.mtxsci.com/api/1.1/wf/customers-v2?page=1");
var request = new RestRequest(Method.GET);
request.AddHeader("Authorization", "Bearer <token>");
IRestResponse response = client.Execute(request);
```

```swift customers_example
import Foundation

let headers = ["Authorization": "Bearer <token>"]

let request = NSMutableURLRequest(url: NSURL(string: "https://one.mtxsci.com/api/1.1/wf/customers-v2?page=1")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```