# sections.get

> Retrieve full section information by section address.



- Member path: `doc.sections.get(…)`
- Mutates document: no
- Idempotency: `idempotent`
- Supports tracked mode: no
- Supports dry run: no

## Expected result

Returns a SectionInfo object with full section properties including margins, columns, and header/footer refs.

## Input schema

```json
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$defs": {
    "SectionAddress": {
      "type": "object",
      "properties": {
        "kind": {
          "const": "section"
        },
        "sectionId": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "required": [
        "kind",
        "sectionId"
      ]
    }
  },
  "type": "object",
  "properties": {
    "address": {
      "$ref": "#/$defs/SectionAddress"
    }
  },
  "additionalProperties": false,
  "required": [
    "address"
  ]
}
```

## Output schema

```json
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$defs": {
    "SectionAddress": {
      "type": "object",
      "properties": {
        "kind": {
          "const": "section"
        },
        "sectionId": {
          "type": "string"
        }
      },
      "additionalProperties": false,
      "required": [
        "kind",
        "sectionId"
      ]
    }
  },
  "type": "object",
  "properties": {
    "address": {
      "$ref": "#/$defs/SectionAddress"
    },
    "index": {
      "type": "integer",
      "minimum": 0
    },
    "range": {
      "type": "object",
      "properties": {
        "startParagraphIndex": {
          "type": "integer",
          "minimum": 0
        },
        "endParagraphIndex": {
          "type": "integer",
          "minimum": 0
        }
      },
      "additionalProperties": false,
      "required": [
        "startParagraphIndex",
        "endParagraphIndex"
      ]
    },
    "breakType": {
      "enum": [
        "continuous",
        "nextPage",
        "evenPage",
        "oddPage"
      ]
    },
    "pageSetup": {
      "type": "object",
      "properties": {
        "width": {
          "type": "number",
          "minimum": 0
        },
        "height": {
          "type": "number",
          "minimum": 0
        },
        "orientation": {
          "enum": [
            "portrait",
            "landscape"
          ]
        },
        "paperSize": {
          "type": "string"
        }
      },
      "additionalProperties": false
    },
    "margins": {
      "type": "object",
      "properties": {
        "top": {
          "type": "number",
          "minimum": 0
        },
        "right": {
          "type": "number",
          "minimum": 0
        },
        "bottom": {
          "type": "number",
          "minimum": 0
        },
        "left": {
          "type": "number",
          "minimum": 0
        },
        "gutter": {
          "type": "number",
          "minimum": 0
        }
      },
      "additionalProperties": false
    },
    "headerFooterMargins": {
      "type": "object",
      "properties": {
        "header": {
          "type": "number",
          "minimum": 0
        },
        "footer": {
          "type": "number",
          "minimum": 0
        }
      },
      "additionalProperties": false
    },
    "columns": {
      "type": "object",
      "properties": {
        "count": {
          "type": "integer",
          "minimum": 1
        },
        "gap": {
          "type": "number",
          "minimum": 0
        },
        "equalWidth": {
          "type": "boolean"
        }
      },
      "additionalProperties": false
    },
    "lineNumbering": {
      "type": "object",
      "properties": {
        "enabled": {
          "type": "boolean"
        },
        "countBy": {
          "type": "integer",
          "minimum": 1
        },
        "start": {
          "type": "integer",
          "minimum": 1
        },
        "distance": {
          "type": "number",
          "minimum": 0
        },
        "restart": {
          "enum": [
            "continuous",
            "newPage",
            "newSection"
          ]
        }
      },
      "additionalProperties": false,
      "required": [
        "enabled"
      ]
    },
    "pageNumbering": {
      "type": "object",
      "properties": {
        "start": {
          "type": "integer",
          "minimum": 1
        },
        "format": {
          "enum": [
            "decimal",
            "lowerLetter",
            "upperLetter",
            "lowerRoman",
            "upperRoman",
            "numberInDash"
          ]
        },
        "chapterStyle": {
          "type": "integer",
          "minimum": 1
        },
        "chapterSeparator": {
          "type": "string",
          "enum": [
            "hyphen",
            "period",
            "colon",
            "emDash",
            "enDash"
          ]
        }
      },
      "additionalProperties": false
    },
    "titlePage": {
      "type": "boolean"
    },
    "oddEvenHeadersFooters": {
      "type": "boolean"
    },
    "verticalAlign": {
      "enum": [
        "top",
        "center",
        "bottom",
        "both"
      ]
    },
    "sectionDirection": {
      "enum": [
        "ltr",
        "rtl"
      ]
    },
    "headerRefs": {
      "type": "object",
      "properties": {
        "default": {
          "type": "string"
        },
        "first": {
          "type": "string"
        },
        "even": {
          "type": "string"
        }
      },
      "additionalProperties": false
    },
    "footerRefs": {
      "type": "object",
      "properties": {
        "default": {
          "type": "string"
        },
        "first": {
          "type": "string"
        },
        "even": {
          "type": "string"
        }
      },
      "additionalProperties": false
    },
    "pageBorders": {
      "type": "object",
      "properties": {
        "display": {
          "enum": [
            "allPages",
            "firstPage",
            "notFirstPage"
          ]
        },
        "offsetFrom": {
          "enum": [
            "page",
            "text"
          ]
        },
        "zOrder": {
          "enum": [
            "front",
            "back"
          ]
        },
        "top": {
          "type": "object",
          "properties": {
            "style": {
              "type": "string"
            },
            "size": {
              "type": "number",
              "minimum": 0
            },
            "space": {
              "type": "number",
              "minimum": 0
            },
            "color": {
              "type": "string"
            },
            "shadow": {
              "type": "boolean"
            },
            "frame": {
              "type": "boolean"
            }
          },
          "additionalProperties": false,
          "oneOf": [
            {
              "required": [
                "style"
              ]
            },
            {
              "required": [
                "size"
              ]
            },
            {
              "required": [
                "space"
              ]
            },
            {
              "required": [
                "color"
              ]
            },
            {
              "required": [
                "shadow"
              ]
            },
            {
              "required": [
                "frame"
              ]
            }
          ]
        },
        "right": {
          "type": "object",
          "properties": {
            "style": {
              "type": "string"
            },
            "size": {
              "type": "number",
              "minimum": 0
            },
            "space": {
              "type": "number",
              "minimum": 0
            },
            "color": {
              "type": "string"
            },
            "shadow": {
              "type": "boolean"
            },
            "frame": {
              "type": "boolean"
            }
          },
          "additionalProperties": false,
          "oneOf": [
            {
              "required": [
                "style"
              ]
            },
            {
              "required": [
                "size"
              ]
            },
            {
              "required": [
                "space"
              ]
            },
            {
              "required": [
                "color"
              ]
            },
            {
              "required": [
                "shadow"
              ]
            },
            {
              "required": [
                "frame"
              ]
            }
          ]
        },
        "bottom": {
          "type": "object",
          "properties": {
            "style": {
              "type": "string"
            },
            "size": {
              "type": "number",
              "minimum": 0
            },
            "space": {
              "type": "number",
              "minimum": 0
            },
            "color": {
              "type": "string"
            },
            "shadow": {
              "type": "boolean"
            },
            "frame": {
              "type": "boolean"
            }
          },
          "additionalProperties": false,
          "oneOf": [
            {
              "required": [
                "style"
              ]
            },
            {
              "required": [
                "size"
              ]
            },
            {
              "required": [
                "space"
              ]
            },
            {
              "required": [
                "color"
              ]
            },
            {
              "required": [
                "shadow"
              ]
            },
            {
              "required": [
                "frame"
              ]
            }
          ]
        },
        "left": {
          "type": "object",
          "properties": {
            "style": {
              "type": "string"
            },
            "size": {
              "type": "number",
              "minimum": 0
            },
            "space": {
              "type": "number",
              "minimum": 0
            },
            "color": {
              "type": "string"
            },
            "shadow": {
              "type": "boolean"
            },
            "frame": {
              "type": "boolean"
            }
          },
          "additionalProperties": false,
          "oneOf": [
            {
              "required": [
                "style"
              ]
            },
            {
              "required": [
                "size"
              ]
            },
            {
              "required": [
                "space"
              ]
            },
            {
              "required": [
                "color"
              ]
            },
            {
              "required": [
                "shadow"
              ]
            },
            {
              "required": [
                "frame"
              ]
            }
          ]
        }
      },
      "additionalProperties": false,
      "oneOf": [
        {
          "required": [
            "display"
          ]
        },
        {
          "required": [
            "offsetFrom"
          ]
        },
        {
          "required": [
            "zOrder"
          ]
        },
        {
          "required": [
            "top"
          ]
        },
        {
          "required": [
            "right"
          ]
        },
        {
          "required": [
            "bottom"
          ]
        },
        {
          "required": [
            "left"
          ]
        }
      ]
    }
  },
  "additionalProperties": false,
  "required": [
    "address",
    "index",
    "range"
  ]
}
```

## Pre-apply throws

- `TARGET_NOT_FOUND`
- `INVALID_TARGET`
- `INVALID_INPUT`
- `CAPABILITY_UNAVAILABLE`

## Non-applied receipt codes

- None

