---
title: "Describe a named label source"
method: GET
path: "/v1/spatial/maps/labelSources/{labelSourceName}"
tags: ["Mapping Service: Miscellaneous"]
---

# Describe a named label source

`GET /v1/spatial/maps/labelSources/{labelSourceName}`

## Request

- Base URL: `https://api.cloud.precisely.com`
- URL: `https://api.cloud.precisely.com/v1/spatial/maps/labelSources/{labelSourceName}`
- Auth: API key in header `Authorization` and HTTP bearer

Returns the description of a named label source in JSON format. The label source name should be provided as part of the URL path after `/labelSources/`.

**Resource dependencies:** A named label source typically references a named table (see the `table` field, e.g. `NamedTable`) that provides the data used to generate labels. This referenced table must already exist in the repository for the label source to render or describe correctly.

**Authorization:** Requires EXECUTE permission on the requested label source. If the caller lacks permission, the API returns `403 Forbidden`; if the label source does not exist, it returns `404 Not Found`. Both share the same error code (`DIS-MS-1016`), but the distinct HTTP status and message text make the two cases distinguishable to the caller.

## Path parameters

- `labelSourceName` string, required

## Response `200`

Label source description retrieved successfully

- LabelSourceResponse: Response payload containing the description of a named label source
  - `labelSourceDescription` LabelSourceDescription: Label source description
    - `name` string
    - `labelSource` union
      - FeatureLabelSource: A label source generating labels from the features of a table.
        - `type` 'NamedLabelSource' | 'FeatureLabelSource', required: Type discriminator of this LabelSource (NamedLabelSource, FeatureLabelSource).
        - `renderable` boolean: Whether labels from this source are rendered.
        - `table` union
          - MemoryTable: Table backed by an in-memory feature collection.
            - `type` 'NamedTable' | 'ViewTable' | 'MemoryTable', required: Type of table (NamedTable, ViewTable, MemoryTable).
            - `name` string, required: Table name.
            - `featureCollection` FeatureCollection, required: A GeoJSON FeatureCollection object, optionally with metadata, bbox, and Crs.
              - …
          - NamedTable: Polymorphic table definition (NamedTable, ViewTable, or MemoryTable).
            - `type` 'NamedTable' | 'ViewTable' | 'MemoryTable', required: Type of table (NamedTable, ViewTable, MemoryTable).
            - `name` string, required: Table name.
          - ViewTable: Table backed by a SQL view definition.
            - `type` 'NamedTable' | 'ViewTable' | 'MemoryTable', required: Type of table (NamedTable, ViewTable, MemoryTable).
            - `name` string, required: Table name.
            - `sql` string, required: SQL statement defining the view.
        - `themes` union[]: Label themes applied to the generated labels.
          - union
            - LabelCustomRangeTheme: A label theme applying label properties per explicitly defined value range.
              - …
            - LabelIndividualValueTheme: A label theme applying label properties per discrete attribute value.
              - …
            - LabelOverrideTheme: A label theme overriding the label properties of every labelled feature.
              - …
            - LabelRangeTheme: A label theme spreading label properties across automatically computed value ranges.
              - …
        - `labelProperties` LabelProperties, required: Full set of properties controlling how labels are generated and drawn for a layer or label theme.
          - `style` union
            - GridStyle: A style that classifies grid/raster values into color bands via inflection breaks.
              - …
            - MapBasicAreaStyle: MapBasic area style: border pen and fill brush.
              - …
            - MapBasicCompositeStyle: MapBasic composite style combining point, line, and area styles.
              - …
            - MapBasicFontStyle: MapBasic font style: name, style flags, size, and foreground/background colors.
              - …
            - MapBasicLineStyle: MapBasic line style: the pen used to draw the line.
              - …
            - MapBasicPointStyle: MapBasic point style: the symbol used to render the point.
              - …
            - MapBasicTextStyle: MapBasic text style: the font style used to render the text.
              - …
            - NamedStyle: A style that references a pre-configured named style.
              - …
          - `angle` Angle: An angle: a magnitude plus its unit of measure.
            - `value` number, double: Angle magnitude.
            - `uom` 'Degree' | 'Minute' | 'Second' | 'Radian', required: Unit of measure for an angle.
          - `expression` string: Expression producing the label text.
          - `horizontalAlignment` 'LEFT' | 'CENTER' | 'RIGHT': Horizontal alignment of a chart, symbol, or label relative to its anchor point.
          - `verticalAlignment` 'TOP' | 'MIDDLE' | 'BOTTOM' | 'BASELINE': Vertical alignment of a chart, symbol, or label relative to its anchor point.
          - `allowOverlap` boolean: Whether the label may overlap other labels.
          - `allowOutOfView` boolean: Whether the label may be drawn partially outside the view.
          - `allowDuplicate` 'INTERLAYER' | 'INTRALAYER' | 'ALL': Scope in which duplicate labels are allowed to be drawn.
          - `recalculationType` 'ALWAYS' | 'OUT_OF_VIEW' | 'NEVER': When label positions are recalculated.
          - `labelRelativeOrientation` 'PARALLEL' | 'FOLLOW_PATH': Orientation of a label relative to the geometry it labels.
          - `justification` 'LEFT' | 'CENTER' | 'RIGHT': Justification of multi-line label text.
          - `referenceGeometry` union
            - GeometryCollection: A GeoJSON GeometryCollection: a list of heterogeneous geometry objects.
              - …
            - LineString: A GeoJSON LineString geometry: a list of coordinates forming a line.
              - …
            - MultiLineString: A GeoJSON MultiLineString geometry: a list of line strings.
              - …
            - MultiPoint: A GeoJSON MultiPoint geometry: a list of coordinates.
              - …
            - MultiPolygon: A GeoJSON MultiPolygon geometry: a list of polygons, each a list of linear rings.
              - …
            - Point: A GeoJSON Point geometry: a single coordinate.
              - …
            - Polygon: A GeoJSON Polygon geometry: a list of linear rings (first is the exterior ring, any others are interior rings/holes).
              - …
          - `xOffset` number, double: Horizontal offset of the label from its anchor point.
          - `yOffset` number, double: Vertical offset of the label from its anchor point.
        - `visibilityConstraints` union[]: Constraints controlling at which scales/zooms the labels are visible.
          - union
            - ScaleVisibilityConstraint: A visibility constraint expressed as a map scale range.
              - …
            - ZoomVisibilityConstraint: A visibility constraint expressed as a zoom (ground distance) range.
              - …
        - `name` string: Name of this label source.
      - NamedLabelSource: A label source referencing a pre-configured named label source.
        - `type` 'NamedLabelSource' | 'FeatureLabelSource', required: Type discriminator of this LabelSource (NamedLabelSource, FeatureLabelSource).
        - `renderable` boolean: Whether labels from this source are rendered.
        - `name` string, required: Name (resource path) of the named label source.
    - `errorMessage` string

## Other responses

- `403`: Caller does not have EXECUTE permission on the requested label source
- `404`: Label source not found

---

[API](https://skmtc.dev/precisely/apis/mapping-api.md) · [All operations](https://skmtc.dev/precisely/apis/mapping-api/llms.txt) · [OpenAPI document](https://skmtc.dev/precisely/apis/mapping-api/revisions/cea0ad9440c5?raw)
