Management Api /api/v2/connections/{id}/status doesn't work

Hello, we are trying to use that endpoint from the management API, but it’s not returning the following response.

{
    "statusCode": 400,
    "error": "Bad Request",
    "message": "Invalid strategy auth0"
}

Using GET /api/v2/connections/{id} with an existing id returns the corresponding connection, but the status doesn’t seem to be working. Could you help me?

Hi @lbarbosa,

I understand you have encountered the “Invalid strategy auth0” error while querying the Management API’s Get a connection endpoint.

To look into this further, could you please provide the details of the request that led to the ‘Invalid strategy auth0’ error?

Thanks,
Rueben

Hi @rueben.tiow,
Yes, of course.
What info do you need?

Hi @lbarbosa,

Thanks for the reply.

Could you share the code snippet you used to request the Management API?

Does your request look something like the following?

curl -L 'https://{{YOUR_DOMAIN}}/api/v2/connections/:id' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer {{MANAGEMENT_API_TOKEN}}

Thanks,
Rueben

Hi!
we are using this:

curl -L 'https://{{YOUR_DOMAIN}}/api/v2/connections/:id/status' \
-H 'Accept: application/json' \
-H 'Authorization: Bearer {{MANAGEMENT_API_TOKEN}}

Hi @lbarbosa,

Thanks for the reply.

It looks like this endpoint you are using is the Management API’s Check connection status endpoint.

This specific endpoint is designed to check the status of an AD/LDAP connection. It seems like you may have tried to use this endpoint with a non-AD/LDAP connection, which resulted in the “Invalid strategy auth0” error.

If you are looking to use this endpoint with regular database connections, it will not be possible. Perhaps you meant to use the Management API’s Get a connection endpoint?

Let me know if you have further questions or if there’s anything else I can help you with.

Thanks,
Rueben

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.