AFAS Profit logoSalesforce logo

Accounts in applications

AFAS to Salesforce integration: sales and service staff from AFAS as Salesforce users

With an integration between AFAS Profit and Salesforce, every new employee with a sales or service job in AFAS automatically gets a Salesforce user with the right profile, the right role and their manager set. On the end date in AFAS the user is deactivated, so the licence is released and customer data is closed off.

What the integration does

Organisations with HR in AFAS Profit and sales and customer service in Salesforce create Salesforce users after an email from HR. Account managers who leave sometimes stay active for weeks, with their licence and their access to every customer record.

  1. HR records the new account manager in AFAS, with job, organisational unit and start date.
  2. KoppelHet reads the employee from AFAS and uses the job to decide whether a Salesforce user is needed, and with which profile.
  3. The user appears in Salesforce with name, work email, role and manager, and signs in with single sign-on or through Salesforce's invitation email.
  4. When the employee changes job or department, KoppelHet adjusts profile, permission sets and role.
  5. On the end date the user is deactivated. If that is not possible straight away, KoppelHet freezes the user and the administrator gets an alert.
AFAS Profit → KoppelHet → SalesforceSOURCEAFAS ProfitTARGETSalesforceKoppelHetmapping · logging · monitoringAFAS Profit → KoppelHet → SalesforceSOURCEAFAS ProfitTARGETSalesforceKoppelHetmapping · logging · monitoring
Out: Salesforce user with name, email and employee number · Profile and permission sets based on the job · Role in the role hierarchy · Manager · Status: active, frozen or deactivated

What to watch for with AFAS Profit and Salesforce

  • AFAS stores the name prefix separately from the surname, while Salesforce only has a first and last name. KoppelHet puts the prefix in front of the surname, so 'Jan de Vries' appears in Salesforce the way colleagues and customers know him.
  • With several employers in one AFAS environment the same person can have two employee numbers. Salesforce has one employee number per user. KoppelHet uses the number of the main employment and puts the employer in the company field, so no second user is created.
  • Salesforce gives every user exactly one profile, and that profile determines which licence the user consumes. The job in AFAS sets the profile; a job without Salesforce work produces no user, so licences are not used up by colleagues who never work in it.
  • In AFAS the manager is often the head of the organisational unit, for example a branch director without a Salesforce licence. Salesforce can only point to an existing user as manager. KoppelHet then looks one level up in AFAS, to the first manager who does have a Salesforce user.
  • Salesforce refuses to deactivate a user who is still the default owner of leads or cases or is used in a hierarchy field. If the AFAS end date hits such a user, KoppelHet freezes the account at once, so sign-in is no longer possible, and tells the administrator what still has to be handed over.
  • Salesforce requires an alias of at most eight characters, shown in list views and reports. KoppelHet builds it from the AFAS preferred name and surname, with a sequence number when two colleagues end up with the same alias.
  • The integration gets its own app connector in AFAS with only the employee fields Salesforce needs. Salary, citizen service number and bank details never come near the CRM.

This integration is also part of joiner, mover, leaver.

How we build and run it

  • The integration runs on the KoppelHet platform, hosted in a data centre in the EU.
  • Every sync and every error is visible in the functional log; on an error your administrator is notified.
  • A change that cannot go through is not half-applied but queued for another attempt.
  • KoppelHet is ISO 27001 certified. Data travels encrypted and stays on the platform no longer than needed.
  • After go-live we manage the integration and adjust it when your process changes.
  • The integration fits next to your existing integration layer. Only the fields in the design are transferred; the platform keeps no register of its own.

Implementation, architecture and compliance

Implementation and price

This is not an app you switch on. We build the integration for your organisation on our platform, with building blocks we reuse on every project. So it is custom work that does not start from scratch.

A consultant prepares the intake and analyses both systems. We then record the mapping and exceptions field by field, test in the test or acceptance environment and go live at a moment you choose. Costs are a one-off amount for the setup and a monthly amount for platform, monitoring and support.

Price indication · Basic

Leave your work email and you see the price indication right away.

We only use your address to follow up on your question about this integration.

Frequently asked questions

What happens to a leaver's accounts and opportunities?

They stay owned by the deactivated user; Salesforce does not delete users. A sales manager or administrator transfers them to a colleague in Salesforce. KoppelHet reports who is leaving, so that can happen in time.

Can we assign permission sets per job too?

Yes. The lookup table holds a profile and zero or more permission sets per AFAS job. You maintain that table yourselves; a new job without a rule goes on a list for the administrator.

Does anything go back from Salesforce to AFAS?

Not by default. AFAS stays the source for name, job and department. Writing back, for example, a Salesforce user ID to a free field in AFAS can be added later as an extension.

Technical details for IT

For those who want to know how it works under the hood: APIs, fields and sources used.

  • AFAS is read with a dedicated GetConnector on employees and employments, filtered on modification date, under a dedicated app connector (OAuth or token). The classic token expires on 31 August 2027.
  • Salesforce is written through the REST API on the User object, with a connected app (OAuth 2.0) and an integration user with the Manage Users permission. Creating a user needs, among others, Username (unique across all Salesforce orgs), Alias (at most 8 characters), Email, LastName, ProfileId, TimeZoneSidKey, LocaleSidKey, LanguageLocaleKey and EmailEncodingKey. EmployeeNumber is at most 20 characters.
  • Extra permissions go through PermissionSetAssignment. On departure KoppelHet sets IsActive to false; if Salesforce refuses, KoppelHet sets IsFrozen on the related UserLogin record and deactivation follows after handover.

Which fields are transferred

The key fields. The full mapping is agreed per customer.

Field in AFAS ProfitField in SalesforceNotes
MedewerkernummerEmployeeNumberFixed key to find the user again
RoepnaamFirstName
Voorvoegsel + AchternaamLastName
NaamgevingsregelUsername, Email en FederationIdentifier
Roepnaam + achternaam (ingekort)AliasAt most 8 characters, with a sequence number for a duplicate
FunctieTitle, ProfileId en permission setsThrough a lookup table per job
Organisatorische eenheidDepartment en UserRoleId
WerkgeverCompanyName
Leidinggevende (medewerkernummer)ManagerIdOnly if the manager has a Salesforce user
Datum uit dienstIsActive

Related

Which systems do you want to connect?

Tell us which systems you use and what should happen automatically. Together we define the smallest working solution, with a clear design and a quote before building.