Get Public Link
get
/documents/api/1.2/publiclinks/{linkId}
Return information about a specific public link.
Request
Supported Media Types
- application/json
- application/xml
Path Parameters
-
linkId: string
Globally unique identifier (GUID) for the public link.
Response
Supported Media Types
- application/json
- application/xml
200 Response
The request was fulfilled.
Root Schema : PublicLinkGetResponse
Type:
object
The response body includes information about the public link.
Show Source
-
errorCode(optional):
string
An error code of zero (0) indicates no errors.
Match All
Show Source
-
object
PublicLinkDefinition
Public link information.
Nested Schema : PublicLinkDefinition
Type:
object
Public link information.
Show Source
-
assignedUsers(optional):
string
The group of users who can use the link.
-
createdTime(optional):
string
Date and time when the public link was created.
-
expirationTime(optional):
string
Date and time when the public link expires.
-
lastModifiedTime(optional):
string
Date and time when the public link was last modified.
-
linkID(optional):
string
Globally unique identifier (GUID) for the public link.
-
linkName(optional):
string
Name of the public link.
-
ownedBy(optional):
object User
User information
-
password(optional):
string
Password for the public link. Use a minimum of 8 characters and a maximum of 50 characters. Passwords are case-sensitive.
-
role(optional):
string
Allowed Values:
[ "viewer", "downloader", "contributor" ]
Access level for the shared item. -
type(optional):
string
Item type
publiclink
.
Nested Schema : User
Type:
object
User information
Show Source
-
displayName(optional):
string
The display name for the user.
-
id(optional):
string
Globally unique identifier (GUID) for the user.
-
loginName(optional):
string
The login name for the user.
-
type(optional):
string
Item type
user
.
Example Response (application/json)
{
"linkID":"LF906748A021ACD714CABC82T0000000000100000001",
"linkName":"MyLinkOne",
"assignedUsers":"@everybody",
"role":"contributor",
"type":"publiclink",
"createdTime":"2015-06-10T16:01:44Z",
"expirationTime":"2016-01-01T00:00:01Z",
"lastModifiedTime":"2015-06-10T16:01:44Z",
"ownedBy":{
"id":"U0EAA20910FAF3052ACB79E4T00000000001",
"displayName":"User AA",
"type":"user"
},
"errorCode":"0"
}
400 Response
Request parameters are not formatted correctly.
403 Response
Forbidden if the user does not have read permission.
404 Response
Link ID is not found.
Examples
The following example returns information about the specified public link.
GET .../publiclinks/LF906748A021ACD714CABC82T0000000000100000001
Request Header
None.
Request Body
None.
HTTP Status Code
HTTP_STATUS = 200
JSON Response
{ "assignedUsers": "@everybody", "createdTime": "2015-06-10T16:01:44Z", "errorCode": "0", "expirationTime": "2016-01-01T00:00:01Z", "lastModifiedTime": "2015-06-10T16:01:44Z", "linkID": "LF906748A021ACD714CABC82T0000000000100000001", "linkName": "MyLinkOne", "ownedBy": { "displayName": "User AA", "loginName": "userAALoginName", "id": "U0EAA20910FAF3052ACB79E4T00000000001", "type": "user" }, "role": "contributor", "type": "publiclink" }
Example 2
The following example returns an error because the link ID is invalid.
GET .../publiclinks/LFE36701FF7D3371DCD7F9E245B3E9DD64907CA0D19F
Request Header
None.
Request Body
None.
HTTP Status Code
HTTP_STATUS = 404
JSON Response
{ "errorCode": "-16", "errorKey": "!csUnableToRetrieveSharedLinkInfo!csUnableToFindLink", "errorMessage": "Failed to retrieve shared link information. Unable to find the specified shared link.", "errorType": "publiclink", "linkID": "LFE36701FF7D3371DCD7F9E245B3E9DD64907CA0D19F", "title": "Failed to retrieve shared link information. Unable to find the specified shared link.", "type": "https://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html" }