Skip to content
AccountFUNDocs

Contacts

Contacts are the customers and suppliers in an organization. Each contact is a hub for their sales and purchase history. Use these endpoints to sync contacts from another system or look up the contactId you need when creating an invoice.

Both endpoints require the contacts:read scope; creating a contact also requires contacts:write. See Authentication.

MethodPathScopeDescription
GET/api/v1/contactscontacts:readList contacts (paginated or full).
POST/api/v1/contactscontacts:writeCreate a contact.
GET/api/v1/contacts/{id}contacts:readFetch a single contact.

Returns contacts for the token’s organization, sorted by name. You can either paginate explicitly or request the full list (capped at 500).

Terminal window
curl https://app.accountfun.com/api/v1/contacts \
-H "Authorization: Bearer $ACCESS_TOKEN"
ParameterTypeDefaultDescription
pageinteger1Page number (1-based). Sending page or limit (either one) switches on pagination and returns a pagination object.
limitinteger25Page size (max 200).
typestring—Filter by role: customer, supplier, or both.
searchstring—Case-insensitive search across name, email, and phone.
includeInactivestringfalseSet to true to include deactivated contacts.
GET /api/v1/contacts?type=customer&search=northwind&page=1&limit=50
{
"contacts": [
{
"id": "00000000-0000-0000-0000-000000000001",
"name": "Northwind Traders",
"email": "ap@northwind.example",
"phone": "+1-555-0100",
"contactType": "customer",
"defaultCurrency": "USD",
"isActive": true,
"...": "..."
}
],
"pagination": {
"page": 1,
"limit": 50,
"total": 73,
"totalPages": 2
}
}

When page and limit are both omitted, the response contains only the contacts array (no pagination object):

{
"contacts": [ { "...": "..." } ]
}

Creates a new contact (customer, supplier, or both). This requires contacts:write, and the authorizing user must hold a role with the manage_contacts permission.

Terminal window
curl -X POST https://app.accountfun.com/api/v1/contacts \
-H "Authorization: Bearer $ACCESS_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"name": "Acme Supplies Ltd",
"contactType": "supplier",
"email": "sales@acme.example",
"phone": "+1-555-0200",
"defaultCurrency": "USD"
}'
FieldTypeRequiredDescription
namestringYesContact name. Max 200 characters. Must be unique in the organization.
contactTypestringNocustomer, supplier, or both. Defaults to customer.
emailstringNoPrimary email. Must be a valid email address (or empty string).
phonestringNoPhone number. Max 50 characters.
addressstringNoPostal address. Max 1000 characters.
firstNamestringNoContact person first name. Max 100 characters.
lastNamestringNoContact person last name. Max 100 characters.
primaryEmailstringNoAlternative primary email for the contact person.
defaultCurrencystringNoISO 4217 code; must be an enabled org currency. Defaults to the org’s base currency.
settlementCurrencystringNoDefault settlement currency copied onto this customer’s new invoices. Must be an enabled org currency.
settlementRateSourcestringNosystem (default) or manual.
remindersDisabledbooleanNoIf true, automatic invoice reminders are suppressed for this contact. Defaults to false.
defaultCcstring[]NoEmail addresses CC’d on every email sent to this contact.
defaultBccstring[]NoEmail addresses BCC’d on every email sent to this contact.
websitestringNoWebsite URL. Max 500 characters.
linkedinstringNoLinkedIn profile URL. Max 500 characters.
instagramstringNoInstagram handle/URL. Max 500 characters.
facebookstringNoFacebook profile/page URL. Max 500 characters.
twitterstringNoTwitter/X handle/URL. Max 500 characters.
{
"contact": {
"id": "00000000-0000-0000-0000-000000000002",
"name": "Acme Supplies Ltd",
"email": "sales@acme.example",
"contactType": "supplier",
"defaultCurrency": "USD",
"isActive": true,
"...": "..."
}
}
StatusCause
400Invalid body (missing name, bad email, unknown currency).
403Insufficient role (the user lacks the manage_contacts permission).
409A contact with the same name already exists in this organization.

Returns the full contact record.

Terminal window
curl https://app.accountfun.com/api/v1/contacts/00000000-0000-0000-0000-000000000001 \
-H "Authorization: Bearer $ACCESS_TOKEN"
{
"contact": {
"id": "00000000-0000-0000-0000-000000000001",
"name": "Northwind Traders",
"email": "ap@northwind.example",
"phone": "+1-555-0100",
"contactType": "customer",
"defaultCurrency": "USD",
"isActive": true,
"remindersDisabled": false,
"defaultCc": [],
"defaultBcc": [],
"...": "..."
}
}

Returned if no contact with that id exists in the token’s organization.


A contact can be a customer (you invoice them), a supplier (you bill them), or both — useful for two-way trading relationships. The contactType field controls how the contact appears in filters and dropdowns throughout AccountFUN.

ValueMeaning
customerAppears in customer pickers (invoices, quotes).
supplierAppears in supplier pickers (bills, purchase orders).
bothAppears in both.