milvus-logo
LFAI
< Docs
  • RESTful

List Roles

POST
http://${MILVUS_URI}/v2/vectordb/roles/list

This operation lists the information about all existing roles.

Example

export MILVUS_URI="localhost:19530"

curl --location --request POST "http://${MILVUS_URI}/v2/vectordb/roles/list" \
--header "Content-Type: application/json" \
--data-raw '{}'

Possible response is similar to the following .

{
    "code": 200,
    "data": [
        "admin",
        "public"
    ]
}

Request

Parameters

  • Header parameters

    ParameterDescription
    Request-Timeoutinteger
    The timeout duration for this operation.
    Setting this to None indicates that this operation timeouts when any response arrives or any error occurs.
    Authorizationstring(required)
    The authentication token.
  • No query parameters required

  • No path parameters required

Request Body

{}
ParameterDescription

Response

A RoleInfo object that contains a list of RoleItem objects.

Response Bodies

  • Response body if we process your request successfully
{
    "code": "integer",
    "data": [
        {}
    ]
}
  • Response body if we failed to process your request
{
    "code": integer,
    "message": string
}

Properties

The properties in the returned response are listed in the following table.

PropertyDescription
codeinteger
Indicates whether the request succeeds.
  • 200: The request succeeds.
  • Others: Some error occurs.
dataarray
data[]string
A list of item objects.
messagestring
Indicates the possible reason for the reported error.
Feedback

Was this page helpful?