Skip to main content

Test Edge Cases

The previous section describes how to use the Prefer HTTP header to instruct the mock server on the type of data to return.

The following sections provide detailed information on how to test edge cases that are already documented in the Examples (examples) section of the contract.

Available examples​

Each endpoint has a list of static examples, and each example is identified by an unique name following a file path pattern.

You can find the examples in the documentation portal in the Response samples section:

Right hand side.

Example names' format​

Examples are grouped and identified as follows:

  1. Entity type to which the example belongs. Example: people.
  2. Scope of the example, which could be a specific action or common to some or all actions. Example: common, email-verification.
  3. Short example description in kebab-case format. Example: mixed-verification-responses.

For simplicity and standardisation, example names follow these rules:

  • All examples are written in lower case.
  • All sentences or groups of words are written in kebab case (kebab-case) format.
  • All segments are joined using a slash (/).
Example Header

Prefer: example=people/landline-verification/additional-request-props

Static responses​

Because examples are hardcoded scenarios, you cannot request dynamic data. Therefore, you'll always get the same JSON response for a given example name.

info

This is a known limitation of the system, but we encourage you to suggest how we might improve the provided examples so they also can be available in the mock server.