---
title: "Get segment"
method: GET
path: "/api/v1/user/segments/{id}"
tags: ["User"]
---

# Get segment

`GET /api/v1/user/segments/{id}`

## Path parameters

- `id` integer, required

## Response `200`

Segment

- UserSegment — Saved account segment. Extra migration columns may be returned for backward compatibility.
  - `id` integer
  - `user_id` integer
  - `name` string
  - `description` string
  - `filters_json` string
  - `filters` UserSegmentStoredFilters — Read-only decoded filters_json from an existing segment. New writes must use UserSegmentFilters. Historic records may still contain removed keys such as forma or estado; clients must present them as unavailable and execution fails closed rather than ignoring them.
  - `persona` string, nullable
  - `icon` string, nullable
  - `pinned` union
    - integer
    - boolean
  - `created_at` string
  - `updated_at` string

## Other responses

- `404` — Resource not found

## Changes

- **2026-07-26** `996f96a11758` — 36 info
  - api operation id `getUserSegmentsById` was added
  - added the media type `application/json` for the response with the status `200`
  - added the optional property `_alias_of` to the response with the `404` status
  - added the optional property `action` to the response with the `404` status
  - …32 more

[Change history](https://skmtc.dev/openmercantil/apis/openmercantil-public-api/changes/api/v1/user/segments/:id/get.md)

---

[API](https://skmtc.dev/openmercantil/apis/openmercantil-public-api.md) · [All operations](https://skmtc.dev/openmercantil/apis/openmercantil-public-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/openmercantil/openmercantil-public-api/revisions/601ff6123c86/schema)
