Tuyu Developers

Developers

Customize the URLs on this site with your Tuyu URL:

https:// .
Method Documentation > Users and Workspaces

Workspace Info GET

Method Type

GET

Description

Retrieves all relevant info on a workspace.

URL

All responses are in JSON format by default, to specify an XML response add “.xml” to the end of the method name (in this case “workspace_info”)

https://<your subdomain>.<your domain>/api/workspace_info

Restrictions

The calling user must have:

  • Admin privileges for the site.

Parameters

Bold indicates required. Please note parameters must be appended to the URL in alphabetical order, except for “signature”, which is always at the end.

Parameter Description
api_key Your API Key.
timestamp The current time in Unix timestamp format.
workspace_id The ID of the workspace.
signature Please see “User Authentication” for more information.

Sample Response

Successful response In JSON:

{"workspaceInfo":
{
    "id":1,
    "name":"Workspace 1",
    "path":"/Workspace_1_workspace/",
    "created":"04/07/15 at 09:05 am EDT",
    "modified":"05/27/15 at 09:26 am EDT"
    "users": [
        {'user': {
            'id': 1, 
            'firstName': 'John',
            'lastName': 'Doe',
            'email': 'johndoe@acme.com',
            'username': 'johndoe',
            'subadmin': 0
        }},
        {'user': {
            'id': 1, 
            'firstName': 'Jane',
            'lastName': 'Doe',
            'email': 'janedoe@acme.com',
            'username': 'janedoe',
            'subadmin': 0
        }}
    ],
    "workspaceOverridePermissions": {
        "uploadFiles": 1,
        "batchUploadFiles": 1,
        "sendFiles": 1,
        "sendFilesNonUser": 0,
        "downloadFiles": 1,
        "batchDownloadFiles": 0,
        "moveCopyFiles": 0,
        "batchMoveCopyFiles": 0,
        "renameFiles": 1,
        "deleteFiles": 0,
        "batchDeleteFiles": 0,
        "createFolders": 1,
    },
    "workspaceOverrideNotifications": {
        "uploadNotifications": 1,
        "downloadNotifications": 0
    }
}
}

Successful response in XML:

<workspaceInfo>
    <id>1</id>
    <name>Workspace 1</name>
    <path>/Workspace_1_workspace/</path>
    <created>04/07/15 at 09:05 am EDT</created>
    <modified>05/27/15 at 09:26 am EDT</modified>
    <users>
        <user>
            <id>1</id>
            <firstName>John</firstName>
            <lastName>Doe</lastName>
            <email>johndoe@acme.com</email>
            <username>johndoe</username>
            <subadmin>0</subadmin>
        </user>
        <user>
            <id>2</id>
            <firstName>Jane</firstName>
            <lastName>Doe</lastName>
            <email>janedoe@acme.com</email>
            <username>janedoe</username>
            <subadmin>0</subadmin>
        </user>
    </users>
    <workspaceOverridePermissions>
        <uploadFiles>1</uploadFiles>
        <batchUploadFiles>1</batchUploadFiles>
        <sendFiles>1</sendFiles>
        <sendFilesNonUser>0</sendFilesNonUser>
        <downloadFiles>1</downloadFiles>
        <batchDownloadFiles>0</batchDownloadFiles>
        <moveCopyFiles>0</moveCopyFiles>
        <batchMoveCopyFiles>0</batchMoveCopyFiles>
        <renameFiles>1</renameFiles>
        <deleteFiles>0</deleteFiles>
        <batchDeleteFiles>0</batchDeleteFiles>
        <createFolders>1</createFolders>
    </workspaceOverridePermissions>
    <workspaceOverrideNotifications>
        <uploadNotifications>1</uploadNotifications>
        <downloadNotifications>1</downloadNotifications>
    </workspaceOverrideNotifications>
</workspaceInfo>

Error response In JSON:

{"error":{
    "title":""Workspace Info Failed",
    "message":"You must be an administrator to call this method"}
}

Error response In XML:

<error>
    <title>'Workspace Info Failed</title>
    <message>You must be an administrator to call this method</message>
</error>