> ## Documentation Index
> Fetch the complete documentation index at: https://bunnynet-cb9733c2-support-migration.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Create log forwarding configuration

> Create a new log forwarding configuration.



## OpenAPI

````yaml https://api-mc.opsbunny.net/docs/public/swagger.json post /log/forwarding
openapi: 3.0.4
info:
  title: Public API
  description: 'Public API endpoints for user consumption. Release version: v1.9.36.0'
  version: '1.0'
servers:
  - url: https://api.bunny.net/mc
security:
  - AccessKey: []
paths:
  /log/forwarding:
    post:
      tags:
        - Log Forwarding
      summary: Create log forwarding configuration
      description: Create a new log forwarding configuration.
      operationId: CreateLogForwardingConfiguration
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateLogForwardingRequest'
        required: true
      responses:
        '201':
          description: Log-forwarding configuration created successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/LogForwardingConfiguration'
        '400':
          description: Invalid input.
        '401':
          description: User is unauthorized.
        '500':
          description: Unexpected server error.
components:
  schemas:
    CreateLogForwardingRequest:
      required:
        - app
        - type
        - endpoint
        - port
        - format
        - enabled
      type: object
      properties:
        app:
          type: string
          description: App unique identifier
        type:
          enum:
            - SyslogUdp
            - SyslogTcp
          type: string
          description: Log endpoint type
        endpoint:
          type: string
          description: Log destination endpoint
        port:
          type: integer
          description: Log destination port
        token:
          type: string
          description: Token passed as field of syslog
        format:
          enum:
            - SyslogRfc3164
            - SyslogRfc5424
          type: string
          description: Which Syslog RFC will be used
        enabled:
          type: boolean
          description: Whether forwarding is enabled
    LogForwardingConfiguration:
      type: object
      properties:
        id:
          type: string
          description: Unique identifier
        app:
          type: string
          description: App unique identifier
        productId:
          type: string
          description: Product unique identifier
        type:
          enum:
            - SyslogUdp
            - SyslogTcp
          type: string
          description: Log endpoint type
        endpoint:
          type: string
          description: Log destination endpoint
        port:
          type: integer
          description: Log destination port
        createdAt:
          type: string
          description: When the configuration was created
          format: date-time
        token:
          type: string
          description: Token passed as field of syslog
        format:
          enum:
            - SyslogRfc3164
            - SyslogRfc5424
          type: string
          description: Which Syslog RFC will be used
        enabled:
          type: boolean
          description: Whether forwarding is enabled
  securitySchemes:
    AccessKey:
      type: apiKey
      description: Please enter a valid personal API key.
      name: AccessKey
      in: header

````