• Native OpenStack API

noa
  1. Help Center
  2. Native OpenStack API
  3. API Reference
  4. Keystone
  5. Domain
  6. Querying the List of Domains Accessible to Users

Querying the List of Domains Accessible to Users

Function Description

This interface is used to query the list of domains accessible to users.

URI

URI format

GET /v3/auth/domains

Request

  • Request header parameter description

    Parameter

    Mandatory

    Type

    Description

    X-Auth-Token

    Yes

    String

    An authenticated token.

  • Sample request
    curl -i -k -H 'Accept:application/json' -H 'Content-Type:application/json;charset=utf8' -H "X-Auth-Token:$token" -X GET https://172.30.48.86:31943/v3/auth/domains

Response

  • Response body parameter description

    Parameter

    Mandatory

    Type

    Description

    domains

    Yes

    JSONArray

    List of domains.

    links

    Yes

    JSONObject

    Link to a resource.

  • Description for the domain format

    Parameter

    Mandatory

    Type

    Description

    enabled

    Yes

    Boolean

    Whether a domain is enabled. true indicates that the domain is enabled. false indicates that the domain is disabled. The default value is true.

    id

    Yes

    String

    Domain ID.

    enterpriseName

    Yes

    String

    Enterprise domain name.

    name

    Yes

    String

    Domain name.

    links

    Yes

    JSONObject

    Links to a domain resource.

    description

    No

    String

    Domain description.

  • Sample response
    {
        "domains": [{
            "description": "desc of domain",
            "enabled": true,
            "enterpriseName": "hw",
            "id": "37ef61",
            "links": {
                "self": "http://example.com/v3/domains/37ef61"
            },
            "name": "my domain"
        }],
        "links": {
            "self": "http://example.com/v3/auth/domains",
            "previous": null,
            "next": null
        }
    }

Status Codes

Status Code

Description

200

The request is successful.

400

The server failed to process the request.

401

You must enter a username and password to access the requested page.

403

You are forbidden to access the requested page.

405

You are not allowed to use the method specified in the request.

413

The request entity is too large.

500

Failed to complete the request because of an internal service error.

503

Failed to complete the request because the service is unavailable.