Making your first request

Now that you have been given access to the Api and are able to retrieve an authentication token, you are ready to make your first request! We'll start with the Programme Metadata endpoint which will show you which programmes you have access to, and what policy countries and policy types are available. We'll then use this information to create a basic incident and review the newly created incident in Claims Manager.

Environments

The Claims Manager Api staging and live details are shown below:

Environment Base Url
Staging https://api.claimsmanagertest.crawco.co.uk
Live https://api-op.claimsmanager.crawco.co.uk

The Staging environment is available to use while you are developing your integration. You are free to try out any the resources you have access to. The Live environment should only be used once you are ready to move into production.

The Staging environment is periodically refreshed with scrambled data from production. Be aware that you cannot rely on incidents you create in the staging environment being available indefinitely.

Collecting programme metadata

In order to create an incident, we first need to know the internal codes for the programme and policy type of the record we want to create. We can look these up using the metadata/programmes endpoint. By issuing a GET request to this endpoint, we will be presented with the available programmes, policy countries and policy types.

curl --location --request GET 'https://api.claimsmanagertest.crawco.co.uk/metadata/Programmes' \
--header 'Authorization: Bearer {access token}'

Remember to replace the placeholder {access token} with your actual token given to you by the authentication endpoint. See Getting Started for a reminder about how to do this.

The programmes metadata endpoint will return a list of programmes you have access to, along with which policy types and policy countries are available in each case as shown below:

[
    {
        "code": "8ffd4f55",
        "name": "Demonstration Programme",
        "policyTypes": [
            {
                "name": "Motor",
                "code": "17ed9895",
                "countries": ["AF", "AT", "BE", "CN", "CZ", "DE", "SI", "IT", "LU", "NL", "PL", "RO", "SE", "DK", "ES", "FI", "FR", "GB", "IN"]
            },
            {
                "name": "Property and Business Interruption",
                "code": "76ecdf6d",
                "countries": ["RO", "SE", "SI", "GB", "IN", "IT", "LU", "NL", "PL", "CZ", "DE", "DK", "ES", "FI", "FR", "AF", "AT", "BE", "CN"]
            },
            {
                "name": "General Liability (Public)",
                "code": "a4aee5d3",
                "countries": ["SE", "SI", "IN", "IT", "LU", "NL", "PL", "RO", "DE", "DK", "ES", "FI", "FR", "GB", "AF", "AT", "BE", "CN", "CZ"]
            }
        ]
    },
    {
        "code": "887efa06",
        "name": "Demonstration Programme 2",
        "policyTypes": [
            {
                "name": "Motor",
                "code": "17ed9895",
                "countries": ["AT", "BE", "CZ", "DE", "DK", "ES", "PL", "RO", "SE", "SI", "FI", "FR", "GB", "IT", "LU", "NL"]
            },
            {
                "name": "Property and Business Interruption",
                "code": "76ecdf6d",
                "countries": ["LU", "NL", "PL", "RO", "SE", "SI", "DK", "ES", "FI", "FR", "GB", "IT", "AT", "BE", "CZ", "DE"]
            },
            {
                "name": "General Liability (Public)",
                "code": "a4aee5d3",
                "countries": ["SE", "SI", "GB", "IT", "LU", "NL", "PL", "RO", "CZ", "DE", "DK", "ES", "FI", "FR", "AT", "BE"]
            }
        ]
    },
    {
        "code": "11041c05",
        "name": "Demonstration Programme (UK Property)",
        "policyTypes": [
            {
                "name": "Property and Business Interruption",
                "code": "9319a04a",
                "countries": ["GB"]
            },
            {
                "name": "Contractors All Risks",
                "code": "953e01a6",
                "countries": ["GB"]
            },
            {
                "name": "General Liability (Public)",
                "code": "b4d86084",
                "countries": ["GB"]
            }
        ]
    },
    {
        "code": "c76f374f",
        "name": "Demonstration Programme (Travel)",
        "policyTypes": [
            {
                "name": "Accident and Health / Travel",
                "code": "74b38a6b",
                "countries": ["AU", "BE", "DE", "ES", "GB", "SG"]
            }
        ]
    }
]

For the purposes of this tutorial, we will add a Motor incident against the Demonstration Programme with a policy country of GB. Looking at the response above, we can see that the code for the Demonstration Programme is 8ffd4f55 and the code for the policy type of Motor is 17ed9895. We will make a note of these as we will need them when creating the incident in the next step.

These codes are static once the programme has been created in Claims Manager, and persist across environments so the same codes will be in use in Staging and Live. You can hard-code these reference codes into your application if desired.