Implementing Automation for Cisco Security Solutions (SAUTO) — Question 27
Which curl command lists all tags (host groups) that are associated with a tenant using the Cisco Stealthwatch Enterprise API?
Answer options
- A. curl -X PUT"Cookie:{Cookie Data}"https://{stealthwatch_host}/smc-configuration/rest/v1/tenants/{tenant_id}/tags
- B. curl -X POST -H"Cookie:{Cookie Data}"https://{stealthwatch_host}/smc-configuration/rest/v1/tenants/tags
- C. curl -X GET -H"Cookie:{Cookie Data}"https://{stealthwatch_host}/smc-configuration/rest/v1/tenants/{tenant_id}/tags
- D. curl -X GET -H"Cookie:{Cookie Data}"https://{stealthwatch_host}/smc-configuration/rest/v1/tenants/tags
Correct answer: C
Explanation
The correct answer is C because it uses the GET method, which is appropriate for retrieving information, specifically tags associated with a tenant. Options A and B use incorrect HTTP methods (PUT and POST, respectively) that are not suitable for listing resources, and option D lacks the tenant_id in the URL, which is necessary to specify which tenant's tags are being requested.