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

# Pin

> Executes api/v1/accounts/chat_room_messages#pin.



## OpenAPI

````yaml /openapi/application.json post /api/v1/accounts/{account_id}/chat_rooms/{chat_room_id}/messages/{id}/pin
openapi: 3.1.0
info:
  title: WiseApp API — Aplicação
  description: >-
    Referência completa da API do WiseApp: plataforma (provisionamento),
    aplicação (conta), cliente (canais públicos) e MCP.
  version: 1.1.0
servers:
  - url: https://chat.wiseapp360.com
    description: Sua instalação WiseApp
security: []
paths:
  /api/v1/accounts/{account_id}/chat_rooms/{chat_room_id}/messages/{id}/pin:
    parameters:
      - name: account_id
        in: path
        required: true
        schema:
          type: integer
        example: 1
      - name: chat_room_id
        in: path
        required: true
        schema:
          type: integer
        example: 1
      - name: id
        in: path
        required: true
        schema:
          type: integer
        example: 1
    post:
      tags:
        - Account
      summary: Pin
      description: Executes api/v1/accounts/chat_room_messages#pin.
      operationId: post-api-v1-accounts-account-id-chat-rooms-chat-room-id-messages-id-pin
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                duration:
                  type: string
                  enum:
                    - 24_hours
                    - 7_days
                    - 30_days
                  default: 7_days
            example:
              duration: 24_hours
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/chat_room_message'
              example:
                id: 1
                content: Sample text
                message_type: 1
                content_type: Sample text
                status: open
                created_at: 1
                chat_room_id: 1
                echo_id: 1
                updated_at: 1
                conversation_id: 1
                room_name: Sample resource
                sender:
                  source: api
                  segment: enterprise
        '401':
          description: Unauthorized.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
              example:
                error: Unauthorized
        '404':
          description: Resource not found.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
              example:
                error: Resource not found
        '422':
          description: Invalid request or resource state.
          content:
            application/json:
              schema:
                type: object
                properties:
                  message:
                    type: string
                  attributes:
                    type: array
                    items:
                      type: string
              example:
                message: Validation failed
                attributes:
                  - name cannot be blank
      security:
        - userApiKey: []
components:
  schemas:
    chat_room_message:
      type: object
      required:
        - id
        - content
        - message_type
        - content_type
        - status
        - created_at
        - chat_room_id
      properties:
        id:
          type: integer
        echo_id:
          type:
            - string
            - 'null'
        content:
          type:
            - string
            - 'null'
        message_type:
          type: integer
        content_type:
          type: string
        status:
          type: string
        created_at:
          type: integer
        updated_at:
          type: integer
        conversation_id:
          type:
            - integer
            - 'null'
        chat_room_id:
          type: integer
        room_name:
          type: string
        sender:
          type:
            - object
            - 'null'
        attachments:
          type: array
          items:
            type: object
        content_attributes:
          type: object
        parent_id:
          type:
            - integer
            - 'null'
        replies_count:
          type: integer
        deleted:
          type: boolean
        edited:
          type: boolean
        pinned:
          type: boolean
  securitySchemes:
    userApiKey:
      type: apiKey
      in: header
      name: api_access_token
      description: >-
        Token de acesso do usuário (Perfil → Token de acesso). Dá acesso
        conforme o papel do usuário e age em nome dele.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.