Cisco DNA Center API documentation
1 Documentation Source
These notes are taken straight out of developer.cisco.com
2 DNA Center Northbound-Southbound API
3 Authentication
API to obtain an access token. The token obtained using this API is required to be set as value to the X-Auth-Token HTTP Header for all API calls to Cisco DNA Center.
3.1 URI
POST /dna/system/api/v1/auth/token
3.2 Parameters
Name | Description | Default value |
---|---|---|
Content-Type | Request body content type | application/json |
string (header) | ||
Authorization | Basic Auth Base64 | |
string | ||
Response Codes | ||
200 | Successfull Token Generation | |
401 | Invalid credentials |
Content-Type * string (header) Request body content type Default value : application/json
Authorization * string (header) Basic Auth Base64 encoding of :
Default value :
4 Example of the rich API
These docs are specific to a given release. Always check the release. Here is the link for version 1.3.3.x
5 Run it
The pyATS docker container defaults to starting in an interactive Python shell
$docker run -it ciscotestautomation/pyats:latest
But if you want to start in an interactive bash shell run:
$docker run -it ciscotestautomation/pyats:latest /bin/bash
5.1 Exiting the container with C-D or C-d ?
5.2 Good examples built in:
$ docker run -it ciscotestautomation/pyats:latest /bin/bash [Entrypoint] Starting pyATS Docker Image ... [Entrypoint] Workspace Directory: /pyats [Entrypoint] Activating workspace root@0c832ac21322:/pyats# easypy examples/basic/job/basic_example_job.py
6 Customizing the PyATS container
Again, this is straight out of the online documentation on hub.docker.com