Queries the information of a folder.

In this example, the information of the folder fd-Jyl5U7**** is queried.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes GetFolder

The operation that you want to perform. Set the value to GetFolder.

FolderId String Yes fd-Jyl5U7****

The ID of the folder.

For more information about common request parameters, see Common parameters.

Response parameters

Parameter Type Example Description
RequestId String C2CBCA30-C8DD-423E-B4AD-4FB694C9180C

The ID of the request.

Folder Object

The information of the folder.

FolderId String fd-Jyl5U7****

The ID of the folder.

CreateTime String 2021-06-15T06:39:08.521Z

The time when the folder was created.

ParentFolderId String r-Wm****

The ID of the parent folder.

FolderName String Applications

The name of the folder.

ResourceDirectoryPath String rd-3G****/r-Wm****/fd-Jyl5U7****

The path of the folder in the resource directory.

Examples

Sample requests

https://resourcemanager.aliyuncs.com/?Action=GetFolder
&FolderId=fd-Jyl5U7****
&<Common request parameters>

Sample success responses

XML format

HTTP/1.1 200 OK
Content-Type:application/xml

<?xml version="1.0" encoding="UTF-8" ?>
<GetFolderResponse>
    <RequestId>88EF473E-D5CD-589F-AAB3-F6E0D12AECA3</RequestId>
    <Folder>
        <CreateTime>2021-06-15T06:39:08.521Z</CreateTime>
        <FolderId>fd-Jyl5U7****</FolderId>
        <FolderName>Applications</FolderName>
        <ParentFolderId>r-Wm****</ParentFolderId>
        <ResourceDirectoryPath>rd-3G****/r-Wm****/fd-Jyl5U7****</ResourceDirectoryPath>
    </Folder>
</GetFolderResponse>

JSON format

HTTP/1.1 200 OK
Content-Type:application/json

{
  "RequestId" : "88EF473E-D5CD-589F-AAB3-F6E0D12AECA3",
  "Folder" : {
    "CreateTime" : "2021-06-15T06:39:08.521Z",
    "FolderId" : "fd-Jyl5U7****",
    "FolderName" : "Applications",
    "ParentFolderId" : "r-Wm****",
    "ResourceDirectoryPath" : "rd-3G****/r-Wm****/fd-Jyl5U7****"
  }
}

Error codes

HTTP status code Error code Error message Description
400 MissingParameter.FolderId You must specify FolderId. The error message returned because the FolderId parameter is not configured. Configure this parameter.
400 InvalidParameter.FolderId The FolderId is invalid. The error message returned because the value of the FolderId parameter is invalid. Specify a value that starts with r- followed by 6 characters or starts with fd- followed by 10 characters. Valid characters are letters and digits.
404 EntityNotExists.ResourceDirectory The resource directory for the account is not enabled. We recommend that you first enable the resource directory for the account. The error message returned because the resource directory for the account is not enabled. Enable the resource directory for the account.
404 EntityNotExists.Folder The resource directory folder does not exist. The error message returned because the folder does not exist. Create such a folder first.

For a list of error codes, visit the API Error Center.