
Research
/Security News
Shai Hulud Strikes Again (v2)
Another wave of Shai-Hulud campaign has hit npm with more than 500 packages and 700+ versions affected.
@govflanders/mbp-embed-sdk
Advanced tools
Library to integrate designated pages into Mijn Burgerprofiel (App and Web).
@govflanders/mbp-embed-sdk - a javascript library designed to integrate designated pages into Mijn Burgerprofiel.
βΉοΈ TIP:
The preferred way to read this is on our documentation site.
That way, you are working with the most recent version, and you get additional information (like generated type definitions).
Digitaal Vlaanderen provides and hosts 'Mijn Burgerprofiel' applications, both for the Flemish government and local municipalities. Citizens either download a mobile app or log in to burgerprofiel.be.
There are a lot of external data sources and functionality that would be useful to include in those applications. Historically, this meant either linking to external pages, or custom development to build API's and integrate that external content. A more flexible approach would be to embed externally hosted content directly by using either iframes (for web aplications), or webviews (for native apps).
To enable this efficiently and securely, @govflanders/mbp-embed-sdk was created.
It defines an official interface to embed your content in Mijn Burgerprofiel applications (and interact with them).
ββββββββββββ βββββββββββββββββ βββββββββββββββββ
β Host β β Embedded Page β β mbp-embed-sdk β
ββββββ¬ββββββ βββββββββ¬ββββββββ βββββββββ¬ββββββββ
ββββββ β β
β β Listens for connections β β
β β [status = loading] β β
ββββββ β β
β Load page β createMbpEmbedClient(id) β
βββββββββββββββββββββββββββββββββΊβββββββββββββββββββββββββββββββββΊβ
β ββββββββββββββββββββββββββββββββββ€
β β β
β β connect() β
β βββββββββββββββββββββββββββββββββΊβ
β <connection request> β β
ββ----------------------------------------------------------------β€
β----β β β
β β Validate connection β β
ββ---β β <connection response> β
β----------------------------------------------------------------βΊβ
β β ββββββ€
β β Validate connection β β
β β βββββΊβ
β β success | exception β
β ββββββββββββββββββββββββββββββββββ€
β β β
β β setStatusLoading(false) β
β βββββββββββββββββββββββββββββββββΊβ
β <status request> β β
ββ----------------------------------------------------------------β€
ββββββ β β
β β Show embedded page β β
β β [status = ready] β β
ββββββ β <status updated> β
β----------------------------------------------------------------βΊβ
β ββββββββββββββββββββββββββββββββββ€
β β β
To get started, you need to go through a short onboarding process with Digitaal Vlaanderen.
Contact Mijn Burgerprofiel aansluitingen with the following details:
Once the integration has been approved, you will receive a client ID to use with the SDK.
You can install the library from npm (it's publicly available):
npm install @govflanders/mbp-embed-sdk
Next, import the library and create a client in your project:
import { createMbpEmbedClient } from '@govflanders/mbp-embed-sdk';
const mbpClient = createMbpEmbedClient('your-client-id', {
allowedHosts: [
'https://*.burgerprofiel.be/*',
'https://admin.vlaanderen.be/*',
],
});
Then, connect the client to the host environment (this is an asynchronous
operation, so either use await or .then()):
try {
await mbpClient.connect();
console.log('Connection successful!');
} catch (e) {
console.error('Failed to connect:', e);
}
When using the library in a standalone page, the client will time out after a while because there is no host environment to connect to.
To check if everything works correctly, you can use our embed preview tool.
βΉοΈ NOTE:
For detailed usage, it's best to consult the official API documentation.
It is generated automatically based on the most recent version of the library.
Examples below are simplified and may not cover all available functionality.
// Set the title
mbpClient.ui.setTitle('Mijn loket');
// Set loading status
mbpClient.ui.setStatusLoading(true);
setTimeout(() => {
mbpClient.ui.setStatusLoading(false);
}, 1000);
// Set error status
mbpClient.ui.setStatusError({
title: 'Oops',
message: 'We are experiencing some problems, try again later!',
});
And more, see API documentation.
// Make sure user confirms before leaving embed page
mbpClient.navigation.enableExitConfirmation({
title: 'Are you sure?',
message: 'There are unsaved changes - you will lose them!',
});
// Navigate back
mbpClient.navigation.back();
// Open a new embed
mbpClient.navigation.openNewEmbed('https://my-embed-url.local/new-page');
// Open an external link
mbpClient.navigation.openExternal('https://www.vlaanderen.be');
And more, see API documentation.
// Get tenant information
const tenant = await mbpClient.context.getTenant();
console.log(tenant.branding.primaryColor); // '#0070c0', for example
// In cases where user was directed from a specific product/context, you can retrieve that information.
const ipdcProduct = await mbpClient.context.getIpdcProduct();
console.log(ipdcProduct.title); // 'Jobbonus voor werknemers en ambtenaren', for example
And more, see API documentation.
This library is managed and developed internally by Digitaal Vlaanderen. For technical questions, feedback or suggestions: please contact Mijn Burgerprofiel App team.
Internal developers can consult CONTRIBUTING.md for details on getting things set up.
FAQs
Library to integrate designated pages into Mijn Burgerprofiel (App and Web).
The npm package @govflanders/mbp-embed-sdk receives a total of 42 weekly downloads. As such, @govflanders/mbp-embed-sdk popularity was classified as not popular.
We found that @govflanders/mbp-embed-sdk demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago.Β It has 20 open source maintainers collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Research
/Security News
Another wave of Shai-Hulud campaign has hit npm with more than 500 packages and 700+ versions affected.

Product
Add real-time Socket webhook events to your workflows to automatically receive software supply chain alert changes in real time.

Security News
ENISA has become a CVE Program Root, giving the EU a central authority for coordinating vulnerability reporting, disclosure, and cross-border response.