Dropbox Team > Legal_holds API

The Team > Legal_holds API from Dropbox — 7 operation(s) for team > legal_holds.

OpenAPI Specification

dropbox-team-legal-holds-api-openapi.yml Raw ↑
openapi: 3.0.0
info:
  title: Dropbox API Reference Account Team > Legal_holds API
  description: "The powerful, yet simple, Dropbox API allows you to manage and control content and team settings programmatically and extend Dropbox capabilities in new and powerful ways. This is a collection that includes requests to all endpoints in the Dropbox API. \n\nThe Dropbox API is divided in two groups of endpoints: User Endpoints and Business Endpoints. Operations that would most likely be executed by a user, such as file operations, are in the User Endpoints folder. Operations that would most likely be executed by a team administrator, such as adding users to groups, live in the Business Endpoints folder. \n\nIf you are new to Dropbox Business and Team Administration, please have a look at the [Dropobox Admin Guide](https://help.dropbox.com/guide/admin/how-to-get-started#dropbox-admin-guide). \n\nIf you want more information on how to use our API please refer to our [Developer Portal](https://www.dropbox.com/developers). \n\n# What's in the collection?\n\nThe endpoints are organized in the following folders:\n* account\n* auth\n* check\n* contacts\n* file_properties\n* file_requests\n* files\n* sharing\n* team\n* team_log\n* users\n\n# Authorization\n\n## OAuth 2.0 for API Access\nDropbox uses OAuth 2.0, an open specification, to authorize access to data. To get an OAuth token from Dropbox to enable Postman to access your Dropbox account via the API you’ll need to create a new app on the DBX Platform.\n\n## Creating an App on the DBX Platform\nNavigate to https://www.dropbox.com/developers/apps and select “Create app” \n1. Choose an API  \n2. Choose the type of access you need \n3. Give your app a name  \n4. Choose the Dropbox account that will own your app  \n\nFor reference, please use the [Dropbox OAuth guide](https://www.dropbox.com/lp/developers/reference/oauth-guide) \n\n## Generating an Access Token\nOnce you select “Create app” a page will load that displays information about your newly created app. To generate an access token scroll down to “OAuth 2” and click “Generate” beneath “Generated access token.” The token will display as a long string of characters. Copy this token for use with the Postman Collection.\n\n## Adding an Access Token to the requests\nIn the Postman client, click on the three dots to the right of the collection name to \"View more actions.\"\n\n![Screenshot of adding access token](https://www.dropbox.com/s/sfebu9ai76cbq39/Screen%20Shot%202020-10-28%20at%2012.50.56%20AM.png?raw=1)\n\nThen, click \"Edit.\"\n\nClick on the \"Variables\" tab and, in the row for the `access_token` variable, paste your access token in the `CURRENT VALUE` column. The default value is `your-access-token-here`.\n\n![Screenshot of adding access token](https://www.dropbox.com/s/ahnbxwe6oscjues/Screen%20Shot%202020-10-28%20at%2012.51.13%20AM.png?raw=1)\n\nFor information on sessions and variables in Postman see the blog post at https://blog.postman.com/sessions-faq/.\n\n# Notes\n* Dropbox also has a Postman Collection in the API Network to help administrators with team management workflows. It is called [Dropbox Team Admin Workflows](). \n\n"
  version: 1.0.0
servers:
- url: https://api.dropbox.com
security:
- bearerAuth: []
tags:
- name: Team > Legal_holds
paths:
  /2/team/legal_holds/create_policy:
    post:
      tags:
      - Team > Legal_holds
      summary: Dropbox legal_holds/create_policy
      description: '[legal_holds/create_policy](https://www.dropbox.com/developers/documentation/http/teams#team-legal_holds-create_policy)


        scope: `team_data.member`


        Creates new legal hold policy. Note: Legal Holds is a paid add-on. Not all teams have the feature.

        Permission : Team member file access.'
      requestBody:
        content:
          '*/*':
            schema:
              type: string
              example: '"{\n    \"name\": \"acme cfo policy\", \n    \"members\": [\n        \"dbmid:FDFSVF-DFSDF\"\n    ], \n    \"start_date\": \"2016-01-01T00:00:00Z\", \n    \"end_date\": \"2017-12-31T00:00:00Z\"\n}"'
      parameters:
      - name: Content-Type
        in: header
        schema:
          type: string
        example: application/json
      responses:
        '200':
          description: OK
          headers:
            X-Dropbox-Request-Id:
              schema:
                type: integer
                example: '1234'
            Content-Type:
              schema:
                type: string
                example: application/json
          content:
            application/json:
              schema:
                type: object
              example:
                id: pid_dbhid:abcd1234
                name: acme cfo policy
                members:
                  team_member_ids:
                  - dbmid:efgh5678
                  permanently_deleted_users: 2
                status:
                  .tag: active
                start_date: '2016-01-01T00:00:00Z'
                activation_time: '2016-01-20T00:00:10Z'
                end_date: '2017-12-31T00:00:00Z'
  /2/team/legal_holds/get_policy:
    post:
      tags:
      - Team > Legal_holds
      summary: Dropbox legal_holds/get_policy
      description: '[legal_holds/get_policy](https://www.dropbox.com/developers/documentation/http/teams#team-legal_holds-get_policy)


        scope: `team_data.member`


        Gets a legal hold by Id. Note: Legal Holds is a paid add-on. Not all teams have the feature.

        Permission : Team member file access.'
      requestBody:
        content:
          '*/*':
            schema:
              type: string
              example: '"{\n    \"id\": \"pid_dbhid:abcd1234\"\n}"'
      parameters:
      - name: Content-Type
        in: header
        schema:
          type: string
        example: application/json
      responses:
        '200':
          description: OK
          headers:
            X-Dropbox-Request-Id:
              schema:
                type: integer
                example: '1234'
            Content-Type:
              schema:
                type: string
                example: application/json
          content:
            application/json:
              schema:
                type: object
              example:
                id: pid_dbhid:abcd1234
                name: acme cfo policy
                members:
                  team_member_ids:
                  - dbmid:efgh5678
                  permanently_deleted_users: 2
                status:
                  .tag: active
                start_date: '2016-01-01T00:00:00Z'
                activation_time: '2016-01-20T00:00:10Z'
                end_date: '2017-12-31T00:00:00Z'
  /2/team/legal_holds/list_held_revisions:
    post:
      tags:
      - Team > Legal_holds
      summary: Dropbox legal_holds/list_held_revisions
      description: '[legal_holds/list_held_revisions](https://www.dropbox.com/developers/documentation/http/teams#team-legal_holds-list_held_revisions)


        scope: `team_data.member`


        List the file metadata that''s under the hold. Note: Legal Holds is a paid add-on. Not all teams have the feature.

        Permission : Team member file access.'
      requestBody:
        content:
          '*/*':
            schema:
              type: string
              example: '"{\n    \"id\": \"pid_dbhid:abcd1234\"\n}"'
      parameters:
      - name: Content-Type
        in: header
        schema:
          type: string
        example: application/json
      responses:
        '200':
          description: OK
          headers:
            X-Dropbox-Request-Id:
              schema:
                type: integer
                example: '1234'
            Content-Type:
              schema:
                type: string
                example: application/json
          content:
            application/json:
              schema:
                type: object
              example:
                entries:
                - new_filename: 111_222.pdf
                  original_revision_id: ab2rij4i5ojgfd
                  original_file_path: /a.pdf
                  server_modified: '2019-08-12T12:08:52Z'
                  author_member_id: dbmid:abcd1234abcd1234abcd1234abcd1234a23
                  author_member_status:
                    .tag: active
                  author_email: a@a.com
                  file_type: Document
                  size: 3
                  content_hash: abcd1234abcd1234abcd1234abcd1234abcd1234abcd1234abcd1234abcd1234
                has_more: false
  /2/team/legal_holds/list_held_revisions_continue:
    post:
      tags:
      - Team > Legal_holds
      summary: Dropbox legal_holds/list_held_revisions_continue
      description: '[legal_holds/list_held_revisions_continue](https://www.dropbox.com/developers/documentation/http/teams#team-legal_holds-list_held_revisions_continue)


        scope: `team_data.member`


        Continue listing the file metadata that''s under the hold. Note: Legal Holds is a paid add-on. Not all teams have the feature.

        Permission : Team member file access.'
      requestBody:
        content:
          '*/*':
            schema:
              type: string
              example: '"{\n    \"id\": \"pid_dbhid:abcd1234\"\n}"'
      parameters:
      - name: Content-Type
        in: header
        schema:
          type: string
        example: application/json
      responses:
        '200':
          description: OK
          headers:
            X-Dropbox-Request-Id:
              schema:
                type: integer
                example: '1234'
            Content-Type:
              schema:
                type: string
                example: application/json
          content:
            application/json:
              schema:
                type: object
              example:
                entries:
                - new_filename: 111_222.pdf
                  original_revision_id: ab2rij4i5ojgfd
                  original_file_path: /a.pdf
                  server_modified: '2019-08-12T12:08:52Z'
                  author_member_id: dbmid:abcd1234abcd1234abcd1234abcd1234a23
                  author_member_status:
                    .tag: active
                  author_email: a@a.com
                  file_type: Document
                  size: 3
                  content_hash: abcd1234abcd1234abcd1234abcd1234abcd1234abcd1234abcd1234abcd1234
                has_more: false
  /2/team/legal_holds/list_policies:
    post:
      tags:
      - Team > Legal_holds
      summary: Dropbox legal_holds/list_policies
      description: '[legal_holds/list_policies](https://www.dropbox.com/developers/documentation/http/teams#team-legal_holds-list_policies)


        scope: `team_data.member`


        Lists legal holds on a team. Note: Legal Holds is a paid add-on. Not all teams have the feature.

        Permission : Team member file access.'
      requestBody:
        content:
          '*/*':
            schema:
              type: string
              example: '"{\n    \"include_released\": false\n}"'
      parameters:
      - name: Content-Type
        in: header
        schema:
          type: string
        example: application/json
      responses:
        '200':
          description: OK
          headers:
            X-Dropbox-Request-Id:
              schema:
                type: integer
                example: '1234'
            Content-Type:
              schema:
                type: string
                example: application/json
          content:
            application/json:
              schema:
                type: object
              example:
                policies:
                - id: pid_dbhid:abcd1234
                  name: acme cfo policy
                  members:
                    team_member_ids:
                    - dbmid:efgh5678
                    permanently_deleted_users: 2
                  status:
                    .tag: active
                  start_date: '2016-01-01T00:00:00Z'
                  activation_time: '2016-01-20T00:00:10Z'
                  end_date: '2017-12-31T00:00:00Z'
  /2/team/legal_holds/release_policy:
    post:
      tags:
      - Team > Legal_holds
      summary: Dropbox legal_holds/release_policy
      description: '[legal_holds/release_policy](https://www.dropbox.com/developers/documentation/http/teams#team-legal_holds-release_policy)


        scope: `team_data.member`


        Releases a legal hold by Id. Note: Legal Holds is a paid add-on. Not all teams have the feature.

        Permission : Team member file access.'
      requestBody:
        content:
          '*/*':
            schema:
              type: string
              example: '"{\n    \"id\": \"pid_dbhid:abcd1234\"\n}"'
      parameters:
      - name: Content-Type
        in: header
        schema:
          type: string
        example: application/json
      responses:
        '200':
          description: Successful response
          content:
            application/json: {}
  /2/team/legal_holds/update_policy:
    post:
      tags:
      - Team > Legal_holds
      summary: Dropbox legal_holds/update_policy
      description: '[legal_holds/update_policy](https://www.dropbox.com/developers/documentation/http/teams#team-legal_holds-update_policy)


        scope: `team_data.member`


        Updates a legal hold. Note: Legal Holds is a paid add-on. Not all teams have the feature.

        Permission : Team member file access.'
      requestBody:
        content:
          '*/*':
            schema:
              type: string
              example: '"{\n    \"id\": \"pid_dbhid:abcd1234\", \n    \"members\": [\n        \"dbmid:FDFSVF-DFSDF\"\n    ]\n}"'
      parameters:
      - name: Content-Type
        in: header
        schema:
          type: string
        example: application/json
      responses:
        '200':
          description: OK
          headers:
            X-Dropbox-Request-Id:
              schema:
                type: integer
                example: '1234'
            Content-Type:
              schema:
                type: string
                example: application/json
          content:
            application/json:
              schema:
                type: object
              example:
                id: pid_dbhid:abcd1234
                name: acme cfo policy
                members:
                  team_member_ids:
                  - dbmid:efgh5678
                  permanently_deleted_users: 2
                status:
                  .tag: active
                start_date: '2016-01-01T00:00:00Z'
                activation_time: '2016-01-20T00:00:10Z'
                end_date: '2017-12-31T00:00:00Z'
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer