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

# Change BGP polling time

> POST /v2/api/change_bgp_polling_time



## OpenAPI

````yaml /openapi/9.0/aviatrix-api.json post /v2/api/change_bgp_polling_time
openapi: 3.1.0
info:
  title: Aviatrix Controller API
  version: '9.0'
  description: >-
    Aviatrix Controller API — version 9.0. Selected operations with Mintlify
    metadata.
servers: []
security: []
tags:
  - name: policies
    x-group: Policies
  - name: authentication
    x-group: Authentication
  - name: account-management
    x-group: Account Management
  - name: rbac
    x-group: RBAC & Permissions
  - name: gateways
    x-group: Gateways
  - name: transit
    x-group: Transit
  - name: nat
    x-group: NAT
  - name: app-domains
    x-group: SmartGroups
  - name: certificates
    x-group: Certificates
  - name: mitm
    x-group: MITM
  - name: monitoring
    x-group: Monitoring & Diagnostics
  - name: fqdn
    x-group: FQDN
  - name: logging
    x-group: Logging
  - name: vpn
    x-group: UserVPN
  - name: site-to-cloud
    x-group: Site-to-Cloud
  - name: controller
    x-group: Controller
  - name: bgp
    x-group: BGP
  - name: general
    x-group: General
  - name: firenet
    x-group: FireNet
  - name: networking
    x-group: Networking
  - name: tgw
    x-group: AWS TGW
  - name: ips
    x-group: IPS
  - name: saml
    x-group: SAML
paths:
  /v2/api/change_bgp_polling_time:
    post:
      tags:
        - bgp
      operationId: change_bgp_polling_time
      requestBody:
        content:
          application/json:
            schema:
              properties:
                CID:
                  $ref: '#/components/schemas/CID'
                accept_communities:
                  description: Accept BGP communities from peers.
                  type: string
                action:
                  $ref: '#/components/schemas/action'
                bgp_hold_time:
                  description: Configure BGP polling time (12-360)sec.
                  type: string
                bgp_local_as_num:
                  description: BGP local AS number.
                  type: string
                bgp_neighbor_status_polling_time:
                  description: Configure BGP neighbor status polling time (1-10)sec.
                  type: integer
                bgp_polling_time:
                  description: Configure BGP route polling time (10-50)sec.
                  type: string
                dampening:
                  description: Enable or disable bgp dampening.
                  enum:
                    - 'false'
                    - 'true'
                  type: string
                gateway_name:
                  description: BGP gateway name.
                  type: string
                mode:
                  description: Enable or disable BGP GW configuration.
                  enum:
                    - disable
                    - enable
                  type: string
                send_communities:
                  description: Send BGP communities to peers.
                  type: string
              required:
                - gateway_name
                - bgp_polling_time
              type: object
        required: true
      responses:
        '200':
          $ref: '#/components/responses/general_response_v2'
        default:
          $ref: '#/components/responses/general_response_v2'
      x-codeSamples:
        - lang: curl
          label: cURL
          source: >-
            curl -sk -X POST
            "https://<controller>/v2/api/change_bgp_polling_time" \
              -H "Authorization: cid <CID>"
        - lang: python
          label: Python
          source: |-
            import requests

            url = "https://<controller>/v2/api/change_bgp_polling_time"
            headers = {"Authorization": "cid <CID>"}

            response = requests.post(url, headers=headers, verify=False)
            print(response.status_code)
            print(response.text)
        - lang: javascript
          label: JavaScript
          source: |-
            fetch("https://<controller>/v2/api/change_bgp_polling_time", {
              method: "POST",
              headers: {"Authorization": "cid <CID>"}
            })
              .then(res => res.text())
              .then(console.log)
              .catch(console.error);
        - lang: go
          label: Go
          source: |-
            package main

            import (
              "fmt"
              "net/http"
            )

            func main() {
              req, _ := http.NewRequest("POST", "https://<controller>/v2/api/change_bgp_polling_time", nil)
              req.Header.Set("Authorization", "cid <CID>")

              client := &http.Client{}
              resp, err := client.Do(req)
              if err != nil {
                panic(err)
              }
              defer resp.Body.Close()

              fmt.Println(resp.Status)
            }
components:
  schemas:
    CID:
      description: The opaque session ID token. Required for 7.2 controllers only.
      type: string
    action:
      description: The API action to perform. Required for 7.2 controllers only.
      type: string
    general_response_v2:
      additionalProperties: true
      description: A generic API response container for v2 style APIs.
      properties:
        errortype:
          description: Error type if the API failed.
          type: string
        reason:
          description: Failure reason if the API failed.
          type: string
        results:
          oneOf:
            - description: API response data
              type: boolean
            - description: API response data
              type: integer
            - description: API response data
              type: string
            - description: API response data
              type: object
            - description: API response data
              items: {}
              type: array
        return:
          description: Whether the API returned successfully
          type: boolean
      title: General Response v2
      type: object
  responses:
    general_response_v2:
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/general_response_v2'
      description: General v2 API response schema.

````