Files
dashlibstorage/API.entitycontact.md
seb 70e0a9ddc4 Add entity customer numbers and scope APIs via selected company.
Entity gets an optional unique-per-company number with allocate/peek/isNumberFree helpers. Company-scoped store methods no longer take companyId and resolve google_auth.selected_company instead.
2026-08-07 04:29:35 +02:00

1.0 KiB

entitycontact

This document is auto-generated from the JSDoc comments in src/store by running npm run api-doc.

entitycontact.create

Source: src/store/entitycontact/create.js

Creates a new contact for an entity.

const fn = create(pool);
const contact = await fn(42, 5, { contactType: 'email', contact: 'a@b.c' });
// => { id, entityId, contactType, contact, sort }

entitycontact.delete

Source: src/store/entitycontact/delete.js

Deletes a contact of an entity.

const fn = del(pool);
await fn(42, 5, 9);

entitycontact.list

Source: src/store/entitycontact/list.js

Lists the contacts of an entity.

const fn = list(pool);
const contacts = await fn(42, 5);
// => [{ id, entityId, contactType, contact, sort }]

entitycontact.update

Source: src/store/entitycontact/update.js

Updates a contact of an entity.

const fn = update(pool);
const contact = await fn(42, 5, 9, { contact: 'b@c.d' });
// => { id, entityId, contactType, contact, sort }