---
title: "🔒 Обновление параметров программного модуля."
method: POST
path: "/projects/module/update"
tags: ["Projects: Modules"]
---

# 🔒 Обновление параметров программного модуля.

`POST /projects/module/update`

## Request

- Base URL: `http://localhost`
- URL: `http://localhost/projects/module/update`
- Auth: one of:
  - API key in header `sid` and API key in header `rts` and API key in header `sig`
  - HTTP bearer

Обновление параметров программного модуля.

**Access:** `authorized` (10 ) · **Scope:** `write`

**Allows:** `product:structure` (все обязательны; ресурс — `ID (module)`)

### TypeScript (copy-paste)

**`POST /projects/module/update`**

<details open><summary><b>Params</b></summary>

```typescript
export interface ProjectsModuleUpdateParams {
  ID: string
}
```

</details>

<details open><summary><b>Body (Partial)</b></summary>

```typescript
// Patch-body: все поля опциональны (Valid.Patch)
export type ProjectsModuleUpdateBody = Partial<Module>

export interface ProjectsModuleUpdateBodyFields {
  cID?: string
  projectID?: string
  productID?: string
  parentID?: string | null
  ID?: string
  /** Unix timestamp in milliseconds */
  ord?: number
  title?: string
  desc?: string
  components?: Record<string, any>
  ver?: number
  designID?: string | null
  path?: {
  key: string
  title: string
} | null
  isDeleted?: boolean | null
  /** Unix timestamp in milliseconds */
  deletedTS?: number | null
  /** Unix timestamp in milliseconds */
  updTS?: number
  updUID?: string
}
```

</details>

<details open><summary><b>Response</b></summary>

```typescript
export type ProjectsModuleUpdateResponse = IServerResponse<Module>

export interface IServerResponse<T = any> {
  code: number
  data: T
  srvTS: number
  rkey: string
}
```

</details>

> Полный файл типов: [`/docs/types`](/docs/types) · raw: [`/docs/api-types.ts`](/docs/api-types.ts)

## Query parameters

- `ID` string, uuid, required

## Headers

- `devID` string, uuid, required
- `tz` string, required
- `app` string, required
- `appVer` string, required
- `rKey` string

## Request body

- ProjectsModuleUpdateBody: Partial body (Valid.Patch) for `projects/module/update` — все поля опциональны
  - `cID` string, uuid
  - `projectID` string, uuid
  - `productID` string, uuid
  - `parentID` string, uuid, nullable
  - `ID` string, uuid
  - `ord` integer: Unix timestamp in milliseconds
  - `title` string
  - `desc` string
  - `components` object
  - `ver` integer
  - `designID` string, uuid, nullable
  - `path` object, nullable
    - `key` string, required
    - `title` string, required
  - `isDeleted` boolean, nullable
  - `deletedTS` integer, nullable: Unix timestamp in milliseconds
  - `updTS` integer: Unix timestamp in milliseconds
  - `updUID` string

## Response `200`

OK — `IServerResponse<Module>`

- object
  - `code` integer, required
  - `data` Module, required: Entity `Module` (table: Module )
    - `cID` string, uuid, required
    - `projectID` string, uuid, required
    - `productID` string, uuid, required
    - `parentID` string, uuid, nullable
    - `ID` string, uuid, required
    - `ord` integer, required: Unix timestamp in milliseconds
    - `title` string, required
    - `desc` string, required
    - `components` object, required
    - `ver` integer, required
    - `designID` string, uuid, nullable
    - `path` object, nullable
      - `key` string, required
      - `title` string, required
    - `isDeleted` boolean, nullable
    - `deletedTS` integer, nullable: Unix timestamp in milliseconds
    - `updTS` integer, required: Unix timestamp in milliseconds
    - `updUID` string, required
  - `srvTS` integer, required: Server timestamp (ms)
  - `rkey` string, required: Request key

## Other responses

- `400`: BadRequest / Validation — неверные params/body/headers
- `401`: Unauthorized: Active user session required
- `403`: AccessNotAllowed: Privilege product:structure required
- `404`: NotFound: Module with specified ID does not exist
- `406`: TimeResync — расхождение rts с сервером

---

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