> For the complete documentation index, see [llms.txt](https://swallow-1.gitbook.io/swallow/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://swallow-1.gitbook.io/swallow/developer-api/endpoints/tests.md).

# /tests

**Retrieve tests**

{% openapi src="/files/GZ3sFFmV6e4LBseKKPkK" path="/sw/tests/{version\_reference}" method="get" %}
[openapi\_5.json](https://1110149073-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fu89vYHjuY9Vj4vhZX5IZ%2Fuploads%2FHq1XfYRcYOI2opkc1T2i%2Fopenapi_5.json?alt=media\&token=0660dd0c-e092-481e-82ed-71adc8066362)
{% endopenapi %}

Tests for any Swallow pricing project version can be downloaded in bulk for either offline analysis or to run through other CI/CD systems.

<pre><code><strong>{
</strong><strong>    tests : [
</strong><strong>        ...,
</strong>        {
            "id": "jeowtsmk",
            "mocks": {},
            "name": "SL59KXV - Young but experienced in London",
            "key": "sl59kxv_young_but_experienced_in_london",
            "result": {
                "vehicle_make": "NISSAN",
                "vehicle_colour": "RED",
                "vehicle_fuel": "PETROL",
                "vehicle_engine_capacity": "1386",
                "vehicle_manufacture_year": "2009",
                "premium_tax": 56.64,
                "premium_commission": 59.1,
                "result": 509.72,
                "valid": false
            },
            "output": {
                "result": 509.72,
                "valid": false
            },
            "input": {
                "vehicle_reg": "SL59KXV",
                "vehicle_ncd": 6,
                "proposer_dob": "2000-01-01",
                "proposer_postcode": "W53TR",
                "additional_drivers_count": 0
            }
        },
        ...
    ]
}
</code></pre>

The ***result*** is what the Swallow pricing project calculates. The ***output*** is what is expected (this might be generated via offline Excel rater or other pricing tools).  If the ***resul*****t** and ***output*** match, then the project is pricing as expected.

There can be thousands of tests stored against each project version.&#x20;

**Offline pricing analysis**

Tests are stored against each project version. This means you have a historic record of how the price has changed based on the test scenarios. You can use this movement to understand how pricing has changed over time.

First fetch all project versions via:

```
https://api.llow.io/sw/projects/versions?project_reference=56c575d2-b6b9-44ed-9c75-5d705b987ec1
```

then hit the test endpoint to return all the test cases per project

```
https://api.llow.io/sw/tests/16c575d2-b6b9-44ed-9c75-5d705b987ec1
https://api.llow.io/sw/tests/26c575d2-b6b9-44ed-9c75-5d705b987ec1
https://api.llow.io/sw/tests/36c575d2-b6b9-44ed-9c75-5d705b987ec1
https://api.llow.io/sw/tests/46c575d2-b6b9-44ed-9c75-5d705b987ec1
```

You will now have all the information needed to plot pricing changes over time and even pivot via input values.

**Running tests**

There is no endpoint to run tests as this is all done in the browser. This means the tests must be first run within the platform via the UI as part of the project version changes.
