Actions38
- Correspondent Actions
- Custom Field Actions
- Document Actions
- Document Type Actions
- Group Actions
- Storage Path Actions
- Tag Actions
- User Actions
Overview
The node integrates with the Paperless NGX API to update an existing Document Type. This operation is useful for managing document classification within a document management system, allowing users to modify how documents are categorized and matched automatically.
Typical use cases include:
- Changing the name or matching criteria of a document type.
- Adjusting the algorithm used to match incoming documents to this type.
- Setting ownership and permissions for access control on the document type.
For example, you might update a "Invoice" document type to improve automatic recognition by changing its matching algorithm or adding new keywords to the match string.
Properties
| Name | Meaning |
|---|---|
| Note (globalPermissionsNote) | Informational notice that owner and permission fields accept numeric IDs. Users should retrieve available User and Group IDs using the respective nodes before setting these properties. |
| Name (name) | The name of the document type. This is a required field when updating the document type. |
| Match (match) | A string that Paperless NGX will try to find in document content to automatically assign this document type. |
| Matching Algorithm (matchingAlgorithm) | The algorithm used to match documents to this document type. Options include: None, Any, All, Literal, Regular Expression, Fuzzy Match, Auto (let Paperless decide). Default is None. |
| Case Insensitive (isInsensitive) | Boolean flag indicating whether the matching should ignore case differences. |
| Owner User ID (owner) | Numeric user ID to set as the owner of this document type. |
| Set Permissions (setPermissions) | JSON object defining view and change permissions for users and groups. Format: {"view":{"users":[],"groups":[]},"change":{"users":[],"groups":[]}}. Users and groups must be specified by their numeric IDs. |
| Note (permissionsNote) | Informational notice reminding users to look up User and Group IDs via the respective endpoints, as this node does not support creating/updating/deleting users or groups. |
| Document Type ID (id) | The numeric ID of the document type to update. This is a required field. |
Output
The node outputs JSON data representing the updated Document Type as returned by the Paperless NGX API. This typically includes all properties of the document type such as its ID, name, matching criteria, matching algorithm, owner information, and permissions.
No binary data output is expected from this operation.
Dependencies
- Requires an active connection to a Paperless NGX instance via an API key credential.
- The node expects the base URL of the Paperless NGX API to be configured in the credentials.
- To set owner and permissions, users must have numeric IDs of users and groups, which can be retrieved using separate nodes querying
/api/users/and/api/groups/.
Troubleshooting
- Invalid or missing Document Type ID: Ensure the
idproperty is provided and corresponds to an existing document type in Paperless NGX. - Permission errors: Verify that the API key has sufficient rights to update document types and that the owner and permissions IDs are valid.
- Malformed permissions JSON: The
setPermissionsproperty must be a valid JSON object with correct structure; otherwise, the API may reject the request. - Matching algorithm issues: Using an unsupported or incorrect matching algorithm value may cause unexpected behavior. Use one of the documented options.
- Case sensitivity confusion: If matching does not behave as expected, check the
isInsensitiveflag to ensure it matches your intended case sensitivity.
Links and References
- Paperless NGX API Documentation
- Paperless NGX GitHub Repository
- n8n Documentation on Creating Custom Nodes