Get User Domain

Get the domain information of a user using the email address.

Operation Permissions

User login to Application Portal is not required.

Request Format

GET http://{apigw-address}/app-portal-service/v2.2/user/domain

Request Parameters (URI)

Name

Location (Path/Query)

Mandatory/Optional

Data Type

Description

email

Query

Mandatory

String

The email address of the user.

Response Parameters

Name

Data Type

Description

id

String

The domain ID.

name

String

The domain name.

url

String

The domain URL.

description

String

The description of the domain.

Error Code

Code

Description

31400

The user email address is required.

Samples

Request Sample

url: http://{apigw-address}/app-portal-service/v2.2/user/domain?email=xxx.yy@envision-digital.com
method: GET

Return Sample

{
    "code":0,
    "data":{
        "id":"xxx",
        "name":"domain name",
        "url":"domain url",
        "description":"domain description"
    },
    "message":""
}

Java SDK Sample

public class AppPortalSdkTest{
    @Test
    public void getUserDomainTest() {
        UserDomainRequest request=new UserDomainRequest("xxx@domain.com");
        UserDomainResponse response=Poseidon.config(PConfig.init().appKey("your_access_key").appSecret("your_secret_key").debug())
                .url("https://{apigw-address}").getResponse(request,UserDomainResponse.class);
        assertNotNull("response data should not be null", response.data);
    }
}