02-13-2025 07:13 AM
I am using the Cisco FMC Sandbox API Explorer on the Always-On Sandbox (Sandbox URL), but I am experiencing issues when querying device records and checking task statuses.
GET {{protocol}}://{{hostname}}/api/fmc_config/v1/domain/{{domain_id}}/job/taskstatuses/{{device_registration_task_id}}
Response:
{ "error": { "category": "FRAMEWORK", "messages": [ { "description": "The user is not authorized" } ], "severity": "ERROR" } }
GET {{protocol}}://{{hostname}}/api/fmc_config/v1/domain/{{domain_id}}/devices/devicerecords?expanded=True
Response:
{ "links": {}, "paging": { "offset": 0, "limit": 0, "count": 0, "pages": 0 } }
Why am I getting an "Unauthorized" error when checking task statuses?
Why are no devices appearing when querying devices/devicerecords?
Any guidance on troubleshooting this would be greatly appreciated. Thanks in advance!
02-13-2025 08:00 AM - edited 02-13-2025 08:09 AM
@mdusman did you generate a token? https://<management_center_IP_or_name>/api/fmc_platform/v1/auth/generatetoken
.
02-13-2025 08:32 AM
Hi @bigevilbeard , thanks for the response.
Yes I have. Getting Access Policies worked fine but Other than Devices returns empty and registration status task endpoint also giving User not authorized issue.
02-13-2025 08:37 AM - edited 02-13-2025 08:38 AM
@mdusman just tested also, reply back is the same, i tried to get the tasks also.... as well as your first call same error as below.
python fmc_task_lists.py
Authentication successful! Access token and domain UUID retrieved.
Access Token: 45b2df3e-6457-4061-880a-5df948338c04
Domain UUID: e276abec-e0f2-11e3-8169-6d9ed49b625f
Failed to retrieve tasks. Status code: 403
{"error":{"category":"FRAMEWORK","messages":[{"description":"The user is not authorized"}],"severity":"ERROR"}}
Getting the devices
✦ ❯ python fmc_devices.py
Authentication successful! Access token and domain UUID retrieved.
Access Token: f0dd0eb7-f2e8-4248-851b-4c700dba92c0
Domain UUID: e276abec-e0f2-11e3-8169-6d9ed49b625f
Device records retrieved successfully!
{'links': {}, 'paging': {'offset': 0, 'limit': 0, 'count': 0, 'pages': 0}}
I saw a pop up in the UI which said 'no devices attached' i cannot recall how i saw this tho, it flashed up. Guess team will need to advise here.
02-13-2025 08:54 AM
Did you try Devices endpoint on Sandbox environment?
02-13-2025 08:56 AM
@mdusman Checking Device Registration Status? Yes same error as you.
02-13-2025 09:03 AM
Thanks for the feedback @bigevilbeard , can I contact support for this?
02-14-2025 01:58 AM
@mdusman the Devnet team monitor this space, it’s Cisco Live this week so they might be busy keeping the lights on for the sandbox there. I’m sure they will pick this up
02-15-2025 07:30 AM
Okay, Thanks for the response. Have a good weekend
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide