{
  "opencollection": "1.0.0",
  "info": {
    "name": "Cintoo Open Account Share Link API",
    "version": "2.0.0"
  },
  "request": {
    "auth": {
      "type": "oauth2",
      "flow": "authorization_code",
      "authorizationUrl": "https://aec.cintoo.com/oauth/authorize",
      "accessTokenUrl": "https://aec.cintoo.com/oauth/token",
      "credentials": {
        "clientId": "{{clientId}}",
        "clientSecret": "{{clientSecret}}"
      }
    }
  },
  "items": [
    {
      "info": {
        "name": "Share Link",
        "type": "folder"
      },
      "items": [
        {
          "info": {
            "name": "List share links",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://aec.cintoo.com/api/2/accounts/:accountRef/projects/:projectRef/share-links",
            "params": [
              {
                "name": "accountRef",
                "value": "",
                "type": "path",
                "description": "The Id or Urn of the account"
              },
              {
                "name": "projectRef",
                "value": "",
                "type": "path",
                "description": "The Id or Urn of the project"
              }
            ]
          },
          "docs": "<span class='tag beta'>BETA</span>List share links.\n\nPermissions:\nA link will only be listed if the user needs has either:\n- the `workzone:share-links:read` permission\n- the `workzone:own-share-links:read` permission if he is the creator of the link\n\nProject owner automatically gets the `workzone:share-links:read` permission on all the project's work zones.\nRoles with the \"Share\" permission grants the `workzone:own-share-links:read` permission.\n"
        },
        {
          "info": {
            "name": "Create a share link",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://aec.cintoo.com/api/2/accounts/:accountRef/projects/:projectRef/share-links",
            "params": [
              {
                "name": "accountRef",
                "value": "",
                "type": "path",
                "description": "The Id or Urn of the account"
              },
              {
                "name": "projectRef",
                "value": "",
                "type": "path",
                "description": "The Id or Urn of the project"
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            }
          },
          "docs": "<span class='tag beta'>BETA</span>Create a share link.\n\n<span class='block' style='background-color: PapayaWhip;'><span class='icon' style='color: red; font-size:20px;'>&#9888;</span> A share link with no password will be freely usable by anyone with its id</span>\n\nPermissions:\n- the user need to have the `workzone:share-links:write` or `workzone:own-share-links:write` permission\n\nProject owner automatically gets the `workzone:share-links:write` permission on all the project's work zones.\nRoles "
        },
        {
          "info": {
            "name": "Get a share link",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://aec.cintoo.com/api/2/accounts/:accountRef/projects/:projectRef/share-links/:shareLinkRef",
            "params": [
              {
                "name": "accountRef",
                "value": "",
                "type": "path",
                "description": "The Id or Urn of the account"
              },
              {
                "name": "projectRef",
                "value": "",
                "type": "path",
                "description": "The Id or Urn of the project"
              },
              {
                "name": "shareLinkRef",
                "value": "",
                "type": "path",
                "description": "The Urn of the share link"
              }
            ]
          },
          "docs": "<span class='tag beta'>BETA</span>Get details on a share link.\n\nPermissions:\nThe user need to either:\n- have the `workzone:share-links:read` permission\n- have the `workzone:own-share-links:read` permission and be the creator of the link\n\nProject owner automatically gets the `workzone:share-links:read` permission on all the project's work zones.\nRoles with the \"Share\" permission grants the `workzone:own-share-links:read` permission.\n"
        },
        {
          "info": {
            "name": "Update a share link",
            "type": "http"
          },
          "http": {
            "method": "PUT",
            "url": "https://aec.cintoo.com/api/2/accounts/:accountRef/projects/:projectRef/share-links/:shareLinkRef",
            "params": [
              {
                "name": "accountRef",
                "value": "",
                "type": "path",
                "description": "The Id or Urn of the account"
              },
              {
                "name": "projectRef",
                "value": "",
                "type": "path",
                "description": "The Id or Urn of the project"
              },
              {
                "name": "shareLinkRef",
                "value": "",
                "type": "path",
                "description": "The Urn of the share link"
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            }
          },
          "docs": "<span class='tag beta'>BETA</span>Update a share link.\n\n<span class='block' style='background-color: PapayaWhip;'><span class='icon' style='color: red; font-size:20px;'>&#9888;</span> Overwrites all fields. Missing fields will be considered as null and current values will be erased</span>\n\nNote: the `password` field has a special semantic here, to allow updating a share link without supplying the password every time.\nIt can be either:\n- null or absent field: the password will remain the same.\n- "
        },
        {
          "info": {
            "name": "Delete a share link",
            "type": "http"
          },
          "http": {
            "method": "DELETE",
            "url": "https://aec.cintoo.com/api/2/accounts/:accountRef/projects/:projectRef/share-links/:shareLinkRef",
            "params": [
              {
                "name": "accountRef",
                "value": "",
                "type": "path",
                "description": "The Id or Urn of the account"
              },
              {
                "name": "projectRef",
                "value": "",
                "type": "path",
                "description": "The Id or Urn of the project"
              },
              {
                "name": "shareLinkRef",
                "value": "",
                "type": "path",
                "description": "The Urn of the share link"
              }
            ]
          },
          "docs": "<span class='tag beta'>BETA</span>Delete a share link.\n\nPermissions:\nThe user need to either:\n- have the `workzone:share-links:write` permission\n- have the `workzone:own-share-links:write` permission and be the creator of the link\n\nProject owner automatically gets the `workzone:share-links:write` permission on all the project's work zones.\nRoles with the \"Share\" permission grants the `workzone:own-share-links:write` permission.\n"
        }
      ]
    }
  ],
  "bundled": true
}