Files
doc-exports/docs/iam/api-ref/en-us_topic_0057845574.html
weihongmin1 46d24ba358 IAM API 0401 Version
Reviewed-by: Belejkanic, Lukas <lukas.belejkanic@t-systems.com>
Co-authored-by: weihongmin1 <weihongmin1@huawei.com>
Co-committed-by: weihongmin1 <weihongmin1@huawei.com>
2026-01-14 14:13:49 +00:00

18 KiB

Querying the List of Domains Accessible to Users

Function

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

URI

GET /v3/auth/domains

Request Parameters

  • Parameters in the request header

    Parameter

    Mandatory

    Type

    Description

    X-Auth-Token

    Yes

    String

    Authenticated token.

  • Example request
    curl -i -k -H 'Accept:application/json' -H 'Content-Type:application/json;charset=utf8' -H "X-Auth-Token:$token" -X GET https://sample.domain.com/v3/auth/domains

Response Parameters

  • Parameters in the response body

    Parameter

    Mandatory

    Type

    Description

    domains

    Yes

    JSONArray

    List of domains.

    links

    Yes

    JSON object

    Domain resource link.

  • domains

    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.

    name

    Yes

    String

    Domain name.

    links

    Yes

    JSON object

    Domain resource link.

    description

    No

    String

    Domain description.

  • domains.links

    Parameter

    Type

    Description

    self

    String

    Resource link.

  • links

    Parameter

    Type

    Description

    self

    String

    Resource link.

  • Example response
    {
        "domains": [{
            "description": "desc of domain",
            "enabled": true,
            "id": "37ef61",
            "links": {
                "self": "https://sample.domain.com/v3/domains/37ef61"
            },
            "name": "my domain"
        }],
        "links": {
            "self": "https://sample.domain.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

Authentication failed.

403

Access denied.

405

The method specified in the request is not allowed for the requested resource.

413

The request entity is too large.

500

Internal server error.

503

Service unavailable.