Retrieve the Metadata for a Single File or Folder
Applies To: Windows Server 2012 Essentials
Retrieves the basic metadata of a single item.
URI Template
GET services/builtin/FileOperationService.svc/itemmetadata?path={path}
{path}
A network path that begins with the server name, in the format /ServerName/FolderPath[/FileName].
Sample Request
GET https://www.contoso.com/services/builtin/FileOperationService.svc/itemmetadata?path=servername/Users HTTP/1.1
Accept: application/xml
Cookie: ASP.NET_SessionId=********************
Canary: *********************
Host: domainname
Sample Response
HTTP/1.1 200 OK
Cache-Control: private
Content-Length: 387
Content-Type: application/xml; charset=utf-8
Server: Microsoft-IIS/8.0
Set-Cookie: ASP.NET_SessionId=wnrm1yhkcg1nc42a31ntua4o; path=/; HttpOnly
X-AspNet-Version: 4.0.30319
Set-Cookie: UserToken=b157ea4f-ad7e-d96a-df9c-b438bd8e6fc3; path=/
X-Powered-By: ASP.NET
X-Content-Type-Options: nosniff
Date: Wed, 19 Oct 2011 06:33:15 GMT
<ItemInfo
xmlns="http://contracts.microsoft.com/WindowsServerEssentials/2011/09/WebApi"
xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
<AccessPermission>2</AccessPermission>
<CreateTime>2011-10-12T23:24:15.2808966-07:00</CreateTime>
<IsDirectory>true</IsDirectory>
<ModifiedTime>2011-10-18T01:12:36.9315201-07:00</ModifiedTime>
<Name>Users</Name>
<Path>\\SERVERNAME</Path>
<Size>0</Size>
</ItemInfo>
Error Codes
Error Code | Error Message |
---|---|
400 | One or more parameters are not valid. |
401 | Access is denied to the requested resource. |
404 | The path does not exist. |
Remarks
The AccessPermission
element in the response can contain one of the following enumeration values:
Enumeration Value Name | Value | Meaning |
---|---|---|
None |
0 | No access. |
ReadOnly |
1 | Read-only access. |
Full |
2 | Read/write access. |
Other |
3 | Unknown or unspecified access. |