Ellipse Gradient for Header

M-Files Integration Guide

Integrate M-Files vaults, documents, objects, metadata, and files with enterprise systems through the M-Files REST API, selected event mechanisms, and scheduled synchronization.

M-Files integration options at a glance

M-Files provides a REST API for working with vaults, Documents, Objects, Properties, files, workflows, and related resources. Authentication uses configured credentials or identity-provider methods and tokens, with permissions applied at the vault and content level. Selected M-Files deployment contexts may provide event-driven notifications, but event coverage and delivery behavior must be confirmed. Martini can consume the REST API, retrieve or update document files and metadata, and orchestrate incremental synchronization with checkpoints. Scheduled workflows provide a practical fallback when event notifications are unavailable, while controlled batch processing, pagination, validation, retries, and idempotent writes support larger repositories.

Integration pointSupported by M-Files?Common use casesHow Martini supports it
REST APIsYesAccess vaults, Documents, Objects, Properties, files, users, workflows, and related M-Files resources. The REST API is the recommended basis for new integrations.Martini can consume M-Files REST endpoints, map request and response payloads, apply business rules, and expose APIs for upstream systems.
Webhooks / outbound callbacksLimitedSelected M-Files application or deployment contexts may provide event-driven notifications. Coverage, payloads, delivery guarantees, and deployment availability must be verified.Martini can receive a supported notification through an API or webhook workflow, then retrieve authoritative M-Files data and process duplicates safely.
SOAP and other legacy APIsLegacyM-Files documents additional Web Service and client or server APIs that may support existing applications, but REST is generally preferred for new integrations.Martini can consume SOAP services where a target deployment requires them, while keeping the REST API as the preferred M-Files integration boundary.
File / attachment APIsYesRetrieve document files, upload content, update associated files, and coordinate file metadata and document versions.Martini can separate metadata and content operations, transform file-related data, and orchestrate uploads with timeouts, retries, and correlation identifiers.
Bulk / async / batch APIsLimitedREST operations can support controlled batch synchronization, but a universal bulk export or asynchronous export service was not confirmed.Martini can process pages or bounded batches with checkpoints, controlled concurrency, incremental filters, and idempotent writes.
AuthenticationYesM-Files REST requests use authentication tokens and configured user, OAuth 2.0, or identity-provider-backed methods depending on the environment.Martini can store credentials, client secrets, token-generation settings, and tokens in environment-level secrets and apply them to API workflows.
Database / analytics accessNoDirect access to the underlying M-Files vault database is not a supported integration contract.Martini should use M-Files APIs or approved export and reporting mechanisms rather than querying internal vault tables.

How M-Files exposes data and business events

M-Files REST APIs

The M-Files REST API is the primary documented integration mechanism for accessing vaults, Documents, Objects, metadata, files, users, workflows, and related resources. It supports HTTP operations and query parameters for retrieving and modifying M-Files data.

Martini implementation pattern

Martini implementation pattern: a workflow authenticates to the configured M-Files environment, calls the required REST endpoint, validates the response, maps the result to a canonical model, and writes to the target system or exposes the result through a Martini API.

Implementation sequence

Authenticate against the configured M-Files environment
Retrieve the required Documents, Objects, Properties, or files
Validate permissions, identifiers, and required metadata
Map and transform the response for the target system
Write the result and persist a successful checkpoint
Route transient and validation failures through error handling

M-Files event notifications

M-Files supports event-driven extension and notification mechanisms in selected application and deployment contexts. Public webhook coverage is not universal, so the available events, payload shape, endpoint reachability, retries, and signatures must be confirmed.

Martini implementation pattern

Martini implementation pattern: receive the supported notification through a Martini API or webhook workflow, treat it as a trigger rather than the authoritative payload, retrieve the current M-Files Document or Object, and process the result idempotently. A scheduled workflow can provide fallback coverage.

Implementation sequence

Receive the supported M-Files notification
Validate the event source and correlation identifier
Retrieve the authoritative M-Files resource
Apply version and duplicate checks
Update the downstream system
Record the event outcome and retry transient failures

M-Files document files

M-Files Documents can contain file content together with metadata. The REST API supports retrieving document files and uploading or updating files associated with Documents, subject to permissions and document-version behavior.

Martini implementation pattern

Martini implementation pattern: retrieve or receive the file and its metadata, apply content and size policies, map document class and Property values, and upload or version the content through M-Files or a connected application. Metadata and file-content failures are handled separately.

Implementation sequence

Identify the Document and required version behavior
Retrieve or receive the file content and metadata
Validate file size, type, permissions, and required Properties
Transform metadata and prepare the target request
Upload, replace, or version the document content
Record the external identifier and processing result

Scheduled incremental synchronization

When event delivery is unavailable or incomplete, M-Files data can be synchronized by querying for changed Documents or Objects with supported metadata and modification-date filters. Large repositories require pagination and checkpoints.

Martini implementation pattern

Martini implementation pattern: a scheduler starts the workflow, the workflow reads the last successful checkpoint, retrieves changed pages, processes each item idempotently, and advances the checkpoint only after downstream writes succeed.

Implementation sequence

Start the scheduled synchronization workflow
Read the last successful checkpoint
Retrieve changed pages using supported filters
Map and write each Document or Object
Persist the checkpoint after successful downstream processing
Report failures for retry or manual review

Common M-Files integration patterns

Pattern 1: Synchronize document metadata with Salesforce

When to use this pattern

Use this pattern when customer, opportunity, contract, or document metadata must remain aligned between M-Files and Salesforce. It supports either M-Files-led scheduled synchronization or bidirectional updates initiated by an external event.

Integration direction
M-Files
Martini
Salesforce
Example Mapping
M-Files FieldCanonical FieldTarget Field
M-Files Document IDdocumentIdSalesforce ContentDocument.ExternalId
M-Files Properties.CustomercustomerReferenceSalesforce Account.Id
M-Files Properties.ContractStatuscontractStatusSalesforce Contract.Status
M-Files Document.VersionsourceVersionSalesforce ContentVersion.VersionData
Martini implementation pattern

Martini retrieves changed Documents or customer-related Objects, resolves Properties and Value lists, and maps them to Salesforce records using stable identifiers. Business rules determine whether to update metadata, create a new document version, or skip unchanged content. Failed permissions, validation errors, and transient responses are separated for retry or review.

Martini capabilities used
  • workflows
  • API consumption
  • data mapping
  • business rules
  • error handling
  • scheduled synchronization

Pattern 2: Archive SAP documents in M-Files

When to use this pattern

Use this pattern when SAP generates invoices, purchase orders, supplier documents, or other business files that should be stored in M-Files with searchable metadata and controlled access.

Integration direction
SAP
Martini
M-Files
Example Mapping
M-Files FieldCanonical FieldTarget Field
SAP Document NumbersourceDocumentIdM-Files Properties.ExternalDocumentId
SAP Supplier NumbersupplierIdM-Files Properties.Supplier
SAP Document TypedocumentClassM-Files Document Class
SAP File ContentfileContentM-Files Document.Files
Martini implementation pattern

Martini receives SAP business data and file content, validates the required M-Files Document class and Value list identifiers, and uploads or updates the Document through the REST API. Correlation identifiers prevent duplicate archives, while bounded file handling, retries, and a status response support reliable processing.

Martini capabilities used
  • API consumption
  • workflows
  • file handling
  • data mapping
  • validation
  • error handling

Pattern 3: Route M-Files contracts through DocuSign

When to use this pattern

Use this pattern when an M-Files Document reaches an approval state and must be signed electronically, with the completed agreement and signature status returned to M-Files.

Integration direction
M-Files
Martini
DocuSign
Martini M-Files
Example Mapping
M-Files FieldCanonical FieldTarget Field
M-Files Document.FilesdocumentContentDocuSign Envelope.Documents
M-Files Document IDsourceDocumentIdDocuSign Envelope.CustomFields.MFilesDocumentId
M-Files Properties.SignerssignerListDocuSign Envelope.Recipients
DocuSign Envelope.StatussignatureStatusM-Files Properties.SignatureStatus
Martini implementation pattern

A Martini workflow identifies eligible Documents, retrieves content and signer metadata, submits an envelope, and stores the envelope identifier. On completion, it verifies the callback or performs a controlled status retrieval, then updates M-Files metadata or uploads the signed file as a new version. Duplicate callbacks are safely ignored.

Martini capabilities used
  • workflows
  • API consumption
  • file handling
  • mapping
  • business rules
  • idempotency
  • error handling

Pattern 4: Incrementally synchronize M-Files Objects with ServiceNow

When to use this pattern

Use this pattern when operational cases or knowledge processes need current M-Files customer, project, contract, or asset Objects and their document references. It is suitable when event coverage is limited and scheduled retrieval is more portable.

Integration direction
M-Files
Martini
ServiceNow
Example Mapping
M-Files FieldCanonical FieldTarget Field
M-Files Object IDsourceObjectIdServiceNow u_mfiles_object_id
M-Files Object TypeobjectTypeServiceNow u_mfiles_object_type
M-Files Properties.ContractStatusstatusServiceNow state
M-Files Document IDdocumentReferenceServiceNow u_mfiles_document_reference
Martini implementation pattern

A scheduled Martini workflow reads the last successful timestamp, retrieves changed Object pages, resolves metadata and document references, and upserts ServiceNow records. Required fields are validated before writing, checkpoints advance only after successful processing, and rate-limit or transient failures are retried without creating duplicates.

Martini capabilities used
  • scheduler triggers
  • workflows
  • API consumption
  • pagination
  • data mapping
  • validation
  • checkpointing
  • error handling

Applications commonly integrated with M-Files

M-Files can be integrated with the following named applications to connect controlled document content and metadata with business processes. These relationships should be designed against the APIs, callbacks, files, and permissions available in each specific deployment.

Application Scenario Direction Martini Pattern
Salesforce Synchronize customer, opportunity, contract, and document metadata between CRM processes and M-Files. Salesforce → Martini → M-Files Martini consumes Salesforce data or receives an external event, maps identifiers and business metadata to M-Files Properties and Objects, and uses the M-Files REST API to create or update content. Reverse synchronization can publish M-Files status or document references back to Salesforce with idempotent matching.
Microsoft Dynamics 365 Connect customer and sales processes with controlled documents and contract content stored in M-Files. Microsoft Dynamics 365 → Martini → M-Files A Martini workflow retrieves or receives Dynamics data, validates the required M-Files object types and Value lists, and writes document metadata or references through the REST API. Status updates and selected document links can be returned to Dynamics after successful processing.
SAP Archive invoices, purchase orders, supplier documents, and other ERP-generated content in M-Files. SAP → Martini → M-Files Martini receives SAP business-process data and document content, transforms it into M-Files document classes and Properties, and uploads or updates the associated document. Correlation identifiers, bounded file handling, retries, and status responses support reliable processing.
DocuSign Send M-Files documents for signature and store signed versions or signature status back in M-Files. M-Files → Martini → DocuSign → Martini M-Files Martini retrieves an eligible M-Files document and metadata, sends the required content or reference to DocuSign, and processes the completion callback. The workflow verifies the callback, updates M-Files metadata, and optionally uploads the signed document as a new version.
Microsoft 365 Coordinate Office documents, collaboration content, users, and controlled records managed through M-Files. Microsoft 365 → Martini → M-Files Martini maps Microsoft 365 document or user context to M-Files metadata and controlled content, applying vault permissions and document-version rules before writing through the relevant APIs. Changes can be synchronized in either direction where the source APIs support them.
ServiceNow Associate service cases, knowledge content, and operational records with controlled M-Files documents. ServiceNow → Martini → M-Files Martini receives ServiceNow changes or polls for eligible cases, maps case identifiers and document references to M-Files Objects and Properties, and updates both systems after validation. Error paths route permission, missing-object, and transient API failures for retry or review.
Adobe Acrobat Sign Send documents for electronic signature and update M-Files with completed documents and signature status. M-Files → Martini → Adobe Acrobat Sign → Martini M-Files A Martini workflow identifies documents requiring signature, retrieves the file and metadata from M-Files, submits the signing request, and consumes the completion notification where available. It then records the external agreement identifier and updates or versions the M-Files document.
NetSuite Archive financial and commercial documents while synchronizing customer, vendor, or transaction metadata with M-Files. NetSuite → Martini → M-Files Martini retrieves NetSuite transactions and files, transforms them into M-Files document metadata and Value list references, and performs idempotent writes. Optional reverse updates can publish M-Files document status or identifiers to NetSuite.

How to build a M-Files integration in Martini

Objective

Establish the M-Files REST API connection for the target vault or tenant and define environment-specific identifiers and credentials.

Instructions in Martini

  • Configure the M-Files base URL and vault identifier
  • Store credentials, client secrets, and token settings in Martini Secrets Management
  • Use the authentication method supported by the M-Files deployment
  • Configure least-privilege access for the integration account

Objective

Select event-driven processing when the required M-Files event is confirmed, or use scheduled incremental synchronization as the portable fallback.

Instructions in Martini

  • Confirm event availability, payload shape, and delivery behavior
  • Expose a Martini API or webhook workflow for supported notifications
  • Configure a Scheduler Trigger for polling workflows when necessary
  • Define the checkpoint and event-correlation strategy

Objective

Retrieve authoritative M-Files Documents, Objects, Properties, files, or workflow information rather than relying solely on notification payloads.

Instructions in Martini

  • Call the relevant M-Files REST endpoints
  • Process large result sets page by page
  • Retrieve document content separately from metadata when appropriate
  • Preserve stable M-Files identifiers and version information

Objective

Coordinate calls, branching, enrichment, and target writes in a maintainable Martini workflow.

Instructions in Martini

  • Use workflow nodes to sequence M-Files and target-system operations
  • Separate metadata, file-content, and status operations where useful
  • Apply bounded concurrency for larger synchronization jobs
  • Persist correlation identifiers for tracing

Objective

Convert M-Files Properties, Value lists, Object types, and files into the target system's canonical and application-specific model.

Instructions in Martini

  • Map typed M-Files Properties to canonical fields
  • Resolve Value list and lookup identifiers
  • Transform dates, numbers, users, and document references
  • Handle JSON and file payloads according to target requirements

Objective

Apply document-class, lifecycle, permission, version, and duplicate-handling rules before modifying either system.

Instructions in Martini

  • Validate required M-Files metadata and target fields
  • Decide whether to create, update, skip, or version a Document
  • Use stable identifiers and source versions for idempotency
  • Route missing objects and permission failures for review

Common M-Files data objects used in integrations

ObjectTypical UseCommon target systemsMartini handling
DocumentsManage files, document classes, metadata, versions, and associated properties.Salesforce, Microsoft Dynamics 365, SAP, DocuSign, Microsoft 365Martini retrieves or updates document metadata and content through REST workflows, applies versioning rules, and stores stable identifiers for idempotency.
ObjectsRepresent customers, projects, contracts, employees, assets, and other business entities in a vault.Salesforce, Microsoft Dynamics 365, ServiceNow, NetSuiteMartini maps Object types and Properties to canonical models, validates permissions and identifiers, and creates or updates matching target records.
Object typesDefine the kinds of Objects available in a vault.Salesforce, Microsoft Dynamics 365, ServiceNow, NetSuiteMartini uses environment-specific Object type identifiers and validates configuration before processing data.
PropertiesStore typed metadata such as text, numbers, dates, lookups, and users on Documents and Objects.Salesforce, SAP, Microsoft Dynamics 365, ServiceNowMartini transforms values, resolves lookups and Value list items, validates required fields, and handles schema changes explicitly.
Value listsProvide controlled values for metadata fields and lookup Properties.Salesforce, Microsoft Dynamics 365, SAP, NetSuiteMartini resolves stable identifiers or configured mappings rather than relying only on display names, with environment-specific configuration.
Workflows and assignmentsControl document and Object lifecycle states, transitions, and assignments.Salesforce, ServiceNow, DocuSign, Adobe Acrobat SignMartini evaluates lifecycle status and assignment data, applies business rules, and coordinates external approvals or status updates.

Authentication and security considerations

Authentication and authorization

M-Files REST API requests use authentication tokens and configured user, OAuth 2.0, or identity-provider-backed methods depending on the deployment. Vault, user, document, Object, and metadata permissions affect what an integration can read or change.

Secure configuration

Store M-Files base URLs, vault identifiers, credentials, client secrets, and token-generation settings in Martini environment-level secrets. Use HTTPS, least-privilege accounts, and separate configuration for development, test, and production.

Content protection

  • Do not place tokens or document content in application logs.
  • Validate callback sources when event mechanisms provide verification data.
  • Review whether document metadata contains confidential information.
  • Test with the same permission model used in production.

Operational considerations for M-Files integrations

Pagination and incremental processing

Process large Document and Object collections page by page. Use modification timestamps, versions, stable identifiers, or supported filters with a checkpoint that advances only after successful downstream writes.

Versions and idempotency

Define whether updates modify metadata, upload a new Document version, replace file content, or create a new Document. Use M-Files identifiers and versions as idempotency keys to prevent duplicate target writes.

Throttling and retries

Confirm deployment-specific request limits. Use bounded concurrency and exponential backoff for transient failures, including appropriate handling for HTTP 429 and 5xx responses.

Schema and deployment changes

Object types, classes, Properties, Value lists, workflows, and identifiers can vary across vaults and environments. Validate required metadata and maintain environment-specific configuration rather than hard-coding display names.

Testing and monitoring

Test permissions, file sizes, version behavior, callbacks, pagination, duplicate delivery, and failure recovery before production. Monitor authentication, permission, validation, file-transfer, and downstream errors separately.

Why use Martini instead of scripts or point-to-point integrations?

Centralized orchestration

Martini coordinates M-Files API calls, event or scheduled triggers, file operations, transformations, business rules, and target-system writes in one maintainable workflow.

Reliable synchronization

Instead of repeating custom polling and retry code in scripts, Martini provides structured workflows for pagination, checkpoints, idempotency, validation, error routing, and operational monitoring.

Reusable integration assets

Martini can consume the M-Files REST API, expose controlled APIs for other applications, and reuse mapping, authentication, and error-handling logic across document, Object, and metadata processes.

Adaptable architecture

When M-Files event coverage is limited or deployment-specific, the same integration design can switch to scheduled synchronization without replacing the overall orchestration and transformation model.

Frequently asked questions

How can M-Files be integrated with enterprise systems?

M-Files is primarily integrated through its REST API, which provides access to vaults, Documents, Objects, Properties, files, users, workflows, and related resources. Selected deployment contexts may support event notifications, while scheduled incremental synchronization is a practical fallback. Authentication and permissions must be configured for the target vault or tenant.

Can Martini integrate with M-Files?

Yes. Martini can consume the M-Files REST API, retrieve and update document metadata and files, orchestrate scheduled synchronization, and expose APIs for other systems. Where a suitable M-Files event or callback is available, Martini can also receive the notification and retrieve the authoritative resource.

Do I need a connector to integrate M-Files with Martini?

No. A dedicated M-Files connector is not required. Martini can integrate using M-Files native REST APIs, supported authentication methods, document file operations, selected event mechanisms, and scheduled workflows.

Is there any extra Lonti cost to integrate M-Files with Martini?

Lonti does not charge an additional per-connector or per-vendor fee to integrate M-Files. Integrations are subject to the provisioned capacity of the Martini environment. Separate costs may apply from M-Files, infrastructure, or other third-party systems based on subscription, usage, and deployment model.

Which M-Files integration methods should new projects use?

The M-Files REST API is the recommended basis for new integrations. File and attachment operations are also supported through the REST API. Older Web Service or client and server APIs may be relevant to existing applications, but they should be treated as legacy or deployment-specific. No official M-Files GraphQL API was confirmed.

Can M-Files trigger a Martini workflow?

Potentially, where the target M-Files deployment provides a suitable event or callback mechanism for the required event. Coverage is not universal and must be verified. Martini can receive a supported notification and then retrieve the current M-Files resource; scheduled incremental synchronization provides a fallback.

How should M-Files data synchronization handle documents and versions?

Use paginated retrieval, modification filters or timestamps, stable identifiers, version information, checkpoints, and idempotent writes. Define whether each change updates metadata, uploads a new document version, replaces file content, or creates a new Document. Advance checkpoints only after downstream processing succeeds.

How does Martini handle M-Files mapping, errors, and retries?

Martini workflows can map typed Properties, Value lists, Object types, document files, and external identifiers into target models, then apply validation and business rules. Error paths can distinguish authentication, permissions, validation, missing-resource, file-transfer, rate-limit, and transient service failures, with retries and duplicate protection where appropriate.