Skip to main content

Simulator

The Simulator is a tool in the eID Hub to test an authentication process without the need to add or activate any eID in your account.

The Simulator acts as an identity provider simulator to return sample responses that help you understand the user attributes that apply to a specific eID.

We recommend using the Simulator when:

  • You want to test an eID before it becomes active in your account; for example, when you are waiting for a certificate.
  • There exists no test credentials for a given eID.
  • You want a flexible solution to customise the user attributes returned from authentication.
  • You want to test a connection with an authentication protocol without depending on a specific eID.
Notes
  • The Simulator works both with and without using a connection with an authentication protocol.
  • The Simulator is only available for use in a sandbox account.

How it works

The Simulator is a flexible tool that lets you test and prepare for your integration in a self-contained environment.

When using the Simulator, you mock an authentication process without connecting directly to an eID. Nonetheless, you can customise and review the user attributes that you would normally receive after a successful authentication. You don't need any test credentials or to activate any eID in your account.

When you add the Simulator to your sandbox account, it becomes available for testing like any other eID:

Simulator available as an eID in a sandbox account.

Simulator available as an eID in a sandbox account.

Data quality

The Simulator provides only a limited sample of user attributes. Use it as a testing tool to support your development, rather than a definitive source of truth.

Get started

To use the Simulator, you must first add it in your Signicat account.

Which eIDs does the Simulator support?

The Simulator is currently available for a portion of the eIDs in the eID Hub.

We are in the process of adding support for more eIDs, and will eventually roll out support for all.

Prerequisites

If you don't have an account already, sign up for a free Signicat account by completing the following initial preparations:

  1. Sign up to the Signicat Dashboard and register your profile. For more details, see the Get started with Signicat guide.
  2. In the Dashboard, make sure you have set up an organisation and an account.
  3. Additionally, to use this product, you must set up a domain.
Accounts: Test in sandbox, go live in production

We recommend you create a sandbox account to test our services before going live. Sandbox and production accounts must be set up separately.

Domains and eIDs

For the scope of this guide, you can use a standard Signicat domain.


However, note that certain eIDs may require additional security measures, such as the use of digital SSL certificates and custom domains. You find more details in the specific documentation for the eID.

Add the Simulator

Before you can start testing, add the Simulator by following these steps:

  1. In the Dashboard, navigate to Products > eID Hub > eIDs.
  2. Select + Add new in the top-right corner.
  3. Select Simulator from the list of supported eIDs.
  4. On the Simulator configuration page, set the following:
    • Name: The name of the Simulator (required).
    • Include only when scoped: If ticked, the Simulator is available for authentication only when you pass Simulator in the query parameter of your request. Scoping varies per authentication protocol. Learn more in the Scoping the Simulator section (optional).
    • Select attribute filter: Allows you to use an attribute filter (optional).
    • Response attribute mappings: Maps attributes to keys that you define (optional).
  5. Select Add to activate the Simulator.

Here is how the configuration page looks like:

How to configure the Simulator.

How to configure the Simulator.

Now, you can choose the Simulator as an eID for testing.

Start testing

You can run tests using the Simulator in three ways:

  1. Test with eIDs
  2. Test with custom provider
  3. Test protocol connections

Test with eIDs

Imagine a scenario where you want to implement Swedish BankID in your application. Before starting the integration, you want to test it but you don't have any credentials. Instead, you can test Swedish BankID with the Simulator, by doing this:

  1. In the Dashboard, navigate to Products > eID Hub > eIDs.
  2. Select Test eIDs in the top right.
  3. Choose the Simulator from the list of available providers. The name of the Simulator depends on your configuration.
  4. In the next step, choose Swedish BankID.
  5. Optional. Edit the data to suit your needs. Then, select Send to send the request.
  6. Review the user data attributes in the response.

Here is how the steps look like in the Dashboard:

Test with custom provider

To test an authentication process without any particular eID, you can choose a custom provider.

To do this:

  1. In the Dashboard, navigate to Products > eID Hub > eIDs.
  2. Select Test eIDs in the top right.
  3. Choose the Simulator from the list of available providers. The name of the Simulator depends on your configuration.
  4. In the next step, choose Custom.
  5. Edit the data according to your needs. Then, select Send to send the request.
  6. Review the user data attributes in the response.

Test protocol connections

A notable scenario to use the Simulator is when you are building the integration and want to test a connection after you set up an authentication protocol. We support OpenID Connect (OIDC), SAML 2.0 and the Signicat Authentication REST API.

When you navigate to the authorisation URL you built with an authentication protocol, you can choose the Simulator as an identity provider in the provider selection screen.

For example, an authorisation (URL) request using OIDC might look like this:

https://<YOUR_SIGNICAT_DOMAIN>/auth/open/connect/authorize?
&client_id=<OIDC_CLIENT_ID>
&response_type=<GRANT_TYPE_CODE>
&redirect_uri=<REDIRECT_URI>
&scope=openid%20profile
&state=<STATE>
&code_challenge=ABC123
&code_challenge_method=S256

To skip the selection screen and route directly to the Simulator UI, you can scope the Simulator.

Scoping the Simulator

To bypass the selection screen with the different protocols, use the following query parameters in your authorisation request:

Note

Scoping also works when you enable the Include only when scoped setting, as explained in the Add the Simulator section above.

Scoping request examples

To automatically test the Simulator with OIDC, define acr_values=idp:simulator in your authorisation request:

https://<YOUR_SIGNICAT_DOMAIN>/auth/open/connect/authorize?
&client_id=<OIDC_CLIENT_ID>
&response_type=<GRANT_TYPE_CODE>
&redirect_uri=<REDIRECT_URI>
&scope=openid%20profile
&state=<STATE>
&code_challenge=ABC123
&code_challenge_method=S256
&acr_values=idp:simulator