> ## Documentation Index
> Fetch the complete documentation index at: https://docs.stateset.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Close a month

> Close a month

### Request body

`CloseMonthRequest`

<ParamField body="closed_by" type="string,null">
  Actor recorded as the closer. Defaults to `api`.
</ParamField>

<ParamField body="dry_run" type="boolean,null">
  Compute counts/amounts per step without writing anything.
</ParamField>

<ParamField body="period_id" type="string" required>
  Accounting period to close.
</ParamField>

<ParamField body="skip_depreciation" type="boolean,null">
  Skip posting scheduled fixed-asset depreciation.
</ParamField>

<ParamField body="skip_fx_revaluation" type="boolean,null">
  Skip FX revaluation of foreign-currency accounts.
</ParamField>

<ParamField body="skip_period_close" type="boolean,null">
  Skip the final period close (closing entries + close period).
</ParamField>

<ParamField body="skip_revenue_recognition" type="boolean,null">
  Skip recognizing deferred revenue through period end.
</ParamField>

### Responses

<ResponseField name="200" type="CloseMonthResponse" />

<ResponseField name="400" type="ErrorBody" />

<ResponseField name="404" type="ErrorBody" />

<ResponseField name="422" type="ErrorBody" />

<RequestExample>
  ```bash cURL theme={null}
  curl --request POST \
    --url 'https://api.stateset.com/api/v1/gl/close-month' \
    --header 'Authorization: Bearer YOUR_API_KEY' \
    --header 'Content-Type: application/json' \
    --data '{
    "closed_by": null,
    "dry_run": null,
    "period_id": "string",
    "skip_depreciation": null,
    "skip_fx_revaluation": null,
    "skip_period_close": null,
    "skip_revenue_recognition": null
  }'
  ```
</RequestExample>

<ResponseExample>
  ```json 200 theme={null}
  {
    "closing_entry": null,
    "depreciation": {
      "entry_count": 1,
      "status": "string",
      "total_amount": "string",
      "warnings": [
        "string"
      ]
    },
    "dry_run": true,
    "fx_revaluation": {
      "entry_count": 1,
      "status": "string",
      "total_amount": "string",
      "warnings": [
        "string"
      ]
    },
    "period_close": {
      "entry_count": 1,
      "status": "string",
      "total_amount": "string",
      "warnings": [
        "string"
      ]
    },
    "period_id": "string",
    "period_name": "string",
    "period_status": "string",
    "revenue_recognition": {
      "entry_count": 1,
      "status": "string",
      "total_amount": "string",
      "warnings": [
        "string"
      ]
    }
  }
  ```
</ResponseExample>
