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

# Create action



## OpenAPI

````yaml /openapi/orders.json post /v1/crm/requests/{request_id}/action/
openapi: 3.0.3
info:
  title: Yume API — Аренда
  version: 1.0.0
  description: Управление арендой, заявками и заказами.
servers:
  - url: https://api.yume.cloud
    description: Production
  - url: https://api.stage.yume.cloud
    description: Stage
security: []
paths:
  /v1/crm/requests/{request_id}/action/:
    post:
      tags:
        - action
      summary: Create action
      operationId: action_create
      parameters:
        - in: path
          name: request_id
          schema:
            type: integer
          required: true
        - $ref: '#/components/parameters/TenantId'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/OrderAction'
          application/x-www-form-urlencoded:
            schema:
              $ref: '#/components/schemas/OrderAction'
          multipart/form-data:
            schema:
              $ref: '#/components/schemas/OrderAction'
        required: true
      responses:
        '201':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OrderAction'
          description: ''
      security:
        - jwtAuth: []
components:
  parameters:
    TenantId:
      name: X-Tenant-Id
      in: header
      required: false
      schema:
        type: integer
      description: >-
        Компания, в контексте которой выполняется запрос — её id из `GET
        /v1/tenant/`. Пользователь должен состоять в этой компании: чужой id
        доступа к данным не даёт. Без заголовка компания определяется по домену
        запроса.
  schemas:
    OrderAction:
      type: object
      properties:
        order_inventories:
          type: array
          items:
            type: integer
        status:
          $ref: '#/components/schemas/Status3e1Enum'
        action:
          $ref: '#/components/schemas/ActionEnum'
        datetime:
          type: string
          format: date-time
          nullable: true
        actions:
          type: array
          items:
            $ref: '#/components/schemas/OrderRequestAction'
          readOnly: true
      required:
        - actions
        - status
    Status3e1Enum:
      enum:
        - 0
        - 1
        - 2
        - 3
        - 4
        - 5
        - 6
      type: integer
      description: |-
        * `0` - Запрос
        * `1` - Забронировано
        * `2` - В аренде
        * `3` - Отменено
        * `4` - Завершено
        * `5` - Должник
        * `6` - Просрочка
    ActionEnum:
      enum:
        - 0
        - 1
        - 2
        - 3
        - 4
        - 5
        - 6
        - 7
        - 8
      type: integer
      description: |-
        * `0` - Бронь
        * `1` - Выдача
        * `2` - Приём
        * `3` - Отмена
        * `4` - Архив
        * `5` - Сборка
        * `6` - Создание
        * `7` - Забор доставки
        * `8` - Выдача доставки
    OrderRequestAction:
      type: object
      properties:
        id:
          type: integer
          readOnly: true
        user:
          type: integer
        created_at:
          type: string
          format: date-time
          readOnly: true
          title: Создан
        type:
          allOf:
            - $ref: '#/components/schemas/TypeFb2Enum'
          minimum: -32768
          maximum: 32767
        inventories:
          type: array
          items:
            type: integer
          readOnly: true
      required:
        - created_at
        - id
        - inventories
        - type
        - user
    TypeFb2Enum:
      enum:
        - 0
        - 1
        - 2
        - 3
        - 4
        - 5
        - 6
        - 7
        - 8
      type: integer
      description: |-
        * `0` - Бронь
        * `1` - Выдача
        * `2` - Приём
        * `3` - Отмена
        * `4` - Архив
        * `5` - Сборка
        * `6` - Создание
        * `7` - Забор доставки
        * `8` - Выдача доставки
  securitySchemes:
    jwtAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT

````