cisco.dnac.device_credential (2.0.7) — module

Manage DeviceCredential objects of NetworkSettings

| "added in version" 1.0.0 of cisco.dnac"

Authors: Rafael Campos (@racampos)

This plugin has a corresponding action plugin.

Install collection

Install with ansible-galaxy collection install cisco.dnac:==2.0.7


Add to requirements.yml

  collections:
    - name: cisco.dnac
      version: 2.0.7

Description

API to get device credential details.

API to create device credentials.

API to update device credentials.

Delete device credential.


Requirements

Usage examples

  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: get_device_credential_details
  cisco.dnac.device_credential:
    state: query  # required
    site_id: SomeValue  # string
  register: nm_get_device_credential_details
  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: create_device_credentials
  cisco.dnac.device_credential:
    state: create  # required
    settings:  # required
      cliCredential:
      - description: SomeValue  # string, required
        username: SomeValue  # string, required
        password: SomeValue  # string, required
        enablePassword: SomeValue  # string
      snmpV2cRead:
      - readCommunity: SomeValue  # string, required
        description: SomeValue  # string
      snmpV2cWrite:
      - writeCommunity: SomeValue  # string, required
        description: SomeValue  # string
      snmpV3:
      - description: SomeValue  # string, required
        username: SomeValue  # string, required
        privacyType: SomeValue  # string, required
        privacyPassword: SomeValue  # string, required
        authType: SomeValue  # string, required
        snmpMode: SomeValue  # string, required
        authPassword: SomeValue  # string
      httpsRead:
      - username: SomeValue  # string, required
        password: SomeValue  # string, required
        name: SomeValue  # string
        port: 1  #  number
      httpsWrite:
      - username: SomeValue  # string, required
        password: SomeValue  # string, required
        name: SomeValue  # string
        port: 1  #  number
  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: update_device_credentials
  cisco.dnac.device_credential:
    state: update  # required
    settings:  # required
      cliCredential:
        description: SomeValue  # string
        username: SomeValue  # string
        password: SomeValue  # string
        enablePassword: SomeValue  # string
        id: SomeValue  # string
      snmpV2cRead:
        description: SomeValue  # string
        readCommunity: SomeValue  # string
        id: SomeValue  # string
      snmpV2cWrite:
        description: SomeValue  # string
        writeCommunity: SomeValue  # string
        id: SomeValue  # string
      snmpV3:
        authPassword: SomeValue  # string
        authType: SomeValue  # string
        snmpMode: SomeValue  # string
        privacyPassword: SomeValue  # string
        privacyType: SomeValue  # string
        username: SomeValue  # string
        description: SomeValue  # string
        id: SomeValue  # string
      httpsRead:
        name: SomeValue  # string
        username: SomeValue  # string
        password: SomeValue  # string
        port: SomeValue  # string
        id: SomeValue  # string
      httpsWrite:
        name: SomeValue  # string
        username: SomeValue  # string
        password: SomeValue  # string
        port: SomeValue  # string
        id: SomeValue  # string
  • Success
    Steampunk Spotter scan finished with no errors, warnings or hints.
- name: delete_device_credential
  cisco.dnac.device_credential:
    state: delete  # required
    id: SomeValue  # string, required

Inputs

    
id:
    description:
    - Global credential id.
    - Required for state delete.
    type: str

site_id:
    description:
    - Site id to retrieve the credential details associated with the site.
    type: str

settings:
    description:
    - Settings, property of the request body.
    required: true
    suboptions:
      cliCredential:
        description:
        - It is the device credential's cliCredential.
        - Type list for state create.
        - Type dict for state update.
        type: raw
      httpsRead:
        description:
        - It is the device credential's httpsRead.
        - Type list for state create.
        - Type dict for state update.
        type: raw
      httpsWrite:
        description:
        - It is the device credential's httpsWrite.
        - Type list for state create.
        - Type dict for state update.
        type: raw
      snmpV2cRead:
        description:
        - It is the device credential's snmpV2cRead.
        - Type list for state create.
        - Type dict for state update.
        type: raw
      snmpV2cWrite:
        description:
        - It is the device credential's snmpV2cWrite.
        - Type list for state create.
        - Type dict for state update.
        type: raw
      snmpV3:
        description:
        - It is the device credential's snmpV3.
        - Type list for state create.
        - Type dict for state update.
        type: raw
    type: dict

Outputs

dnac_response:
  description: A dictionary with the response returned by the DNA Center Python SDK
  returned: always
  sample:
    response: 29
    version: '1.0'
  type: dict
missing_params:
  description: Provided arguments do not comply with the schema of the DNA Center
    Python SDK function
  returned: when the function request schema is not satisfied
  sample: null
  type: list
sdk_function:
  description: The DNA Center SDK function used to execute the task
  returned: always
  sample: network_settings.create_device_credentials
  type: str

See also