Project management

Get a list of all projects

You can get a list of projects created by an administrator. These projects can be copied to a user's account, along with the blacklists, groups and charts they contain.

GET /api/v2/organizations/:org_id/projects
Authorization: Bearer ZW1haWxAZXhhbXBsZS5jb206cGFzc3dvcmQ=
Accept: application/json

The response should look like this:

{
    "projects": [{
        "id": "68987654567876567",
        "name": "My Project",
        "description": "My Project Description",
        "dataset":{
            "name": "Listing reviews 2012-2014",
            "description": "All listing reviews in English between 2012 and 2014",
            "numberOfDocuments": 18723,
            "createdAt": "2017-01-09T19:13:53.392Z"
        },
        "createdBy": {
            "id": "2312as212dlk12",
            "firstName": "John",
            "lastName": "Matthews",
            "email": "john.matthews@example.com",
            "createdAt": "2016-05-09T14:17:39.127Z"
        },
        "createdAt": "2017-01-11T20:53:53.374Z"
    }]
}
Property Type Description
id string The project's ID.
name string The project's name.
description string The project's description.
datasetId string The associated dataset's ID.
createdBy string
Property Type Description
id string The admin user's ID.
firstName string The admin user's first name.
lastName string The admin user's last name.
email string The admin user's email address.
createdAt string The date and time the admin user was created.
createdAt string The date and time the project was created.

Copy a project to a user's account

To take an existing project and copy it to a user's account, along with the blacklists, groups and charts it contains, get the project's ID with the endpoint described above, then follow the instructions to authenticate a user and replace the datasetId property with projectId.

If the project already exists in the user's account, you can overwrite their blacklists, groups and charts by setting the forceListUpdate property to true:

POST /api/v2/organizations/:org_id/access-url
Authorization: Bearer ZW1haWxAZXhhbXBsZS5jb206cGFzc3dvcmQ=
Content-Type: application/json
Accept: application/json

{
    "email": "tom@example.com",
    "filters": [{
         "projectId": "68987654567876567",
         "forceListUpdate": true
    }]
}

Please note that there can only be one project per dataset. If you try to give the user access to multiple projects for the same dataset, only the last project in the request will actually be copied to the user's account.

results matching ""

    No results matching ""