NAV
bash javascript

Info

The PreciseFP API is organized around REST. It's designed with resource-oriented URLs, and uses HTTP codes to indicate success and error responses. We use standard HTTP features, like HTTP authentication and HTTP verbs, which are understood by off-the-shelf HTTP clients. JSON is returned by all API responses, including errors.

To use our API, please contact us to register your application and receive your client credentials.

Authorization

PreciseFP uses oAuth 2.0 for authorization.

Authorization URL

https://app.precisefp.com/oauth/authorize

Token refresh URL

https://app.precisefp.com/oauth/token

Authorization header

All API request requiring authentication must include an authorization header.

Authorization: Bearer {token}

You must replace {token} with the access token received from the oAuth flow.

Accounts

List accounts

Returns a collection of accounts.


Requires authentication

Example request:

curl -X GET -G "https://app.precisefp.com/api/v2/accounts" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://app.precisefp.com/api/v2/accounts");

    let params = {
            "sort": "fhhjHZlbpypZNwf8",
            "limit": "jaJuIGC5t58RfIef",
            "offset": "V1w2xmYmcbzwtzPQ",
            "query": "rbBwNrfDJbsK0ktr",
            "type": "6",
            "pipeline": "R0E7TSXoP6sdtV56",
        };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "items": [
        {
            "id": 1910,
            "type": "CLIENT",
            "client": {
                "id": 2455,
                "first_name": "John",
                "last_name": "Doe",
                "email": "johndoe@precisefp.com",
                "phone": {
                    "code": "+1",
                    "number": "4155552671",
                    "country": "US"
                },
                "status": "NEW",
                "pin": "70392378"
            },
            "coclient": {
                "id": 2456,
                "first_name": "Jane",
                "last_name": "Doe",
                "email": "janedoe@precisefp.com",
                "phone": {
                    "country": null,
                    "code": null,
                    "number": null
                },
                "status": "NEW",
                "pin": "80182751"
            },
            "quality": {
                "score": 35,
                "rules": [
                    {
                        "message": "Email specified",
                        "valid": true
                    },
                    {
                        "message": "Birthdate not specified",
                        "valid": false
                    },
                    {
                        "message": "Risk score not specified",
                        "valid": false
                    },
                    {
                        "message": "Financial goals specified",
                        "valid": true
                    },
                    {
                        "message": "Mobile phone not specified (Coclient Example)",
                        "valid": false
                    },
                    {
                        "message": "Income information specified",
                        "valid": true
                    },
                    {
                        "message": "Fixed expenses not specified",
                        "valid": false
                    },
                    {
                        "message": "Variable expenses not specified",
                        "valid": false
                    },
                    {
                        "message": "Tax related expenses not specified",
                        "valid": false
                    },
                    {
                        "message": "Insurance information not specified",
                        "valid": false
                    },
                    {
                        "message": "Retirement plan information not specified",
                        "valid": false
                    },
                    {
                        "message": "Asset information not specified",
                        "valid": false
                    },
                    {
                        "message": "Liability information not specified",
                        "valid": false
                    },
                    {
                        "message": "Estate planning information not specified",
                        "valid": false
                    }
                ]
            },
            "pipeline": {
                "id": "33e1d4b2-7243-4028-ad67-9bf4c171b057",
                "icon": "i_user_tag",
                "title": "Onboard1",
                "description": "Gather the information required to understand your client's wants and needs."
            },
            "favorited": false,
            "archived": false,
            "created_at": "2018-11-28 09:33:32",
            "updated_at": "2018-11-28 09:33:33"
        }
    ],
    "params": {
        "limit": 50,
        "offset": 2,
        "sort": "-created_at",
        "total": 1
    }
}

HTTP Request

GET api/v2/accounts

Query Parameters

Parameter Status Description
sort optional Sorts list by this parameter. Prefix the parameter with - (dash) to sort descendingly. Allowed values: type, quality, pipeline, favorited, archived, created_at, updated_at, client.first_name, client.last_name, client.email, coclient.first_name, coclient.last_name, coclient.email. Defaults to -created_at.
limit optional Limits the results by this parameter. Defaults to 50.
offset optional Returns results starting from this parameter. Defaults to 0.
query optional Returns results where the client and/or coclient first_name, last_name and/or email start with this parameter.
type optional Filters results by this parameter. Allowed values: client, prospect, favorite, archived, all. If not sent, archived accounts will not be included.
pipeline optional Filters results by pipeline id. List of available pipelines is returned along with the authenticated user.

Create account

Creates a new account record.


Requires authentication

Example request:

curl -X POST "https://app.precisefp.com/api/v2/accounts" \
    -H "Authorization: Bearer {token}" \
    -d "type"="CLIENT" \
    -d "client.first_name"="John" \
    -d "client.last_name"="Doe" \
    -d "client.email"="johndoe@precisefp.com" \
    -d "client.phone.code"="+1" \
    -d "client.phone.number"="4155552671" \
    -d "client.phone.country"="us" \
    -d "coclient.first_name"="Jane" \
    -d "coclient.last_name"="Doe" \
    -d "coclient.email"="janedoe@precisefp.com" \
    -d "coclient.phone.code"="+1" \
    -d "coclient.phone.number"="4155552672" \
    -d "coclient.phone.country"="us" 
const url = new URL("https://app.precisefp.com/api/v2/accounts");

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

let body = JSON.stringify({
    "type": "CLIENT",
    "client.first_name": "John",
    "client.last_name": "Doe",
    "client.email": "johndoe@precisefp.com",
    "client.phone.code": "+1",
    "client.phone.number": "4155552671",
    "client.phone.country": "us",
    "coclient.first_name": "Jane",
    "coclient.last_name": "Doe",
    "coclient.email": "janedoe@precisefp.com",
    "coclient.phone.code": "+1",
    "coclient.phone.number": "4155552672",
    "coclient.phone.country": "us",
})

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "id": 1910,
    "type": "CLIENT",
    "client": {
        "id": 2455,
        "first_name": "John",
        "last_name": "Doe",
        "email": "johndoe@precisefp.com",
        "phone": {
            "code": "+1",
            "number": "4155552671",
            "country": "US"
        },
        "status": "NEW",
        "pin": "70392378"
    },
    "coclient": {
        "id": 2456,
        "first_name": "Jane",
        "last_name": "Doe",
        "email": "janedoe@precisefp.com",
        "phone": {
            "country": null,
            "code": null,
            "number": null
        },
        "status": "NEW",
        "pin": "80182751"
    },
    "quality": {
        "score": 52,
        "rules": [
            {
                "message": "Email specified",
                "valid": true
            },
            {
                "message": "Birthdate not specified",
                "valid": true
            },
            {
                "message": "Risk score not specified",
                "valid": true
            },
            {
                "message": "Financial goals not specified",
                "valid": false
            },
            {
                "message": "Mobile phone specified",
                "valid": true
            },
            {
                "message": "Income information not specified",
                "valid": true
            },
            {
                "message": "Fixed expenses not specified",
                "valid": false
            },
            {
                "message": "Variable expenses not specified",
                "valid": false
            },
            {
                "message": "Tax related expenses not specified",
                "valid": false
            },
            {
                "message": "Insurance information not specified",
                "valid": false
            },
            {
                "message": "Retirement plan information not specified",
                "valid": false
            },
            {
                "message": "Asset information not specified",
                "valid": false
            },
            {
                "message": "Liability information not specified",
                "valid": false
            },
            {
                "message": "Estate planning information not specified",
                "valid": false
            }
        ]
    },
    "pipeline": {
        "id": "33e1d4b2-7243-4028-ad67-9bf4c171b057",
        "icon": "i_user_tag",
        "title": "Onboard1",
        "description": "Gather the information required to understand your client's wants and needs."
    },
    "favorited": false,
    "archived": false,
    "created_at": "2018-11-28 09:33:32",
    "updated_at": "2018-11-28 09:33:33"
}

HTTP Request

POST api/v2/accounts

Body Parameters

Parameter Type Status Description
type string required Account type. Allowed values: CLIENT, PROSPECT.
client.first_name string required First name of the new client.
client.last_name string required Last name of the new client.
client.email string required Email address of the new client.
client.phone.code string optional Country calling code.
client.phone.number string optional Phone number of the new client.
client.phone.country string optional Iso 3166-1 alpha-2 country code
coclient.first_name string optional First name of the coclient.
coclient.last_name string optional Last name of the coclient.
coclient.email string optional Email address of the coclient.
coclient.phone.code string optional Coclient phone number country code.
coclient.phone.number string optional Phone number of the new coclient.
coclient.phone.country string optional Iso 3166-1 alpha-2 country code

Get account

Returns one account record.


Requires authentication

Example request:

curl -X GET -G "https://app.precisefp.com/api/v2/accounts/{account}" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://app.precisefp.com/api/v2/accounts/{account}");

    let params = {
            "account": "3",
        };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "id": 1910,
    "type": "CLIENT",
    "client": {
        "id": 2455,
        "first_name": "John",
        "last_name": "Doe",
        "email": "johndoe@precisefp.com",
        "phone": {
            "code": "+1",
            "number": "4155552671",
            "country": "US"
        },
        "status": "NEW",
        "pin": "70392378"
    },
    "coclient": {
        "id": 2456,
        "first_name": "Jane",
        "last_name": "Doe",
        "email": "janedoe@precisefp.com",
        "phone": {
            "country": null,
            "code": null,
            "number": null
        },
        "status": "NEW",
        "pin": "80182751"
    },
    "quality": {
        "score": 52,
        "rules": [
            {
                "message": "Email specified",
                "valid": true
            },
            {
                "message": "Birthdate not specified",
                "valid": true
            },
            {
                "message": "Risk score not specified",
                "valid": true
            },
            {
                "message": "Financial goals not specified",
                "valid": false
            },
            {
                "message": "Mobile phone specified",
                "valid": true
            },
            {
                "message": "Income information not specified",
                "valid": true
            },
            {
                "message": "Fixed expenses not specified",
                "valid": false
            },
            {
                "message": "Variable expenses not specified",
                "valid": false
            },
            {
                "message": "Tax related expenses not specified",
                "valid": false
            },
            {
                "message": "Insurance information not specified",
                "valid": false
            },
            {
                "message": "Retirement plan information not specified",
                "valid": false
            },
            {
                "message": "Asset information not specified",
                "valid": false
            },
            {
                "message": "Liability information not specified",
                "valid": false
            },
            {
                "message": "Estate planning information not specified",
                "valid": false
            }
        ]
    },
    "pipeline": {
        "id": "33e1d4b2-7243-4028-ad67-9bf4c171b057",
        "icon": "i_user_tag",
        "title": "Onboard1",
        "description": "Gather the information required to understand your client's wants and needs."
    },
    "favorited": false,
    "archived": false,
    "created_at": "2018-11-28 09:33:32",
    "updated_at": "2018-11-28 09:33:33"
}

HTTP Request

GET api/v2/accounts/{account}

Query Parameters

Parameter Status Description
account required The account id.

Update account

Updates an account record.


Requires authentication

Example request:

curl -X POST "https://app.precisefp.com/api/v2/accounts/{account}" \
    -H "Authorization: Bearer {token}" \
    -d "type"="CLIENT" \
    -d "client.first_name"="John" \
    -d "client.last_name"="Doe" \
    -d "client.email"="johndoe@precisefp.com" \
    -d "client.phone.code"="+1" \
    -d "client.phone.number"="4155552671" \
    -d "client.phone.country"="us" \
    -d "coclient.first_name"="Jane" \
    -d "coclient.last_name"="Doe" \
    -d "coclient.email"="janedoe@precisefp.com" \
    -d "coclient.phone.code"="+1" \
    -d "coclient.phone.number"="4155552672" \
    -d "coclient.phone.country"="us" \
    -d "archived"="false" \
    -d "favorited"="false" \
    -d "pipeline.id"="33e1d4b2-7243-4028-ad67-9bf4c171b057" 
const url = new URL("https://app.precisefp.com/api/v2/accounts/{account}");

    let params = {
            "account": "1",
        };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

let body = JSON.stringify({
    "type": "CLIENT",
    "client.first_name": "John",
    "client.last_name": "Doe",
    "client.email": "johndoe@precisefp.com",
    "client.phone.code": "+1",
    "client.phone.number": "4155552671",
    "client.phone.country": "us",
    "coclient.first_name": "Jane",
    "coclient.last_name": "Doe",
    "coclient.email": "janedoe@precisefp.com",
    "coclient.phone.code": "+1",
    "coclient.phone.number": "4155552672",
    "coclient.phone.country": "us",
    "archived": "",
    "favorited": "",
    "pipeline.id": "33e1d4b2-7243-4028-ad67-9bf4c171b057",
})

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "id": 1910,
    "type": "CLIENT",
    "client": {
        "id": 2455,
        "first_name": "John",
        "last_name": "Doe",
        "email": "johndoe@precisefp.com",
        "phone": {
            "code": "+1",
            "number": "4155552671",
            "country": "US"
        },
        "status": "NEW",
        "pin": "70392378"
    },
    "coclient": {
        "id": 2456,
        "first_name": "Jane",
        "last_name": "Doe",
        "email": "janedoe@precisefp.com",
        "phone": {
            "country": null,
            "code": null,
            "number": null
        },
        "status": "NEW",
        "pin": "80182751"
    },
    "quality": {
        "score": 52,
        "rules": [
            {
                "message": "Email specified",
                "valid": true
            },
            {
                "message": "Birthdate not specified",
                "valid": true
            },
            {
                "message": "Risk score not specified",
                "valid": true
            },
            {
                "message": "Financial goals not specified",
                "valid": false
            },
            {
                "message": "Mobile phone specified",
                "valid": true
            },
            {
                "message": "Income information not specified",
                "valid": true
            },
            {
                "message": "Fixed expenses not specified",
                "valid": false
            },
            {
                "message": "Variable expenses not specified",
                "valid": false
            },
            {
                "message": "Tax related expenses not specified",
                "valid": false
            },
            {
                "message": "Insurance information not specified",
                "valid": false
            },
            {
                "message": "Retirement plan information not specified",
                "valid": false
            },
            {
                "message": "Asset information not specified",
                "valid": false
            },
            {
                "message": "Liability information not specified",
                "valid": false
            },
            {
                "message": "Estate planning information not specified",
                "valid": false
            }
        ]
    },
    "pipeline": {
        "id": "33e1d4b2-7243-4028-ad67-9bf4c171b057",
        "icon": "i_user_tag",
        "title": "Onboard1",
        "description": "Gather the information required to understand your client's wants and needs."
    },
    "favorited": false,
    "archived": false,
    "created_at": "2018-11-28 09:33:32",
    "updated_at": "2018-11-28 09:33:33"
}

HTTP Request

POST api/v2/accounts/{account}

Body Parameters

Parameter Type Status Description
type string required Account type. Allowed values: CLIENT, PROSPECT.
client.first_name string required First name of the new client.
client.last_name string required Last name of the new client.
client.email string required Email address of the new client.
client.phone.code string optional Country calling code.
client.phone.number string optional Phone number of the new client.
client.phone.country string optional Iso 3166-1 alpha-2 country code
coclient.first_name string optional First name of the coclient.
coclient.last_name string optional Last name of the coclient.
coclient.email string optional Email address of the coclient.
coclient.phone.code string optional Coclient phone number country code.
coclient.phone.number string optional Phone number of the new coclient.
coclient.phone.country string optional Iso 3166-1 alpha-2 country code
archived boolean optional Mark as archived.
favorited boolean optional Mark as favorite.
pipeline.id string optional Update Client's pipeline stage. List of available pipelines is returned along with the authenticated user.

Query Parameters

Parameter Status Description
account required The account id.

Delete account

Deletes an account record.


Requires authentication

Example request:

curl -X DELETE "https://app.precisefp.com/api/v2/accounts/{account}" \
    -H "Authorization: Bearer {token}" \
    -d "password"="vyZyRQ3V4HW53Rtb" 
const url = new URL("https://app.precisefp.com/api/v2/accounts/{account}");

    let params = {
            "account": "15",
        };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

let body = JSON.stringify({
    "password": "vyZyRQ3V4HW53Rtb",
})

fetch(url, {
    method: "DELETE",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

DELETE api/v2/accounts/{account}

Body Parameters

Parameter Type Status Description
password string required For security reasons, the password of the authenticated user is verified on all delete operations.

Query Parameters

Parameter Status Description
account required The account id.

Get profile

Returns an account's profile data.


Requires authentication

Example request:

curl -X GET -G "https://app.precisefp.com/api/v2/accounts/{account}/profile" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://app.precisefp.com/api/v2/accounts/{account}/profile");

    let params = {
            "account": "3",
        };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

[
    {
        "id": "a76d13ce-9027-4152-b442-fdafa52c0184",
        "dataset_id": "ffca48cd-45ae-4695-9388-c10aa99f13e8",
        "member_id": 1013,
        "row_id": "594eba61-9b92-447c-bf0a-7291b7115aaf",
        "type": "STRING",
        "value": "Jane"
    },
    {
        "id": "8fd41dcc-559e-4b67-b06a-417c03faf415",
        "dataset_id": "a09c63ec-b551-4c98-9214-7f5210c7d54d",
        "member_id": 1013,
        "row_id": "594eba61-9b92-447c-bf0a-7291b7115aaf",
        "type": "STRING",
        "value": "Jane  Doe"
    },
    {
        "id": "7bd8b06a-db04-4ead-997c-82df730cb50c",
        "dataset_id": "90cc0d96-1c41-483a-aeba-5dcbff12f3e7",
        "member_id": 1013,
        "row_id": "594eba61-9b92-447c-bf0a-7291b7115aaf",
        "type": "STRING",
        "value": "Doe"
    }
]

HTTP Request

GET api/v2/accounts/{account}/profile

Query Parameters

Parameter Status Description
account required The account id.

Get activity

Returns an account's activity timeline.


Requires authentication

Example request:

curl -X GET -G "https://app.precisefp.com/api/v2/accounts/{account}/activity" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://app.precisefp.com/api/v2/accounts/{account}/activity");

    let params = {
            "account": "13",
            "sort": "xS9NOySf6pILkQuU",
            "limit": "Fg0qGT1VoK7s0GC9",
            "offset": "i5nNLctu19dScQnP",
            "type": "PjGRSIHZrbIXc6Fq",
        };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "items": [
        {
            "id": 34891,
            "type": "engagement.created",
            "icon": "i_engagement_plus",
            "description": "John Doe was engaged with the \"Quick Fact Finder\" template",
            "options": {
                "author": "James Brown",
                "template": "Quick Fact Finder",
                "name": "John Doe"
            },
            "created_at": "2018-11-28 09:39:34"
        },
        {
            "id": 34884,
            "type": "engagement.created",
            "icon": "i_engagement_plus",
            "description": "Sample Coclient was engaged with the \"Quick Fact Finder\" template",
            "options": {
                "author": "Jane Doe",
                "template": "Financial Fact Finder",
                "name": "James Brown"
            },
            "created_at": "2018-11-27 13:45:57"
        }
    ]
}

HTTP Request

GET api/v2/accounts/{account}/activity

Query Parameters

Parameter Status Description
account required The account id.
sort optional Sorts list by this parameter. Prefix the parameter with - (dash) to sort descendingly. Allowed values: type, created_at. Defaults to -created_at.
limit optional Limits the results by this parameter. Defaults to 50.
offset optional Returns results starting from this parameter. Defaults to 0.
type optional Filters results by type. List of activity types is available in get activities.

Get document

Returns an account's document file.


Requires authentication

Example request:

curl -X GET -G "https://app.precisefp.com/api/v2/accounts/{account}/file/document/{element}/{index}/{name}" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://app.precisefp.com/api/v2/accounts/{account}/file/document/{element}/{index}/{name}");

    let params = {
            "account": "7",
            "element": "1i1RiWZUKj5u7WRY",
            "index": "sGRTJYgWRWRBG9yG",
            "name": "TUQ7RkrJQ4EguPUa",
        };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

"file content"

HTTP Request

GET api/v2/accounts/{account}/file/document/{element}/{index}/{name}

Query Parameters

Parameter Status Description
account required The account id.
element required The element id.
index required The element index.
name required The file name.

Get image

Returns an account's image file.


Requires authentication

Example request:

curl -X GET -G "https://app.precisefp.com/api/v2/accounts/{account}/file/image/{element}/{name}" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://app.precisefp.com/api/v2/accounts/{account}/file/image/{element}/{name}");

    let params = {
            "account": "12",
            "element": "EKARJEVucThjgXqA",
            "name": "DtAyBzGMh9aChhTE",
        };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

"file content"

HTTP Request

GET api/v2/accounts/{account}/file/image/{element}/{name}

Query Parameters

Parameter Status Description
account required The account id.
element required The element id.
name required The file name.

Config

Get icons

Returns a collection with all possible icon names. Use this list to ensure your application supports the icons returned by the API.


Requires authentication

Example request:

curl -X GET -G "https://app.precisefp.com/api/v2/config/icons" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://app.precisefp.com/api/v2/config/icons");

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

[
    "i_archive",
    "i_award",
    "i_badge",
    "i_building",
    "i_bullseye",
    "i_child",
    "i_coins",
    "i_comments",
    "i_crown",
    "i_diamond",
    "i_dollar",
    "i_download",
    "i_engagement_check",
    "i_engagement_minus",
    "i_engagement_plus",
    "i_engagement_shield",
    "i_engagement_tag",
    "i_envelope",
    "i_female",
    "i_globe",
    "i_heart",
    "i_lightbulb",
    "i_male",
    "i_medal",
    "i_money",
    "i_pen",
    "i_search",
    "i_spade",
    "i_star",
    "i_umbrella",
    "i_upload",
    "i_user",
    "i_user_check",
    "i_user_clock",
    "i_user_cog",
    "i_user_friends",
    "i_user_graduate",
    "i_user_lock",
    "i_user_minus",
    "i_user_plus",
    "i_user_shield",
    "i_user_slash",
    "i_user_tag",
    "i_user_tie",
    "i_user_times",
    "i_users",
    "i_users_cog"
]

HTTP Request

GET api/v2/config/icons

Get activities

Returns a collection with all possible activities. Use this list to ensure your application supports all activities returned by the API.


Requires authentication

Example request:

curl -X GET -G "https://app.precisefp.com/api/v2/config/activities" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://app.precisefp.com/api/v2/config/activities");

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "account.created": {
        "icon": "i_user_plus",
        "options": [
            "author",
            "type",
            "name"
        ]
    },
    "account.updated": {
        "icon": "i_user_check",
        "options": [
            "author",
            "name"
        ]
    }
}

HTTP Request

GET api/v2/config/activities

Get dataset

Returns all panels, groups and elements that constitute the dataset. Use this to ensure your application shows a correct account profile.


Requires authentication

Example request:

curl -X GET -G "https://app.precisefp.com/api/v2/config/dataset/{mode?}/{type?}" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://app.precisefp.com/api/v2/config/dataset/{mode?}/{type?}");

    let params = {
            "mode": "a4r2jOOpHWz5Qwgm",
        };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "panels": [
        {
            "id": "8e5a59dd-c6ff-49b0-ac53-bff092d548b8",
            "type": "INDIVIDUAL",
            "title": "Client Details",
            "description": null,
            "position": 0
        },
        {
            "id": "caf092c2-3ee9-4adf-bf37-c8d3796a8e2e",
            "type": "INDIVIDUAL",
            "title": "Employment & Income",
            "description": "",
            "position": 1
        },
        {
            "id": "9d8e393c-b131-4357-be98-48bdfd75a4ef",
            "type": "ACCOUNT",
            "title": "Family Members",
            "description": "",
            "position": 2
        }
    ],
    "groups": [
        {
            "id": "94229e22-0f87-4bb4-877e-cb133ef883bd",
            "panel_id": "8e5a59dd-c6ff-49b0-ac53-bff092d548b8",
            "type": "SINGLE",
            "title": "Personal Details",
            "description": null,
            "position": 0
        },
        {
            "id": "d979e0fc-3dfa-4ed2-a1e1-2825551252d0",
            "panel_id": "8e5a59dd-c6ff-49b0-ac53-bff092d548b8",
            "type": "SINGLE",
            "title": "Contact Details",
            "description": null,
            "position": 1
        },
        {
            "id": "233f3709-46c9-4e3f-b1fb-1150a4c02f87",
            "panel_id": "8e5a59dd-c6ff-49b0-ac53-bff092d548b8",
            "type": "SINGLE",
            "title": "Driver's License",
            "description": "",
            "position": 2
        }
    ],
    "elements": [
        {
            "id": "a09c63ec-b551-4c98-9214-7f5210c7d54d",
            "group_id": "94229e22-0f87-4bb4-877e-cb133ef883bd",
            "type": "STRING",
            "title": "Full Name",
            "description": "",
            "size": 100,
            "position": "0,0"
        },
        {
            "id": "ffca48cd-45ae-4695-9388-c10aa99f13e8",
            "group_id": "94229e22-0f87-4bb4-877e-cb133ef883bd",
            "type": "STRING",
            "title": "First Name",
            "description": null,
            "size": 25,
            "position": "0,1"
        },
        {
            "id": "af4f22e0-f9de-47cd-9153-97fb8d58f506",
            "group_id": "94229e22-0f87-4bb4-877e-cb133ef883bd",
            "type": "STRING",
            "title": "Middle Initial",
            "description": null,
            "size": 25,
            "position": "1,1"
        }
    ]
}

HTTP Request

GET api/v2/config/dataset/{mode?}/{type?}

Query Parameters

Parameter Status Description
mode optional How the dataset will be returned. flat will return single level collections of panels, groups and elements. nested will return a collection of panels with related groups nested on each panel and related elements nested on each group. Defaults to "flat".

Get template

Returns all panels, groups and elements that constitute the template. Use this to ensure your application handles all possible elements of an engagement.


Requires authentication

Example request:

curl -X GET -G "https://app.precisefp.com/api/v2/config/template/{template}/{mode?}" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://app.precisefp.com/api/v2/config/template/{template}/{mode?}");

    let params = {
            "template": "3EHO1nDutdCpsclu",
            "mode": "qh7sx0IXT8uo0B2x",
        };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "panels": [
        {
            "id": "8e5a59dd-c6ff-49b0-ac53-bff092d548b8",
            "type": "INDIVIDUAL",
            "title": "Client Details",
            "description": null,
            "position": 0
        },
        {
            "id": "caf092c2-3ee9-4adf-bf37-c8d3796a8e2e",
            "type": "INDIVIDUAL",
            "title": "Employment & Income",
            "description": "",
            "position": 1
        },
        {
            "id": "9d8e393c-b131-4357-be98-48bdfd75a4ef",
            "type": "ACCOUNT",
            "title": "Family Members",
            "description": "",
            "position": 2
        }
    ],
    "groups": [
        {
            "id": "94229e22-0f87-4bb4-877e-cb133ef883bd",
            "panel_id": "8e5a59dd-c6ff-49b0-ac53-bff092d548b8",
            "type": "SINGLE",
            "title": "Personal Details",
            "description": null,
            "position": 0
        },
        {
            "id": "d979e0fc-3dfa-4ed2-a1e1-2825551252d0",
            "panel_id": "8e5a59dd-c6ff-49b0-ac53-bff092d548b8",
            "type": "SINGLE",
            "title": "Contact Details",
            "description": null,
            "position": 1
        },
        {
            "id": "233f3709-46c9-4e3f-b1fb-1150a4c02f87",
            "panel_id": "8e5a59dd-c6ff-49b0-ac53-bff092d548b8",
            "type": "SINGLE",
            "title": "Driver's License",
            "description": "",
            "position": 2
        }
    ],
    "elements": [
        {
            "id": "a09c63ec-b551-4c98-9214-7f5210c7d54d",
            "group_id": "94229e22-0f87-4bb4-877e-cb133ef883bd",
            "type": "STRING",
            "title": "Full Name",
            "description": "",
            "size": 100,
            "position": "0,0"
        },
        {
            "id": "ffca48cd-45ae-4695-9388-c10aa99f13e8",
            "group_id": "94229e22-0f87-4bb4-877e-cb133ef883bd",
            "type": "STRING",
            "title": "First Name",
            "description": null,
            "size": 25,
            "position": "0,1"
        },
        {
            "id": "af4f22e0-f9de-47cd-9153-97fb8d58f506",
            "group_id": "94229e22-0f87-4bb4-877e-cb133ef883bd",
            "type": "STRING",
            "title": "Middle Initial",
            "description": null,
            "size": 25,
            "position": "1,1"
        }
    ]
}

HTTP Request

GET api/v2/config/template/{template}/{mode?}

Query Parameters

Parameter Status Description
template required The template id.
mode optional How the structure will be returned. flat will return single level collections of panels, groups and elements. nested will return a collection of panels with related groups nested on each panel and related elements nested on each group. Defaults to "flat".

Engagements

List engagements

Returns a collection of engagements.


Requires authentication

Example request:

curl -X GET -G "https://app.precisefp.com/api/v2/engagements" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://app.precisefp.com/api/v2/engagements");

    let params = {
            "sort": "5",
            "limit": "BaJQ3YjAkLQ17nxq",
            "offset": "6wTAgxTussRHajaH",
            "query": "yOPLJeuJ0bzdk0Vo",
            "type": "W9LQTZOngChUdXlI",
            "account_id": "15",
            "member_id": "Vs9mvykaPoCTpwp6",
            "template_id": "dOXm75ymhDmz05pA",
        };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "items": [
        {
            "id": "ed074e2d-9dd2-4df7-b1bd-55697400b42d",
            "account_id": 696,
            "member_id": 1013,
            "template_id": "4217e180-3a21-4c83-b296-45c900cb0669",
            "title": "Quick Fact Finder",
            "description": "A lighter version of the financial fact finder.",
            "security": "HIGH",
            "name": "John Doe",
            "email": "johndoe@precisefp.com",
            "url": "https:\/\/app.precisefp.com\/api\/v2\/engagements\/ed074e2d-9dd2-4df7-b1bd-55697400b42d\/preview",
            "status": "NEW",
            "filled": 0,
            "time": 0,
            "created_at": "2018-11-28 09:39:34",
            "opened_at": null,
            "email_reminders": false,
            "reminded_at": null,
            "email_completed": false,
            "completed_at": null
        },
        {
            "id": "eb653d24-0024-4bc3-b6b1-f9e2ad153b29",
            "account_id": 696,
            "member_id": 2304,
            "template_id": "7046262d-f2ce-4daf-8591-80938f5a5039",
            "title": "Financial Fact Finder",
            "description": "All the information required for a complete financial plan.",
            "security": "HIGH",
            "name": "John Doe",
            "email": "johndoe@precisefp.com",
            "url": "https:\/\/app.precisefp.com\/api\/v2\/engagements\/eb653d24-0024-4bc3-b6b1-f9e2ad153b29\/preview",
            "status": "NEW",
            "filled": 0,
            "time": 0,
            "created_at": "2018-11-22 13:47:32",
            "opened_at": null,
            "email_reminders": false,
            "reminded_at": null,
            "email_completed": false,
            "completed_at": null
        }
    ],
    "params": {
        "total": 2,
        "offset": 2,
        "limit": 50,
        "sort": "-created_at"
    }
}

HTTP Request

GET api/v2/engagements

Query Parameters

Parameter Status Description
sort optional Sorts list by this parameter. Prefix the parameter with - (dash) to sort descendingly. Allowed values: account_id, member_id, template_id, title, description, security, name, email, status, filled, created_at, opened_at, reminded_at, completed_at. Defaults to -created_at.
limit optional Limits the results by this parameter. Defaults to 50.
offset optional Returns results starting from this parameter. Defaults to 0.
query optional Returns results where the title and/or name start with this parameter.
type optional Filters results by this parameter. Allowed values: completed, in-progress.
account_id optional Filters results by account_id.
member_id optional Filters results by member_id.
template_id optional Filters results by template_id.

Create engagement

Creates a new engagement record.


Requires authentication

Example request:

curl -X POST "https://app.precisefp.com/api/v2/engagements" \
    -H "Authorization: Bearer {token}" \
    -d "template_id"="4217e180-3a21-4c83-b296-45c900cb0669" \
    -d "account_id"="1" \
    -d "member_id"="1" \
    -d "email_new"="1" \
    -d "email_reminders"="false" \
    -d "email_completed"="false" 
const url = new URL("https://app.precisefp.com/api/v2/engagements");

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

let body = JSON.stringify({
    "template_id": "4217e180-3a21-4c83-b296-45c900cb0669",
    "account_id": "1",
    "member_id": "1",
    "email_new": "1",
    "email_reminders": "",
    "email_completed": "",
})

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "id": "742da13c-8c1b-4968-9626-fc50d47da4a0",
    "account_id": 696,
    "member_id": 1013,
    "template_id": "4217e180-3a21-4c83-b296-45c900cb0669",
    "title": "Quick Fact Finder",
    "description": "A lighter version of the financial fact finder.",
    "security": "HIGH",
    "name": "John Doe",
    "email": "johndoe@precisefp.com",
    "url": "https:\/\/app.precisefp.com\/api\/v2\/engagements\/742da13c-8c1b-4968-9626-fc50d47da4a0\/preview",
    "status": "NEW",
    "filled": 0,
    "time": 0,
    "created_at": "2018-11-28 13:35:57",
    "opened_at": null,
    "email_reminders": false,
    "reminded_at": null,
    "email_completed": true,
    "completed_at": null
}

HTTP Request

POST api/v2/engagements

Body Parameters

Parameter Type Status Description
template_id string required Id of the Template to use. List of available templates is returned along with the authenticated user.
account_id integer required Id of the Account to engage.
member_id integer required Id of the Account Member (Client or Co-client) to engage.
email_new boolean optional Should the new engagement email be sent to the engaged contact.
email_reminders boolean optional Should the email reminders be active for this engagement.
email_completed boolean optional Should the thank you email be active for this engagement.

Get engagement

Returns one engagement record.


Requires authentication

Example request:

curl -X GET -G "https://app.precisefp.com/api/v2/engagements/{engagement}" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://app.precisefp.com/api/v2/engagements/{engagement}");

    let params = {
            "engagement": "gd3jfnpyYM78iXcZ",
        };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "id": "742da13c-8c1b-4968-9626-fc50d47da4a0",
    "account_id": 696,
    "member_id": 1013,
    "template_id": "4217e180-3a21-4c83-b296-45c900cb0669",
    "title": "Quick Fact Finder",
    "description": "A lighter version of the financial fact finder.",
    "security": "HIGH",
    "name": "John Doe",
    "email": "johndoe@precisefp.com",
    "url": "https:\/\/app.precisefp.com\/api\/v2\/engagements\/742da13c-8c1b-4968-9626-fc50d47da4a0\/preview",
    "status": "NEW",
    "filled": 0,
    "time": 0,
    "created_at": "2018-11-28 13:35:57",
    "opened_at": null,
    "email_reminders": false,
    "reminded_at": null,
    "email_completed": true,
    "completed_at": null
}

HTTP Request

GET api/v2/engagements/{engagement}

Query Parameters

Parameter Status Description
engagement required The engagement id.

Close engagement

Updates an engagement to completed.


Requires authentication

Example request:

curl -X POST "https://app.precisefp.com/api/v2/engagements/{engagement}/close" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://app.precisefp.com/api/v2/engagements/{engagement}/close");

    let params = {
            "engagement": "Z61NBqNHvXKAPEPp",
        };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "id": "742da13c-8c1b-4968-9626-fc50d47da4a0",
    "account_id": 696,
    "member_id": 1013,
    "template_id": "4217e180-3a21-4c83-b296-45c900cb0669",
    "title": "Quick Fact Finder",
    "description": "A lighter version of the financial fact finder.",
    "security": "HIGH",
    "name": "Jane Doe",
    "email": "janedoe@precisefp.com",
    "url": "https:\/\/app.precisefp.com\/api\/v2\/engagements\/742da13c-8c1b-4968-9626-fc50d47da4a0\/preview",
    "status": "COMPLETED",
    "filled": 0,
    "time": 0,
    "created_at": "2018-11-28 13:35:57",
    "opened_at": null,
    "email_reminders": false,
    "reminded_at": null,
    "email_completed": false,
    "completed_at": "2018-11-28 13:41:32"
}

HTTP Request

POST api/v2/engagements/{engagement}/close

Query Parameters

Parameter Status Description
engagement required The engagement id.

Reopen engagement

Updates an engagement to opened.


Requires authentication

Example request:

curl -X POST "https://app.precisefp.com/api/v2/engagements/{engagement}/reopen" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://app.precisefp.com/api/v2/engagements/{engagement}/reopen");

    let params = {
            "engagement": "8gsvkBfIn1U3OvIP",
        };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

fetch(url, {
    method: "POST",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "id": "742da13c-8c1b-4968-9626-fc50d47da4a0",
    "account_id": 696,
    "member_id": 1013,
    "template_id": "4217e180-3a21-4c83-b296-45c900cb0669",
    "title": "Quick Fact Finder",
    "description": "A lighter version of the financial fact finder.",
    "security": "HIGH",
    "name": "John Doe",
    "email": "johndoe@precisefp.com",
    "url": "https:\/\/app.precisefp.com\/api\/v2\/engagements\/742da13c-8c1b-4968-9626-fc50d47da4a0\/preview",
    "status": "NEW",
    "filled": 0,
    "time": 0,
    "created_at": "2018-11-28 13:35:57",
    "opened_at": null,
    "email_reminders": false,
    "reminded_at": null,
    "email_completed": true,
    "completed_at": null
}

HTTP Request

POST api/v2/engagements/{engagement}/reopen

Query Parameters

Parameter Status Description
engagement required The engagement id.

Delete engagement

Deletes an engagement record.


Requires authentication

Example request:

curl -X DELETE "https://app.precisefp.com/api/v2/engagements/{engagement}" \
    -H "Authorization: Bearer {token}" \
    -d "password"="UP581DWTepor7zQn" 
const url = new URL("https://app.precisefp.com/api/v2/engagements/{engagement}");

    let params = {
            "engagement": "WvFG9MgPtvd7ZKg1",
        };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

let body = JSON.stringify({
    "password": "UP581DWTepor7zQn",
})

fetch(url, {
    method: "DELETE",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

HTTP Request

DELETE api/v2/engagements/{engagement}

Body Parameters

Parameter Type Status Description
password string required For security reasons, the password of the authenticated user is verified on all delete operations.

Query Parameters

Parameter Status Description
engagement required The engagement id.

Preview engagement

Returns the HTML content of an engagement.


Requires authentication

Example request:

curl -X GET -G "https://app.precisefp.com/api/v2/engagements/{engagement}/preview" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://app.precisefp.com/api/v2/engagements/{engagement}/preview");

    let params = {
            "engagement": "6sSoX2kWW3FYFCqE",
        };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

"HTML content of the engagement"

HTTP Request

GET api/v2/engagements/{engagement}/preview

Query Parameters

Parameter Status Description
engagement required The engagement id.

Get data

Returns a completed engagement's data. Returns 422 (Unprocessable Entity) if the engagement is not completed.


Requires authentication

Example request:

curl -X GET -G "https://app.precisefp.com/api/v2/engagements/{engagement}/data" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://app.precisefp.com/api/v2/engagements/{engagement}/data");

    let params = {
            "engagement": "KQ1dUUfFNF2MUvNa",
        };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

[
    {
        "id": "cb8cddf6-3399-4278-ae5f-98f5234e821e",
        "dataset_id": "1f801c71-8e32-459e-9adf-730ac9be3d33",
        "member_id": 1,
        "row_id": "f9841871-f094-4105-b564-6b393845cdd2",
        "type": "STRING",
        "value": "John C Doe",
        "title": "Full Name",
        "description": null,
        "path": [
            "Client Details",
            "Personal Details",
            "Full Name"
        ]
    },
    {
        "id": "27dcf739-3878-4822-ab1a-b53d5a151d10",
        "dataset_id": "3f8d23d6-0535-4d31-b4f8-e56c893a8b80",
        "member_id": 1,
        "row_id": "f9841871-f094-4105-b564-6b393845cdd2",
        "type": "STRING",
        "value": "John",
        "title": "First Name",
        "description": null,
        "path": [
            "Client Details",
            "Personal Details",
            "First Name"
        ]
    },
    {
        "id": "0c3a96d9-3fdc-419a-ac56-f2a139bd11d0",
        "dataset_id": "60f300bb-d5d3-4a1a-9b48-12b334b5d0c3",
        "member_id": 1,
        "row_id": "f9841871-f094-4105-b564-6b393845cdd2",
        "type": "STRING",
        "value": "Doe",
        "title": "Last Name",
        "description": null,
        "path": [
            "Client Details",
            "Personal Details",
            "Last Name"
        ]
    },
    {
        "id": "192db6fd-5a02-4e0e-9ed0-22e76bc9c918",
        "dataset_id": "3cefed3c-4e97-4e40-9ad0-713c2f5a986a",
        "member_id": 1,
        "row_id": "f9841871-f094-4105-b564-6b393845cdd2",
        "type": "STRING",
        "value": "john.doe@precisefp.com",
        "title": "Email",
        "description": null,
        "path": [
            "Client Details",
            "Contact Details",
            "Email"
        ]
    },
    {
        "id": "e3b90fcf-590b-43d3-95fa-f7d438008f73",
        "dataset_id": "5cb03a18-5585-4e2d-8e1e-d8744293b081",
        "member_id": 1,
        "row_id": "f9841871-f094-4105-b564-6b393845cdd2",
        "type": "STRING",
        "value": "+15554441234",
        "title": "Mobile Phone",
        "description": null,
        "path": [
            "Client Details",
            "Contact Details",
            "Mobile Phone"
        ]
    }
]

HTTP Request

GET api/v2/engagements/{engagement}/data

Query Parameters

Parameter Status Description
engagement required The engagement id. List of available engagements is returned along with the List Engagements.

Get documents

Returns a list of engagement uploaded documents.


Requires authentication

Example request:

curl -X GET -G "https://app.precisefp.com/api/v2/engagements/{engagement}/documents" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://app.precisefp.com/api/v2/engagements/{engagement}/documents");

    let params = {
            "engagement": "n4xfhjunS7jIRxiy",
            "sort": "6RfNn8FXD0kfBMzW",
            "limit": "COiWdqFSTUuwWnpQ",
            "offset": "ZUBeXio9ohvfALGp",
        };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "items": [
        {
            "id": "97a103a9-5b47-45a2-95bc-7de2dfc2e2f9",
            "field_id": "2e0115d7-74fc-4020-9cde-2150d1878127",
            "title": "Employment & Income \/ Employment \/ Pay Stub 2",
            "files": [
                {
                    "name": "uploadedfile.pdf",
                    "url": "https:\/\/app.precisefp.com\/api\/v2\/engagements\/3cb68d4f-a4f6-430e-97fc-796e7138949b\/documents\/2e0115d7-74fc-4020-9cde-2150d1878127\/97a103a9-5b47-45a2-95bc-7de2dfc2e2f9\/0\/ucfN3bl.jpg"
                }
            ],
            "updated_at": "2018-11-22 11:17:53"
        },
        {
            "id": "fbbd5829-c514-4d14-9b3a-b81a7570329b",
            "field_id": "20f60587-a557-49e4-90c7-7b966b127651",
            "title": "Employment & Income \/ Employment \/ Pay Stub 1",
            "files": [
                {
                    "name": "uploadedfile.xml",
                    "url": "https:\/\/app.precisefp.com\/api\/v2\/engagements\/3cb68d4f-a4f6-430e-97fc-796e7138949b\/documents\/20f60587-a557-49e4-90c7-7b966b127651\/fbbd5829-c514-4d14-9b3a-b81a7570329b\/0\/8megstest.jpg"
                }
            ],
            "updated_at": "2018-11-22 13:47:52"
        }
    ],
    "params": {
        "limit": 50,
        "offset": 2,
        "sort": "-updated_at",
        "total": 2
    }
}

HTTP Request

GET api/v2/engagements/{engagement}/documents

Query Parameters

Parameter Status Description
engagement required The engagement id.
sort optional Sorts list by this parameter. Prefix the parameter with - (dash) to sort descendingly. Allowed values: updated_at. Defaults to -updated_at.
limit optional Limits the results by this parameter. Defaults to 50.
offset optional Returns results starting from this parameter. Defaults to 0.

Get document

Returns an engagement's document file.


Requires authentication

Example request:

curl -X GET -G "https://app.precisefp.com/api/v2/engagements/{engagement}/documents/{field}/{element}/{index}/{name?}" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://app.precisefp.com/api/v2/engagements/{engagement}/documents/{field}/{element}/{index}/{name?}");

    let params = {
            "engagement": "dFoIp5bKreHPrY7d",
            "field": "dulrMr5nCgqVidE0",
            "element": "JVs10YsnkGKPETpp",
            "index": "wZjpGoDQV1ZeTK4X",
        };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

"file content"

HTTP Request

GET api/v2/engagements/{engagement}/documents/{field}/{element}/{index}/{name?}

Query Parameters

Parameter Status Description
engagement required The engagement id.
field required The field id.
element required The element id.
index required The element index.

Get signatures

Returns a list of engagement signatures.


Requires authentication

Example request:

curl -X GET -G "https://app.precisefp.com/api/v2/engagements/{engagement}/signatures" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://app.precisefp.com/api/v2/engagements/{engagement}/signatures");

    let params = {
            "engagement": "oZnAVczQrwMoEQpu",
            "sort": "hCw8S8KNs4CVngZy",
            "limit": "EbIlfQ55sJZcHOo3",
            "offset": "RLrOnb0BQjzFxQtC",
        };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "items": [
        {
            "id": 211,
            "field_id": "99e2e442-5f37-4c22-9400-04ab63179fc2",
            "title": "Personal Details \/ Personal Details \/ Your Signature",
            "name": "John Doe",
            "email": "johndoe@precisefp.com",
            "ip": "11.11.111.11",
            "signed_at": "2018-11-22 13:48:49",
            "file": "https:\/\/app.precisefp.com\/api\/v2\/engagements\/3cb68d4f-a4f6-430e-97fc-796e7138949b\/signatures\/99e2e442-5f37-4c22-9400-04ab63179fc2\/3c499cd0-9f70-4592-b3e1-1afe23029d50"
        }
    ],
    "params": {
        "limit": 50,
        "offset": 1,
        "sort": "-signed_at",
        "total": 1
    }
}

HTTP Request

GET api/v2/engagements/{engagement}/signatures

Query Parameters

Parameter Status Description
engagement required The engagement id.
sort optional Sorts list by this parameter. Prefix the parameter with - (dash) to sort descendingly. Allowed values: name, email, ip, signed_at. Defaults to -signed_at.
limit optional Limits the results by this parameter. Defaults to 50.
offset optional Returns results starting from this parameter. Defaults to 0.

Get signature

Returns an engagement's signature file.


Requires authentication

Example request:

curl -X GET -G "https://app.precisefp.com/api/v2/engagements/{engagement}/signatures/{field}/{name}" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://app.precisefp.com/api/v2/engagements/{engagement}/signatures/{field}/{name}");

    let params = {
            "engagement": "oCw7ZMhUasAPeJJH",
            "field": "opEepBs69v4dMOgl",
            "name": "Y1KWV4Hp2bhkCJ2P",
        };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

"file content"

HTTP Request

GET api/v2/engagements/{engagement}/signatures/{field}/{name}

Query Parameters

Parameter Status Description
engagement required The engagement id.
field required The field id.
name required The file name.

Get history

Returns a list of previous versions of this engagement.


Requires authentication

Example request:

curl -X GET -G "https://app.precisefp.com/api/v2/engagements/{engagement}/history" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://app.precisefp.com/api/v2/engagements/{engagement}/history");

    let params = {
            "engagement": "kbrUB4f11le1xrCo",
            "sort": "ho11yjlAGQZuAvML",
            "limit": "QyxZIcQY6St3ISmW",
            "offset": "yGWMYoiteMGcknpz",
        };
    Object.keys(params).forEach(key => url.searchParams.append(key, params[key]));

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "items": [
        {
            "id": "742da13c-8c1b-4968-9626-fc50d47da4a0",
            "url": "https:\/\/app.precisefp.com\/api\/v2\/engagements\/742da13c-8c1b-4968-9626-fc50d47da4a0\/preview",
            "author": "John Doe",
            "created_at": "2018-11-28 11:21:31",
            "completed_at": "2018-11-28 13:42:32"
        },
        {
            "id": "ed074e2d-9dd2-4df7-b1bd-55697400b42d",
            "url": "https:\/\/app.precisefp.com\/api\/v2\/engagements\/ed074e2d-9dd2-4df7-b1bd-55697400b42d\/preview",
            "author": "James Brown",
            "created_at": "2018-11-11 09:39:34",
            "completed_at": "2018-11-28 21:02:44"
        }
    ],
    "params": {
        "limit": 50,
        "offset": 2,
        "sort": "-created_at",
        "total": 2
    }
}

HTTP Request

GET api/v2/engagements/{engagement}/history

Query Parameters

Parameter Status Description
engagement required The engagement id.
sort optional Sorts list by this parameter. Prefix the parameter with - (dash) to sort descendingly. Allowed values: created_at, updated_at. Defaults to -created_at.
limit optional Limits the results by this parameter. Defaults to 50.
offset optional Returns results starting from this parameter. Defaults to 0.

User

Get user

Returns the current authenticated user along with his personal settings and available data.


Requires authentication

Example request:

curl -X GET -G "https://app.precisefp.com/api/v2/user" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://app.precisefp.com/api/v2/user");

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "first_name": "Advisor",
    "last_name": "James",
    "email": "jamesbrownadvisor@precisefp.com",
    "phone": {
        "code": "+1",
        "number": "4155552671",
        "country": "US"
    },
    "photo": "https:\/\/app.precisefp.com\/media\/image\/user\/300164\/nf1PV5n9F3PRrTdFb7d78chJcGkwSvB1myddlyUm.png",
    "timezone": "America\/Chicago",
    "currency": "USD",
    "team": {
        "id": 106,
        "name": "Companyname"
    },
    "teams": [
        {
            "id": 28,
            "name": "Team 1"
        },
        {
            "id": 106,
            "name": "Team 2"
        }
    ],
    "permissions": {
        "accounts.prospects": true,
        "accounts.prospects.create": true,
        "accounts.prospects.update": true,
        "accounts.prospects.delete": true,
        "accounts.clients": true,
        "accounts.clients.create": true,
        "accounts.clients.update": true,
        "accounts.clients.delete": true,
        "accounts.favorite": true,
        "accounts.archive": true,
        "accounts.convert": true,
        "engagements.in-progress": true,
        "engagements.completed": true,
        "engagements.create": true,
        "engagements.close": true,
        "engagements.delete": true
    },
    "templates": [
        {
            "id": "cff90ab5-2bcb-4533-a8dd-117a2a767111",
            "title": "5 Biggest Investor Mistakes",
            "description": "The five biggest mistakes investors make (Optimized for US Clients).",
            "type": "LEADGEN",
            "security": "LOW",
            "owned": true
        },
        {
            "id": "35ce5bbd-127c-4573-a215-4d0c15234d93",
            "title": "Best Credit Card",
            "description": "Offer a credit card consultation to potential prospects.a",
            "type": "OTHER",
            "security": "HIGH",
            "owned": true
        }
    ],
    "pipelines": [
        {
            "id": "33e1d4b2-7243-4028-ad67-9bf4c171b057",
            "type": "CLIENT",
            "title": "Onboard1",
            "description": "Gather the information required to understand your client's wants and needs.\n\n\n\n\nk",
            "icon": "i_user_tag"
        },
        {
            "id": "b6d1cf3d-ee16-4df3-adb6-906eebc3e139",
            "type": "CLIENT",
            "title": "Discover",
            "description": "Gather the information required for a complete financial plan.",
            "icon": "i_user_friends"
        }
    ]
}

HTTP Request

GET api/v2/user

Switch user's team

Updates the current authenticated user's team.


Requires authentication

Example request:

curl -X POST "https://app.precisefp.com/api/v2/user/switch" \
    -H "Authorization: Bearer {token}" \
    -d "id"="11" 
const url = new URL("https://app.precisefp.com/api/v2/user/switch");

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

let body = JSON.stringify({
    "id": "11",
})

fetch(url, {
    method: "POST",
    headers: headers,
    body: body
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

{
    "first_name": "Advisor",
    "last_name": "James",
    "email": "jamesbrownadvisor@precisefp.com",
    "phone": {
        "code": "+1",
        "number": "4155552671",
        "country": "US"
    },
    "photo": "https:\/\/app.precisefp.com\/media\/image\/user\/300164\/nf1PV5n9F3PRrTdFb7d78chJcGkwSvB1myddlyUm.png",
    "timezone": "America\/Chicago",
    "currency": "USD",
    "team": {
        "id": 106,
        "name": "Companyname"
    },
    "teams": [
        {
            "id": 28,
            "name": "Team 1"
        },
        {
            "id": 106,
            "name": "Team 2"
        }
    ],
    "permissions": {
        "accounts.prospects": true,
        "accounts.prospects.create": true,
        "accounts.prospects.update": true,
        "accounts.prospects.delete": true,
        "accounts.clients": true,
        "accounts.clients.create": true,
        "accounts.clients.update": true,
        "accounts.clients.delete": true,
        "accounts.favorite": true,
        "accounts.archive": true,
        "accounts.convert": true,
        "engagements.in-progress": true,
        "engagements.completed": true,
        "engagements.create": true,
        "engagements.close": true,
        "engagements.delete": true
    },
    "templates": [
        {
            "id": "cff90ab5-2bcb-4533-a8dd-117a2a767111",
            "title": "5 Biggest Investor Mistakes",
            "description": "The five biggest mistakes investors make (Optimized for US Clients).",
            "type": "LEADGEN",
            "security": "LOW",
            "owned": true
        },
        {
            "id": "35ce5bbd-127c-4573-a215-4d0c15234d93",
            "title": "Best Credit Card",
            "description": "Offer a credit card consultation to potential prospects.a",
            "type": "OTHER",
            "security": "HIGH",
            "owned": true
        }
    ],
    "pipelines": [
        {
            "id": "33e1d4b2-7243-4028-ad67-9bf4c171b057",
            "type": "CLIENT",
            "title": "Onboard1",
            "description": "Gather the information required to understand your client's wants and needs.\n\n\n\n\nk",
            "icon": "i_user_tag"
        },
        {
            "id": "b6d1cf3d-ee16-4df3-adb6-906eebc3e139",
            "type": "CLIENT",
            "title": "Discover",
            "description": "Gather the information required for a complete financial plan.",
            "icon": "i_user_friends"
        }
    ]
}

HTTP Request

POST api/v2/user/switch

Body Parameters

Parameter Type Status Description
id integer required Team id to switch the user to. List of available teams is returned along with the authenticated user.

Get user available templates

Returns the current authenticated user available templates.


Requires authentication

Example request:

curl -X GET -G "https://app.precisefp.com/api/v2/user/templates" \
    -H "Authorization: Bearer {token}"
const url = new URL("https://app.precisefp.com/api/v2/user/templates");

let headers = {
    "Authorization": "Bearer {token}",
    "Accept": "application/json",
    "Content-Type": "application/json",
}

fetch(url, {
    method: "GET",
    headers: headers,
})
    .then(response => response.json())
    .then(json => console.log(json));

Example response (200):

[
    {
        "id": "cff90ab5-2bcb-4533-a8dd-117a2a767111",
        "title": "5 Biggest Investor Mistakes",
        "description": "The five biggest mistakes investors make (Optimized for US Clients).",
        "type": "LEADGEN",
        "security": "LOW",
        "owned": true
    },
    {
        "id": "35ce5bbd-127c-4573-a215-4d0c15234d93",
        "title": "Best Credit Card",
        "description": "Offer a credit card consultation to potential prospects.a",
        "type": "OTHER",
        "security": "HIGH",
        "owned": true
    }
]

HTTP Request

GET api/v2/user/templates

Response codes

PreciseFP uses the following response codes:

Code Meaning
200 Successful -- The request was successful.
201 Created -- The resource was created.
204 No content -- The request was successful and returned an empty response.
401 Unauthorized -- Invalid credentials.
403 Forbidden -- The authenticated user does not have access to the resource.
404 Not Found -- The specified resource could not be found.
405 Method Not Allowed -- You tried to access a resource with an invalid method.
422 Unprocessable Entity -- The request parameters are invalid.
429 Too Many Requests -- You reached your request limit. Please try again later.
500 Internal Server Error -- We had a problem with our server. Try again later.
503 Service Unavailable -- We're temporarily offline for maintenance. Please try again later.