Context switching

easily switch endpoints, apikeys, usernames...

Mainly important when using apiUi as driver (outbound operations).
A context is a set of properties that together address your system under test. A context may include endpoints, username/passwords database connection strings and even data in message candidates.

By context-switching you can quickly change these properties saving you time and reducing the chance of mistakes.

Enable context-switching for your project by including alias names in relevant properties.

Format of an alias name:


apiUi resolves alias names always at the latest possible moment so you can even assign a value from script containing an alias name. For data in requests, you can switch resolving of aliases on and off at operation level.

The contexts screen

Get to this screen by Project->Context properies (Shift+Cntrl+C)
A row will contain a context; a column an alias name.

Add a context

You can add a context by clicking on the first icon and give your context a name. A new row will appear with the name you specified.

Add an alias name

You can add an alias name by clicking on the second icon and enter the name. A new column will appear with the name you specified.

An example

Below you see two contexts with three aliases and you can see that the currently chosen context is dt2.

Suppose that you have a database connection string filled with dbs://crm/${database}/data and context dt2. With this configuration the database connection string will resolve to dbs://crm/dbsdt2/data.