v3

latestOpenAPI 3.1.02026-07-311,0939714.5 MB
Last modified version numbers

List of employer last modified version numbers

Activity name : <a href="https://developer.loket.nl/Activities/GetEmployerLastModifiedVersionNumbersByUser" target="_blank">GetEmployerLastModifiedVersionNumbersByUser</a>

What does the 'last modified' version number reflect

The sequence number of an employer is a sequential number that reflects whether any changes have occurred in any of its UNDERLYING employments.

More precisely, it reflects the sequence number after the latest change of any database record that relates to an employment within this employer. What we consider to be 'underlying' employment data is based on a predefined set of tables, and of course given id. This predefined set of tables can be found here

The scope of this predefined set is to represent 'static' employment data (vaste gegevens), and thus excludes payroll period data (variabele gegevens).

When to use

This endpoint is most useful for integrations that regularly synchronize Loket employment data with another system. As there are no webhooks available, in practice these integrations would need to regularly poll all data to see whether there any changes in the employment data. The most elementary approach of getting all employment data every time you sync acquires a LOT of calls, in some cases even millions per day. Even though we can handle quite a lot, this is not always the desired way for both client and server. Hence, this endpoint enables an alternative solution to set up such an integration.

How to use

With every update (including additions and deletions) the version number will increase. I.e. the version number will NEVER decrease over time. (Please note this is not only true within the context of a single employer (or any other entity) but applies to all changes in the database). Consequently, in practice one would use this endpoint to check if any empLoyer version numbers have increased by applying the filter query parameter to the version field, for example ?filter=version gt 70429274.

Recommended usage

  • Perform your regular synchronization of static employment data
  • Store the highest version number, for which you have now processed all changes. (You may use the following parameter to do this ?orderBy=-lastModifiedVersionNumber )
  • Next time you want to perform synchronization. Call this endpoint with parameter ?filter=lastModifiedVersionNumber gt {{YourVersionNumber}}
  • Only get employment information for employers that are included in that filtered list. (exclude all other employers as you already know there have been no changes since the last synchronization)
get/v2/providers/employers/lastmodifiedversionnumbers

Query parameters

filterstring
Example:cancellationPeriodTimeUnit.key eq 4

Filter the collection

orderBystring
Example:-companyName,address.houseNumber

Order the collection on one or more fields

pageNumberinteger
Example:2

Specifies which page should be returned

pageSizeinteger
Example:20

Specifies the number of objects per page

Headers

Authorizationstring required
Example:Bearer <TOKEN>

A valid Bearer token for authorizing the request.

Acceptstring required
Example:application/json;version=2018-01-01

The accept header is used to influence what type of output is returned and in most cases the version of the output

Response

OK