APIC Web Agent (apic-cli)
One of the best feature of APIC is the option to use the API designer & tester right from your web browser. But using the web version of APIC has one limitation, CORS. By default all web browsers block API requests made to other hosts unless they specify an
Access-Control-Allow-Originheader that allows APIC to use the API.
Once the agent is up successfully you should see below message on the terminal window
APIC web agent for CORS
Once you have opened APIC web app on your browser you should see below highlight icon in the header. Clicking on the Agent icon should connect to the agent that you started earlier via apic-cli. Now all the API requests you make from APIC will be forwarded to the Agent and once completed the response will be served in APIC. The experience is seamless as if the request was made by the browser itself.
By default the web app tries to connect to the agent on port 8008. If you can started the agent on a different port then yo need to configure the same in the web application.
To do so open the settings from the header and navigate to APIC Web Agent tab. Here you can configure the port to connect to along with the default request timeout interval.