POST
/
v1
/
organizations
/
documents
/
access
/
disablestate
/
update

Use this API to enable or disable both read and write access for all users.

Let’s say your customer’s trial or subscription has ended and you want to disable their access to the Velt data, you could use this to diable access to specific documents.

Endpoint

https://api.velt.dev/v1/organizations/documents/access/disablestate/update

Headers

x-velt-api-key
string
required

Your API key.

x-velt-auth-token
string
required

Body

Params

data
object
required

Example Requests

{
  "data": {
    "organizationId": "yourOrganizationId",
    "documentIds": ["yourDocumentId"],
    "disabled": true
  }
}

Response

Success Response

{
  "result": {
    "status": "success",
    "message": "Updated disable state for documents successfully.",
    "data": {
      "yourDocumentId": {
        "success": true,
        "disabled": true,
        "message": "Document disabled state updated."
      }
    }
  }
}

Failure Response

{
  "error": {
    "message": "ERROR_MESSAGE",
    "status": "INVALID_ARGUMENT"
  }
}