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

# Update Plan Module

> Update a plan module. Superuser only.



## OpenAPI

````yaml https://dev-api.cattix.com/openapi.json put /api/v1/subscriptions/modules/{module_id}
openapi: 3.1.0
info:
  title: CATTIX API
  description: CATTIX Backend API
  version: 0.107.0
servers:
  - url: http://localhost:8000
    description: Local
  - url: https://dev-api.cattix.com
    description: Development
  - url: https://staging-api.cattix.com
    description: Staging
  - url: https://api.cattix.com
    description: Production
security: []
paths:
  /api/v1/subscriptions/modules/{module_id}:
    put:
      tags:
        - Subscriptions
      summary: Update Plan Module
      description: Update a plan module. Superuser only.
      operationId: update_plan_module_api_v1_subscriptions_modules__module_id__put
      parameters:
        - name: module_id
          in: path
          required: true
          schema:
            type: integer
            title: Module Id
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PlanModuleUpdateSchema'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PlanModuleSchema'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - OAuth2PasswordBearer: []
components:
  schemas:
    PlanModuleUpdateSchema:
      properties:
        analysis_type:
          anyOf:
            - $ref: '#/components/schemas/AnalysisTypes'
            - type: 'null'
        constraint:
          anyOf:
            - type: integer
            - type: 'null'
          title: Constraint
        analysis_frequency_hours:
          anyOf:
            - type: integer
            - type: 'null'
          title: Analysis Frequency Hours
        is_autopilot_enabled:
          anyOf:
            - type: boolean
            - type: 'null'
          title: Is Autopilot Enabled
      type: object
      title: PlanModuleUpdateSchema
      description: Schema for updating PlanModule.
    PlanModuleSchema:
      properties:
        analysis_type:
          $ref: '#/components/schemas/AnalysisTypes'
        constraint:
          type: integer
          title: Constraint
        analysis_frequency_hours:
          type: integer
          title: Analysis Frequency Hours
        is_autopilot_enabled:
          type: boolean
          title: Is Autopilot Enabled
          default: false
        id:
          type: integer
          title: Id
        date_added:
          type: string
          format: date-time
          title: Date Added
        date_updated:
          type: string
          format: date-time
          title: Date Updated
      type: object
      required:
        - analysis_type
        - constraint
        - analysis_frequency_hours
        - id
        - date_added
        - date_updated
      title: PlanModuleSchema
      description: Schema for reading PlanModule.
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    AnalysisTypes:
      type: string
      enum:
        - keyword_pause
        - negative_keyword
        - double_check_keywords_to_pause
        - headline
        - description
        - budget_migration
        - pause_hours
        - pause_locations
        - search_terms
      title: AnalysisTypes
      description: The types of analyses.
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
  securitySchemes:
    OAuth2PasswordBearer:
      type: oauth2
      flows:
        password:
          scopes: {}
          tokenUrl: api/v1/users/authorization/token

````