easy-fm is a Node.js client for Claris FileMaker Data API.
It helps you connect Node.js code to FileMaker Server or FileMaker Cloud so you can fetch records, run finds, edit data, work with portals, and run scripts using a typed JavaScript or TypeScript API.
22+fmrest privilegeClaris Data API reference:
help.claris.com/en/data-api-guide/content/index.html
npm install @jd-data-limited/easy-fm
import FMHost from "@jd-data-limited/easy-fm"
const host = new FMHost("https://example.com")
const database = host.database({
database: "Contacts",
credentials: {
method: "filemaker",
username: "api-user",
password: "secret"
},
externalSources: []
})
const layout = database.layout("Contacts_API")
const records = await layout.records.list({
portals: {},
limit: 25
}).fetch()
for (const record of records) {
console.log(record.fields.FirstName.value, record.fields.LastName.value)
}
recordId and modId are internal FileMaker IDs. Avoid treating recordId as a business ID; modId can still be useful for change or concurrency checks.Start here:
docs/getting-started.md: first connection, first find, closing sessionsdocs/core-concepts.md: host, database, layout, record, portal, IDsTask guides:
docs/working-with-records.md: list, create, update, duplicate, delete, portal rowsdocs/query-recipes.md: find requests, sorting, paging, script hooksdocs/authentication-and-sessions.md: auth modes, pooling, lifecycledocs/timezones.md: date, time, and timestamp behaviordocs/typescript-layouts.md: typed layouts and stronger autocompletedocs/testGuide.md: local test commandsAPI reference:
docs_out/index.html: generated TypeDoc sitenpm run docs:build
npm test
npm run test:unit
npm run test:integration
Integration tests require a working FileMaker environment and credentials.