> This page is for Firmware, version 4.0 (default).
> For other versions, use one of these documentation indexes:
> - 4.0 (default): https://docs.ouster.com/sensor-docs/firmware/4.0/llms.txt
> - 3.2: https://docs.ouster.com/sensor-docs/firmware/3.2/llms.txt

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

# Get the lidar data format

GET http://os-992244000006.local/api/v1/sensor/metadata/lidar_data_format

Get the sensor lidar data format

__Note:__ This command only works when the lidar is running

Reference: https://docs.ouster.com/sensor-docs/firmware/api-reference/ouster-http-api/sensor-metadata/get-lidar-data-format

## Response

### 200

Lidar packet structure metadata

- `columns_per_frame` (integer, optional) — Number of measurement columns per frame. This can be 512, 1024, or 2048, depending upon the set lidar mode.
- `columns_per_packet` (integer, optional) — Number of measurement blocks contained in a single lidar packet. __Note:__ This is not user configurable.
- `pixel_shift_by_row` (list of integer, optional) — Offset in terms of pixel count. Can be used to destagger image. Varies by lidar mode. Length of this array is equal to the number of channels of the sensor.
- `pixels_per_column` (integer, optional) — Number of channels of the sensor.
- `column_window` (list of integer, optional) — Index of measurement blocks that are active. Default is [0, lidar_mode-1], e.g. [0,1023]. If there is an azimuth window set, this parameter will reflect which measurement blocks of data are within the region of interest.
- `header_type` (enum, optional, default: STANDARD) — UDP packet header type
  - Allowed values: `STANDARD`, `FUSA`
- `udp_profile_lidar` (enum, optional, default: RNG19_RFL8_SIG16_NIR16) — Lidar data profile format. Defaults to single return profile.
  - Allowed values: `RNG19_RFL8_SIG16_NIR16`, `RNG19_RFL8_SIG16_NIR16_ZONE16`, `RNG19_RFL8_SIG16_ZONE16_DUAL`, `RNG19_RFL8_SIG16_NIR16_DUAL`, `RNG15_RFL8_NIR8`, `RNG15_RFL8_NIR8_ZONE16`, `RNG15_RFL8_NIR8_DUAL`, `CUSTOM`
- `udp_profile_imu` (any, optional, default: ACCEL32_GYRO32_NMEA) — IMU data profile format
- `lidar_frame_azimuth_offset` (integer, optional) — The configured azimuth offset for the lidar coordinate frame in millidegrees

## Examples

**Response**

```json
{
  "columns_per_frame": 1024,
  "columns_per_packet": 16,
  "pixel_shift_by_row": [
    1
  ],
  "pixels_per_column": 128,
  "column_window": [
    0,
    1023
  ],
  "header_type": "STANDARD",
  "udp_profile_lidar": "RNG19_RFL8_SIG16_NIR16",
  "udp_profile_imu": null,
  "lidar_frame_azimuth_offset": 0
}
```

**SDK Code**

```python
import requests

url = "http://os-992244000006.local/api/v1/sensor/metadata/lidar_data_format"

response = requests.get(url)

print(response.json())
```

```javascript
const url = 'http://os-992244000006.local/api/v1/sensor/metadata/lidar_data_format';
const options = {method: 'GET'};

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

```go
package main

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

func main() {

	url := "http://os-992244000006.local/api/v1/sensor/metadata/lidar_data_format"

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

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

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

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

}
```

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

url = URI("http://os-992244000006.local/api/v1/sensor/metadata/lidar_data_format")

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

request = Net::HTTP::Get.new(url)

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

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

HttpResponse<String> response = Unirest.get("http://os-992244000006.local/api/v1/sensor/metadata/lidar_data_format")
  .asString();
```

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

$client = new \GuzzleHttp\Client();

$response = $client->request('GET', 'http://os-992244000006.local/api/v1/sensor/metadata/lidar_data_format');

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

```csharp
using RestSharp;

var client = new RestClient("http://os-992244000006.local/api/v1/sensor/metadata/lidar_data_format");
var request = new RestRequest(Method.GET);
IRestResponse response = client.Execute(request);
```

```swift
import Foundation

let request = NSMutableURLRequest(url: NSURL(string: "http://os-992244000006.local/api/v1/sensor/metadata/lidar_data_format")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"

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()
```