<!-- https://staircase.co/providers/ice-mortgage-technology -->
# ICE Mortgage Technology

# ICE Mortgage Technology

An origination platform and the largest vendor surface on record, covering both of the platform's own integration frameworks.

The record for ICE Mortgage Technology is the integration in provider capacity. No commercial relationship in any other direction is described.

The origination platform holds the loan file, so every mortgage product that reads or writes a loan reaches it through this integration. Both frameworks the platform publishes are covered: a guided one with pre-approved service categories that appears inside the platform's own services tab, and an open one for calls outside those categories.

Desktop and web variants of the platform behave differently on record locking, and the integration was tested against each separately rather than assumed equivalent.

## Catalogue entries

Modelled as entries in the product catalogue, named after this vendor. The operations below are what they declare.

- **`EncompassAdapter`** — filed under Adapters

- **`Encompass`** — filed under Integration

## How the integration works

The two catalogue entries split by altitude. One orders services, receives results and writes them into the loan; the other is a field-level adapter translating canonical loan data into and out of the platform's own model in both directions. The generalised adapter sitting above every origination platform is LOS.

Entitlements are declared rather than assumed. The integration names the exact field pointers in the loan file it requires — borrower tax identifier, residence postal code, and the rest — so a lender can review the list before granting anything, instead of approving broad access.

Credit ordering through this platform is one of the recorded flows: a credit report request, a transaction handler, a custom input form path, and a service order, each its own committed flow file.

## Operations

<!--source:api-specifications-->

### Platform
<!--/source-->

`PUT` `/blobs/{blob_id}/presigned-urls/{action}`

<!--source:api-specifications-->

#### Create Report Download URL
<!--/source-->

`createPresignedUrl`

<!--source:api-specifications-->
Create Report Download URL creates a presigned URL in Staircase. It expires one hour after creation.

If partner provides a report in the documents, you can generate a download url with using staircase blob ID.

<!--/source-->

##### Response

<!--source:api-specifications-->
200 ExampleUpload200 ExampleDownload403
<!--/source-->

<!--source:api-specifications-->
application/json Copy Presigned URL created successfully.

```
{
 "upload": {
 "url": "https://dev-data-manager-blobs-bucket.s3.amazonaws.com/01EZY9J8SEFM2JKDJ1Q3YX65HS"
 }
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Presigned URL created successfully.

```
{
 "download": {
 "url": "https://dev-data-manager-blobs-bucket.s3.amazonaws.com/01EZY9J8SEFM2JKDJ1Q3YX65HS"
 }
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy 403 invalid error

```
{
 "message": "Please check the key you used to call this service",
 "url": "https://api.staircase.co/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post"
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
3
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |
| `blob_id` required | `string` path | `01EZY9J8SEFM2JKDJ1Q3YX65HS` | <!--source:api-specifications-->Blob identifier<!--/source--> |
| `action` required | `string` path | `upload` | <!--source:api-specifications-->Action, one of one of ['upload', 'download']<!--/source--> |

##### Response `200``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Presigned URL created successfully.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `upload` | `object` | <!--source:api-specifications-->Action<!--/source--> |
| `url` | `string` | <!--source:api-specifications-->Presigned_url<!--/source--> |
| `download` | `object` | <!--source:api-specifications-->Action<!--/source--> |
| `url` | `string` | <!--source:api-specifications-->Presigned_url<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
403 invalid error
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Error message.<!--/source--> |
| `url` | `string` | <!--source:api-specifications-->Error additional URL.<!--/source--> |

##### Other responses

`400``404`

`GET` `/products/encompass-adapter/request-schema`

<!--source:api-specifications-->

#### Retrieve Request Collection Schema
<!--/source-->

`retrieveRequestSchema`

<!--source:api-specifications-->
Retrieve Request Schema retrieves a JSON schema for the request collection that you can provide to the invocation. If you'd like to retrieve some examples for the request collection, use `return_examples=True` query parameter.

<!--/source-->

##### Response

<!--source:api-specifications-->
200400 InvalidReturnExamplesValue400 text/html403404 GetProduct404 text/html500
<!--/source-->

<!--source:api-specifications-->
application/json Copy Successfully returned the list of elements needed for product waterfall.

```
{
 "data": {
 "example": {
 "people": [
 {
 "@id": "01FD6ZKZD7WGZXYFGJBVPVP2Q5",
 "has_first_name": {
 "has_value": "John"
 },
 "has_last_name": {
 "has_value": "Jackson"
 },
 "has_birth_date": {
 "has_value": "12/28/1958"
 },
 "has_taxpayer_identifier_value": {
 "has_value": "666234390"
 },
 "with_address": [
 "01FD6ZNGJADZ0RB1H96FSE8BAB"
 ],
 "contact_at": [
 "01FD6ZNGJW9X96WGWX2BD37CFY"
 ]
 }
 ],
 "addresses": [
 {
 "@id": "01FD6ZNGJADZ0RB1H96FSE8BAB",
 "@type": "address",
 "has_address_line_1_text": {
 "has_value": "33 IRVING PLACE"
 },
 "has_address_line_2_text": {
 "has_value": "a"
 },
 "has_city_name": {
 "has_value": "NEW YORK"
 },
 "has_state_code": {
 "has_value": "NY"
 },
 "has_postal_code": {
 "has_value": "10003"
 },
 "has_country_name": {
 "has_value": "US"
 }
 }
 ],
 "contact_information": [
 {
 "@id": "01FD6ZNGJW9X96WGWX2BD37CFY",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "test@test.com"
 }
 }
 ],
 "employment": [
 {
 "provided_by": [
 "01FD6ZNGME8E1JFD342F7WDK8V"
 ]
 }
 ],
 "loans": [
 {
 "with_borrower": [
 "01FD6ZKZD7WGZXYFGJBVPVP2Q5"
 ]
 }
 ],
 "organizations": [
 {
 "@id": "01FD6ZNGNFKY3B7CX0YN6NH56E",
 "@type": "customer"
 }
 ]
 }
 },
 "metadata": {}
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Error

```
{
 "message": "Please provide one of valid return examples values: true, false"
}
```

<!--/source-->

<!--source:api-specifications-->
text/html Copy Error

```
<html>\r\n<head><title>400 Bad Request</title></head>\r\n<body>\r\n<center><h1>400 Bad Request</h1></center>\r\n</body>\r\n</html>\r\n
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy 403 invalid error

```
{
 "message": "Please check the key you used to call this service",
 "url": "https://api.staircase.co/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Resource not found

```
{
 "type": "string",
 "description": "Error Message."
}
```

<!--/source-->

<!--source:api-specifications-->
text/html Copy Resource not found

```
<html>\r\n<head><title>400 Bad Request</title></head>\r\n<body>\r\n<center><h1>400 Bad Request</h1></center>\r\n</body>\r\n</html>\r\n
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Internal server error

```
{
 "message": "The product has encountered an internal server error. If you have used a transaction_id to call our services, please submit it to Staircase support"
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
2
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |
| `return_examples` | `boolean` query | `false` | <!--source:api-specifications-->If included and set to `true`, returns one or more pre-filled examples that conform to the schema. Default to `false`<!--/source--> |

##### Response `200``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Successfully returned the list of elements needed for product waterfall.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `schema` | `object` | <!--source:api-specifications-->Element key / value<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Error
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
403 invalid error
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Error message.<!--/source--> |
| `url` | `string` | <!--source:api-specifications-->Error additional URL.<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Resource not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Error Message.<!--/source--> |

##### Response `500``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Internal server error
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Error message.<!--/source--> |

`GET` `/products/encompass-adapter/response-schema`

<!--source:api-specifications-->

#### Retrieve Response Collection Schema
<!--/source-->

`retrieveResponseSchema`

<!--source:api-specifications-->
Retrieve Response Schema retrieves a JSON schema for the request collection that you can provide to the invocation. If you'd like to retrieve some examples for the request collection, use `return_examples=True` query parameter.

<!--/source-->

##### Response

<!--source:api-specifications-->
200400 InvalidReturnExamplesValue400 text/html403404 GetProduct404 text/html500
<!--/source-->

<!--source:api-specifications-->
application/json Copy Successfully returned the list of elements of response of the product waterfall.

```
{
 "data": {
 "example": {
 "people": [
 {
 "@id": "01FD6ZKZD7WGZXYFGJBVPVP2Q5",
 "has_first_name": {
 "has_value": "John"
 },
 "has_last_name": {
 "has_value": "Jackson"
 },
 "has_birth_date": {
 "has_value": "12/28/1958"
 },
 "has_taxpayer_identifier_value": {
 "has_value": "666234390"
 },
 "with_address": [
 "01FD6ZNGJADZ0RB1H96FSE8BAB"
 ],
 "contact_at": [
 "01FD6ZNGJW9X96WGWX2BD37CFY"
 ]
 }
 ],
 "addresses": [
 {
 "@id": "01FD6ZNGJADZ0RB1H96FSE8BAB",
 "@type": "address",
 "has_address_line_1_text": {
 "has_value": "33 IRVING PLACE"
 },
 "has_address_line_2_text": {
 "has_value": "a"
 },
 "has_city_name": {
 "has_value": "NEW YORK"
 },
 "has_state_code": {
 "has_value": "NY"
 },
 "has_postal_code": {
 "has_value": "10003"
 },
 "has_country_name": {
 "has_value": "US"
 }
 }
 ],
 "contact_information": [
 {
 "@id": "01FD6ZNGJW9X96WGWX2BD37CFY",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "test@test.com"
 }
 }
 ],
 "employment": [
 {
 "provided_by": [
 "01FD6ZNGME8E1JFD342F7WDK8V"
 ]
 }
 ],
 "loans": [
 {
 "with_borrower": [
 "01FD6ZKZD7WGZXYFGJBVPVP2Q5"
 ]
 }
 ],
 "organizations": [
 {
 "@id": "01FD6ZNGNFKY3B7CX0YN6NH56E",
 "@type": "customer"
 }
 ]
 }
 },
 "metadata": {}
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Error

```
{
 "message": "Please provide one of valid return examples values: true, false"
}
```

<!--/source-->

<!--source:api-specifications-->
text/html Copy Error

```
<html>\r\n<head><title>400 Bad Request</title></head>\r\n<body>\r\n<center><h1>400 Bad Request</h1></center>\r\n</body>\r\n</html>\r\n
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy 403 invalid error

```
{
 "message": "Please check the key you used to call this service",
 "url": "https://api.staircase.co/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Resource not found

```
{
 "type": "string",
 "description": "Error Message."
}
```

<!--/source-->

<!--source:api-specifications-->
text/html Copy Resource not found

```
<html>\r\n<head><title>400 Bad Request</title></head>\r\n<body>\r\n<center><h1>400 Bad Request</h1></center>\r\n</body>\r\n</html>\r\n
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Internal server error

```
{
 "message": "The product has encountered an internal server error. If you have used a transaction_id to call our services, please submit it to Staircase support"
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
2
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |
| `return_examples` | `boolean` query | `false` | <!--source:api-specifications-->If included and set to `true`, returns one or more pre-filled examples that conform to the schema. Default to `false`<!--/source--> |

##### Response `200``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Successfully returned the list of elements of response of the product waterfall.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `schema` | `object` | <!--source:api-specifications-->Element key / value element<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Error
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
403 invalid error
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Error message.<!--/source--> |
| `url` | `string` | <!--source:api-specifications-->Error additional URL.<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Resource not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Error Message.<!--/source--> |

##### Response `500``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Internal server error
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Error message.<!--/source--> |

<!--source:api-specifications-->

### CRM
<!--/source-->

`POST` `/products/dailyai/invocations`

<!--source:api-specifications-->

#### Single Loan Transaction API Integration
<!--/source-->

`invokeSingleLoanTransactionProductFlow`

<!--source:api-specifications-->

#### Single Loan Transaction

This endpoint adds a CRM transaction data to DailyAI and returns the result in staircase-graph language.

`product_flow_name = "single-loan-transaction"`

You need to create new `addresses`, `contact_information`, `documents`, `loan_statuses`, `loans`, `people`, `properties`, `property_valuations`, `down_payments`, `loan_terms`, `loan_programs`, `ltvs`, `sales_contracts`, `closing_information`, `loan_products` and `locks` arrays in collection.

Show the rest `addresses` array has 1 object element:

- This element contains Encompass loan's property address data.
- You need to give unique string id inside `@id` field, `property_address` value inside `@type` field.
- You need to give the address text 1 of an Encompass loan property inside `has_address_line_1_text/has_value`, the address text 2 of an Encompass loan property inside `has_address_line_2_text/has_value`, the city of an Encompass loan property inside `has_city_name/has_value`, the state of an Encompass loan property inside `has_state_code/has_value`, the postal code of an Encompass loan property inside `has_postal_code/has_value`.

`contact_information` array has 13 object elements:

- First object of `contact_information`:
- You need to give unique string id(`contact_at` element's value of `people` borrower object) inside `@id` field, `contact_information` value inside `@type` field.
- You need to give the email address of Encompass loan borrower inside `has_email_address/has_value` field, the phone number of Encompass loan borrower inside `has_phone_number/has_value` field.
- Second object of `contact_information`:
- You need to give unique string id(`contact_at` element's value of `people` co_borrower object) inside `@id` field, `contact_information` value inside `@type` field.
- You need to give the email address of Encompass loan coborrower inside `has_email_address/has_value` field, the phone number of Encompass loan coborrower inside `has_phone_number/has_value` field.
- Third object of `contact_information`:
- You need to give unique string id(`contact_at` element's value of `people` broker object) inside `@id` field, `contact_information` value inside `@type` field.
- You need to give the email address of Encompass loan's broker inside `has_email_address/has_value` field, the phone number of Encompass loan's broker inside `has_phone_number/has_value` field.
- Fourth object of `contact_information`:
- You need to give unique string id(`contact_at` element's value of `people` builder object) inside `@id` field, `contact_information` value inside `@type` field.
- You need to give the email address of Encompass loan's builder inside `has_email_address/has_value` field, the phone number of Encompass loan's builder inside `has_phone_number/has_value` field.
- Fifth object of `contact_information`:
- You need to give unique string id(`contact_at` element's value of `people` buyer_agent object) inside `@id` field, `contact_information` value inside `@type` field.
- You need to give the email address of Encompass loan's buying agent inside `has_email_address/has_value` field, the phone number of Encompass loan's buying agent inside `has_phone_number/has_value` field.
- Sixth object of `contact_information`:
- You need to give unique string id(`contact_at` element's value of `people` certified_public_accountant object) inside `@id` field, `contact_information` value inside `@type` field.
- You need to give the email address of Encompass loan's certified public accountant inside `has_email_address/has_value` field, the phone number of Encompass loan's certified public accountant inside `has_phone_number/has_value` field.
- Seventh object of `contact_information`:
- You need to give unique string id(`contact_at` element's value of `people` financial_advisor object) inside `@id` field, `contact_information` value inside `@type` field.
- You need to give the email address of Encompass loan's financial advisor inside `has_email_address/has_value` field, the phone number of Encompass loan's financial advisor inside `has_phone_number/has_value` field.
- Eighth object of `contact_information`:
- You need to give unique string id(`contact_at` element's value of `people` insurance_agent object) inside `@id` field, `contact_information` value inside `@type` field.
- You need to give the email address of Encompass loan's insurance agent inside `has_email_address/has_value` field, the phone number of Encompass loan's insurance agent inside `has_phone_number/has_value` field.
- Ninth object of `contact_information`:
- You need to give unique string id(`contact_at` element's value of `people` seller_coordinator object) inside `@id` field, `contact_information` value inside `@type` field.
- You need to give the email address of Encompass loan's seller coordinator inside `has_email_address/has_value` field, the phone number of Encompass loan's seller coordinator inside `has_phone_number/has_value` field.
- Tenth object of `contact_information`:
- You need to give unique string id(`contact_at` element's value of `people` loan_coordinator object) inside `@id` field, `contact_information` value inside `@type` field.
- You need to give the email address of Encompass loan's buyer coordinator inside `has_email_address/has_value` field, the phone number of Encompass loan's buyer coordinator inside `has_phone_number/has_value` field.
- Eleventh object of `contact_information`:
- You need to give unique string id(`contact_at` element's value of `people` title_holder object) inside `@id` field, `contact_information` value inside `@type` field.
- You need to give the email address of Encompass loan's title `has_email_address/has_value` field, the phone number of Encompass loan's title inside `has_phone_number/has_value` field.
- Twelfth object of `contact_information`:
- You need to give unique string id(`contact_at` element's value of `people` ("@type"=attorney and "has_represented_party_type.has_value"="borrower") object) inside `@id` field, `contact_information` value inside `@type` field.
- You need to give the email address of Encompass loan's buyer attorney `has_email_address/has_value` field, the phone number of Encompass loan's buyer attorney inside `has_phone_number/has_value` field.
- Thirteenth object of `contact_information`:
- You need to give unique string id(`contact_at` element's value of `people` ("@type"=attorney and "has_represented_party_type.has_value"="other") object) inside `@id` field, `contact_information` value inside `@type` field.
- You need to give the email address of Encompass loan's seller attorney `has_email_address/has_value` field, the phone number of Encompass loan's seller attorney inside `has_phone_number/has_value` field.

`documents` array has 1 object elements. It is related with the loan application:

- You need to give unique string id inside `@id` field, `loan_application` value inside `@type` field.
- You need to give `@id` field's values of `borrower` and `co_borrower` inside `with_borrower` array.

`loan_statuses` array has 1 object elements:

- You need to give unique string id inside `@id` field, `loan_status` value inside `@type` field.
- You need to give Encompass loan status value inside `has_loan_status_identifier/has_value` field.

`loans` array has 1 object elements:

- You need to give Encompass loan id inside `@id` field, `loan` value inside `@type` field, Encompass loan's estimated closing date inside `has_source_identifier/has_value`, and Encompass loan's funding date inside `has_loan_funding_date/has_value`
- You need to give `@id` field's values of `loan_application(document)` inside `with_loan_application` array.
- You need to give `@id` field's values of `loan_status` inside `with_loan_status` array.
- You need to give `@id` field's value of `subject_property` inside `secured_by_property` array.
- You need to give `@id` field's value of `down_payment` inside `with_down_payment` array.
- You need to give `@id` field's value of `loan_terms` inside `with_loan_terms` array.
- You need to give `@id` field's value of `loan_program` inside `with_loan_program` array.
- You need to give `@id` field's value of `ltv` inside `with_ltv` array.
- You need to give `@id` field's value of `closing_information` inside `with_closing_information` array.
- You need to give `@id` field's value of `loan_product` inside `with_loan_product` array.

`people` array has 14 object elements:

- First object of `people`:
- You need to give Encompass loan officer id inside `@id` field, `loan_officer` value inside `@type` field and Encompass instance id inside `has_source_identifier/has_value`.
- Second object of `people`:
- You need to give unique string id inside `@id` field, `borrower` value inside `@type` field.
- You need to give the firstname of an Encompass loan borrower inside `has_first_name/has_value`, the lastname of an Encompass loan borrower inside `has_last_name/has_value`
- You need to give unique string value inside `contact_at` array's element. This value should match one object's '@id' of contact_information array
- Third object of `people`:
- You need to give unique string id inside `@id` field, `co_borrower` value inside `@type` field.
- You need to give the firstname of an Encompass loan coborrower inside `has_first_name/has_value`, the lastname of an Encompass loan coborrower inside `has_last_name/has_value`
- You need to give unique string value inside `contact_at` array's element. This value should match one object's '@id' of contact_information array
- Fourth object of `people`:
- You need to give unique string id inside `@id` field, `broker` value inside `@type` field.
- You need to give the firstname of an Encompass loan broker inside `has_first_name/has_value`, the lastname of an Encompass loan broker inside `has_last_name/has_value`
- You need to give unique string value inside `contact_at` array's element. This value should match one object's '@id' of contact_information array
- Fifth object of `people`:
- You need to give unique string id inside `@id` field, `builder` value inside `@type` field.
- You need to give the firstname of an Encompass loan builder inside `has_first_name/has_value`, the lastname of an Encompass loan builder inside `has_last_name/has_value`
- You need to give unique string value inside `contact_at` array's element. This value should match one object's '@id' of contact_information array
- Sixth object of `people`:
- You need to give unique string id inside `@id` field, `buyer_agent` value inside `@type` field.
- You need to give the firstname of an Encompass loan buyer agent inside `has_first_name/has_value`, the lastname of an Encompass loan buyer agent inside `has_last_name/has_value`
- You need to give unique string value inside `contact_at` array's element. This value should match one object's '@id' of contact_information array
- Seventh object of `people`:
- You need to give unique string id inside `@id` field, `certified_public_accountant` value inside `@type` field.
- You need to give the firstname of an Encompass loan certified public accountant inside `has_first_name/has_value`, the lastname of an Encompass loan certified public accountant inside `has_last_name/has_value`
- You need to give unique string value inside `contact_at` array's element. This value should match one object's '@id' of contact_information array
- Eighth object of `people`:
- You need to give unique string id inside `@id` field, `financial_advisor` value inside `@type` field.
- You need to give the firstname of an Encompass loan financial advisor inside `has_first_name/has_value`, the lastname of an Encompass loan financial advisor inside `has_last_name/has_value`
- You need to give unique string value inside `contact_at` array's element. This value should match one object's '@id' of contact_information array
- Ninth object of `people`:
- You need to give unique string id inside `@id` field, `insurance_agent` value inside `@type` field.
- You need to give the firstname of an Encompass loan insurance agent inside `has_first_name/has_value`, the lastname of an Encompass loan insurance agent inside `has_last_name/has_value`
- You need to give unique string value inside `contact_at` array's element. This value should match one object's '@id' of contact_information array
- Tenth object of `people`:
- You need to give unique string id inside `@id` field, `seller_coordinator` value inside `@type` field.
- You need to give the firstname of an Encompass loan seller coordinator inside `has_first_name/has_value`, the lastname of an Encompass loan seller coordinator inside `has_last_name/has_value`
- You need to give unique string value inside `contact_at` array's element. This value should match one object's '@id' of contact_information array
- Eleventh object of `people`:
- You need to give unique string id inside `@id` field, `loan_coordinator` value inside `@type` field.
- You need to give the firstname of an Encompass loan buyer coordinator inside `has_first_name/has_value`, the lastname of an Encompass loan buyer coordinator inside `has_last_name/has_value`
- You need to give unique string value inside `contact_at` array's element. This value should match one object's '@id' of contact_information array
- Twelfth object of `people`:
- You need to give unique string id inside `@id` field, `title_holder` value inside `@type` field.
- You need to give the firstname of an Encompass loan title inside `has_first_name/has_value`, the lastname of an Encompass loan title inside `has_last_name/has_value`
- You need to give unique string value inside `contact_at` array's element. This value should match one object's '@id' of contact_information array
- Thirteenth object of `people`:
- You need to give unique string id inside `@id` field, `attorney` value inside `@type` field.
- You need to give the firstname of an Encompass loan buyer attorney inside `has_first_name/has_value`, the lastname of an Encompass loan buyer attorney inside `has_last_name/has_value`
- You need to give `borrower` inside `has_represented_party_type/has_value`.
- You need to give unique string value inside `contact_at` array's element. This value should match one object's '@id' of contact_information array
- Fourteenth object of `people`:
- You need to give unique string id inside `@id` field, `attorney` value inside `@type` field.
- You need to give the firstname of an Encompass loan seller attorney inside `has_first_name/has_value`, the lastname of an Encompass loan buyer attorney inside `has_last_name/has_value`
- You need to give `other` inside `has_represented_party_type/has_value`.
- You need to give unique string value inside `contact_at` array's element. This value should match one object's '@id' of contact_information array

`properties` array has 1 object elements:

- You need to give unique string id inside `@id` field, `subject_property` value inside `@type` field.
- You need to give `@id` field's value of `property_address` inside `with_address` array.
- You need to give `@id` field's value of `sales_contract` inside `with_sales_contract` array.
- You need to give `@id` field's value of `subject_property_valuation` inside `with_value` array.
- You need to give the 'occupancy type' of an Encompass loan inside `has_property_current_usage_type/has_value`

`property_valuations` array has 1 object elements:

- You need to give unique string id inside `@id` field, `subject_property_valuation` value inside `@type` field.
- You need to give Encompass loan's appraised value inside `has_property_valuation_amount/has_value` field.

`down_payments` array has 1 object elements:

- You need to give unique string id inside `@id` field, `down_payment` value inside `@type` field.
- You need to give Encompass loan's down payment inside `has_down_payment_amount/has_value` field.

`loan_terms` array has 1 object elements:

- You need to give unique string id inside `@id` field, `loan_terms` value inside `@type` field.
- You need to give Encompass loan amortization term inside `has_amortization_term_months_count/has_value`
- You need to give Encompass loan amount inside `has_note_amount/has_value` field.
- You need to give Encompass loan rate payment inside `has_note_rate_percent/has_value` field.
- You need to give Encompass loan purpose payment inside `has_loan_purpose_type/has_value` field.
- You need to give Encompass loan type payment inside `has_mortgage_type/has_value` field.

`loan_programs` array has 1 object elements:

- You need to give unique string id inside `@id` field, `loan_program` value inside `@type` field.
- You need to give Encompass loan program inside `has_loan_program_identifier/has_value` field.

`ltvs` array has 1 object elements:

- You need to give unique string id inside `@id` field, `ltv` value inside `@type` field.
- You need to give Encompass loan value inside `has_ltv_ratio_percent/has_value` field.

`sales_contracts` array has 1 object elements:

- You need to give unique string id inside `@id` field, `property_sales_contract` value inside `@type` field.
- You need to give Encompass loan sales price inside `has_sales_contract_amount/has_value` field.

`closing_information` array has 1 object elements:

- You need to give unique string id inside `@id` field, `closing_information` value inside `@type` field.
- You need to give Encompass loan actual closing date inside `has_closing_date/has_value` field.

`loan_products` array has 1 object elements:

- You need to give unique string id inside `@id` field, `loan_product` value inside `@type` field.
- You need to give `@id` field's value of `lock` inside `with_lock` array.

`locks` array has 1 object elements:

- You need to give unique string id inside `@id` field, `lock` value inside `@type` field.
- You need to give Encompass loan lock date inside `has_lock_datetime/has_value` field.
- You need to give Encompass loan lock expiration date inside `has_lock_expiration_datetime/has_value` field.

Unmapped missing fields from Staircase Graph to DailyAI:

- `homeWarrantyContact` object
- `incomne` field
- `fundedDate` field
- `posId` field

When these unmapped missing fields are mapped, the documentation will be updated.

Example request payload:

```
{
 "addresses": [
 {
 "@id": "01GMDENWW0DN844A89DVD2BMSF",
 "@type": "property_address",
 "has_address_line_1_text": {
 "has_value": "4321 CulDeSac Street"
 },
 "has_city_name": {
 "has_value": "Someplace"
 },
 "has_postal_code": {
 "has_value": "02723"
 },
 "has_state_code": {
 "has_value": "MA"
 }
 }
 ],
 "contact_information": [
 {
 "@id": "01GMDENWW094ER2ECJXJZXVAM2",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "supriya.gopal@elliemae.com"
 },
 "has_phone_number": {
 "has_value": "123-456-7891"
 }
 },
 {
 "@id": "01GMDENWW02BG8YE3GAVXV6K28",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "test@test.com"
 },
 "has_phone_number": {
 "has_value": "123-456-7891"
 }
 },
 {
 "@id": "brokerContact1",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "broker@broker.com"
 },
 "has_phone_number": {
 "has_value": "111-111-1111"
 }
 },
 {
 "@id": "builderContact1",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "builder@builder.com"
 },
 "has_phone_number": {
 "has_value": "111-111-1112"
 }
 },
 {
 "@id": "buyingAgentContact1",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "buyingagent@buyingagent.com"
 },
 "has_phone_number": {
 "has_value": "111-111-1113"
 }
 },
 {
 "@id": "cpaContact1",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "cpa@cpa.com"
 },
 "has_phone_number": {
 "has_value": "111-111-1114"
 }
 },
 {
 "@id": "financialAdvisorContact1",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "financialadvisor@financialadvisor.com"
 },
 "has_phone_number": {
 "has_value": "111-111-1115"
 }
 },
 {
 "@id": "insuranceAgentContact1",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "insuranceagent@insuranceagent.com"
 },
 "has_phone_number": {
 "has_value": "111-111-1116"
 }
 },
 {
 "@id": "sellerCoordinatorContact1",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "sellercoordinator@sellercoordinator.com"
 },
 "has_phone_number": {
 "has_value": "111-111-1117"
 }
 },
 {
 "@id": "buyerCoordinatorContact1",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "buyercoordinator@buyercoordinator.com"
 },
 "has_phone_number": {
 "has_value": "111-111-1118"
 }
 },
 {
 "@id": "titleContact1",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "title@title.com"
 },
 "has_phone_number": {
 "has_value": "111-111-1119"
 }
 },
 {
 "@id": "buyerAttorneyContact1",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "buyerattorney@buyerattorney.com"
 },
 "has_phone_number": {
 "has_value": "111-111-1120"
 }
 },
 {
 "@id": "sellerAttorneyContact1",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "sellerattorney@sellerattorney.com"
 },
 "has_phone_number": {
 "has_value": "111-111-1121"
 }
 }
 ],
 "documents": [
 {
 "@id": "01GMDENWW0P6MY2EKFZFA94A6B",
 "@type": "loan_application",
 "with_borrower": [
 "01GMDENWW00NFVWWBJM3K645BD",
 "01GMDENWW01SSXFGNWDQBRFWSN"
 ]
 }
 ],
 "loan_statuses": [
 {
 "@id": "01GMDENWW0KHBK735TA3V2RAXE",
 "@type": "loan_status",
 "has_loan_status_identifier": {
 "has_value": "Started"
 }
 }
 ],
 "loans": [
 {
 "@id": "5c835f3f-14ca-49f5-9e38-99195d56a131",
 "@type": "loan",
 "has_loan_estimated_closing_date": {
 "has_value": "2012-04-23T18:25:43.511Z"
 },
 "has_loan_funding_date": {
 "has_value": "2012-04-23T18:25:43.511Z"
 },
 "with_loan_application": [
 "01GMDENWW0P6MY2EKFZFA94A6B"
 ],
 "with_loan_status": [
 "01GMDENWW0KHBK735TA3V2RAXE"
 ],
 "secured_by_property": [
 "sbp1"
 ],
 "with_down_payment": [
 "ldp1"
 ],
 "with_loan_terms": [
 "llt1"
 ],
 "with_loan_program": [
 "llp1"
 ],
 "with_ltv": [
 "lltv1"
 ],
 "with_closing_information": [
 "lci1"
 ],
 "with_loan_product": [
 "lp1"
 ]
 }
 ],
 "people": [
 {
 "@id": "admin",
 "@type": "loan_officer",
 "has_source_identifier": {
 "has_value": "TEBE11229152"
 }
 },
 {
 "@id": "01GMDENWW00NFVWWBJM3K645BD",
 "@type": "co_borrower",
 "contact_at": [
 "01GMDENWW094ER2ECJXJZXVAM2"
 ],
 "has_first_name": {
 "has_value": "amy"
 },
 "has_last_name": {
 "has_value": "america"
 }
 },
 {
 "@id": "01GMDENWW01SSXFGNWDQBRFWSN",
 "@type": "borrower",
 "contact_at": [
 "01GMDENWW02BG8YE3GAVXV6K28"
 ],
 "has_first_name": {
 "has_value": "andy"
 },
 "has_last_name": {
 "has_value": "america"
 }
 },
 {
 "@id": "broker1",
 "@type": "broker",
 "contact_at": [
 "brokerContact1"
 ],
 "has_first_name": {
 "has_value": "BrokerFirstName"
 },
 "has_last_name": {
 "has_value": "BrokerLastName"
 }
 },
 {
 "@id": "builder1",
 "@type": "builder",
 "contact_at": [
 "builderContact1"
 ],
 "has_first_name": {
 "has_value": "BuilderFirstName"
 },
 "has_last_name": {
 "has_value": "BuilderLastName"
 }
 },
 {
 "@id": "buyingAgent1",
 "@type": "buyer_agent",
 "contact_at": [
 "buyingAgentContact1"
 ],
 "has_first_name": {
 "has_value": "BuyingAgentFirstName"
 },
 "has_last_name": {
 "has_value": "BuyingAgentLastName"
 }
 },
 {
 "@id": "cpa1",
 "@type": "certified_public_accountant",
 "contact_at": [
 "cpaContact1"
 ],
 "has_first_name": {
 "has_value": "CpaFirstName"
 },
 "has_last_name": {
 "has_value": "CpaLastName"
 }
 },
 {
 "@id": "financialAdvisor1",
 "@type": "financial_advisor",
 "contact_at": [
 "financialAdvisorContact1"
 ],
 "has_first_name": {
 "has_value": "FinancialAdvisorFirstName"
 },
 "has_last_name": {
 "has_value": "FinancialAdvisorLastName"
 }
 },
 {
 "@id": "insuranceAgent1",
 "@type": "insurance_agent",
 "contact_at": [
 "insuranceAgentContact1"
 ],
 "has_first_name": {
 "has_value": "InsuranceAgentFirstName"
 },
 "has_last_name": {
 "has_value": "InsuranceAgentLastName"
 }
 },
 {
 "@id": "sellerCoordinator1",
 "@type": "seller_coordinator",
 "contact_at": [
 "sellerCoordinatorContact1"
 ],
 "has_first_name": {
 "has_value": "SellerCoordinatorFirstName"
 },
 "has_last_name": {
 "has_value": "SellerCoordinatorLastName"
 }
 },
 {
 "@id": "buyerCoordinator1",
 "@type": "loan_coordinator",
 "contact_at": [
 "buyerCoordinatorContact1"
 ],
 "has_first_name": {
 "has_value": "BuyerCoordinatorFirstName"
 },
 "has_last_name": {
 "has_value": "BuyerCoordinatorLastName"
 }
 },
 {
 "@id": "title1",
 "@type": "title_holder",
 "contact_at": [
 "titleContact1"
 ],
 "has_first_name": {
 "has_value": "TitleFirstName"
 },
 "has_last_name": {
 "has_value": "TitleLastName"
 }
 },
 {
 "@id": "buyerAttorney1",
 "@type": "attorney",
 "contact_at": [
 "buyerAttorneyContact1"
 ],
 "has_first_name": {
 "has_value": "BuyerAttorneyirstName"
 },
 "has_last_name": {
 "has_value": "BuyerAttorneyLastName"
 },
 "has_represented_party_type": {
 "has_value": "borrower"
 }
 },
 {
 "@id": "sellerAttorney1",
 "@type": "attorney",
 "contact_at": [
 "sellerAttorneyContact1"
 ],
 "has_first_name": {
 "has_value": "SellerAttorneyirstName"
 },
 "has_last_name": {
 "has_value": "SellerAttorneyLastName"
 },
 "has_represented_party_type": {
 "has_value": "other"
 }
 }
 ],
 "properties": [
 {
 "@id": "sbp1",
 "@type": "subject_property",
 "has_property_current_usage_type": {
 "has_value": "primary_residence"
 },
 "has_amortization_term_months_count": {
 "has_value": 360
 },
 "with_address": [
 "01GMDENWW0DN844A89DVD2BMSF"
 ],
 "with_sales_contract": [
 "psc1"
 ],
 "with_value": [
 "appraisedValue1"
 ]
 }
 ],
 "property_valuations": [
 {
 "@id": "appraisedValue1",
 "@type": "subject_property_valuation",
 "has_property_valuation_amount": {
 "has_value": 1000
 }
 }
 ],
 "down_payments": [
 {
 "@id": "ldp1",
 "@type": "down_payment",
 "has_down_payment_amount": {
 "has_value": 1000
 }
 }
 ],
 "loan_terms": [
 {
 "@id": "llt1",
 "@type": "loan_terms",
 "has_note_amount": {
 "has_value": 1234
 },
 "has_note_rate_percent": {
 "has_value": 7.5
 },
 "has_loan_purpose_type": {
 "has_value": "purchase"
 },
 "has_mortgage_type": {
 "has_value": "fha"
 }
 }
 ],
 "loan_programs": [
 {
 "@id": "llp1",
 "@type": "loan_program",
 "has_loan_program_identifier": {
 "has_value": "Indentured Servitude"
 }
 }
 ],
 "ltvs": [
 {
 "@id": "lltv1",
 "@type": "ltv",
 "has_ltv_ratio_percent": {
 "has_value": 1000.1
 }
 }
 ],
 "sales_contracts": [
 {
 "@id": "psc1",
 "@type": "property_sales_contract",
 "has_sales_contract_amount": {
 "has_value": 1000
 }
 }
 ],
 "closing_information": [
 {
 "@id": "lci1",
 "@type": "closing_information",
 "has_closing_date": {
 "has_value": "2012-04-23T18:25:43.511Z"
 }
 }
 ],
 "loan_products": [
 {
 "@id": "lp1",
 "@type": "loan_product",
 "with_lock": [
 "lpl1"
 ]
 }
 ],
 "locks": [
 {
 "@id": "lpl1",
 "@type": "lock",
 "has_lock_datetime": {
 "has_value": "2012-04-23T18:25:43.511Z"
 },
 "has_lock_expiration_datetime": {
 "has_value": "2012-04-23T18:25:43.511Z"
 }
 }
 ]
}
```

After calling `single-loan-transaction` product flow invocation, you can retrieve this invocation status using this API. Parameter product_name should be `dailyai` and invocation_id parameter should be the invocation_id value in the product flow invocation response body.

#### Historical Loan Transaction

In order to send loan historical loan update, the same input as for single-loan-transaction should be created. This time putting historical-loan-transaction in product_flow_name field.

`product_flow_name = "historical-loan-transaction"`

#### Create Transaction

You can create a transaction and use transaction_id in your request body of product API calls. Please check this API.

#### Retrieve Transaction Collections

You can use this API to retrieve collections used in same transaction.

#### Retrieve a Transaction's Collection

You can use this API to retrieve a transaction's collection.

<!--/source-->

##### Request

<!--source:api-specifications-->
single_loan_transaction_invocation_with_collection_idsingle_loan_transaction_invocation_with_request_data
<!--/source-->

<!--source:api-specifications-->
application/json Copy
```
{
 "transaction_id": "01FV0H1MPRMAF6JAHJ6BAPYF9X",
 "product_flow_name": "single-loan-transaction",
 "request_collection_id": "01FV0H1MWC9N5F71DG0W79V0H3"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy
```
{
 "product_flow_name": "single-loan-transaction",
 "request_data": {
 "addresses": [
 {
 "@id": "01GMDENWW0DN844A89DVD2BMSF",
 "@type": "property_address",
 "has_address_line_1_text": {
 "has_value": "4321 CulDeSac Street"
 },
 "has_city_name": {
 "has_value": "Someplace"
 },
 "has_postal_code": {
 "has_value": "02723"
 },
 "has_state_code": {
 "has_value": "MA"
 }
 }
 ],
 "contact_information": [
 {
 "@id": "01GMDENWW094ER2ECJXJZXVAM2",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "supriya.gopal@elliemae.com"
 },
 "has_phone_number": {
 "has_value": "123-456-7891"
 }
 },
 {
 "@id": "01GMDENWW02BG8YE3GAVXV6K28",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "test@test.com"
 },
 "has_phone_number": {
 "has_value": "123-456-7891"
 }
 },
 {
 "@id": "brokerContact1",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "broker@broker.com"
 },
 "has_phone_number": {
 "has_value": "111-111-1111"
 }
 },
 {
 "@id": "builderContact1",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "builder@builder.com"
 },
 "has_phone_number": {
 "has_value": "111-111-1112"
 }
 },
 {
 "@id": "buyingAgentContact1",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "buyingagent@buyingagent.com"
 },
 "has_phone_number": {
 "has_value": "111-111-1113"
 }
 },
 {
 "@id": "cpaContact1",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "cpa@cpa.com"
 },
 "has_phone_number": {
 "has_value": "111-111-1114"
 }
 },
 {
 "@id": "financialAdvisorContact1",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "financialadvisor@financialadvisor.com"
 },
 "has_phone_number": {
 "has_value": "111-111-1115"
 }
 },
 {
 "@id": "insuranceAgentContact1",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "insuranceagent@insuranceagent.com"
 },
 "has_phone_number": {
 "has_value": "111-111-1116"
 }
 },
 {
 "@id": "sellerCoordinatorContact1",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "sellercoordinator@sellercoordinator.com"
 },
 "has_phone_number": {
 "has_value": "111-111-1117"
 }
 },
 {
 "@id": "buyerCoordinatorContact1",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "buyercoordinator@buyercoordinator.com"
 },
 "has_phone_number": {
 "has_value": "111-111-1118"
 }
 },
 {
 "@id": "titleContact1",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "title@title.com"
 },
 "has_phone_number": {
 "has_value": "111-111-1119"
 }
 },
 {
 "@id": "buyerAttorneyContact1",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "buyerattorney@buyerattorney.com"
 },
 "has_phone_number": {
 "has_value": "111-111-1120"
 }
 },
 {
 "@id": "sellerAttorneyContact1",
 "@type": "contact_information",
 "has_email_address": {
 "has_value": "sellerattorney@sellerattorney.com"
 },
 "has_phone_number": {
 "has_value": "111-111-1121"
 }
 }
 ],
 "documents": [
 {
 "@id": "01GMDENWW0P6MY2EKFZFA94A6B",
 "@type": "loan_application",
 "with_borrower": [
 "01GMDENWW00NFVWWBJM3K645BD",
 "01GMDENWW01SSXFGNWDQBRFWSN"
 ]
 }
 ],
 "loan_statuses": [
 {
 "@id": "01GMDENWW0KHBK735TA3V2RAXE",
 "@type": "loan_status",
 "has_loan_status_identifier": {
 "has_value": "Started"
 }
 }
 ],
 "loans": [
 {
 "@id": "5c835f3f-14ca-49f5-9e38-99195d56a131",
 "@type": "loan",
 "has_loan_estimated_closing_date": {
 "has_value": "2012-04-23T18:25:43.511Z"
 },
 "has_loan_funding_date": {
 "has_value": "2012-04-23T18:25:43.511Z"
 },
 "with_loan_application": [
 "01GMDENWW0P6MY2EKFZFA94A6B"
 ],
 "with_loan_status": [
 "01GMDENWW0KHBK735TA3V2RAXE"
 ],
 "secured_by_property": [
 "sbp1"
 ],
 "with_down_payment": [
 "ldp1"
 ],
 "with_loan_terms": [
 "llt1"
 ],
 "with_loan_program": [
 "llp1"
 ],
 "with_ltv": [
 "lltv1"
 ],
 "with_closing_information": [
 "lci1"
 ],
 "with_loan_product": [
 "lp1"
 ]
 }
 ],
 "people": [
 {
 "@id": "admin",
 "@type": "loan_officer",
 "has_source_identifier": {
 "has_value": "TEBE11229152"
 }
 },
 {
 "@id": "01GMDENWW00NFVWWBJM3K645BD",
 "@type": "co_borrower",
 "contact_at": [
 "01GMDENWW094ER2ECJXJZXVAM2"
 ],
 "has_first_name": {
 "has_value": "amy"
 },
 "has_last_name": {
 "has_value": "america"
 }
 },
 {
 "@id": "01GMDENWW01SSXFGNWDQBRFWSN",
 "@type": "borrower",
 "contact_at": [
 "01GMDENWW02BG8YE3GAVXV6K28"
 ],
 "has_first_name": {
 "has_value": "andy"
 },
 "has_last_name": {
 "has_value": "america"
 }
 },
 {
 "@id": "broker1",
 "@type": "broker",
 "contact_at": [
 "brokerContact1"
 ],
 "has_first_name": {
 "has_value": "BrokerFirstName"
 },
 "has_last_name": {
 "has_value": "BrokerLastName"
 }
 },
 {
 "@id": "builder1",
 "@type": "builder",
 "contact_at": [
 "builderContact1"
 ],
 "has_first_name": {
 "has_value": "BuilderFirstName"
 },
 "has_last_name": {
 "has_value": "BuilderLastName"
 }
 },
 {
 "@id": "buyingAgent1",
 "@type": "buyer_agent",
 "contact_at": [
 "buyingAgentContact1"
 ],
 "has_first_name": {
 "has_value": "BuyingAgentFirstName"
 },
 "has_last_name": {
 "has_value": "BuyingAgentLastName"
 }
 },
 {
 "@id": "cpa1",
 "@type": "certified_public_accountant",
 "contact_at": [
 "cpaContact1"
 ],
 "has_first_name": {
 "has_value": "CpaFirstName"
 },
 "has_last_name": {
 "has_value": "CpaLastName"
 }
 },
 {
 "@id": "financialAdvisor1",
 "@type": "financial_advisor",
 "contact_at": [
 "financialAdvisorContact1"
 ],
 "has_first_name": {
 "has_value": "FinancialAdvisorFirstName"
 },
 "has_last_name": {
 "has_value": "FinancialAdvisorLastName"
 }
 },
 {
 "@id": "insuranceAgent1",
 "@type": "insurance_agent",
 "contact_at": [
 "insuranceAgentContact1"
 ],
 "has_first_name": {
 "has_value": "InsuranceAgentFirstName"
 },
 "has_last_name": {
 "has_value": "InsuranceAgentLastName"
 }
 },
 {
 "@id": "sellerCoordinator1",
 "@type": "seller_coordinator",
 "contact_at": [
 "sellerCoordinatorContact1"
 ],
 "has_first_name": {
 "has_value": "SellerCoordinatorFirstName"
 },
 "has_last_name": {
 "has_value": "SellerCoordinatorLastName"
 }
 },
 {
 "@id": "buyerCoordinator1",
 "@type": "loan_coordinator",
 "contact_at": [
 "buyerCoordinatorContact1"
 ],
 "has_first_name": {
 "has_value": "BuyerCoordinatorFirstName"
 },
 "has_last_name": {
 "has_value": "BuyerCoordinatorLastName"
 }
 },
 {
 "@id": "title1",
 "@type": "title_holder",
 "contact_at": [
 "titleContact1"
 ],
 "has_first_name": {
 "has_value": "TitleFirstName"
 },
 "has_last_name": {
 "has_value": "TitleLastName"
 }
 },
 {
 "@id": "buyerAttorney1",
 "@type": "attorney",
 "contact_at": [
 "buyerAttorneyContact1"
 ],
 "has_first_name": {
 "has_value": "BuyerAttorneyirstName"
 },
 "has_last_name": {
 "has_value": "BuyerAttorneyLastName"
 },
 "has_represented_party_type": {
 "has_value": "borrower"
 }
 },
 {
 "@id": "sellerAttorney1",
 "@type": "attorney",
 "contact_at": [
 "sellerAttorneyContact1"
 ],
 "has_first_name": {
 "has_value": "SellerAttorneyirstName"
 },
 "has_last_name": {
 "has_value": "SellerAttorneyLastName"
 },
 "has_represented_party_type": {
 "has_value": "other"
 }
 }
 ],
 "properties": [
 {
 "@id": "sbp1",
 "@type": "subject_property",
 "has_property_current_usage_type": {
 "has_value": "primary_residence"
 },
 "with_address": [
 "01GMDENWW0DN844A89DVD2BMSF"
 ],
 "with_sales_contract": [
 "psc1"
 ],
 "with_value": [
 "appraisedValue1"
 ]
 }
 ],
 "property_valuations": [
 {
 "@id": "appraisedValue1",
 "@type": "subject_property_valuation",
 "has_property_valuation_amount": {
 "has_value": 1000
 }
 }
 ],
 "down_payments": [
 {
 "@id": "ldp1",
 "@type": "down_payment",
 "has_down_payment_amount": {
 "has_value": 1000
 }
 }
 ],
 "loan_terms": [
 {
 "@id": "llt1",
 "@type": "loan_terms",
 "has_note_amount": {
 "has_value": 1234
 },
 "has_amortization_term_months_count": {
 "has_value": 360
 },
 "has_note_rate_percent": {
 "has_value": 7.5
 },
 "has_loan_purpose_type": {
 "has_value": "purchase"
 },
 "has_mortgage_type": {
 "has_value": "fha"
 }
 }
 ],
 "loan_programs": [
 {
 "@id": "llp1",
 "@type": "loan_program",
 "has_loan_program_identifier": {
 "has_value": "Indentured Servitude"
 }
 }
 ],
 "ltvs": [
 {
 "@id": "lltv1",
 "@type": "ltv",
 "has_ltv_ratio_percent": {
 "has_value": 1000.1
 }
 }
 ],
 "sales_contracts": [
 {
 "@id": "psc1",
 "@type": "property_sales_contract",
 "has_sales_contract_amount": {
 "has_value": 1000
 }
 }
 ],
 "closing_information": [
 {
 "@id": "lci1",
 "@type": "closing_information",
 "has_closing_date": {
 "has_value": "2012-04-23T18:25:43.511Z"
 }
 }
 ],
 "loan_products": [
 {
 "@id": "lp1",
 "@type": "loan_product",
 "with_lock": [
 "lpl1"
 ]
 }
 ],
 "locks": [
 {
 "@id": "lpl1",
 "@type": "lock",
 "has_lock_datetime": {
 "has_value": "2012-04-23T18:25:43.511Z"
 },
 "has_lock_expiration_datetime": {
 "has_value": "2012-04-23T18:25:43.511Z"
 }
 }
 ]
 }
}
```

<!--/source-->

##### Response

<!--source:api-specifications-->
201400403404
<!--/source-->

<!--source:api-specifications-->
application/json Copy Successfully started flow invocation.

```
{
 "invocation_id": "9aefb465-90fb-4d50-8ae6-2df2b58373f4",
 "invocation_mode": "single_flow",
 "invocation_status": "STARTED",
 "product_flow_name": "single-loan-transaction",
 "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4",
 "request_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK",
 "response_collection_id": "01F6NAQ4894HPMCBGB4P0G78HG",
 "widget_url": "",
 "_links": {
 "health_metrics": "https://YOUR_ENVIRONMENT_DOMAIN.staircaseapi.com/code-health-checker/metric/01F6NAMXWN2XVBD1YJ92A6S6R4?product_name=<redacted>"
 }
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Request data failed validation

```
{
 "message": "{'data': ['Missing data for required field.']}"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy 403 invalid error

```
{
 "message": "Please check the key you used to call this service",
 "url": "https://api.staircase.co/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post"
}
```

<!--/source-->

<!--source:api-specifications-->
text/html Copy Resource not found

```
<html>\r\n<head><title>400 Bad Request</title></head>\r\n<body>\r\n<center><h1>400 Bad Request</h1></center>\r\n</body>\r\n</html>\r\n
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
1
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |

##### Request body`application/json`

<!--source:api-specifications-->
10 fields
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `product_flow_name` | `string` | <!--source:api-specifications-->Product flow name. If it is not specified, the default product flow will be invoked. If the product has no default product flow, the first created flow will be invoked. Cannot be specified together with vendor_name.<!--/source--> |
| `vendor_name` | `string` | <!--source:api-specifications-->Vendor name. Cannot be specified together with product_flow_name.<!--/source--> |
| `transaction_id` | `string` | <!--source:api-specifications-->Transaction ID used for invocation.<!--/source--> |
| `request_collection_id` | `string` | <!--source:api-specifications-->Request Collection ID.<!--/source--> |
| `response_collection_id` | `string` | <!--source:api-specifications-->Response Collection ID.<!--/source--> |
| `callback_url` | `string (uri)` | <!--source:api-specifications-->Callback URL.<!--/source--> |
| `request_data` | `object` | <!--source:api-specifications-->Request JSON body.<!--/source--> |
| `tags` | `string[]` | <!--source:api-specifications-->List of tags.<!--/source--> |
| `options` | `object` | <!--source:api-specifications-->Additional information that should be passed to the connector but not be added to the request collection.<!--/source--> |
| `invocation_mode` | `string` | <!--source:api-specifications-->The invocation mode of a product flow single_flow or waterfall, default value single_flow<!--/source--> |

##### Response `201``application/json`

<!--source:api-specifications-->
12 fields
<!--/source-->
<!--source:api-specifications-->
Successfully started flow invocation.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `invocation_id`required | `string` | <!--source:api-specifications-->Invocation ID.<!--/source--> |
| `invocation_status`required | `string` | <!--source:api-specifications-->The status of the invocation.<!--/source-->`STARTED` |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID.<!--/source--> |
| `request_collection_id`required | `string` | <!--source:api-specifications-->Request collection ID.<!--/source--> |
| `response_collection_id`required | `string` | <!--source:api-specifications-->Response collection ID.<!--/source--> |
| `product_flow_name` | `string` | <!--source:api-specifications-->Product flow name.<!--/source--> |
| `metadata` | `object` | <!--source:api-specifications-->The metadata of the invoked product flow.<!--/source--> |
| `callback_url` | `string` | <!--source:api-specifications-->Callback URL.<!--/source--> |
| `request_data` | `object` | <!--source:api-specifications-->The data for the request collection.<!--/source--> |
| `tags` | `string[]` | <!--source:api-specifications-->List of tags.<!--/source--> |
| `options` | `object` | <!--source:api-specifications-->Additional information that should be passed to the connector but not be added to the request collection.<!--/source--> |
| `widget_url` | `string` | <!--source:api-specifications-->Product widget URL listening on the connector widget URL<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Request data failed validation
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
403 invalid error
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Error message.<!--/source--> |
| `url` | `string` | <!--source:api-specifications-->Error additional URL.<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Resource not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Message<!--/source--> |

`POST` `/products/encompass-dailyai/invocations`

<!--source:api-specifications-->

#### Move Historic Loan CRM data of a Loan Officer from Encompass to DailyAI
<!--/source-->

`invokeMoveLOLoansFromEncompassToDailyAIProductFlow`

<!--source:api-specifications-->
Move Loan CRM data of a Loan Officer from Encompass to DailyAI
<!--/source-->

<!--source:api-specifications-->

#### Move Loan CRM data of a Loan Officer from Encompass to DailyAI

This endpoint moves historic loan CRM data of a Loan Officer from Encompass to DailyAI.

`product_flow_name = "move-lo-loans-from-encompass-to-dailyai"`

You need to create a new `people` arrays in collection.

`people` array has 3 object elements:

- First object of `people`:
- You need to give Encompass loan officer id inside `@id` field, `loan_officer` value inside `@type` field and Encompass instance id inside `has_source_identifier/has_value`.

You can also specify number of loans to be retrieved as 'limit' in options field. In addition, in order to get loans modified at specific dates set 'start_date' and 'end_date' parameters in 'options'. Default value for limit is 1000. Maximum amount of loans to be retrieved at a time is 2500. Example request data:

Show the rest
```
{ 
 "options": {
 "limit": 100,
 "start_date": "2023-01-20",
 "end_date": "2023-01-31",
 },
 "request_data": {
 "people": [{
 "@id": "admin",
 "@type": "loan_officer",
 "has_source_identifier": {
 "has_value": "TEBE11229152"
 }
 }]
 }
}
```

This API can be used to retrieve number of loans given start and end dates.

After calling `move-lo-loans-from-encompass-to-dailyai` product flow invocation, you can retrieve invocation information using this API. Parameter product_name should be `encompass-dailyai` and invocation_id parameter should be the invocation_id value in the product flow invocation response body.

You can also check number of succeeded operations using this API. Add relevant transaction_id, start and end dates. Set "product_api_identifier" field to '5e43d84b-8dff-47c3-b6fe-9459a00f2d63', "product_identifier" field to '2545c293-c09a-47b5-99ec-c154d43aded1' and "status" field to "SUCCEEDED". Using resulting "query_id", you can retrieve all relevant metrics from this API.

<!--/source-->

##### Request

<!--source:api-specifications-->
move_lo_loans_from_encompass_to_daiylai_with_collection_idmove_lo_loans_from_encompass_to_daiylai_with_request_data
<!--/source-->

<!--source:api-specifications-->
application/json Copy
```
{
 "transaction_id": "01FV0H1MPRMAF6JAHJ6BAPYF9X",
 "product_flow_name": "single-loan-transaction",
 "request_collection_id": "01FV0H1MWC9N5F71DG0W79V0H3"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy
```
{
 "product_flow_name": "move-lo-loans-from-encompass-to-<redacted>",
 "request_data": {
 "people": [
 {
 "@id": "admin",
 "@type": "loan_officer",
 "has_source_identifier": {
 "has_value": "TEBE11229152"
 }
 }
 ]
 }
}
```

<!--/source-->

##### Response

<!--source:api-specifications-->
201400403404
<!--/source-->

<!--source:api-specifications-->
application/json Copy Successfully started flow invocation.

```
{
 "invocation_id": "9aefb465-90fb-4d50-8ae6-2df2b58373f4",
 "invocation_mode": "single_flow",
 "invocation_status": "STARTED",
 "product_flow_name": "single-loan-transaction",
 "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4",
 "request_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK",
 "response_collection_id": "01F6NAQ4894HPMCBGB4P0G78HG",
 "widget_url": "",
 "_links": {
 "health_metrics": "https://YOUR_ENVIRONMENT_DOMAIN.staircaseapi.com/code-health-checker/metric/01F6NAMXWN2XVBD1YJ92A6S6R4?product_name=<redacted>"
 }
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Request data failed validation

```
{
 "message": "{'data': ['Missing data for required field.']}"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy 403 invalid error

```
{
 "message": "Please check the key you used to call this service",
 "url": "https://api.staircase.co/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post"
}
```

<!--/source-->

<!--source:api-specifications-->
text/html Copy Resource not found

```
<html>\r\n<head><title>400 Bad Request</title></head>\r\n<body>\r\n<center><h1>400 Bad Request</h1></center>\r\n</body>\r\n</html>\r\n
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
1
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |

##### Request body`application/json`

<!--source:api-specifications-->
10 fields
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `product_flow_name` | `string` | <!--source:api-specifications-->Product flow name. If it is not specified, the default product flow will be invoked. If the product has no default product flow, the first created flow will be invoked. Cannot be specified together with vendor_name.<!--/source--> |
| `vendor_name` | `string` | <!--source:api-specifications-->Vendor name. Cannot be specified together with product_flow_name.<!--/source--> |
| `transaction_id` | `string` | <!--source:api-specifications-->Transaction ID used for invocation.<!--/source--> |
| `request_collection_id` | `string` | <!--source:api-specifications-->Request Collection ID.<!--/source--> |
| `response_collection_id` | `string` | <!--source:api-specifications-->Response Collection ID.<!--/source--> |
| `callback_url` | `string (uri)` | <!--source:api-specifications-->Callback URL.<!--/source--> |
| `request_data` | `object` | <!--source:api-specifications-->Request JSON body.<!--/source--> |
| `tags` | `string[]` | <!--source:api-specifications-->List of tags.<!--/source--> |
| `options` | `object` | <!--source:api-specifications-->Additional information that should be passed to the connector but not be added to the request collection.<!--/source--> |
| `invocation_mode` | `string` | <!--source:api-specifications-->The invocation mode of a product flow single_flow or waterfall, default value single_flow<!--/source--> |

##### Response `201``application/json`

<!--source:api-specifications-->
12 fields
<!--/source-->
<!--source:api-specifications-->
Successfully started flow invocation.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `invocation_id`required | `string` | <!--source:api-specifications-->Invocation ID.<!--/source--> |
| `invocation_status`required | `string` | <!--source:api-specifications-->The status of the invocation.<!--/source-->`STARTED` |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID.<!--/source--> |
| `request_collection_id`required | `string` | <!--source:api-specifications-->Request collection ID.<!--/source--> |
| `response_collection_id`required | `string` | <!--source:api-specifications-->Response collection ID.<!--/source--> |
| `product_flow_name` | `string` | <!--source:api-specifications-->Product flow name.<!--/source--> |
| `metadata` | `object` | <!--source:api-specifications-->The metadata of the invoked product flow.<!--/source--> |
| `callback_url` | `string` | <!--source:api-specifications-->Callback URL.<!--/source--> |
| `request_data` | `object` | <!--source:api-specifications-->The data for the request collection.<!--/source--> |
| `tags` | `string[]` | <!--source:api-specifications-->List of tags.<!--/source--> |
| `options` | `object` | <!--source:api-specifications-->Additional information that should be passed to the connector but not be added to the request collection.<!--/source--> |
| `widget_url` | `string` | <!--source:api-specifications-->Product widget URL listening on the connector widget URL<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Request data failed validation
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
403 invalid error
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Error message.<!--/source--> |
| `url` | `string` | <!--source:api-specifications-->Error additional URL.<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Resource not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Message<!--/source--> |

<!--source:api-specifications-->

### EncompassAdapter
<!--/source-->

`POST` `/products/encompass-adapter/invocations`

<!--source:api-specifications-->

#### Services
<!--/source-->

`invokeProductFlow`

<!--source:api-specifications-->
Encompass Orchestration
<!--/source-->

<!--source:api-specifications-->
This endpoint creates orchestration for Encompass. Using Encompass APIs orchestration calls a Staircase product.

<!--/source-->

##### Request

<!--source:api-specifications-->
invocation_with_collection_idinvocation_with_custom_credentialsinvocation_with_credentials_profile
<!--/source-->

<!--source:api-specifications-->
application/json Copy
```
{
 "transaction_id": "01FV0H1MPRMAF6JAHJ6BAPYF9X",
 "partner_name": "meridian",
 "request_collection_id": "01FV0H1MWC9N5F71DG0W79V0H3"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy
```
{
 "transaction_id": "01FV0H1MPRMAF6JAHJ6BAPYF9X",
 "options": {
 "credentials": {
 "client_id": "client_id",
 "client_secret": "<redacted>"
 }
 },
 "partner_name": "meridian",
 "request_collection_id": "01FV0H1MWC9N5F71DG0W79V0H3"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy
```
{
 "partner_name": "cbc",
 "options": {
 "credentials_profile": "profile-name"
 },
 "request_data": "..."
}
```

<!--/source-->

##### Response

<!--source:api-specifications-->
201400403404500
<!--/source-->

<!--source:api-specifications-->
application/json Copy Successfully started flow invocation.

```
{
 "invocation_id": "9aefb465-90fb-4d50-8ae6-2df2b58373f4",
 "invocation_status": "STARTED",
 "product_flow_name": "VOE",
 "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4",
 "request_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK",
 "response_collection_id": "01F6NAQ4894HPMCBGB4P0G78HG",
 "options": {
 "dry_run": false
 },
 "tags": [
 "manual verification"
 ],
 "widget_url": "https://product-dev-productsbucket-1j472c4onqkxw.s3.amazonaws.com/widgets/063f5f"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Request data failed validation

```
{
 "message": "{'data': ['Missing data for required field.']}"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy 403 invalid error

```
{
 "message": "Please check the key you used to call this service",
 "url": "https://api.staircase.co/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post"
}
```

<!--/source-->

<!--source:api-specifications-->
text/html Copy Resource not found

```
<html>\r\n<head><title>400 Bad Request</title></head>\r\n<body>\r\n<center><h1>400 Bad Request</h1></center>\r\n</body>\r\n</html>\r\n
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Internal server error

```
{
 "message": "The product has encountered an internal server error. If you have used a transaction_id to call our services, please submit it to Staircase support"
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
1
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |

##### Request body`application/json`

<!--source:api-specifications-->
6 fields
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `loan_id` | `string` | <!--source:api-specifications-->Loan ID<!--/source--> |
| `transaction_id` | `string` | <!--source:api-specifications-->Transaction ID used for invocation.<!--/source--> |
| `transaction_identifier` | `string` | <!--source:api-specifications-->Encompass transaction identifier.<!--/source--> |
| `product_name` | `string` | <!--source:api-specifications-->Product name to call.<!--/source--> |
| `partner_name` | `string` | <!--source:api-specifications-->Partner of product to call<!--/source--> |
| `options` | `object` | <!--source:api-specifications-->Request JSON body.<!--/source--> |
| `devconnect` | `boolean` | <!--source:api-specifications-->Use DevConnect or EPC<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Request data failed validation
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
403 invalid error
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Error message.<!--/source--> |
| `url` | `string` | <!--source:api-specifications-->Error additional URL.<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Resource not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `500``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Internal server error
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Error message.<!--/source--> |

##### Other responses

`201`

`GET` `/products/encompass-adapter/invocations/{invocation_id}`

<!--source:api-specifications-->

#### Retrieve Orchestration Verification Status
<!--/source-->

`RetrieveProductFlowInvocationStatus`

<!--source:api-specifications-->
Retrieves the status of running Product flow invocation.

<!--/source-->

##### Response

<!--source:api-specifications-->
200400403404500
<!--/source-->

<!--source:api-specifications-->
application/json Copy Successfully returned status of the Product flow Invocation.

```
{
 "invocation_id": "9aefb465-90fb-4d50-8ae6-2df2b58373f4",
 "invocation_status": "COMPLETED",
 "product_flow_name": "CBC",
 "service_invocation": {
 "Connector": {
 "connector_flow_name": "cbc-credit-flow",
 "invocation_id": "e75e8566-976d-4a15-b801-1e2301646f4e",
 "status": "COMPLETED"
 },
 "Language": {
 "input": {
 "translation_id": "0742bc3d-07ca-45fb-a4b7-e9bf627108d0",
 "from_language": "staircase-graph",
 "to_language": "credit-input",
 "status": "TRANSLATED"
 },
 "output": {
 "translation_id": "ad985392-1255-4dc0-8a26-bc166744c60c",
 "from_language": "staircase-graph",
 "to_language": "credit-mismo231",
 "status": "TRANSLATED"
 }
 }
 },
 "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4",
 "request_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK",
 "convert_request_collection_id": "01F6NAQ4894HPMCBGB4P0G9KX5",
 "response_collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN",
 "convert_response_collection_id": "01F6QF1QJF20DMSXH4SYXKBNS1",
 "connector_job_id": "3706b519-9426-4533-9868-14a7dec4fd97",
 "request_collection": {
 "collection_id": "01FCWSAQD3QDKEW91K7CPXN4Y2",
 "transaction_id": "01FCWSAH1RVMC0DH6GRQ9JSAE7",
 "data": {},
 "metadata": {
 "created_at": "2021-08-12T04:58:15.331517-04:00",
 "validation": false
 }
 },
 "response_collection": {
 "collection_id": "01FCWSAQD3QDKEW91K7CPXN4Y2",
 "transaction_id": "01FCWSAH1RVMC0DH6GRQ9JSAE7",
 "data": {},
 "metadata": {
 "created_at": "2021-08-12T04:58:15.331517-04:00",
 "validation": false,
 "report_download_urls": {
 "credit_report": {
 "download_url": "https://dev-data-manager-blobs-bucket-us-east-1-873429376159.s3.amazonaws.com/01FJYAHNJR",
 "blob_id": "01FCWSAQD3QDKEW91K7CPXN4Y2",
 "status": "Succeeded"
 }
 },
 "service_invocation": {
 "Connector": {
 "connector_flow_name": "cbc-credit-flow",
 "invocation_id": "e75e8566-976d-4a15-b801-1e2301646f4e",
 "status": "COMPLETED"
 },
 "Language": {
 "input": {
 "translation_id": "0742bc3d-07ca-45fb-a4b7-e9bf627108d0",
 "from_language": "staircase-graph",
 "to_language": "credit-input",
 "status": "TRANSLATED"
 },
 "output": {
 "translation_id": "ad985392-1255-4dc0-8a26-bc166744c60c",
 "from_language": "staircase-graph",
 "to_language": "credit-mismo231",
 "status": "TRANSLATED"
 }
 },
 "document_mapping": {
 "from_language": "staricase-graph",
 "to_language": "credit-report-language",
 "status": "TRANSLATED"
 },
 "report_mapping": {
 "status": "COMPLETED"
 }
 }
 }
 },
 "options": {
 "dry_run": false
 }
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Request data failed validation

```
{
 "message": "{'data': ['Missing data for required field.']}"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy 403 invalid error

```
{
 "message": "Please check the key you used to call this service",
 "url": "https://api.staircase.co/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post"
}
```

<!--/source-->

<!--source:api-specifications-->
text/html Copy Resource not found

```
<html>\r\n<head><title>400 Bad Request</title></head>\r\n<body>\r\n<center><h1>400 Bad Request</h1></center>\r\n</body>\r\n</html>\r\n
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Internal server error

```
{
 "message": "The product has encountered an internal server error. If you have used a transaction_id to call our services, please submit it to Staircase support"
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
2
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |
| `invocation_id` required | `string (ulid)` path | `d7ccedb8-8889-4657-add4-bc1s4xs97637` | <!--source:api-specifications-->Product flow invocation identifier<!--/source--> |

##### Response `200``application/json`

<!--source:api-specifications-->
13 fields
<!--/source-->
<!--source:api-specifications-->
Successfully returned status of the Product flow Invocation.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `invocation_id`required | `string` | <!--source:api-specifications-->Invocation ID.<!--/source--> |
| `invocation_status`required | `string` | <!--source:api-specifications-->Invocation Status.<!--/source-->`ACTION_REQUIRED``COMPLETED``FAILED``RUNNING``STARTED` |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID used for invocation.<!--/source--> |
| `request_collection_id` | `string` | <!--source:api-specifications-->Request Collection ID.<!--/source--> |
| `request_collection` | `object` | <!--source:api-specifications-->Collection.<!--/source--> |
| `transaction_id` | `string (ulid)` | <!--source:api-specifications-->Transaction ID.<!--/source-->Example `01EZQ32PJQGKRA6HR8D72Q9FFF` |
| `collection_id` | `string (ulid)` | <!--source:api-specifications-->Collection ID.<!--/source-->Example `01EZQ32PJQGKRA6HR8D72Q9FFF` |
| `data` | `object` | <!--source:api-specifications-->Data in Staircase language schema.<!--/source--> |
| `metadata` | `object` | <!--source:api-specifications-->Metadata about collection, f.e version of used Staircase schema.<!--/source--> |
| `response_collection_id` | `string` | <!--source:api-specifications-->Response Collection ID.<!--/source--> |
| `response_collection` | `object` | <!--source:api-specifications-->Collection.<!--/source--> |
| `transaction_id` | `string (ulid)` | <!--source:api-specifications-->Transaction ID.<!--/source-->Example `01EZQ32PJQGKRA6HR8D72Q9FFF` |
| `collection_id` | `string (ulid)` | <!--source:api-specifications-->Collection ID.<!--/source-->Example `01EZQ32PJQGKRA6HR8D72Q9FFF` |
| `data` | `object` | <!--source:api-specifications-->Data in Staircase language schema.<!--/source--> |
| `metadata` | `object` | <!--source:api-specifications-->Metadata about collection, f.e version of used Staircase schema.<!--/source--> |
| `report_download_urls`required | `object` | <!--source:api-specifications-->Information about each generated report identified by template name.<!--/source--> |
| `callback_url` | `string` | <!--source:api-specifications-->URL that was specified in flow invocation and will be used to send the callback when flow invocation will be finished.<!--/source--> |
| `widget_url` | `string (uri)` | <!--source:api-specifications-->URL of the widget.<!--/source--> |
| `metadata` | `object` | <!--source:api-specifications-->Response Collection ID.<!--/source--> |
| `options` | `—` | <!--source:api-specifications-->Options that were passed to the flow invocation.<!--/source--> |
| `connector_job_id` | `string` | <!--source:api-specifications-->Connector job ID.<!--/source--> |
| `service_invocation`required | `one of` | <!--source:api-specifications-->Includes underlying services invocation.<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Request data failed validation
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
403 invalid error
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Error message.<!--/source--> |
| `url` | `string` | <!--source:api-specifications-->Error additional URL.<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Resource not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `500``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Internal server error
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Error message.<!--/source--> |

<!--source:api-specifications-->

### Invocation
<!--/source-->

`POST` `/products/encompass-loan/invocations`

<!--source:api-specifications-->

#### Encompass Loan Invocation
<!--/source-->

`encompassLoanInvocations`

<!--source:api-specifications-->
Encompass Loan Invocation: is the main API in Encompass Loan that invokes the next jobs:

- conditions-underwriting
- upload-attachment-document

<!--/source-->

##### Request

<!--source:api-specifications-->
Create conditions underwritingUpload attachment document
<!--/source-->

<!--source:api-specifications-->
application/json Copy
```
{
 "product_flow_name": "conditions-underwriting",
 "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK",
 "request_collection_id": "01F7S0N7CQ31DZQYVSVPN66GNK"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy
```
{
 "product_flow_name": "upload-attachment-document",
 "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK",
 "request_collection_id": "01F7S0N7CQ31DZQYVSVPN66GNK"
}
```

<!--/source-->

##### Response

<!--source:api-specifications-->
201400
<!--/source-->

<!--source:api-specifications-->
application/json Copy Successfully started flow invocation.

```
{
 "invocation_id": "9aefb465-90fb-4d50-8ae6-2df2b58373f4",
 "invocation_status": "STARTED",
 "product_flow_name": "product_flow_name_example",
 "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4",
 "request_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK",
 "response_collection_id": "01F6NAQ4894HPMCBGB4P0G78HG",
 "options": {
 "dry_run": false
 },
 "tags": [
 "manual verification"
 ],
 "widget_url": "https://product-dev-productsbucket-1j472c4onqkxw.s3.amazonaws.com/widgets/063f5f"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
2
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |
| `Content-Type` required | `string` header | `application/json` | <!--source:api-specifications-->Content type<!--/source--> |

##### Request body`application/json`

<!--source:api-specifications-->
10 fields
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `product_flow_name` | `string` | <!--source:api-specifications-->Product flow name. If it is not specified, the default product flow will be invoked. If the product has no default product flow, the first created flow will be invoked. Cannot be specified together with vendor_name.<!--/source--> |
| `vendor_name` | `string` | <!--source:api-specifications-->Vendor name. Cannot be specified together with product_flow_name.<!--/source--> |
| `transaction_id` | `string` | <!--source:api-specifications-->Transaction ID used for invocation.<!--/source--> |
| `request_collection_id` | `string` | <!--source:api-specifications-->Request Collection ID.<!--/source--> |
| `response_collection_id` | `string` | <!--source:api-specifications-->Response Collection ID.<!--/source--> |
| `callback_url` | `string (uri)` | <!--source:api-specifications-->Callback URL.<!--/source--> |
| `request_data` | `object` | <!--source:api-specifications-->Request JSON body.<!--/source--> |
| `tags` | `string[]` | <!--source:api-specifications-->List of tags.<!--/source--> |
| `options` | `object` | <!--source:api-specifications-->Additional information that should be passed to the connector but not be added to the request collection.<!--/source--> |
| `invocation_mode` | `string` | <!--source:api-specifications-->The invocation mode of a product flow single_flow or waterfall, default value single_flow<!--/source--> |

##### Response `201``application/json`

<!--source:api-specifications-->
12 fields
<!--/source-->
<!--source:api-specifications-->
Successfully started flow invocation.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `invocation_id`required | `string` | <!--source:api-specifications-->Invocation ID.<!--/source--> |
| `invocation_status`required | `string` | <!--source:api-specifications-->The status of the invocation.<!--/source-->`STARTED` |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID.<!--/source--> |
| `request_collection_id`required | `string` | <!--source:api-specifications-->Request collection ID.<!--/source--> |
| `response_collection_id`required | `string` | <!--source:api-specifications-->Response collection ID.<!--/source--> |
| `product_flow_name` | `string` | <!--source:api-specifications-->Product flow name.<!--/source--> |
| `metadata` | `object` | <!--source:api-specifications-->The metadata of the invoked product flow.<!--/source--> |
| `callback_url` | `string` | <!--source:api-specifications-->Callback URL.<!--/source--> |
| `request_data` | `object` | <!--source:api-specifications-->The data for the request collection.<!--/source--> |
| `tags` | `string[]` | <!--source:api-specifications-->List of tags.<!--/source--> |
| `options` | `object` | <!--source:api-specifications-->Additional information that should be passed to the connector but not be added to the request collection.<!--/source--> |
| `widget_url` | `string` | <!--source:api-specifications-->Product widget_url listening on the connector widget_url<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which url the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner, flow or execution not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

`POST` `/products/homegen-price-loan/invocations`

<!--source:api-specifications-->

#### Homegen Price Loan Invocation
<!--/source-->

`homegenPriceLoanInvocations`

<!--source:api-specifications-->
Homegen Price Loan Invocation: is the main API in Homegen Price Loan that run the rules on collection containing:

- Loan information
- Daily Pricing
- Average Median Income Sample Request Collection below

```
{
 "data": {
 "loans": [
 {
 "@id": "cf38085b-2ac1-491b-9d4f-f18bc1cfd708",
 "@type": "loan",
 "with_borrower": {
 "@id": "fa726df9-c9aa-4732-8531-0dd93244a061",
 "@type": "borrower",
 "has_full_name": {
 "has_value": "John Doe"
 },
 "has_first_name": {
 "has_value": "John"
 },
 "has_last_name": {
 "has_value": &quShow the restot;Doe"
 },
 "has_middle_name": {
 "has_value": "Doe"
 },
 "owes_liability": {
 "@id": "7909d8a4-4f3c-40a7-b624-91cde372319d",
 "@type": "liability",
 "has_liability_monthly_payment_amount": {
 "has_value": 0
 }
 },
 "with_credit_score": {
 "@id": "00f75721-3911-42c9-ae88-1f7e8fda4e87",
 "@type": "credit_score",
 "has_credit_score_value": {
 "has_value": "600"
 }
 },
 "with_current_income": {
 "@id": "dcf9deda-52e4-41f3-8963-abbb5e1c678e",
 "@type": "current_income",
 "has_total_assessed_borrower_monthly_income_amount": {
 "has_value": 0
 }
 },
 "with_address": {
 "@id": "9d1321f1-adda-41e7-a8f5-30db15cd55a5",
 "@type": "residential_address",
 "has_country_code": {
 "has_value": "US"
 },
 "has_county_name": {
 "has_value": "Sufflock"
 },
 "has_state_code": {
 "has_value": "NY"
 },
 "has_address_line_1_text": {
 "has_value": "65 4th Ave"
 },
 "has_postal_code": {
 "has_value": "10003"
 },
 "has_city_name": {
 "has_value": "New York"
 }
 }
 },
 "with_government_loan": {
 "@id": "91429e3f-da1f-4f9f-b482-bd2297bf5237",
 "@type": "government_loan",
 "has_fha_loan_lender_identifier": {
 "has_value": "TEST220701994"
 }
 },
 "with_down_payment": {
 "@id": "a425d508-1833-4b62-8c4f-f35da1fd13ab",
 "@type": "down_payment",
 "has_down_payment_amount": {
 "has_value": 22495
 }
 },
 "with_down_payment_assistance_program": {
 "@id": "d0501ffc-e009-49b8-be92-962ff3d43ddb",
 "@type": "down_payment_assistance_program",
 "has_down_payment_assistance_program_name": {
 "has_value": "Forgivable 5%"
 }
 },
 "secured_by_property": {
 "@id": "466f4c41-3b7e-4ae6-ba06-39f338ba3096",
 "@type": "subject_property",
 "has_affordable_units_count": {
 "has_value": 2
 },
 "has_construction_method_type": {
 "has_value": "manufactured"
 }
 },
 "has_current_interest_rate_percent": {
 "has_value": 5.5
 },
 "with_loan_product": {
 "@id": "cd282cd7-0920-458d-a3da-5b7d1879d3a3",
 "@type": "loan_product",
 "with_lock": {
 "@id": "test-lock",
 "@type": "lock",
 "has_lock_status_type": {
 "has_value": "locked"
 },
 "has_lock_duration_days_count": {
 "has_value": 15
 }
 }
 },
 "with_loan_terms": {
 "@id": "aca9958b-8462-42e6-a829-2a950c5d038f",
 "@type": "loan_terms",
 "has_amortization_term_months_count": {
 "has_value": 120
 },
 "has_base_loan_amount": {
 "has_value": 449900
 }
 },
 "with_underwriting": {
 "@id": "d3714e40-efd0-4ee0-a62c-6dd2cbc07f52",
 "@type": "underwriting",
 "has_loan_manual_underwriting_indicator": {
 "has_value": true
 }
 },
 "has_loan_identifier_value": {
 "has_value": ""
 },
 "funded_by": {
 "@id": "f3e209b3-b666-4d0d-bda9-de597642b184",
 "@type": "lender",
 "with_address": {
 "@id": "9f5bc4ca-b600-4ab3-8529-bf10e79c4f88",
 "@type": "address",
 "has_full_address_text": {
 "has_value": "New York"
 }
 },
 "has_organization_name": {
 "has_value": "Modoc Agency"
 }
 }
 }
 ],
 "loan_price_quotes": [
 {
 "@id": "db45423d-5a48-4842-ac60-130768e524fb",
 "@type": "loan_price_quote",
 "has_loan_price_quote_identifier": {
 "has_value": "3030NHFAS"
 },
 "has_loan_price_quote_date": {
 "has_value": "2022-06-16"
 },
 "has_loan_price_lock_duration_days_count": {
 "has_value": 15
 },
 "with_loan_price_line_item": {
 "@id": "859aec5c-6d7e-4184-abff-322790946dc2",
 "@type": "loan_price_line_item",
 "has_loan_price_line_item_amount": {
 "has_value": 98.074565
 },
 "has_loan_price_line_item_percent": {
 "has_value": 5.125
 }
 }
 },
 {
 "@id": "08b7eed5-2951-4d63-b015-0f55800f6750",
 "@type": "loan_price_quote",
 "has_loan_price_quote_identifier": {
 "has_value": "3030NHFAS"
 },
 "has_loan_price_quote_date": {
 "has_value": "2022-06-16"
 },
 "has_loan_price_lock_duration_days_count": {
 "has_value": 15
 },
 "with_loan_price_line_item": {
 "@id": "39390c73-244a-491a-b069-143eca6b24d6",
 "@type": "loan_price_line_item",
 "has_loan_price_line_item_amount": {
 "has_value": 98.488641
 },
 "has_loan_price_line_item_percent": {
 "has_value": 5.25
 }
 }
 },
 {
 "@id": "bc4345a0-3e0f-4901-b12a-3b72855aa9cd",
 "@type": "loan_price_quote",
 "has_loan_price_quote_identifier": {
 "has_value": "3030NHFAS"
 },
 "has_loan_price_quote_date": {
 "has_value": "2022-06-16"
 },
 "has_loan_price_lock_duration_days_count": {
 "has_value": 15
 },
 "with_loan_price_line_item": {
 "@id": "92ba247d-2901-4e2a-a99b-12b0fd736fe0",
 "@type": "loan_price_line_item",
 "has_loan_price_line_item_amount": {
 "has_value": 97.614366
 },
 "has_loan_price_line_item_percent": {
 "has_value": 5.375
 }
 }
 },
 {
 "@id": "9929545d-20ca-4baf-8a3e-fb0aa52dd043",
 "@type": "loan_price_quote",
 "has_loan_price_quote_identifier": {
 "has_value": "3030NHFAS"
 },
 "has_loan_price_quote_date": {
 "has_value": "2022-06-16"
 },
 "has_loan_price_lock_duration_days_count": {
 "has_value": 15
 },
 "with_loan_price_line_item": {
 "@id": "f41f586b-ebe8-40da-9f78-8b9f2bdf84fb",
 "@type": "loan_price_line_item",
 "has_loan_price_line_item_amount": {
 "has_value": 98.072457
 },
 "has_loan_price_line_item_percent": {
 "has_value": 5.5
 }
 }
 }], 
 "income_limit_items": [
 {
 "@id": "00f75721-3911-42c9-ae88-1f7e8fda4e34",
 "@type": "income_limit_item",
 "has_income_limit_amount": {
 "has_value": 12345
 } 
 }
 ]
 },
 "metadata": {
 "validation": true,
 "version": 2
 }
 }
```

<!--/source-->

##### Request

<!--source:api-specifications-->
application/json Copy
```
{
 "product_flow_name": "homegen-price-loan",
 "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK",
 "request_collection_id": "01F7S0N7CQ31DZQYVSVPN66GNK"
}
```

<!--/source-->

##### Response

<!--source:api-specifications-->
201400
<!--/source-->

<!--source:api-specifications-->
application/json Copy Successfully started flow invocation.

```
{
 "invocation_id": "9aefb465-90fb-4d50-8ae6-2df2b58373f4",
 "invocation_status": "STARTED",
 "product_flow_name": "product_flow_name_example",
 "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4",
 "request_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK",
 "response_collection_id": "01F6NAQ4894HPMCBGB4P0G78HG",
 "options": {
 "dry_run": false
 },
 "tags": [
 "manual verification"
 ],
 "widget_url": "https://product-dev-productsbucket-1j472c4onqkxw.s3.amazonaws.com/widgets/063f5f"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
1
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |

##### Request body`application/json`

<!--source:api-specifications-->
10 fields
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `product_flow_name` | `string` | <!--source:api-specifications-->Product flow name. If it is not specified, the default product flow will be invoked. If the product has no default product flow, the first created flow will be invoked. Cannot be specified together with vendor_name.<!--/source--> |
| `vendor_name` | `string` | <!--source:api-specifications-->Vendor name. Cannot be specified together with product_flow_name.<!--/source--> |
| `transaction_id` | `string` | <!--source:api-specifications-->Transaction ID used for invocation.<!--/source--> |
| `request_collection_id` | `string` | <!--source:api-specifications-->Request Collection ID.<!--/source--> |
| `response_collection_id` | `string` | <!--source:api-specifications-->Response Collection ID.<!--/source--> |
| `callback_url` | `string (uri)` | <!--source:api-specifications-->Callback URL.<!--/source--> |
| `request_data` | `object` | <!--source:api-specifications-->Request JSON body.<!--/source--> |
| `tags` | `string[]` | <!--source:api-specifications-->List of tags.<!--/source--> |
| `options` | `object` | <!--source:api-specifications-->Additional information that should be passed to the connector but not be added to the request collection.<!--/source--> |
| `invocation_mode` | `string` | <!--source:api-specifications-->The invocation mode of a product flow single_flow or waterfall, default value single_flow<!--/source--> |

##### Response `201``application/json`

<!--source:api-specifications-->
12 fields
<!--/source-->
<!--source:api-specifications-->
Successfully started flow invocation.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `invocation_id`required | `string` | <!--source:api-specifications-->Invocation ID.<!--/source--> |
| `invocation_status`required | `string` | <!--source:api-specifications-->The status of the invocation.<!--/source-->`STARTED` |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID.<!--/source--> |
| `request_collection_id`required | `string` | <!--source:api-specifications-->Request collection ID.<!--/source--> |
| `response_collection_id`required | `string` | <!--source:api-specifications-->Response collection ID.<!--/source--> |
| `product_flow_name` | `string` | <!--source:api-specifications-->Product flow name.<!--/source--> |
| `metadata` | `object` | <!--source:api-specifications-->The metadata of the invoked product flow.<!--/source--> |
| `callback_url` | `string` | <!--source:api-specifications-->Callback URL.<!--/source--> |
| `request_data` | `object` | <!--source:api-specifications-->The data for the request collection.<!--/source--> |
| `tags` | `string[]` | <!--source:api-specifications-->List of tags.<!--/source--> |
| `options` | `object` | <!--source:api-specifications-->Additional information that should be passed to the connector but not be added to the request collection.<!--/source--> |
| `widget_url` | `string` | <!--source:api-specifications-->Product widget_url listening on the connector widget_url<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which URL the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner, flow or execution not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

`POST` `/products/homegen-update-price/invocations`

<!--source:api-specifications-->

#### Homegen Update Price Invocation
<!--/source-->

`homegenUpdatePriceInvocations`

<!--source:api-specifications-->
Homegen Update Price Invocation: is the main API in Homegen Price Loan that update the daily pricing and return collection. Following service is being used:

- update-price

Note: Convert Daily pricing csv into json using online tool such as , use that json as shown below in sample input

Sample Input to this service

```
{
 "product_flow_name":"update-price",
 "transaction_id": "01GF6J5CZN34C2MSXC29F7EXRV",
 "request_data":{
 "prices": [
 {
 "Date": "2022/06/16",
 "Time": "7:18:28",
 "Pricing ID": "3030NHFAS",
 "Yield.NoteRate": 5.125,
 "LockDays": 15,
 Show the rest"Price.SecurityBasePrice": 100.484375,
 "Yield.SecurityCoupon": 4.5,
 "Price.SecurityCouponSpread": 0.125,
 "Price.Servicing.Total": 2.032557,
 "Price.Servicing.BaseDetail": "[Rule] Phoenix Cap MSRs MV - Govt: GNMA 20-30 & $325,000 - $399,999 = -0.027833|[Rule] Phoenix Cap MSRs MV - Govt: GNMA 20-30 & FICO 641-680 = -0.100000|[Rate] Phoenix Cap Rate Shock - Govt 30: 56.5 bps & -0.5000 = +0.208642|[Rule] Phoenix Cap MSRs MV - Govt States: GNMA 30 56.5bps & CA = +1.951748",
 "Price.Pricing": -0.285,
 "Price.PricingDetail": "[Pricing] 15 Day Lock Adj = -0.285000",
 "Price.SecuritySettlementRoll": -0.657366,
 "Yield.NetGuarantorFee": 0.06,
 "Price.Total": 98.074565,
 "#Total-Price-Ceiling#": 98.0745655,
 "#Total-Price-Floor#": 97.3245655,
 "Price.LoanFeature": -3.625,
 "Price.LoanFeatureDetail": "[Rule] .Pricing: 3030NHFAS & DPA = -2.175000|[Rule] .Pricing: 3030NHFAS & Ops = -0.625000|[Rule] .Pricing: 3030NHFAS & Corp = -0.825000",
 "#Target-Price#": 98.0745655
 },
 {
 "Date": "2022/06/16",
 "Time": "7:18:28",
 "Pricing ID": "3030NHFAS",
 "Yield.NoteRate": 5.25,
 "LockDays": 15,
 "Price.SecurityBasePrice": 100.484375,
 "Yield.SecurityCoupon": 4.5,
 "Price.SecurityCouponSpread": 0.125,
 "Price.Servicing.Total": 2.446632,
 "Price.Servicing.BaseDetail": "[Rule] Phoenix Cap MSRs MV - Govt: GNMA 20-30 & $325,000 - $399,999 = -0.027833|[Rule] Phoenix Cap MSRs MV - Govt: GNMA 20-30 & FICO 641-680 = -0.100000|[Rate] Phoenix Cap Rate Shock - Govt 30: 69 bps & -0.3750 = +0.187906|[Rule] Phoenix Cap MSRs MV - Govt States: GNMA 30 69bps & CA = +2.386559",
 "Price.Pricing": -0.285,
 "Price.PricingDetail": "[Pricing] 15 Day Lock Adj = -0.285000",
 "Price.SecuritySettlementRoll": -0.657366,
 "Yield.NetGuarantorFee": 0.06,
 "Price.Total": 98.488641,
 "#Total-Price-Ceiling#": 98.48864055,
 "#Total-Price-Floor#": 97.73864055,
 "Price.LoanFeature": -3.625,
 "Price.LoanFeatureDetail": "[Rule] .Pricing: 3030NHFAS & DPA = -2.175000|[Rule] .Pricing: 3030NHFAS & Ops = -0.625000|[Rule] .Pricing: 3030NHFAS & Corp = -0.825000",
 "#Target-Price#": 98.48864055
 } 
 ]
 }
 }
```

<!--/source-->

##### Request

<!--source:api-specifications-->
application/json Copy
```
{
 "product_flow_name": "homegen-price-loan",
 "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK",
 "request_data": {
 "prices": [
 {
 "Date": "2022/06/16",
 "Pricing ID": "3030NHFAS",
 "Yield.NoteRate": 5.25,
 "LockDays": 15,
 "#Target-Price#": 98.48864055
 }
 ]
 }
}
```

<!--/source-->

##### Response

<!--source:api-specifications-->
201400
<!--/source-->

<!--source:api-specifications-->
application/json Copy Successfully started flow invocation.

```
{
 "invocation_id": "9aefb465-90fb-4d50-8ae6-2df2b58373f4",
 "invocation_status": "STARTED",
 "product_flow_name": "product_flow_name_example",
 "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4",
 "request_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK",
 "response_collection_id": "01F6NAQ4894HPMCBGB4P0G78HG",
 "options": {
 "dry_run": false
 },
 "tags": [
 "manual verification"
 ],
 "widget_url": "https://product-dev-productsbucket-1j472c4onqkxw.s3.amazonaws.com/widgets/063f5f"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
1
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |

##### Request body`application/json`

<!--source:api-specifications-->
10 fields
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `product_flow_name` | `string` | <!--source:api-specifications-->Product flow name. If it is not specified, the default product flow will be invoked. If the product has no default product flow, the first created flow will be invoked. Cannot be specified together with vendor_name.<!--/source--> |
| `vendor_name` | `string` | <!--source:api-specifications-->Vendor name. Cannot be specified together with product_flow_name.<!--/source--> |
| `transaction_id` | `string` | <!--source:api-specifications-->Transaction ID used for invocation.<!--/source--> |
| `request_collection_id` | `string` | <!--source:api-specifications-->Request Collection ID.<!--/source--> |
| `response_collection_id` | `string` | <!--source:api-specifications-->Response Collection ID.<!--/source--> |
| `callback_url` | `string (uri)` | <!--source:api-specifications-->Callback URL.<!--/source--> |
| `request_data` | `object` | <!--source:api-specifications-->Request JSON body.<!--/source--> |
| `tags` | `string[]` | <!--source:api-specifications-->List of tags.<!--/source--> |
| `options` | `object` | <!--source:api-specifications-->Additional information that should be passed to the connector but not be added to the request collection.<!--/source--> |
| `invocation_mode` | `string` | <!--source:api-specifications-->The invocation mode of a product flow single_flow or waterfall, default value single_flow<!--/source--> |

##### Response `201``application/json`

<!--source:api-specifications-->
12 fields
<!--/source-->
<!--source:api-specifications-->
Successfully started flow invocation.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `invocation_id`required | `string` | <!--source:api-specifications-->Invocation ID.<!--/source--> |
| `invocation_status`required | `string` | <!--source:api-specifications-->The status of the invocation.<!--/source-->`STARTED` |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID.<!--/source--> |
| `request_collection_id`required | `string` | <!--source:api-specifications-->Request collection ID.<!--/source--> |
| `response_collection_id`required | `string` | <!--source:api-specifications-->Response collection ID.<!--/source--> |
| `product_flow_name` | `string` | <!--source:api-specifications-->Product flow name.<!--/source--> |
| `metadata` | `object` | <!--source:api-specifications-->The metadata of the invoked product flow.<!--/source--> |
| `callback_url` | `string` | <!--source:api-specifications-->Callback URL.<!--/source--> |
| `request_data` | `object` | <!--source:api-specifications-->The data for the request collection.<!--/source--> |
| `tags` | `string[]` | <!--source:api-specifications-->List of tags.<!--/source--> |
| `options` | `object` | <!--source:api-specifications-->Additional information that should be passed to the connector but not be added to the request collection.<!--/source--> |
| `widget_url` | `string` | <!--source:api-specifications-->Product widget_url listening on the connector widget_url<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which URL the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner, flow or execution not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

`GET` `/products/encompass-loan/invocations/{invocation_id}`

<!--source:api-specifications-->

#### Retrieve Encompass Loan Invocation
<!--/source-->

`retrieveEncompassLoanInvocations`

<!--source:api-specifications-->
Retrieve Encompass Loan Invocation: Retrieves encompass loan execution status

<!--/source-->

##### Response

<!--source:api-specifications-->
200400
<!--/source-->

<!--source:api-specifications-->
application/json Copy Successfully returned status of the Product flow Invocation.

```
{
 "invocation_id": "9aefb465-90fb-4d50-8ae6-2df2b58373f4",
 "invocation_status": "COMPLETED",
 "product_flow_name": "product_flow_name_example",
 "service_invocation": {
 "Connector": {
 "connector_flow_name": "demo_flow",
 "invocation_id": "e75e8566-976d-4a15-b801-1e2301646f4e",
 "status": "COMPLETED"
 }
 },
 "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4",
 "request_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK",
 "convert_request_collection_id": "01F6NAQ4894HPMCBGB4P0G9KX5",
 "response_collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN",
 "convert_response_collection_id": "01F6QF1QJF20DMSXH4SYXKBNS1",
 "connector_job_id": "3706b519-9426-4533-9868-14a7dec4fd97",
 "request_collection": {
 "collection_id": "01FCWSAQD3QDKEW91K7CPXN4Y2",
 "transaction_id": "01FCWSAH1RVMC0DH6GRQ9JSAE7",
 "data": {},
 "metadata": {
 "created_at": "2021-08-12T04:58:15.331517-04:00",
 "validation": false
 }
 },
 "response_collection": {
 "collection_id": "01FCWSAQD3QDKEW91K7CPXN4Y2",
 "transaction_id": "01FCWSAH1RVMC0DH6GRQ9JSAE7",
 "data": {},
 "metadata": {
 "created_at": "2021-08-12T04:58:15.331517-04:00",
 "validation": false,
 "partner_name": "test_partner",
 "service_invocation": {
 "Connector": {
 "connector_flow_name": "demo_flow",
 "invocation_id": "e75e8566-976d-4a15-b801-1e2301646f4e",
 "status": "COMPLETED"
 }
 }
 }
 }
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
2
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `invocation_id` required | `string (ulid)` path | `d7ccedb8-8889-4657-add4-bc1s4xs97637` | <!--source:api-specifications-->Product flow invocation identifier<!--/source--> |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |

##### Response `200``application/json`

<!--source:api-specifications-->
13 fields
<!--/source-->
<!--source:api-specifications-->
Successfully returned status of the Product flow Invocation.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `invocation_id`required | `string` | <!--source:api-specifications-->Invocation ID.<!--/source--> |
| `invocation_status`required | `string` | <!--source:api-specifications-->Invocation Status.<!--/source-->`ACTION_REQUIRED``COMPLETED``FAILED``RUNNING``STARTED` |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID used for invocation.<!--/source--> |
| `request_collection_id` | `string` | <!--source:api-specifications-->Request Collection ID.<!--/source--> |
| `request_collection` | `object` | <!--source:api-specifications-->Request Collection data.<!--/source--> |
| `response_collection_id` | `string` | <!--source:api-specifications-->Response Collection ID.<!--/source--> |
| `response_collection` | `object` | <!--source:api-specifications-->Response Collection data.<!--/source--> |
| `callback_url` | `string` | <!--source:api-specifications-->URL that was specified in flow invocation and will be used to send the callback when flow invocation will be finished.<!--/source--> |
| `widget_url` | `string (uri)` | <!--source:api-specifications-->URL of the widget.<!--/source--> |
| `metadata` | `object` | <!--source:api-specifications-->Response Collection ID.<!--/source--> |
| `options` | `—` | <!--source:api-specifications-->Options that were passed to the flow invocation.<!--/source--> |
| `connector_job_id` | `string` | <!--source:api-specifications-->Connector job ID.<!--/source--> |
| `service_invocation`required | `object` | <!--source:api-specifications-->Includes underlying services invocation.<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which URL the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner, flow or execution not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

`GET` `/products/homegen-price-loan/invocations/{invocation_id}`

<!--source:api-specifications-->

#### Retrieve Homegen Price Loan Invocation
<!--/source-->

`retrieveHomegenLoanPriceInvocations`

<!--source:api-specifications-->
Retrieve Homegen Price Loan Invocation: Retrieves homegen price loan execution status

<!--/source-->

##### Response

<!--source:api-specifications-->
200400
<!--/source-->

<!--source:api-specifications-->
application/json Copy Successfully returned status of the Product flow Invocation.

```
{
 "invocation_id": "9aefb465-90fb-4d50-8ae6-2df2b58373f4",
 "invocation_status": "COMPLETED",
 "product_flow_name": "product_flow_name_example",
 "service_invocation": {
 "Connector": {
 "connector_flow_name": "demo_flow",
 "invocation_id": "e75e8566-976d-4a15-b801-1e2301646f4e",
 "status": "COMPLETED"
 }
 },
 "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4",
 "request_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK",
 "convert_request_collection_id": "01F6NAQ4894HPMCBGB4P0G9KX5",
 "response_collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN",
 "convert_response_collection_id": "01F6QF1QJF20DMSXH4SYXKBNS1",
 "connector_job_id": "3706b519-9426-4533-9868-14a7dec4fd97",
 "request_collection": {
 "collection_id": "01FCWSAQD3QDKEW91K7CPXN4Y2",
 "transaction_id": "01FCWSAH1RVMC0DH6GRQ9JSAE7",
 "data": {},
 "metadata": {
 "created_at": "2021-08-12T04:58:15.331517-04:00",
 "validation": false
 }
 },
 "response_collection": {
 "collection_id": "01FCWSAQD3QDKEW91K7CPXN4Y2",
 "transaction_id": "01FCWSAH1RVMC0DH6GRQ9JSAE7",
 "data": {},
 "metadata": {
 "created_at": "2021-08-12T04:58:15.331517-04:00",
 "validation": false,
 "partner_name": "test_partner",
 "service_invocation": {
 "Connector": {
 "connector_flow_name": "demo_flow",
 "invocation_id": "e75e8566-976d-4a15-b801-1e2301646f4e",
 "status": "COMPLETED"
 }
 }
 }
 }
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
2
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `invocation_id` required | `string (ulid)` path | `d7ccedb8-8889-4657-add4-bc1s4xs97637` | <!--source:api-specifications-->Product flow invocation identifier<!--/source--> |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |

##### Response `200``application/json`

<!--source:api-specifications-->
13 fields
<!--/source-->
<!--source:api-specifications-->
Successfully returned status of the Product flow Invocation.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `invocation_id`required | `string` | <!--source:api-specifications-->Invocation ID.<!--/source--> |
| `invocation_status`required | `string` | <!--source:api-specifications-->Invocation Status.<!--/source-->`ACTION_REQUIRED``COMPLETED``FAILED``RUNNING``STARTED` |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID used for invocation.<!--/source--> |
| `request_collection_id` | `string` | <!--source:api-specifications-->Request Collection ID.<!--/source--> |
| `request_collection` | `object` | <!--source:api-specifications-->Request Collection data.<!--/source--> |
| `response_collection_id` | `string` | <!--source:api-specifications-->Response Collection ID.<!--/source--> |
| `response_collection` | `object` | <!--source:api-specifications-->Response Collection data.<!--/source--> |
| `callback_url` | `string` | <!--source:api-specifications-->URL that was specified in flow invocation and will be used to send the callback when flow invocation will be finished.<!--/source--> |
| `widget_url` | `string (uri)` | <!--source:api-specifications-->URL of the widget.<!--/source--> |
| `metadata` | `object` | <!--source:api-specifications-->Response Collection ID.<!--/source--> |
| `options` | `—` | <!--source:api-specifications-->Options that were passed to the flow invocation.<!--/source--> |
| `connector_job_id` | `string` | <!--source:api-specifications-->Connector job ID.<!--/source--> |
| `service_invocation`required | `object` | <!--source:api-specifications-->Includes underlying services invocation.<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which URL the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner, flow or execution not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

`GET` `/products/homegen-update-price/invocations/{invocation_id}`

<!--source:api-specifications-->

#### Retrieve Homegen Update Price Loan Invocation
<!--/source-->

`retrieveHomegenUpdatePriceInvocations`

<!--source:api-specifications-->
Retrieve Homegen Update Price Invocation
<!--/source-->

<!--source:api-specifications-->
Retrieve Homegen Update Price Invocation: Retrieves homegen update price execution status

<!--/source-->

##### Response

<!--source:api-specifications-->
200400
<!--/source-->

<!--source:api-specifications-->
application/json Copy Successfully returned status of the Product flow Invocation.

```
{
 "invocation_id": "9aefb465-90fb-4d50-8ae6-2df2b58373f4",
 "invocation_status": "COMPLETED",
 "product_flow_name": "product_flow_name_example",
 "service_invocation": {
 "Connector": {
 "connector_flow_name": "demo_flow",
 "invocation_id": "e75e8566-976d-4a15-b801-1e2301646f4e",
 "status": "COMPLETED"
 }
 },
 "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4",
 "request_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK",
 "convert_request_collection_id": "01F6NAQ4894HPMCBGB4P0G9KX5",
 "response_collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN",
 "convert_response_collection_id": "01F6QF1QJF20DMSXH4SYXKBNS1",
 "connector_job_id": "3706b519-9426-4533-9868-14a7dec4fd97",
 "request_collection": {
 "collection_id": "01FCWSAQD3QDKEW91K7CPXN4Y2",
 "transaction_id": "01FCWSAH1RVMC0DH6GRQ9JSAE7",
 "data": {},
 "metadata": {
 "created_at": "2021-08-12T04:58:15.331517-04:00",
 "validation": false
 }
 },
 "response_collection": {
 "collection_id": "01FCWSAQD3QDKEW91K7CPXN4Y2",
 "transaction_id": "01FCWSAH1RVMC0DH6GRQ9JSAE7",
 "data": {},
 "metadata": {
 "created_at": "2021-08-12T04:58:15.331517-04:00",
 "validation": false,
 "partner_name": "test_partner",
 "service_invocation": {
 "Connector": {
 "connector_flow_name": "demo_flow",
 "invocation_id": "e75e8566-976d-4a15-b801-1e2301646f4e",
 "status": "COMPLETED"
 }
 }
 }
 }
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
2
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `invocation_id` required | `string (ulid)` path | `d7ccedb8-8889-4657-add4-bc1s4xs97637` | <!--source:api-specifications-->Product flow invocation identifier<!--/source--> |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |

##### Response `200``application/json`

<!--source:api-specifications-->
13 fields
<!--/source-->
<!--source:api-specifications-->
Successfully returned status of the Product flow Invocation.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `invocation_id`required | `string` | <!--source:api-specifications-->Invocation ID.<!--/source--> |
| `invocation_status`required | `string` | <!--source:api-specifications-->Invocation Status.<!--/source-->`ACTION_REQUIRED``COMPLETED``FAILED``RUNNING``STARTED` |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID used for invocation.<!--/source--> |
| `request_collection_id` | `string` | <!--source:api-specifications-->Request Collection ID.<!--/source--> |
| `request_collection` | `object` | <!--source:api-specifications-->Request Collection data.<!--/source--> |
| `response_collection_id` | `string` | <!--source:api-specifications-->Response Collection ID.<!--/source--> |
| `response_collection` | `object` | <!--source:api-specifications-->Response Collection data.<!--/source--> |
| `callback_url` | `string` | <!--source:api-specifications-->URL that was specified in flow invocation and will be used to send the callback when flow invocation will be finished.<!--/source--> |
| `widget_url` | `string (uri)` | <!--source:api-specifications-->URL of the widget.<!--/source--> |
| `metadata` | `object` | <!--source:api-specifications-->Response Collection ID.<!--/source--> |
| `options` | `—` | <!--source:api-specifications-->Options that were passed to the flow invocation.<!--/source--> |
| `connector_job_id` | `string` | <!--source:api-specifications-->Connector job ID.<!--/source--> |
| `service_invocation`required | `object` | <!--source:api-specifications-->Includes underlying services invocation.<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which URL the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner, flow or execution not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

`POST` `/products/homegen-eligibilty/invocations`

<!--source:api-specifications-->

#### Homegen Eligbility Invocation
<!--/source-->

`homegenElibilityInvocations`

<!--source:api-specifications-->
Homegen Eligbility Invocation: is the main API in Homegen Eligbility that run following service:

- check-eligibility

Sample Request Collection below

```
{
 "data": {
 "loans": [
 {
 "@id": "cf38085b-2ac1-491b-9d4f-f18bc1cfd708",
 "@type": "loan",
 "with_borrower": {
 "@id": "fa726df9-c9aa-4732-8531-0dd93244a061",
 "@type": "borrower",
 "has_full_name": {
 "has_value": "John Doe"
 },
 "with_address": {
 "@id": "9d1321f1-adda-41e7-a8f5-30db15cd55a5",
 "@type": "residential_address",
 "has_country_code": {
 "has_vShow the restalue": "US"
 },
 "has_county_name": {
 "has_value": "Sufflock"
 },
 "has_state_code": {
 "has_value": "NY"
 },
 "has_address_line_1_text": {
 "has_value": "65 4th Ave"
 },
 "has_postal_code": {
 "has_value": "10003"
 },
 "has_city_name": {
 "has_value": "New York"
 }
 }
 },
 "with_down_payment": {
 "@id": "a425d508-1833-4b62-8c4f-f35da1fd13ab",
 "@type": "down_payment",
 "has_down_payment_amount": {
 "has_value": 22495
 }
 },
 "with_down_payment_assistance_program": {
 "@id": "d0501ffc-e009-49b8-be92-962ff3d43ddb",
 "@type": "down_payment_assistance_program",
 "has_down_payment_assistance_program_name": {
 "has_value": "Forgivable 5%"
 }
 }
 }
 ]
 },
 "metadata": {
 "validation": true,
 "version": 2
 }
 }
```

<!--/source-->

##### Request

<!--source:api-specifications-->
application/json Copy
```
{
 "product_flow_name": "check-eligibility",
 "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK",
 "request_collection_id": "01F7S0N7CQ31DZQYVSVPN66GNK"
}
```

<!--/source-->

##### Response

<!--source:api-specifications-->
201400
<!--/source-->

<!--source:api-specifications-->
application/json Copy Successfully started flow invocation.

```
{
 "invocation_id": "9aefb465-90fb-4d50-8ae6-2df2b58373f4",
 "invocation_status": "STARTED",
 "product_flow_name": "product_flow_name_example",
 "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4",
 "request_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK",
 "response_collection_id": "01F6NAQ4894HPMCBGB4P0G78HG",
 "options": {
 "dry_run": false
 },
 "tags": [
 "manual verification"
 ],
 "widget_url": "https://product-dev-productsbucket-1j472c4onqkxw.s3.amazonaws.com/widgets/063f5f"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
1
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |

##### Request body`application/json`

<!--source:api-specifications-->
10 fields
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `product_flow_name` | `string` | <!--source:api-specifications-->Product flow name. If it is not specified, the default product flow will be invoked. If the product has no default product flow, the first created flow will be invoked. Cannot be specified together with vendor_name.<!--/source--> |
| `vendor_name` | `string` | <!--source:api-specifications-->Vendor name. Cannot be specified together with product_flow_name.<!--/source--> |
| `transaction_id` | `string` | <!--source:api-specifications-->Transaction ID used for invocation.<!--/source--> |
| `request_collection_id` | `string` | <!--source:api-specifications-->Request Collection ID.<!--/source--> |
| `response_collection_id` | `string` | <!--source:api-specifications-->Response Collection ID.<!--/source--> |
| `callback_url` | `string (uri)` | <!--source:api-specifications-->Callback URL.<!--/source--> |
| `request_data` | `object` | <!--source:api-specifications-->Request JSON body.<!--/source--> |
| `tags` | `string[]` | <!--source:api-specifications-->List of tags.<!--/source--> |
| `options` | `object` | <!--source:api-specifications-->Additional information that should be passed to the connector but not be added to the request collection.<!--/source--> |
| `invocation_mode` | `string` | <!--source:api-specifications-->The invocation mode of a product flow single_flow or waterfall, default value single_flow<!--/source--> |

##### Response `201``application/json`

<!--source:api-specifications-->
12 fields
<!--/source-->
<!--source:api-specifications-->
Successfully started flow invocation.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `invocation_id`required | `string` | <!--source:api-specifications-->Invocation ID.<!--/source--> |
| `invocation_status`required | `string` | <!--source:api-specifications-->The status of the invocation.<!--/source-->`STARTED` |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID.<!--/source--> |
| `request_collection_id`required | `string` | <!--source:api-specifications-->Request collection ID.<!--/source--> |
| `response_collection_id`required | `string` | <!--source:api-specifications-->Response collection ID.<!--/source--> |
| `product_flow_name` | `string` | <!--source:api-specifications-->Product flow name.<!--/source--> |
| `metadata` | `object` | <!--source:api-specifications-->The metadata of the invoked product flow.<!--/source--> |
| `callback_url` | `string` | <!--source:api-specifications-->Callback URL.<!--/source--> |
| `request_data` | `object` | <!--source:api-specifications-->The data for the request collection.<!--/source--> |
| `tags` | `string[]` | <!--source:api-specifications-->List of tags.<!--/source--> |
| `options` | `object` | <!--source:api-specifications-->Additional information that should be passed to the connector but not be added to the request collection.<!--/source--> |
| `widget_url` | `string` | <!--source:api-specifications-->Product widget_url listening on the connector widget_url<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which URL the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner, flow or execution not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

`GET` `/products/homegen-eligibility/invocations/{invocation_id}`

<!--source:api-specifications-->

#### Retrieve Homegen Eligibility Invocation
<!--/source-->

`retrieveHomegenEligibilityInvocations`

<!--source:api-specifications-->
Retrieve Homegen Eligibility Invocation: Retrieves homegen eligibility execution status

<!--/source-->

##### Response

<!--source:api-specifications-->
200400
<!--/source-->

<!--source:api-specifications-->
application/json Copy Successfully returned status of the Product flow Invocation.

```
{
 "invocation_id": "9aefb465-90fb-4d50-8ae6-2df2b58373f4",
 "invocation_status": "COMPLETED",
 "product_flow_name": "product_flow_name_example",
 "service_invocation": {
 "Connector": {
 "connector_flow_name": "demo_flow",
 "invocation_id": "e75e8566-976d-4a15-b801-1e2301646f4e",
 "status": "COMPLETED"
 }
 },
 "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4",
 "request_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK",
 "convert_request_collection_id": "01F6NAQ4894HPMCBGB4P0G9KX5",
 "response_collection_id": "01F6QF1QJF20DMSXH4SYXKB1SN",
 "convert_response_collection_id": "01F6QF1QJF20DMSXH4SYXKBNS1",
 "connector_job_id": "3706b519-9426-4533-9868-14a7dec4fd97",
 "request_collection": {
 "collection_id": "01FCWSAQD3QDKEW91K7CPXN4Y2",
 "transaction_id": "01FCWSAH1RVMC0DH6GRQ9JSAE7",
 "data": {},
 "metadata": {
 "created_at": "2021-08-12T04:58:15.331517-04:00",
 "validation": false
 }
 },
 "response_collection": {
 "collection_id": "01FCWSAQD3QDKEW91K7CPXN4Y2",
 "transaction_id": "01FCWSAH1RVMC0DH6GRQ9JSAE7",
 "data": {},
 "metadata": {
 "created_at": "2021-08-12T04:58:15.331517-04:00",
 "validation": false,
 "partner_name": "test_partner",
 "service_invocation": {
 "Connector": {
 "connector_flow_name": "demo_flow",
 "invocation_id": "e75e8566-976d-4a15-b801-1e2301646f4e",
 "status": "COMPLETED"
 }
 }
 }
 }
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
2
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `invocation_id` required | `string (ulid)` path | `d7ccedb8-8889-4657-add4-bc1s4xs97637` | <!--source:api-specifications-->Product flow invocation identifier<!--/source--> |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |

##### Response `200``application/json`

<!--source:api-specifications-->
13 fields
<!--/source-->
<!--source:api-specifications-->
Successfully returned status of the Product flow Invocation.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `invocation_id`required | `string` | <!--source:api-specifications-->Invocation ID.<!--/source--> |
| `invocation_status`required | `string` | <!--source:api-specifications-->Invocation Status.<!--/source-->`ACTION_REQUIRED``COMPLETED``FAILED``RUNNING``STARTED` |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID used for invocation.<!--/source--> |
| `request_collection_id` | `string` | <!--source:api-specifications-->Request Collection ID.<!--/source--> |
| `request_collection` | `object` | <!--source:api-specifications-->Request Collection data.<!--/source--> |
| `response_collection_id` | `string` | <!--source:api-specifications-->Response Collection ID.<!--/source--> |
| `response_collection` | `object` | <!--source:api-specifications-->Response Collection data.<!--/source--> |
| `callback_url` | `string` | <!--source:api-specifications-->URL that was specified in flow invocation and will be used to send the callback when flow invocation will be finished.<!--/source--> |
| `widget_url` | `string (uri)` | <!--source:api-specifications-->URL of the widget.<!--/source--> |
| `metadata` | `object` | <!--source:api-specifications-->Response Collection ID.<!--/source--> |
| `options` | `—` | <!--source:api-specifications-->Options that were passed to the flow invocation.<!--/source--> |
| `connector_job_id` | `string` | <!--source:api-specifications-->Connector job ID.<!--/source--> |
| `service_invocation`required | `object` | <!--source:api-specifications-->Includes underlying services invocation.<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which URL the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner, flow or execution not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

<!--source:api-specifications-->

### Partner Connect
<!--/source-->

`POST` `/products/encompass/invocations`

<!--source:api-specifications-->

#### Services
<!--/source-->

`invokeEPCProductFlow`

<!--source:api-specifications-->
This endpoint updates the status of ongoing transaction and returns the acknowledgment of change in the status of transaction

#### Send Acknowledgment

You need to provide `organizations` array with required `has_transaction_identifier` object. `has_transaction_identifier` object has `has_value` field, which contains the id of transaction for partner to update.

Show the rest
```
{
"organizations": [
{
"@id": "test",
"@type": "company",
"has_transaction_identifier": {
"has_value": "test"
}
}
]
}
```

At the end of invocation, the status of encompass transaction will be changed to "processing".

#### Send Complete Transaction

`product_flow_name = complete_encompass_transaction`

You need to provide `organizations` array with required `has_transaction_identifier` object. `has_transaction_identifier` object has `has_value` field, which contains the id of transaction for partner Request data for completion of transaction takes one more field - `documents` array, which must contain 4 fields:

- `@type`
- `has_document_identifier` - must have the resource id generated by EPC
- `has_document_name`
- `has_document_mime_type`

```
{
 ...
 "documents": [
 {
 "@id": "test",
 "@type": "test_verification",
 "has_document_mime_type": {
 "has_value": "application/pdf"
 },
 "has_document_name": {
 "has_value": "test.pdf"
 },
 "has_document_identifier":
 "has_value": "test"
 }
 ]
}
```

At the end of invocation, the status of encompass transaction will be changed to "complete".

#### Fail Encompass Transaction

`product_flow_name = fail_encompass_transaction`

To successfully update encompass transaction to "failed", `error_messages` array should be sent along with transaction identifier. It must contain 2 fields:

- `has_error_message_code`
- `has_error_message_text`

```
{
 ...
 "error_messages": [
 {
 "has_error_message_code": {
 "has_value": "404"
 },
 "has_error_message_text": {
 "has_value": "Bad request"
 }
 }
 ]
}
```

At the end of invocation, the status of encompass transaction will be changed to "failed".

#### Upload Report

`product_flow_name = upload_report`

Invoking this product flow allows uploading the report document to an external url provided by Encompass partner. Request data should contain `documents` and `organizations` arrays. "Documents" array must contain following fields:

- `@id`
- `@type`
- `has_document_name`
- `has_document_mime_type`
- `has_staircase_blob_identifier`

File name must have the same format as it is indicated in `has_document_mime_type` property. "Organizations" array must contain `has_transaction_identifier` property.

```
{
 "documents": [
 {
 "@type": "verification_test",
 "has_document_mime_type": {
 "has_value": "application/pdf"
 },
 "has_document_name": {
 "has_value": "document_name"
 },
 "has_staircase_blob_identifier": {
 "has_value": "01KLE2DOS978SFD92NFSQMBPS"
 },
 "has_staircase_document_category_type": {
 "has_value": "staircase"
 },
 "@id": "01SK3WHQ6GWX8QD0R4S092S"
 }
 ],
 "organizations": [
 {
 "@type": "company",
 "@id": "01GDDGYVTW975SCGZ0H84RRH6J",
 "has_organization_name": {
 "has_value": "partner"
 },
 "has_transaction_identifier": {
 "has_value": "test"
 }
 }
 ]
 }
```

The status after invocation is completed or failed can be found in response collection.

You can check the status of flow invocation by using this API. Invocation ID is retrieved from the response body of invocation.

<!--/source-->

##### Request

<!--source:api-specifications-->
send_acknowledgment_with_collection_idsend_acknowledgment_with_request_datacomplete_transaction_with_request_datafail_encompass_transaction_with_request_dataupload_report_with_request_data
<!--/source-->

<!--source:api-specifications-->
application/json Copy
```
{
 "transaction_id": "01FV0H1MPRMAF6JAHJ6BAPYF9X",
 "product_flow_name": "send_ack",
 "request_collection_id": "01FV0H1MWC9N5F71DG0W79V0H3"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy
```
{
 "product_flow_name": "send_ack",
 "request_data": {
 "organizations": [
 {
 "@id": "test",
 "@type": "company",
 "has_transaction_identifier": {
 "has_value": "01FV0H1MPRMAF6JAHJ6BAPYF9X"
 }
 }
 ]
 }
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy
```
{
 "product_flow_name": "complete_encompass_transaction",
 "request_data": {
 "organizations": [
 {
 "@id": "test",
 "@type": "company",
 "has_transaction_identifier": {
 "has_value": "01FV0H1MPRMAF6JAHJ6BAPYF9X"
 }
 }
 ],
 "documents": [
 {
 "@id": "test",
 "@type": "verification_test",
 "has_document_mime_type": {
 "has_value": "application/json"
 },
 "has_document_name": {
 "has_value": "test.json"
 },
 "has_document_identifier": {
 "has_value": "test"
 }
 }
 ]
 }
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy
```
{
 "product_flow_name": "fail_encompass_transaction",
 "request_data": {
 "organizations": [
 {
 "@id": "test",
 "@type": "company",
 "has_transaction_identifier": {
 "has_value": "01FV0H1MPRMAF6JAHJ6BAPYF9X"
 }
 }
 ],
 "error_messages": [
 {
 "@id": "test",
 "@type": "error",
 "has_error_message_code": {
 "has_value": "404"
 },
 "has_error_message_text": {
 "has_value": "Bad request"
 }
 }
 ]
 }
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy
```
{
 "product_flow_name": "upload_report",
 "request_data": {
 "organizations": [
 {
 "@id": "test",
 "@type": "company",
 "has_transaction_identifier": {
 "has_value": "01FV0H1MPRMAF6JAHJ6BAPYF9X"
 }
 }
 ],
 "documents": [
 {
 "@id": "test",
 "@type": "verification_test",
 "has_document_mime_type": {
 "has_value": "application/json"
 },
 "has_document_name": {
 "has_value": "test.json"
 },
 "has_staircase_blob_identifier": {
 "has_value": "01KLE2DOS978SFD92NFSQMBPS"
 }
 }
 ]
 }
}
```

<!--/source-->

##### Response

<!--source:api-specifications-->
201400403404
<!--/source-->

<!--source:api-specifications-->
application/json Copy Successfully started flow invocation.

```
{
 "invocation_id": "9aefb465-90fb-4d50-8ae6-2df2b58373f4",
 "invocation_mode": "single_flow",
 "invocation_status": "STARTED",
 "product_flow_name": "send_ack",
 "transaction_id": "01F6NAMXWN2XVBD1YJ92A6S6R4",
 "request_collection_id": "01F6NAQ4894HPMCBGB4P0G95XK",
 "response_collection_id": "01F6NAQ4894HPMCBGB4P0G78HG",
 "widget_url": "",
 "_links": {
 "health_metrics": "https://YOUR_ENVIRONMENT_DOMAIN.staircaseapi.com/code-health-checker/metric/01F6NAMXWN2XVBD1YJ92A6S6R4?product_name=encompass"
 }
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Request data failed validation

```
{
 "message": "{'data': ['Missing data for required field.']}"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy 403 invalid error

```
{
 "message": "Please check the key you used to call this service",
 "url": "https://api.staircase.co/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post"
}
```

<!--/source-->

<!--source:api-specifications-->
text/html Copy Resource not found

```
<html>\r\n<head><title>400 Bad Request</title></head>\r\n<body>\r\n<center><h1>400 Bad Request</h1></center>\r\n</body>\r\n</html>\r\n
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
1
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |

##### Request body`application/json`

<!--source:api-specifications-->
10 fields
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `product_flow_name` | `string` | <!--source:api-specifications-->Product flow name. If it is not specified, the default product flow will be invoked. If the product has no default product flow, the first created flow will be invoked. Cannot be specified together with vendor_name.<!--/source--> |
| `vendor_name` | `string` | <!--source:api-specifications-->Vendor name. Cannot be specified together with product_flow_name.<!--/source--> |
| `transaction_id` | `string` | <!--source:api-specifications-->Transaction ID used for invocation.<!--/source--> |
| `request_collection_id` | `string` | <!--source:api-specifications-->Request Collection ID.<!--/source--> |
| `response_collection_id` | `string` | <!--source:api-specifications-->Response Collection ID.<!--/source--> |
| `callback_url` | `string (uri)` | <!--source:api-specifications-->Callback URL.<!--/source--> |
| `request_data` | `object` | <!--source:api-specifications-->Request JSON body.<!--/source--> |
| `tags` | `string[]` | <!--source:api-specifications-->List of tags.<!--/source--> |
| `options` | `object` | <!--source:api-specifications-->Additional information that should be passed to the connector but not be added to the request collection.<!--/source--> |
| `invocation_mode` | `string` | <!--source:api-specifications-->The invocation mode of a product flow single_flow or waterfall, default value single_flow<!--/source--> |

##### Response `201``application/json`

<!--source:api-specifications-->
12 fields
<!--/source-->
<!--source:api-specifications-->
Successfully started flow invocation.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `invocation_id`required | `string` | <!--source:api-specifications-->Invocation ID.<!--/source--> |
| `invocation_status`required | `string` | <!--source:api-specifications-->The status of the invocation.<!--/source-->`STARTED` |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID.<!--/source--> |
| `request_collection_id`required | `string` | <!--source:api-specifications-->Request collection ID.<!--/source--> |
| `response_collection_id`required | `string` | <!--source:api-specifications-->Response collection ID.<!--/source--> |
| `product_flow_name` | `string` | <!--source:api-specifications-->Product flow name.<!--/source--> |
| `metadata` | `object` | <!--source:api-specifications-->The metadata of the invoked product flow.<!--/source--> |
| `callback_url` | `string` | <!--source:api-specifications-->Callback URL.<!--/source--> |
| `request_data` | `object` | <!--source:api-specifications-->The data for the request collection.<!--/source--> |
| `tags` | `string[]` | <!--source:api-specifications-->List of tags.<!--/source--> |
| `options` | `object` | <!--source:api-specifications-->Additional information that should be passed to the connector but not be added to the request collection.<!--/source--> |
| `widget_url` | `string` | <!--source:api-specifications-->Product widget URL listening on the connector widget URL<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Request data failed validation
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
403 invalid error
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Error message.<!--/source--> |
| `url` | `string` | <!--source:api-specifications-->Error additional URL.<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Resource not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Message<!--/source--> |

`GET` `/products/encompass/invocations/{invocation_id}`

<!--source:api-specifications-->

#### Retrieve Status
<!--/source-->

`RetrieveProductFlowInvocationStatus`

<!--source:api-specifications-->
Services
<!--/source-->

<!--source:api-specifications-->
Retrieves the status of running Product flow invocation.

<!--/source-->

##### Response

<!--source:api-specifications-->
200400403404500
<!--/source-->

<!--source:api-specifications-->
application/json Copy Successfully returned status of the Product flow Invocation.

```
{
 "status": "SUCCEEDED",
 "message": "Invocation completed successfully",
 "created_at": "2022-01-22T04:54:13.507355-05:00",
 "invocation_status": "COMPLETED",
 "last_updated_at": "2022-01-22T04:55:31.399320-05:00"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Request data failed validation

```
{
 "message": "{'data': ['Missing data for required field.']}"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy 403 invalid error

```
{
 "message": "Please check the key you used to call this service",
 "url": "https://api.staircase.co/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post"
}
```

<!--/source-->

<!--source:api-specifications-->
text/html Copy Resource not found

```
<html>\r\n<head><title>400 Bad Request</title></head>\r\n<body>\r\n<center><h1>400 Bad Request</h1></center>\r\n</body>\r\n</html>\r\n
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Internal server error

```
{
 "message": "The product has encountered an internal server error. If you have used a transaction_id to call our services, please submit it to Staircase support"
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
2
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |
| `invocation_id` required | `string (ulid)` path | `d7ccedb8-8889-4657-add4-bc1s4xs97637` | <!--source:api-specifications-->Product flow invocation identifier<!--/source--> |

##### Response `200``application/json`

<!--source:api-specifications-->
5 fields
<!--/source-->
<!--source:api-specifications-->
Successfully returned status of the Product flow Invocation.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `status` | `string` | <!--source:api-specifications-->Mapped status of the invocation.<!--/source-->Example `STARTED` |
| `message` | `string` | <!--source:api-specifications-->Message.<!--/source-->Example `Verification is completed, please check response collection to see verification data.` |
| `created_at` | `string` | <!--source:api-specifications-->Time of creation<!--/source--> |
| `invocation_status` | `string` | <!--source:api-specifications-->Status of the product invocation before mapping<!--/source--> |
| `last_updated_at` | `string` | <!--source:api-specifications-->Last time the collection was updated<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Request data failed validation
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
403 invalid error
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Error message.<!--/source--> |
| `url` | `string` | <!--source:api-specifications-->Error additional URL.<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Resource not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `500``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Internal server error
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Error message.<!--/source--> |

<!--source:api-specifications-->

### Persistence
<!--/source-->

`POST` `/transactions`

<!--source:api-specifications-->

#### Create Transaction
<!--/source-->

`create_transaction`

<!--source:api-specifications-->
Create empty transaction You can subscribe to every changes inside transaction by providing `callback_url` in body, and you will receive `POST` request to this url, with your `x-api-key` in headers. If you respond with a non `2XX` status code or not within 6 sec, requests will be retried during 5 minutes every 2 seconds, you can indicate if you already processed that event, but for some reasons respond with non `2XX` code by `id` parameter. `type` parameter indicates type of the event.

Show the rest

| Event type | Description |
| --- | --- |
| co.staircase.persistence.collection_created | New collection was created |
| co.staircase.persistence.collection_data_inserted | Data was added to collection |
| co.staircase.persistence.collection_metadata_updated | Metadata of collection was updated |
| co.staircase.persistence.collection_updated | Both metadata and data of collection was updated |
| Event structure is cloudevents, so you can use any tools that supports it or SDK ```json json_schema |  |
| { |  |
| "type": "object", |  |
| "$schema": "", |  |
| "properties": { |  |
| "specversion": { |  |
| "type": "string", |  |
| "description": "Version of cloudevents event structure" |  |
| }, |  |
| "id": { |  |
| "type": "string", |  |
| "description": "Unique identifier of the event, for retired requests will always be the same" |  |
| }, |  |
| "source": { |  |
| "type": "string", |  |
| "description": "Source of the event, for Persistence it will always be co.staircase.persistence", |  |
| "const": "persistence" |  |
| }, |  |
| "type": { |  |
| "type": "string", |  |
| "description": "Name of the event, that indicates, what happened", |  |
| "enum": [ |  |
| "co.staircase.persistence.collection_created", |  |
| "co.staircase.persistence.collection_data_inserted", |  |
| "co.staircase.persistence.collection_metadata_updated", |  |
| "co.staircase.persistence.collection_updated" |  |
| ] |  |
| }, |  |
| "time": { |  |
| "type": "string", |  |
| "format": "date-time", |  |
| "description": "Timestamp of when the occurrence happened." |  |
| }, |  |
| "data": { |  |
| "type": "object", |  |
| "properties": { |  |
| "transaction_id": { |  |
| "type": "string", |  |
| "format": "ulid", |  |
| "description": "Transaction id" |  |
| }, |  |
| "collection_id": { |  |
| "type": "string", |  |
| "format": "ulid", |  |
| "description": "Collection id" |  |
| }, |  |
| "collection": { |  |
| "type": "object", |  |
| "description": "Collection itself" |  |
| } |  |
| } |  |
| } |  |
| } |  |
| } |  |
| ``` You can assign label to transaction by providing `label` field. To search for transaction using label you should use Retrieve List of Transactions endpoint |  |

<!--/source-->

##### Request

<!--source:api-specifications-->
application/json Copy
```
{
 "label": "first_transaction"
}
```

<!--/source-->

##### Response

<!--source:api-specifications-->
201400
<!--/source-->

<!--source:api-specifications-->
application/json Copy Transaction have been created

```
{
 "transaction_id": "01EZQ32PJQGKRA6HR8D72Q9FFF",
 "created_at": "03/01/2021, 2:29:07 PM EST"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Request data failed validation

```
{
 "message": "{'data': ['Missing data for required field.']}"
}
```

<!--/source-->

##### Request body`application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `callback_url` | `string (url)` | <!--source:api-specifications-->URL for receiving events about changes inside transaction<!--/source--> |
| `label` | `string` | <!--source:api-specifications-->Transaction label<!--/source--> |

##### Response `201``application/json`

<!--source:api-specifications-->
5 fields
<!--/source-->
<!--source:api-specifications-->
Transaction have been created
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `transaction_id` | `string (ulid)` | <!--source:api-specifications-->Transaction id<!--/source-->Example `01EZQ32PJQGKRA6HR8D72Q9FFF` |
| `created_at` | `string` | <!--source:api-specifications-->Datetime, when transaction was created<!--/source--> |
| `callback_url` | `string` | <!--source:api-specifications-->Callback url<!--/source--> |
| `label` | `string` | <!--source:api-specifications-->Transaction label<!--/source--> |
| `_links` | `object` | <!--source:api-specifications-->Links<!--/source--> |
| `collections` | `string (url)` | <!--source:api-specifications-->Link to transaction collections<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Request data failed validation
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Missing API key
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `429``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
The user has sent too many requests in a given amount of time ("rate limiting")
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Message<!--/source--> |

`POST` `/transactions/{transaction_id}/collections`

<!--source:api-specifications-->

#### Create Collection
<!--/source-->

`create_collection`

##### Request

<!--source:api-specifications-->
application/json Copy
```
{
 "metadata": {
 "version": 2,
 "validation": true,
 "linked_collections": [
 {
 "collection_id": "01EZQ32PJQGKRA6HR8D72Q9FFF",
 "label": "Employment Verification Report"
 }
 ]
 },
 "data": {
 "people": [
 {
 "@type": "borrower",
 "@id": "01FDF04MYHEZ98AD7T8ZGY5CMB",
 "has_first_name": {
 "has_value": "John"
 },
 "has_last_name": {
 "has_value": "Deere"
 },
 "has_birth_date": {
 "has_value": "1985-01-01"
 },
 "has_taxpayer_identifier_value": {
 "has_value": "999-00-0000"
 },
 "contact_at": [
 "01FDF09BNQCT03DCAX7M5KM52T"
 ],
 "employed_as": [
 "01FDF0DFYAHBRJGFA5RS26HVP1"
 ]
 }
 ],
 "addresses": [
 {
 "@id": "01FDF077N6V7R2RNC64DGT31DY",
 "@type": "business_address",
 "has_address_line_1_text": {
 "has_value": "33 IRVING PLACE",
 "data_sourced_from": [
 "01FDF10040SA2VTETKJQXJ3MQZ"
 ]
 },
 "has_address_line_2_text": {
 "has_value": "additional_line_text",
 "data_sourced_from": [
 "01FDF10040SA2VTETKJQXJ3MQZ"
 ]
 },
 "has_city_name": {
 "has_value": "NEW YORK",
 "data_sourced_from": [
 "01FDF10040SA2VTETKJQXJ3MQZ"
 ]
 },
 "has_postal_code": {
 "has_value": "10003",
 "data_sourced_from": [
 "01FDF10040SA2VTETKJQXJ3MQZ"
 ]
 },
 "has_country_name": {
 "has_value": "US",
 "data_sourced_from": [
 "01FDF10040SA2VTETKJQXJ3MQZ"
 ]
 }
 }
 ],
 "contact_information": [
 {
 "@type": "contact_information",
 "@id": "01FDF09BNQCT03DCAX7M5KM52T",
 "has_phone_number": {
 "has_value": "+1234567890"
 }
 }
 ],
 "employment": [
 {
 "@type": "employment",
 "@id": "01FDF0DFYAHBRJGFA5RS26HVP1",
 "has_employment_position_description": {
 "has_value": "Engineer",
 "data_sourced_from": [
 "01FDF10040SA2VTETKJQXJ3MQZ"
 ]
 },
 "provided_by": [
 "01FDF0G4BP9AE6B7FT5VDEWK5F"
 ]
 }
 ],
 "organizations": [
 {
 "@type": "organization",
 "@id": "01FDF0G4BP9AE6B7FT5VDEWK5F",
 "has_organization_name": {
 "has_value": "GRAIN PROCESSING COR",
 "data_sourced_from": [
 "01FDF10040SA2VTETKJQXJ3MQZ"
 ]
 },
 "with_address": [
 "01FDF077N6V7R2RNC64DGT31DY"
 ]
 }
 ],
 "mortgage_products": [
 {
 "@type": "employment",
 "@id": "01FDF10040SA2VTETKJQXJ3MQZ",
 "has_data_source_date": {
 "has_value": "1972-01-01"
 },
 "has_purpose_of_verification_description": {
 "has_value": "risk-assessment"
 }
 }
 ],
 "documents": [
 {
 "@type": "irs_w2",
 "@id": "01FS9VK2BVSBZYN0MMYQQ73KAZ",
 "has_document_description": {
 "has_value": "Employment Verification Report prepared by Staircase"
 },
 "has_document_mime_type": {
 "has_value": "application/pdf"
 },
 "has_document_name": {
 "has_value": "01FD9X8V5N804Y0CFWY7F72ZCD.pdf"
 }
 }
 ]
 }
}
```

<!--/source-->

##### Response

<!--source:api-specifications-->
201400404
<!--/source-->

<!--source:api-specifications-->
application/json Copy 201 response

```
{
 "transaction_id": "01FJCADX5QEXEDVRWNXAK206MA",
 "collection_id": "01FJCAQW7EYJAA6FY05WRKRM3T",
 "metadata": {
 "version": 2
 },
 "data": {
 "people": [
 {
 "@type": "borrower",
 "@id": "01FDF04MYHEZ98AD7T8ZGY5CMB",
 "has_first_name": {
 "has_value": "John"
 },
 "has_last_name": {
 "has_value": "Deere"
 },
 "has_birth_date": {
 "has_value": "01/01/1985"
 },
 "has_taxpayer_identifier_value": {
 "has_value": "999-00-0000"
 },
 "contact_at": [
 "01FDF09BNQCT03DCAX7M5KM52T"
 ],
 "employed_as": [
 "01FDF0DFYAHBRJGFA5RS26HVP1"
 ]
 }
 ],
 "addresses": [
 {
 "@id": "01FDF077N6V7R2RNC64DGT31DY",
 "@type": "business_address",
 "has_address_line_1_text": {
 "has_value": "33 IRVING PLACE",
 "data_sourced_from": [
 "01FDF10040SA2VTETKJQXJ3MQZ"
 ]
 },
 "has_address_line_2_text": {
 "has_value": "additional_line_text",
 "data_sourced_from": [
 "01FDF10040SA2VTETKJQXJ3MQZ"
 ]
 },
 "has_city_name": {
 "has_value": "NEW YORK",
 "data_sourced_from": [
 "01FDF10040SA2VTETKJQXJ3MQZ"
 ]
 },
 "has_postal_code": {
 "has_value": "10003",
 "data_sourced_from": [
 "01FDF10040SA2VTETKJQXJ3MQZ"
 ]
 },
 "has_country_name": {
 "has_value": "US",
 "data_sourced_from": [
 "01FDF10040SA2VTETKJQXJ3MQZ"
 ]
 }
 }
 ],
 "contact_information": [
 {
 "@type": "contact_information",
 "@id": "01FDF09BNQCT03DCAX7M5KM52T",
 "has_phone_number": {
 "has_value": "+1234567890"
 }
 }
 ],
 "employment": [
 {
 "@type": "employment",
 "@id": "01FDF0DFYAHBRJGFA5RS26HVP1",
 "has_employment_position_description": {
 "has_value": "Engineer",
 "data_sourced_from": [
 "01FDF10040SA2VTETKJQXJ3MQZ"
 ]
 },
 "provided_by": [
 "01FDF0G4BP9AE6B7FT5VDEWK5F"
 ]
 }
 ],
 "organizations": [
 {
 "@type": "organization",
 "@id": "01FDF0G4BP9AE6B7FT5VDEWK5F",
 "has_organization_name": {
 "has_value": "GRAIN PROCESSING COR",
 "data_sourced_from": [
 "01FDF10040SA2VTETKJQXJ3MQZ"
 ]
 },
 "has_transaction_identifier": {
 "has_value": "e171ec31-75b4-4fd6-ada1",
 "data_sourced_from": [
 "01FDF10040SA2VTETKJQXJ3MQZ"
 ]
 },
 "with_address": [
 "01FDF077N6V7R2RNC64DGT31DY"
 ]
 }
 ],
 "mortgage_products": [
 {
 "@type": "employment",
 "@id": "01FDF10040SA2VTETKJQXJ3MQZ",
 "has_data_source_date": {
 "has_value": "01/01/1972"
 },
 "has_purpose_of_verification_description": {
 "has_value": "risk-assessment"
 }
 }
 ],
 "documents": [
 {
 "@type": "irs_w2",
 "has_staircase_document_category_type": {
 "has_value": "staircase"
 },
 "has_document_description": {
 "has_value": "Employment Verification Report prepared by Staircase"
 },
 "has_document_mime_type": {
 "has_value": "application/pdf"
 },
 "has_document_name": {
 "has_value": "01FD9X8V5N804Y0CFWY7F72ZCD.pdf"
 }
 }
 ]
 }
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Request data failed validation

```
{
 "message": "{'data': ['Missing data for required field.']}"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Requested resource not found

```
{
 "message": "Collection not found"
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
1
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `transaction_id` required | `string (ulid)` path | `01FJCADX5QEXEDVRWNXAK206MA` | <!--source:api-specifications-->Transaction ID<!--/source--> |

##### Request body`application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `data`required | `object` | <!--source:api-specifications-->Collection data<!--/source--> |
| `metadata` | `object` | <!--source:api-specifications-->Collection metadata. Maximum allowable length of the dumped json object - 400 000 symbols.<!--/source--> |
| `version` | `integer` | <!--source:api-specifications-->Version of staircase language with what collection has been created.<!--/source-->`0``2` |
| `validation` | `boolean` | <!--source:api-specifications-->Flag that enables validation<!--/source--> |
| `linked_collections` | `object[]` | <!--source:api-specifications-->List of linked collections<!--/source--> |
| `collection_id` | `string (ulid)` | <!--source:api-specifications-->Collection ID of linked collection<!--/source--> |
| `label` | `string` | <!--source:api-specifications-->Label of linked collection<!--/source--> |

##### Response `201``application/json`

<!--source:api-specifications-->
4 fields
<!--/source-->
<!--source:api-specifications-->
201 response
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `transaction_id` | `string (ulid)` | <!--source:api-specifications-->Transaction id<!--/source-->Example `01EZQ32PJQGKRA6HR8D72Q9FFF` |
| `collection_id` | `string (ulid)` | <!--source:api-specifications-->Collection id<!--/source-->Example `01EZQ32PJQGKRA6HR8D72Q9FFF` |
| `data` | `object` | <!--source:api-specifications-->Data in Staircase language schema<!--/source--> |
| `metadata` | `object` | <!--source:api-specifications-->Metadata about collection, f.e version of used Staircase schema. Maximum allowable length of the dumped json object - 400 000 symbols.<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Request data failed validation
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Missing API key
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Requested resource not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `429``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
The user has sent too many requests in a given amount of time ("rate limiting")
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Message<!--/source--> |

##### Other responses

`413`

`GET` `/transactions/{transaction_id}/collections`

<!--source:api-specifications-->

#### Retrieve Transaction Collections
<!--/source-->

`get_collections`

<!--source:api-specifications-->
Retrieve Transaction Collections. Collections can be filtered by collection_id or created_at fields. Supported operations per fields:

- collection_id:
- in:
- description: Get only collections with specified ids
- example: collection_id+in+01EZQ32PJQGKRA6HR8D72Q9FFF,01EZQ32NZ34WACWSAF54WGEM51
- created_at:
- gt:
- description: Get collections that were created after specified datetime in ISO format
- example: created_at+gt+2021-03-30T04:27:15.372006-04:00
- lt:
- description: Get collections that were created before specified datetime in ISO format
- example: created_at+lt+2021-03-30T04:27:15.372006-04:00

<!--/source-->

##### Response

<!--source:api-specifications-->
400404
<!--/source-->

<!--source:api-specifications-->
application/json Copy Request data failed validation

```
{
 "message": "{'data': ['Missing data for required field.']}"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Requested resource not found

```
{
 "message": "Collection not found"
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
5
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `transaction_id` required | `string (ulid)` path | `01FJCADX5QEXEDVRWNXAK206MA` | <!--source:api-specifications-->Transaction ID<!--/source--> |
| `filter` | `string` query | `collection_id+in+01EZQ32PJQGKRA6HR8D72Q9FFF,01EZQ32NZ34WACWSAF54WGEM51` | <!--source:api-specifications-->Filter expression in format {field_name}+{operation}+{value}<!--/source--> |
| `sort` | `string` query | `asc` | <!--source:api-specifications-->Order of sorting<!--/source--> |
| `limit` | `number` query | `5` | <!--source:api-specifications-->Amount of items to show<!--/source--> |
| `after_id` | `string` query | `01EZQ32PJQGKRA6HR8D72Q9FFF` | <!--source:api-specifications-->id of last evaluated transaction<!--/source--> |

##### Response `200``application/json`

<!--source:api-specifications-->
4 fields
<!--/source-->
<!--source:api-specifications-->
200 response
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `transaction_id` | `string (ulid)` | <!--source:api-specifications-->Transaction id<!--/source-->Example `01EZQ32PJQGKRA6HR8D72Q9FFF` |
| `collection_id` | `string (ulid)` | <!--source:api-specifications-->Collection id<!--/source-->Example `01EZQ32PJQGKRA6HR8D72Q9FFF` |
| `data` | `object` | <!--source:api-specifications-->Data in Staircase language schema<!--/source--> |
| `metadata` | `object` | <!--source:api-specifications-->Metadata about collection, f.e version of used Staircase schema. Maximum allowable length of the dumped json object - 400 000 symbols.<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Request data failed validation
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Requested resource not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `422``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Unprocessable Entity
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Message<!--/source--> |
| `collections` | `object[]` | <!--source:api-specifications-->List of collections without 'data' field and with links to retrieve single collections.<!--/source--> |
| `transaction_id` | `string (ulid)` | <!--source:api-specifications-->Transaction id<!--/source--> |
| `collection_id` | `string (ulid)` | <!--source:api-specifications-->Collection id<!--/source--> |
| `metadata` | `object` | <!--source:api-specifications-->Metadata about collection, f.e version of used Staircase schema Maximum allowable length of the dumped json object - 400 000 symbols.<!--/source--> |
| `_links` | `object` | <!--source:api-specifications-->Links<!--/source--> |
| `collection` | `string (url)` | <!--source:api-specifications-->Link to retrieve full collection.<!--/source--> |

##### Response `429``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
The user has sent too many requests in a given amount of time ("rate limiting")
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Message<!--/source--> |

<!--source:api-specifications-->

### Loan
<!--/source-->

`GET` `/transactions/{transaction_id}/collections/{collection_id}`

<!--source:api-specifications-->

#### Retrieve Collection
<!--/source-->

`get_collection`

##### Response

<!--source:api-specifications-->
200400404
<!--/source-->

<!--source:api-specifications-->
application/json Copy 200 response

```
{
 "transaction_id": "01FJCADX5QEXEDVRWNXAK206MA",
 "collection_id": "01FJCAQW7EYJAA6FY05WRKRM3T",
 "metadata": {
 "version": 2
 },
 "data": {
 "people": [
 {
 "@type": "borrower",
 "@id": "01FDF04MYHEZ98AD7T8ZGY5CMB",
 "has_first_name": {
 "has_value": "John"
 },
 "has_last_name": {
 "has_value": "Deere"
 },
 "has_birth_date": {
 "has_value": "01/01/1985"
 },
 "has_taxpayer_identifier_value": {
 "has_value": "999-00-0000"
 },
 "contact_at": [
 "01FDF09BNQCT03DCAX7M5KM52T"
 ],
 "employed_as": [
 "01FDF0DFYAHBRJGFA5RS26HVP1"
 ]
 }
 ],
 "addresses": [
 {
 "@id": "01FDF077N6V7R2RNC64DGT31DY",
 "@type": "business_address",
 "has_address_line_1_text": {
 "has_value": "33 IRVING PLACE",
 "data_sourced_from": [
 "01FDF10040SA2VTETKJQXJ3MQZ"
 ]
 },
 "has_address_line_2_text": {
 "has_value": "additional_line_text",
 "data_sourced_from": [
 "01FDF10040SA2VTETKJQXJ3MQZ"
 ]
 },
 "has_city_name": {
 "has_value": "NEW YORK",
 "data_sourced_from": [
 "01FDF10040SA2VTETKJQXJ3MQZ"
 ]
 },
 "has_postal_code": {
 "has_value": "10003",
 "data_sourced_from": [
 "01FDF10040SA2VTETKJQXJ3MQZ"
 ]
 },
 "has_country_name": {
 "has_value": "US",
 "data_sourced_from": [
 "01FDF10040SA2VTETKJQXJ3MQZ"
 ]
 }
 }
 ],
 "contact_information": [
 {
 "@type": "contact_information",
 "@id": "01FDF09BNQCT03DCAX7M5KM52T",
 "has_phone_number": {
 "has_value": "+1234567890"
 }
 }
 ],
 "employment": [
 {
 "@type": "employment",
 "@id": "01FDF0DFYAHBRJGFA5RS26HVP1",
 "has_employment_position_description": {
 "has_value": "Engineer",
 "data_sourced_from": [
 "01FDF10040SA2VTETKJQXJ3MQZ"
 ]
 },
 "provided_by": [
 "01FDF0G4BP9AE6B7FT5VDEWK5F"
 ]
 }
 ],
 "organizations": [
 {
 "@type": "organization",
 "@id": "01FDF0G4BP9AE6B7FT5VDEWK5F",
 "has_organization_name": {
 "has_value": "GRAIN PROCESSING COR",
 "data_sourced_from": [
 "01FDF10040SA2VTETKJQXJ3MQZ"
 ]
 },
 "has_transaction_identifier": {
 "has_value": "e171ec31-75b4-4fd6-ada1",
 "data_sourced_from": [
 "01FDF10040SA2VTETKJQXJ3MQZ"
 ]
 },
 "with_address": [
 "01FDF077N6V7R2RNC64DGT31DY"
 ]
 }
 ],
 "mortgage_products": [
 {
 "@type": "employment",
 "@id": "01FDF10040SA2VTETKJQXJ3MQZ",
 "has_data_source_date": {
 "has_value": "01/01/1972"
 },
 "has_purpose_of_verification_description": {
 "has_value": "risk-assessment"
 }
 }
 ],
 "documents": [
 {
 "@type": "irs_w2",
 "has_staircase_document_category_type": {
 "has_value": "staircase"
 },
 "has_document_description": {
 "has_value": "Employment Verification Report prepared by Staircase"
 },
 "has_document_mime_type": {
 "has_value": "application/pdf"
 },
 "has_document_name": {
 "has_value": "01FD9X8V5N804Y0CFWY7F72ZCD.pdf"
 }
 }
 ]
 }
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Request data failed validation

```
{
 "message": "{'data': ['Missing data for required field.']}"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Requested resource not found

```
{
 "message": "Collection not found"
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
4
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `transaction_id` required | `string (ulid)` path | `01FJCADX5QEXEDVRWNXAK206MA` | <!--source:api-specifications-->Transaction ID<!--/source--> |
| `collection_id` required | `string (ulid)` path | `01FJCAQW7EYJAA6FY05WRKRM3T` | <!--source:api-specifications-->Collection ID<!--/source--> |
| `refs` | `boolean` query | `true` | <!--source:api-specifications-->If `true`, refs will not be resolved<!--/source--> |
| `flatten` | `boolean` query | `true` | <!--source:api-specifications-->If `true`, the collection will be flattened<!--/source--> |

##### Response `200``application/json`

<!--source:api-specifications-->
25 fields
<!--/source-->
<!--source:api-specifications-->
200 response
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `additional_information` | `object[]` | <!--source:api-specifications-->Additional information<!--/source--> |
| `@id` | `string` | <!--source:api-specifications-->ID<!--/source--> |
| `@type` | `string` | <!--source:api-specifications-->Type<!--/source--> |
| `addresses` | `object[]` | <!--source:api-specifications-->addresses<!--/source--> |
| `@id` | `string` | <!--source:api-specifications-->ID<!--/source--> |
| `@type` | `string` | <!--source:api-specifications-->Type<!--/source--> |
| `has_address_line_1_text` | `object` | <!--source:api-specifications-->Address line 1<!--/source--> |
| `has_value` | `string` | <!--source:api-specifications-->Address line 1 value<!--/source--> |
| `has_city_name` | `object` | <!--source:api-specifications-->City name<!--/source--> |
| `has_value` | `string` | <!--source:api-specifications-->City name value<!--/source--> |
| `has_postal_code` | `object` | <!--source:api-specifications-->Postal code<!--/source--> |
| `has_value` | `string` | <!--source:api-specifications-->Postal code value<!--/source--> |
| `has_state_code` | `object` | <!--source:api-specifications-->State code<!--/source--> |
| `has_value` | `string` | <!--source:api-specifications-->State code value<!--/source--> |
| `closing_information` | `object[]` | <!--source:api-specifications-->Closing Information<!--/source--> |
| `@id` | `string` | <!--source:api-specifications-->ID<!--/source--> |
| `@type` | `string` | <!--source:api-specifications-->Type<!--/source--> |
| `has_closing_date` | `object` | <!--source:api-specifications-->Loan closing information datetime<!--/source--> |
| `has_value` | `string` | <!--source:api-specifications-->Loan closing information datetime value<!--/source--> |
| `contact_information` | `object[]` | <!--source:api-specifications-->Contact information<!--/source--> |
| `@id` | `string` | <!--source:api-specifications-->ID<!--/source--> |
| `@type` | `string` | <!--source:api-specifications-->Type<!--/source--> |
| `has_contact_description` | `object` | <!--source:api-specifications-->Contact description<!--/source--> |
| `has_value` | `string` | <!--source:api-specifications-->Contact description value<!--/source--> |
| `has_phone_number` | `object` | <!--source:api-specifications-->Phone number<!--/source--> |
| `has_value` | `string` | <!--source:api-specifications-->Phone number value<!--/source--> |
| `has_email_address` | `object` | <!--source:api-specifications-->Email address<!--/source--> |
| `has_value` | `string` | <!--source:api-specifications-->Email address value<!--/source--> |
| `credit_liabilities` | `object[]` | <!--source:api-specifications-->Credit liabilities<!--/source--> |
| `@id` | `string` | <!--source:api-specifications-->ID<!--/source--> |
| `@type` | `string` | <!--source:api-specifications-->Type<!--/source--> |
| `has_credit_liability_account_identifier` | `object` | <!--source:api-specifications-->Credit liability account identifier<!--/source--> |
| `has_value` | `string` | <!--source:api-specifications-->Credit liability account identifier value<!--/source--> |
| `has_credit_liability_account_type` | `object` | <!--source:api-specifications-->Credit liability account type<!--/source--> |
| `has_value` | `string` | <!--source:api-specifications-->Credit liability account type value<!--/source--> |
| `has_credit_liability_monthly_payment_amount` | `object` | <!--source:api-specifications-->Credit liability monthly payment amount<!--/source--> |
| `has_value` | `integer (int32)` | <!--source:api-specifications-->Credit liability monthly payment amount value<!--/source--> |
| `has_credit_liability_months_remaining_count` | `object` | <!--source:api-specifications-->Credit liability months remaining count<!--/source--> |
| `has_value` | `integer (int32)` | <!--source:api-specifications-->Credit liability months remaining count value<!--/source--> |
| `has_credit_liability_unpaid_balance_amount` | `object` | <!--source:api-specifications-->Credit liability unpaid balance amount<!--/source--> |
| `has_value` | `integer (int32)` | <!--source:api-specifications-->Credit liability unpaid balance amount value<!--/source--> |
| `with_credit_liability_creditor` | `string[]` | <!--source:api-specifications-->Credit liability creditor ID array<!--/source--> |
| `credit_liability_creditors` | `object[]` | <!--source:api-specifications-->Credit liability creditors<!--/source--> |
| `@id` | `string` | <!--source:api-specifications-->ID<!--/source--> |
| `@type` | `string` | <!--source:api-specifications-->Type<!--/source--> |
| `with_address` | `string[]` | <!--source:api-specifications-->Address ID array<!--/source--> |
| `with_name` | `string[]` | <!--source:api-specifications-->Name ID array<!--/source--> |
| `credit_scores` | `object[]` | <!--source:api-specifications-->Credit scores<!--/source--> |
| `@id` | `string` | <!--source:api-specifications-->ID<!--/source--> |
| `@type` | `string` | <!--source:api-specifications-->Type<!--/source--> |
| `has_credit_repository_source_type` | `object` | <!--source:api-specifications-->Credit repository source type<!--/source--> |
| `has_value` | `string` | <!--source:api-specifications-->Credit repository source type value<!--/source--> |
| `documents` | `object[]` | <!--source:api-specifications-->Documents<!--/source--> |
| `@id` | `string` | <!--source:api-specifications-->ID<!--/source--> |
| `@type` | `string` | <!--source:api-specifications-->Type<!--/source--> |
| `with_borrower` | `string[]` | <!--source:api-specifications-->Borrower ID array<!--/source--> |
| `down_payments` | `object[]` | <!--source:api-specifications-->Down payments<!--/source--> |
| `@id` | `string` | <!--source:api-specifications-->ID<!--/source--> |
| `@type` | `string` | <!--source:api-specifications-->Type<!--/source--> |
| `has_down_payment_amount` | `object` | <!--source:api-specifications-->Down payment amount<!--/source--> |
| `has_value` | `integer (int32)` | <!--source:api-specifications-->Down payment amount value<!--/source--> |
| `fees` | `object[]` | <!--source:api-specifications-->Fees<!--/source--> |
| `@id` | `string` | <!--source:api-specifications-->ID<!--/source--> |
| `@type` | `string` | <!--source:api-specifications-->Type<!--/source--> |
| `has_fee_type` | `object` | <!--source:api-specifications-->Fee type<!--/source--> |
| `has_value` | `string` | <!--source:api-specifications-->Fee type value<!--/source--> |
| `with_paid_to` | `string[]` | <!--source:api-specifications-->Paid to ID array<!--/source--> |
| `legal_entities` | `object[]` | <!--source:api-specifications-->Legal entities<!--/source--> |
| `@id` | `string` | <!--source:api-specifications-->ID<!--/source--> |
| `@type` | `string` | <!--source:api-specifications-->Type<!--/source--> |
| `has_full_name` | `object` | <!--source:api-specifications-->Full name<!--/source--> |
| `has_value` | `string` | <!--source:api-specifications-->Full name value<!--/source--> |
| `loan_products` | `object[]` | <!--source:api-specifications-->Loan Products<!--/source--> |
| `@id` | `string` | <!--source:api-specifications-->ID<!--/source--> |
| `@type` | `string` | <!--source:api-specifications-->Type<!--/source--> |
| `with_lock` | `string[]` | <!--source:api-specifications-->Lock ID array<!--/source--> |
| `loan_programs` | `object[]` | <!--source:api-specifications-->Loan programs<!--/source--> |
| `@id` | `string` | <!--source:api-specifications-->ID<!--/source--> |
| `@type` | `string` | <!--source:api-specifications-->Type<!--/source--> |
| `has_loan_program_identifier` | `object` | <!--source:api-specifications-->Loan program identifier<!--/source--> |
| `has_value` | `string` | <!--source:api-specifications-->Loan program identifier value<!--/source--> |
| `loan_statuses` | `object[]` | <!--source:api-specifications-->Loan statuses<!--/source--> |
| `@id` | `string` | <!--source:api-specifications-->ID<!--/source--> |
| `@type` | `string` | <!--source:api-specifications-->Type<!--/source--> |
| `has_loan_status_identifier` | `object` | <!--source:api-specifications-->Loan status identifier<!--/source--> |
| `has_value` | `string` | <!--source:api-specifications-->Loan status identifier value<!--/source--> |
| `loan_terms` | `object[]` | <!--source:api-specifications-->Loan Terms<!--/source--> |
| `@id` | `string` | <!--source:api-specifications-->ID<!--/source--> |
| `@type` | `string` | <!--source:api-specifications-->Type<!--/source--> |
| `has_note_amount` | `object` | <!--source:api-specifications-->Note amount<!--/source--> |
| `has_value` | `integer (int32)` | <!--source:api-specifications-->Note amount<!--/source--> |
| `has_amortization_term_months_count` | `object` | <!--source:api-specifications-->Amortization term in months<!--/source--> |
| `has_value` | `integer (int32)` | <!--source:api-specifications-->Amortization term in months value<!--/source--> |
| `has_note_rate_percent` | `object` | <!--source:api-specifications-->Note rate percent<!--/source--> |
| `has_value` | `number (float32)` | <!--source:api-specifications-->Note rate percent value<!--/source--> |
| `has_loan_purpose_type` | `object` | <!--source:api-specifications-->Loan purpose type<!--/source--> |
| `has_value` | `string` | <!--source:api-specifications-->Loan purpose type value<!--/source--> |
| `has_mortgage_type` | `object` | <!--source:api-specifications-->Mortgage type<!--/source--> |
| `has_value` | `string` | <!--source:api-specifications-->Mortgage type value<!--/source--> |
| `loans` | `object[]` | <!--source:api-specifications-->Loans<!--/source--> |
| `@id` | `string` | <!--source:api-specifications-->ID<!--/source--> |
| `@type` | `string` | <!--source:api-specifications-->Type<!--/source--> |
| `has_loan_estimated_closing_date` | `object` | <!--source:api-specifications-->Loan estimated closing datetime<!--/source--> |
| `has_value` | `string` | <!--source:api-specifications-->Loan estimated closing datetime value<!--/source--> |
| `has_loan_funding_date` | `object` | <!--source:api-specifications-->Loan funding datetime<!--/source--> |
| `has_value` | `string` | <!--source:api-specifications-->Loan funding datetime value<!--/source--> |
| `secured_by_property` | `string[]` | <!--source:api-specifications-->Secured by property ID array<!--/source--> |
| `with_loan_application` | `string[]` | <!--source:api-specifications-->Loan application ID array<!--/source--> |
| `with_borrower` | `string[]` | <!--source:api-specifications-->Borrower ID array<!--/source--> |
| `with_closing_information` | `string[]` | <!--source:api-specifications-->Closing information ID array<!--/source--> |
| `with_down_payment` | `string[]` | <!--source:api-specifications-->Down payment ID array<!--/source--> |
| `with_loan_status` | `string[]` | <!--source:api-specifications-->Loan status ID array<!--/source--> |
| `with_loan_terms` | `string[]` | <!--source:api-specifications-->Loan terms ID array<!--/source--> |
| `with_loan_product` | `string[]` | <!--source:api-specifications-->Loan product ID array<!--/source--> |
| `with_loan_program` | `string[]` | <!--source:api-specifications-->Loan program ID array<!--/source--> |
| `with_ltv` | `string[]` | <!--source:api-specifications-->Loan to value ID array<!--/source--> |
| `locks` | `object[]` | <!--source:api-specifications-->Locks<!--/source--> |
| `@id` | `string` | <!--source:api-specifications-->ID<!--/source--> |
| `@type` | `string` | <!--source:api-specifications-->Type<!--/source--> |
| `has_lock_datetime` | `object` | <!--source:api-specifications-->Lock datetime<!--/source--> |
| `has_value` | `string` | <!--source:api-specifications-->Lock datetime value<!--/source--> |
| `has_lock_expiration_datetime` | `object` | <!--source:api-specifications-->Lock expiration datetime<!--/source--> |
| `has_value` | `string` | <!--source:api-specifications-->Lock expiration datetime value<!--/source--> |
| `ltvs` | `object[]` | <!--source:api-specifications-->Loan to Values<!--/source--> |
| `@id` | `string` | <!--source:api-specifications-->ID<!--/source--> |
| `@type` | `string` | <!--source:api-specifications-->Type<!--/source--> |
| `has_ltv_ratio_percent` | `object` | <!--source:api-specifications-->Loan to value ratio percent<!--/source--> |
| `has_value` | `number (float32)` | <!--source:api-specifications-->Loan to value ratio percent value<!--/source--> |
| `names` | `object[]` | <!--source:api-specifications-->Names<!--/source--> |
| `@id` | `string` | <!--source:api-specifications-->ID<!--/source--> |
| `@type` | `string` | <!--source:api-specifications-->Type<!--/source--> |
| `has_full_name` | `object` | <!--source:api-specifications-->Full name<!--/source--> |
| `has_value` | `string` | <!--source:api-specifications-->Full name value<!--/source--> |
| `paid_tos` | `object[]` | <!--source:api-specifications-->Paid to array<!--/source--> |
| `@id` | `string` | <!--source:api-specifications-->ID<!--/source--> |
| `@type` | `string` | <!--source:api-specifications-->Type<!--/source--> |
| `with_legal_entity` | `string[]` | <!--source:api-specifications-->Legal entity ID array<!--/source--> |
| `people` | `object[]` | <!--source:api-specifications-->People<!--/source--> |
| `@id` | `string` | <!--source:api-specifications-->ID<!--/source--> |
| `@type` | `string` | <!--source:api-specifications-->Type<!--/source--> |
| `contact_at` | `string[]` | <!--source:api-specifications-->Contact at<!--/source--> |
| `has_first_name` | `object` | <!--source:api-specifications-->First name<!--/source--> |
| `has_value` | `string` | <!--source:api-specifications-->Fist name value<!--/source--> |
| `has_last_name` | `object` | <!--source:api-specifications-->Last name<!--/source--> |
| `has_value` | `string` | <!--source:api-specifications-->Last name value<!--/source--> |
| `has_source_identifier` | `object` | <!--source:api-specifications-->Source identifier<!--/source--> |
| `has_value` | `string` | <!--source:api-specifications-->Source identifier value<!--/source--> |
| `has_taxpayer_identifier_value` | `object` | <!--source:api-specifications-->Taxpayer identifier<!--/source--> |
| `has_value` | `string` | <!--source:api-specifications-->Taxpayer identifier value<!--/source--> |
| `lives_at` | `string[]` | <!--source:api-specifications-->Lives at ID array<!--/source--> |
| `properties` | `object[]` | <!--source:api-specifications-->Properties<!--/source--> |
| `@id` | `string` | <!--source:api-specifications-->ID<!--/source--> |
| `@type` | `string` | <!--source:api-specifications-->Type<!--/source--> |
| `has_property_current_usage_type` | `object` | <!--source:api-specifications-->Current usage type of property<!--/source--> |
| `has_value` | `string` | <!--source:api-specifications-->Current usage type of property value<!--/source--> |
| `with_address` | `string[]` | <!--source:api-specifications-->Address ID array<!--/source--> |
| `with_sales_contract` | `string[]` | <!--source:api-specifications-->Address ID array<!--/source--> |
| `with_value` | `string[]` | <!--source:api-specifications-->Value ID array<!--/source--> |
| `property_valuations` | `object[]` | <!--source:api-specifications-->Property Valuations<!--/source--> |
| `@id` | `string` | <!--source:api-specifications-->ID<!--/source--> |
| `@type` | `string` | <!--source:api-specifications-->Type<!--/source--> |
| `has_property_valuation_amount` | `object` | <!--source:api-specifications-->Property valuation amount<!--/source--> |
| `has_value` | `integer (int32)` | <!--source:api-specifications-->Property valuation amount value<!--/source--> |
| `sales_contracts` | `object[]` | <!--source:api-specifications-->Sales Contracts<!--/source--> |
| `@id` | `string` | <!--source:api-specifications-->ID<!--/source--> |
| `@type` | `string` | <!--source:api-specifications-->Type<!--/source--> |
| `has_sales_contract_amount` | `object` | <!--source:api-specifications-->Property valuation amount<!--/source--> |
| `has_value` | `integer (int32)` | <!--source:api-specifications-->Property valuation amount value<!--/source--> |
| `residences` | `object[]` | <!--source:api-specifications-->Residences<!--/source--> |
| `@id` | `string` | <!--source:api-specifications-->ID<!--/source--> |
| `@type` | `string` | <!--source:api-specifications-->Type<!--/source--> |
| `with_address` | `string[]` | <!--source:api-specifications-->Address ID array<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Request data failed validation
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Missing API key
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Requested resource not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `429``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
The user has sent too many requests in a given amount of time ("rate limiting")
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Message<!--/source--> |

##### Other responses

`422`

`GET` `/products/encompass/status/{transaction_id}/{response_collection_id}`

<!--source:api-specifications-->

#### Retrieve Status
<!--/source-->

`RetrieveProductFlowInvocationStatus`

<!--source:api-specifications-->
Retrieves the status of running encompass loan invocation.

<!--/source-->

##### Response

<!--source:api-specifications-->
200400403404500
<!--/source-->

<!--source:api-specifications-->
application/json Copy Successfully returned status of the Product flow Invocation.

```
{
 "status": "SUCCEEDED",
 "message": "Invocation completed successfully",
 "created_at": "2022-01-22T04:54:13.507355-05:00",
 "invocation_status": "COMPLETED",
 "last_updated_at": "2022-01-22T04:55:31.399320-05:00"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Request data failed validation

```
{
 "message": "{'data': ['Missing data for required field.']}"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy 403 invalid error

```
{
 "message": "Please check the key you used to call this service",
 "url": "https://api.staircase.co/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post"
}
```

<!--/source-->

<!--source:api-specifications-->
text/html Copy Resource not found

```
<html>\r\n<head><title>400 Bad Request</title></head>\r\n<body>\r\n<center><h1>400 Bad Request</h1></center>\r\n</body>\r\n</html>\r\n
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Internal server error

```
{
 "message": "The product has encountered an internal server error. If you have used a transaction_id to call our services, please submit it to Staircase support"
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
3
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |
| `transaction_id` required | `string (ulid)` path | `01F0KHK7DN3H5JZ4QJKMYAM6GB` | <!--source:api-specifications-->Staircase Transaction Identifier<!--/source--> |
| `response_collection_id` required | `string (ulid)` path | `01F0KHKADN0HRFXMCQQXPA6AFZ` | <!--source:api-specifications-->Response Collection of Invocation<!--/source--> |

##### Response `200``application/json`

<!--source:api-specifications-->
5 fields
<!--/source-->
<!--source:api-specifications-->
Successfully returned status of the Product flow Invocation.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `status` | `string` | <!--source:api-specifications-->Mapped status of the invocation.<!--/source-->Example `STARTED` |
| `message` | `string` | <!--source:api-specifications-->Message.<!--/source-->Example `Verification is completed, please check response collection to see verification data.` |
| `created_at` | `string` | <!--source:api-specifications-->Time of creation<!--/source--> |
| `invocation_status` | `string` | <!--source:api-specifications-->Status of the product invocation before mapping<!--/source--> |
| `last_updated_at` | `string` | <!--source:api-specifications-->Last time the collection was updated<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Request data failed validation
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
403 invalid error
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Error message.<!--/source--> |
| `url` | `string` | <!--source:api-specifications-->Error additional URL.<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Resource not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `500``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Internal server error
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Error message.<!--/source--> |

<!--source:api-specifications-->

### Credentials
<!--/source-->

`PUT` `/vendors/encompass-loan/credentials`

<!--source:api-specifications-->

#### Update credentials
<!--/source-->

`updateCredentials`

<!--source:api-specifications-->
Update credentials Update credentials. They will be used to connect with Encompass API.

<!--/source-->

##### Request

<!--source:api-specifications-->
application/json Copy
```
{
 "encompass_instance_id": "TEBE11223344",
 "client_id": "x5ztrzui",
 "client_secret": "<redacted>",
 "username": "my-admin-user@encompass:TEBE11223344",
 "password": "<redacted>",
 "grant_type": "password"
}
```

<!--/source-->

##### Response

<!--source:api-specifications-->
200400
<!--/source-->

<!--source:api-specifications-->
application/json Copy Credentials successfully updated.

```
{
 "encompass_instance_id": "TEBE11223344",
 "client_id": "x5ztrzui",
 "client_secret": "<redacted>",
 "username": "my-admin-user@encompass:TEBE11223344",
 "password": "<redacted>",
 "grant_type": "password"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
2
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |
| `Content-Type` required | `string` header | `application/json` | <!--source:api-specifications-->Content type<!--/source--> |

##### Request body`application/json`

<!--source:api-specifications-->
6 fields
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `encompass_instance_id`required | `string` | <!--source:api-specifications-->Encompass Instance ID<!--/source-->Example `TEBE11223344` |
| `client_id`required | `string` | <!--source:api-specifications-->Encompass Client ID<!--/source-->Example `x5ztrzui` |
| `client_secret`required | `string` | <!--source:api-specifications-->Encompass Client Secret<!--/source-->Example `<redacted>` |
| `username`required | `string` | <!--source:api-specifications-->Encompass username<!--/source-->Example `my-admin-user@encompass:TEBE11223344` |
| `password`required | `string` | <!--source:api-specifications-->Encompass password<!--/source-->Example `<redacted>` |
| `grant_type`required | `string` | <!--source:api-specifications-->Grant type.<!--/source-->Example `password` |

##### Response `200``application/json`

<!--source:api-specifications-->
6 fields
<!--/source-->
<!--source:api-specifications-->
Credentials successfully updated.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `encompass_instance_id`required | `string` | <!--source:api-specifications-->Encompass Instance ID<!--/source-->Example `TEBE11223344` |
| `client_id`required | `string` | <!--source:api-specifications-->Encompass Client ID<!--/source-->Example `x5ztrzui` |
| `client_secret`required | `string` | <!--source:api-specifications-->Encompass Client Secret<!--/source-->Example `<redacted>` |
| `username`required | `string` | <!--source:api-specifications-->Encompass username<!--/source-->Example `my-admin-user@encompass:TEBE11223344` |
| `password`required | `string` | <!--source:api-specifications-->Encompass password<!--/source-->Example `<redacted>` |
| `grant_type`required | `string` | <!--source:api-specifications-->Grant type.<!--/source-->Example `password` |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which url the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

`POST` `/vendors/encompass-loan/lookups/refresh_dev_connect_token/jobs`

<!--source:api-specifications-->

#### Verify Dev Connect Credentials
<!--/source-->

`verifyDevConnectCredentials`

<!--source:api-specifications-->
Verify if credentials are set up correctly. If request is returning token in the response, it means that credentials are healthy for Dev Connect.

<!--/source-->

##### Request

<!--source:api-specifications-->
application/json Copy
```
{
 "request_payload": {}
}
```

<!--/source-->

##### Response

<!--source:api-specifications-->
200400
<!--/source-->

<!--source:api-specifications-->
application/json Copy Partner credentials successfully updated.

```
{
 "transaction_id": "",
 "response_payload": {
 "mode": "static",
 "token_value": "0002qo60Z6rgY0VqRdjX1b9pehep",
 "token_name": "encompass_dev_connect_token"
 }
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
1
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which URL the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

##### Other responses

`200`

<!--source:api-specifications-->

### Conditions
<!--/source-->

`POST` `/vendors/encompass-loan/flows/conditions-underwriting/jobs`

<!--source:api-specifications-->

#### Create underwriting conditions
<!--/source-->

`createunderwritingConditions`

<!--source:api-specifications-->
Create Underwriting Conditions
<!--/source-->

<!--source:api-specifications-->
Create underwriting conditions Creates underwriting conditions for the specified loan.

Request collection example:

```
{
 "metadata": {
 "validation": true,
 "version": 2
 },
 "data": {
 "documents": [
 {
 "@id": "79762ab7-cc56-4279-a400-b627fdce3ec5",
 "@type": "bailee_letter",
 }
 ],
 "loan_identifiers": [
 {
 "@id": "11231233223231",
 "@type": "loan_identifier",
 "has_loan_identifier_value": {
 "has_value": "0ab69a33-38b5-4cb7-a846-815ee6463bca"
 }
 }
 ],
 "loans": [
 {
 "@id": "456463545646123",
 "@type": "loan",
 "with_loan_identifier": [
 "11231233223231"
 ]
 }
 ]
 }
 }
```

<!--/source-->

##### Request

<!--source:api-specifications-->
application/json Copy
```
{
 "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK",
 "request_collection_id": "01F7S0N7CQ31DZQYVSVPN66GNK",
 "callback_url": "https://webhook.site/cc87117a-36ee-4b8b-b098-e9cf209821a2"
}
```

<!--/source-->

##### Response

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
1
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |

##### Request body`application/json`

<!--source:api-specifications-->
6 fields
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID<!--/source--> |
| `request_collection_id` | `string` | <!--source:api-specifications-->Request collection ID<!--/source--> |
| `response_collection_id` | `string` | <!--source:api-specifications-->Response collection ID<!--/source--> |
| `callback_url`required | `string (uri)` | <!--source:api-specifications-->Destination URL on which final result of the flow execution will be sent<!--/source--> |
| `request_payload`required | `object` | <!--source:api-specifications-->Data that have to passed into the flow<!--/source--> |
| `debug_config` | `object` | <!--source:api-specifications-->Debug configuration.<!--/source--> |
| `dry_run` | `boolean` | <!--source:api-specifications-->Whether to run a flow in a debug response-mocked mode. Applicable with other debug options.<!--/source-->Example `false` |
| `render_ack_url` | `string (uri)` | <!--source:api-specifications-->If flow contains `CREATE_WIDGET` step, Connector will try to acknowledge user with POST request sent to `render_ack_url`. Applicable with other debug options.<!--/source-->Example `https://notifications.example.com/rendered-widgets-w-job` |
| `poll_with` | `object` | <!--source:api-specifications-->Whether to run a flow in a debug self-poll mode. Applicable with other debug options.<!--/source--> |
| `interval`required | `integer` | <!--source:api-specifications-->Polling interval in seconds.<!--/source-->Example `30` |

##### Response `200``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Partner credentials successfully updated.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `job_id` | `string` | <!--source:api-specifications-->Execution ID<!--/source--> |
| `job_status` | `string` | <!--source:api-specifications-->Execution status<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which URL the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

`GET` `/vendors/encompass-loan/flows/conditions-underwriting/jobs/{job_id}`

<!--source:api-specifications-->

#### Retrieve Create Underwriting Conditions Status
<!--/source-->

`retrieveCreateunderwritingConditionsStatus`

<!--source:api-specifications-->
Retrieve Create Underwriting Conditions Execution Status
<!--/source-->

<!--source:api-specifications-->
This endpoint allows getting status of the job.

<!--/source-->

##### Response

<!--source:api-specifications-->
200400
<!--/source-->

<!--source:api-specifications-->
application/json Copy Execution status successfully retrieved

```
{
 "status": "FAILED",
 "executed_events": [
 "GetCredentials",
 "Wait1",
 "Wait2"
 ],
 "last_event": "Wait2",
 "details": [
 {
 "event_id": 2,
 "event_type": "stateEnteredEventDetails",
 "event_name": "GetCredentials",
 "timestamp": "2021-06-10 23:25:27.661000+03:00",
 "previous_event_id": 0,
 "input_details": {}
 },
 {
 "event_id": 6,
 "event_type": "stateExitedEventDetails",
 "event_name": "GetCredentials",
 "timestamp": "2021-06-10 23:25:30.280000+03:00",
 "previous_event_id": 5
 },
 {
 "event_id": 7,
 "event_type": "stateEnteredEventDetails",
 "event_name": "Wait1",
 "timestamp": "2021-06-10 23:25:30.289000+03:00",
 "previous_event_id": 6,
 "input_details": {}
 },
 {
 "event_id": 8,
 "event_type": "stateExitedEventDetails",
 "event_name": "Wait1",
 "timestamp": "2021-06-10 23:25:40.289000+03:00",
 "previous_event_id": 7
 },
 {
 "event_id": 9,
 "event_type": "stateEnteredEventDetails",
 "event_name": "Wait2",
 "timestamp": "2021-06-10 23:25:40.296000+03:00",
 "previous_event_id": 8,
 "input_details": {}
 },
 {
 "event_id": 10,
 "event_type": "executionFailedEventDetails",
 "timestamp": "2021-06-10 23:25:40.296000+03:00",
 "previous_event_id": 0,
 "error": {
 "type": "Runtime",
 "cause": "An error occurred while executing the state 'Wait2' (entered at the event id #9). The SecondsPath parameter does not reference an input value: $.request_payload.sec"
 }
 }
 ],
 "input": {
 "callback_url": "https://rock.site/09876ercftvghnj3iy4738c-3crv/",
 "transaction_id": "01FG3YHN4FCJ4EYW6326ZAQW6Y",
 "response_collection_id": "01FG3YHR1TYXTAAZZHMTX50HQV",
 "request_collection_id": "01FG3YHQW2TY3A2GVKX5SXAB4D"
 },
 "output": {
 "response_payload": {
 "invoice_id": "in_18jwqyLlRB0eXbMtrUQ97YBw",
 "invoice_data": {
 "object": {
 "id": "cs_temp_use_ConnectorForANYVendor integration",
 "name": "customer",
 "amount": 100000
 }
 },
 "invoice_metadata": {
 "user_id": "9872b3ck2kmXYZ"
 }
 },
 "extraction_errors": {
 "lpa.xyz": "not-found"
 }
 }
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
2
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |
| `job_id` required | `string (uuid)` path | `7c668252-d2ba-job-id-896d-1f73236287d9` | <!--source:api-specifications-->Execution ID<!--/source--> |

##### Response `200``application/json`

<!--source:api-specifications-->
6 fields
<!--/source-->
<!--source:api-specifications-->
Execution status successfully retrieved
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `status` | `string` | <!--source:api-specifications-->Execution status<!--/source-->`ABORTED``FAILED``RUNNING``SUCCEEDED``TIMED_OUT` |
| `executed_events` | `string[]` | <!--source:api-specifications-->List of executed events<!--/source--> |
| `last_event` | `string` | <!--source:api-specifications-->Last executed event<!--/source--> |
| `details` | `object[]` | <!--source:api-specifications-->Executed events details<!--/source--> |
| `input` | `object` | <!--source:api-specifications-->Short data you used for invoking the flow.<!--/source--> |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID<!--/source--> |
| `request_collection_id`required | `string` | <!--source:api-specifications-->Request collection ID<!--/source--> |
| `response_collection_id`required | `string` | <!--source:api-specifications-->Response collection ID<!--/source--> |
| `callback_url`required | `string (uri)` | <!--source:api-specifications-->Destination URL on which final result of the flow execution was configured to be sent<!--/source--> |
| `output` | `object` | <!--source:api-specifications-->Short data of the output.<!--/source--> |
| `response_payload`required | `one of` | <!--source:api-specifications-->Response payload.<!--/source--> |
| `extraction_errors`required | `one of` | <!--source:api-specifications-->Extraction errors.<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which URL the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner, flow or execution not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

`POST` `/vendors/encompass-loan/flows/post-closing-condition/jobs`

<!--source:api-specifications-->

#### Create Post Closing conditions
<!--/source-->

`createPostClosingCondition`

<!--source:api-specifications-->
Create Post Closing Conditions
<!--/source-->

<!--source:api-specifications-->
Create Post Closing conditions Creates post closing conditions for the specified loan.

Request collection example:

```
{
 "metadata": {
 "validation": true,
 "version": 2
 },
 "data": {
 "loan_identifiers": [
 {
 "@id": "9b769276-84ef-4090-b746-845d7b5cf623",
 "@type": "loan_identifier",
 "has_loan_identifier_value": {
 "has_value": "843dda6c-0b51-4699-a822-faea3a7f0215"
 }
 }
 ],
 "conditions": [
 {
 "@id": "11d4f1b0-9fa7-4aa2-b543-5286e811ed50",
 "@type": "condition",
 "has_condition_description": {
 "has_value": "First post closing condition description"
 }
 },
 {
 "@id": "11d4f1b0-9fa7-4aa2-b543-5286e811ed50",
 "@type": "condition",
 "has_condition_description": {
 "has_value": "Second post closing condition description"
 }
 }
 ]
 }
}
```

<!--/source-->

##### Request

<!--source:api-specifications-->
application/json Copy
```
{
 "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK",
 "request_collection_id": "01F7S0N7CQ31DZQYVSVPN66GNK",
 "callback_url": "https://httpbin.org/post"
}
```

<!--/source-->

##### Response

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
1
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |

##### Request body`application/json`

<!--source:api-specifications-->
6 fields
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID<!--/source--> |
| `request_collection_id` | `string` | <!--source:api-specifications-->Request collection ID<!--/source--> |
| `response_collection_id` | `string` | <!--source:api-specifications-->Response collection ID<!--/source--> |
| `callback_url`required | `string (uri)` | <!--source:api-specifications-->Destination URL on which final result of the flow execution will be sent<!--/source--> |
| `request_payload`required | `object` | <!--source:api-specifications-->Data that have to passed into the flow<!--/source--> |
| `debug_config` | `object` | <!--source:api-specifications-->Debug configuration.<!--/source--> |
| `dry_run` | `boolean` | <!--source:api-specifications-->Whether to run a flow in a debug response-mocked mode. Applicable with other debug options.<!--/source-->Example `false` |
| `render_ack_url` | `string (uri)` | <!--source:api-specifications-->If flow contains `CREATE_WIDGET` step, Connector will try to acknowledge user with POST request sent to `render_ack_url`. Applicable with other debug options.<!--/source-->Example `https://notifications.example.com/rendered-widgets-w-job` |
| `poll_with` | `object` | <!--source:api-specifications-->Whether to run a flow in a debug self-poll mode. Applicable with other debug options.<!--/source--> |
| `interval`required | `integer` | <!--source:api-specifications-->Polling interval in seconds.<!--/source-->Example `30` |

##### Response `200``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Partner credentials successfully updated.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `job_id` | `string` | <!--source:api-specifications-->Execution ID<!--/source--> |
| `job_status` | `string` | <!--source:api-specifications-->Execution status<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which URL the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

`GET` `/vendors/encompass-loan/flows/post-closing-condition/jobs/{job_id}`

<!--source:api-specifications-->

#### Retrieve Post Closing Conditions Status
<!--/source-->

`retrievePostClosingConditionStatus`

<!--source:api-specifications-->
Retrieve Post Closing Conditions Execution Status
<!--/source-->

<!--source:api-specifications-->
This endpoint allows getting status of the job.

<!--/source-->

##### Response

<!--source:api-specifications-->
200400
<!--/source-->

<!--source:api-specifications-->
application/json Copy Execution status successfully retrieved

```
{
 "status": "FAILED",
 "executed_events": [
 "GetCredentials",
 "Wait1",
 "Wait2"
 ],
 "last_event": "Wait2",
 "details": [
 {
 "event_id": 2,
 "event_type": "stateEnteredEventDetails",
 "event_name": "GetCredentials",
 "timestamp": "2021-06-10 23:25:27.661000+03:00",
 "previous_event_id": 0,
 "input_details": {}
 },
 {
 "event_id": 6,
 "event_type": "stateExitedEventDetails",
 "event_name": "GetCredentials",
 "timestamp": "2021-06-10 23:25:30.280000+03:00",
 "previous_event_id": 5
 },
 {
 "event_id": 7,
 "event_type": "stateEnteredEventDetails",
 "event_name": "Wait1",
 "timestamp": "2021-06-10 23:25:30.289000+03:00",
 "previous_event_id": 6,
 "input_details": {}
 },
 {
 "event_id": 8,
 "event_type": "stateExitedEventDetails",
 "event_name": "Wait1",
 "timestamp": "2021-06-10 23:25:40.289000+03:00",
 "previous_event_id": 7
 },
 {
 "event_id": 9,
 "event_type": "stateEnteredEventDetails",
 "event_name": "Wait2",
 "timestamp": "2021-06-10 23:25:40.296000+03:00",
 "previous_event_id": 8,
 "input_details": {}
 },
 {
 "event_id": 10,
 "event_type": "executionFailedEventDetails",
 "timestamp": "2021-06-10 23:25:40.296000+03:00",
 "previous_event_id": 0,
 "error": {
 "type": "Runtime",
 "cause": "An error occurred while executing the state 'Wait2' (entered at the event id #9). The SecondsPath parameter does not reference an input value: $.request_payload.sec"
 }
 }
 ],
 "input": {
 "callback_url": "https://rock.site/09876ercftvghnj3iy4738c-3crv/",
 "transaction_id": "01FG3YHN4FCJ4EYW6326ZAQW6Y",
 "response_collection_id": "01FG3YHR1TYXTAAZZHMTX50HQV",
 "request_collection_id": "01FG3YHQW2TY3A2GVKX5SXAB4D"
 },
 "output": {
 "response_payload": {
 "invoice_id": "in_18jwqyLlRB0eXbMtrUQ97YBw",
 "invoice_data": {
 "object": {
 "id": "cs_temp_use_ConnectorForANYVendor integration",
 "name": "customer",
 "amount": 100000
 }
 },
 "invoice_metadata": {
 "user_id": "9872b3ck2kmXYZ"
 }
 },
 "extraction_errors": {
 "lpa.xyz": "not-found"
 }
 }
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
2
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |
| `job_id` required | `string (uuid)` path | `7c668252-d2ba-job-id-896d-1f73236287d9` | <!--source:api-specifications-->Execution ID<!--/source--> |

##### Response `200``application/json`

<!--source:api-specifications-->
6 fields
<!--/source-->
<!--source:api-specifications-->
Execution status successfully retrieved
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `status` | `string` | <!--source:api-specifications-->Execution status<!--/source-->`ABORTED``FAILED``RUNNING``SUCCEEDED``TIMED_OUT` |
| `executed_events` | `string[]` | <!--source:api-specifications-->List of executed events<!--/source--> |
| `last_event` | `string` | <!--source:api-specifications-->Last executed event<!--/source--> |
| `details` | `object[]` | <!--source:api-specifications-->Executed events details<!--/source--> |
| `input` | `object` | <!--source:api-specifications-->Short data you used for invoking the flow.<!--/source--> |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID<!--/source--> |
| `request_collection_id`required | `string` | <!--source:api-specifications-->Request collection ID<!--/source--> |
| `response_collection_id`required | `string` | <!--source:api-specifications-->Response collection ID<!--/source--> |
| `callback_url`required | `string (uri)` | <!--source:api-specifications-->Destination URL on which final result of the flow execution was configured to be sent<!--/source--> |
| `output` | `object` | <!--source:api-specifications-->Short data of the output.<!--/source--> |
| `response_payload`required | `one of` | <!--source:api-specifications-->Response payload.<!--/source--> |
| `extraction_errors`required | `one of` | <!--source:api-specifications-->Extraction errors.<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which URL the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner, flow or execution not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

<!--source:api-specifications-->

### Management
<!--/source-->

`POST` `/vendors/encompass-loan/flows/create-loan/jobs`

<!--source:api-specifications-->

#### Create loan
<!--/source-->

`createLoan`

<!--source:api-specifications-->
Create loan Create a new loan. Result collection will contain a unique loan identifier.

Request collection example:

```
{
 "metadata": {
 "version": 2,
 "validation": true
 },
 "data": {
 "loans": [
 {
 "@id": "01GE2HCSCYZ6G0T2M1PJ9DWKMB",
 "@type": "loan",
 "with_borrower": [
 "01G8GQR3ZJTN94YDQ6PNTZEVYB"
 ]
 }
 ],
 "people": [
 {
 "@id": "01G8GQR3ZJTN94YDQ6PNTZEVYB",
 "@type": "borrower",
 "has_first_name": {
 "has_value": "John"
 },
 "has_last_name": {
 "has_value": "Doe"
 },
 "has_borroweShow the restr_birth_date": {
 "has_value": "1983-01-02"
 },
 "contact_at": ["01FKFFD83NWT8FKZ3EMFEHXW8M"]
 }
 ],
 "contact_information": [
 {
 "has_email_address": {
 "has_value": "some.email@fake.com"
 },
 "has_home_phone_number": {
 "has_value": "555666777"
 },
 "@type": "contact_information",
 "@id": "01FKFFD83NWT8FKZ3EMFEHXW8M"
 }
 ]
 }
 }
```

<!--/source-->

##### Request

<!--source:api-specifications-->
application/json Copy
```
{
 "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK",
 "request_collection_id": "01F7S0N7CQ31DZQYVSVPN66GNK",
 "request_payload": {},
 "callback_url": "https://webhook.site/cc87117a-36ee-4b8b-b098-e9cf209821a2"
}
```

<!--/source-->

##### Response

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
1
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |

##### Request body`application/json`

<!--source:api-specifications-->
6 fields
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID<!--/source--> |
| `request_collection_id` | `string` | <!--source:api-specifications-->Request collection ID<!--/source--> |
| `response_collection_id` | `string` | <!--source:api-specifications-->Response collection ID<!--/source--> |
| `callback_url`required | `string (uri)` | <!--source:api-specifications-->Destination URL on which final result of the flow execution will be sent<!--/source--> |
| `request_payload`required | `object` | <!--source:api-specifications-->Data that have to passed into the flow<!--/source--> |
| `debug_config` | `object` | <!--source:api-specifications-->Debug configuration.<!--/source--> |
| `dry_run` | `boolean` | <!--source:api-specifications-->Whether to run a flow in a debug response-mocked mode. Applicable with other debug options.<!--/source-->Example `false` |
| `render_ack_url` | `string (uri)` | <!--source:api-specifications-->If flow contains `CREATE_WIDGET` step, Connector will try to acknowledge user with POST request sent to `render_ack_url`. Applicable with other debug options.<!--/source-->Example `https://notifications.example.com/rendered-widgets-w-job` |
| `poll_with` | `object` | <!--source:api-specifications-->Whether to run a flow in a debug self-poll mode. Applicable with other debug options.<!--/source--> |
| `interval`required | `integer` | <!--source:api-specifications-->Polling interval in seconds.<!--/source-->Example `30` |

##### Response `200``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
New loan successfully created.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `job_id` | `string` | <!--source:api-specifications-->Execution ID<!--/source--> |
| `job_status` | `string` | <!--source:api-specifications-->Execution status<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which URL the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

`GET` `/vendors/encompass-loan/flows/create-loan/jobs/{job_id}`

<!--source:api-specifications-->

#### Retrieve Create Loan Status
<!--/source-->

`retrieveCreateLoanStatus`

<!--source:api-specifications-->
Retrieve create loan status
<!--/source-->

<!--source:api-specifications-->
This endpoint allows getting status of the job.

<!--/source-->

##### Response

<!--source:api-specifications-->
200400
<!--/source-->

<!--source:api-specifications-->
application/json Copy Execution status successfully retrieved

```
{
 "status": "FAILED",
 "executed_events": [
 "GetCredentials",
 "Wait1",
 "Wait2"
 ],
 "last_event": "Wait2",
 "details": [
 {
 "event_id": 2,
 "event_type": "stateEnteredEventDetails",
 "event_name": "GetCredentials",
 "timestamp": "2021-06-10 23:25:27.661000+03:00",
 "previous_event_id": 0,
 "input_details": {}
 },
 {
 "event_id": 6,
 "event_type": "stateExitedEventDetails",
 "event_name": "GetCredentials",
 "timestamp": "2021-06-10 23:25:30.280000+03:00",
 "previous_event_id": 5
 },
 {
 "event_id": 7,
 "event_type": "stateEnteredEventDetails",
 "event_name": "Wait1",
 "timestamp": "2021-06-10 23:25:30.289000+03:00",
 "previous_event_id": 6,
 "input_details": {}
 },
 {
 "event_id": 8,
 "event_type": "stateExitedEventDetails",
 "event_name": "Wait1",
 "timestamp": "2021-06-10 23:25:40.289000+03:00",
 "previous_event_id": 7
 },
 {
 "event_id": 9,
 "event_type": "stateEnteredEventDetails",
 "event_name": "Wait2",
 "timestamp": "2021-06-10 23:25:40.296000+03:00",
 "previous_event_id": 8,
 "input_details": {}
 },
 {
 "event_id": 10,
 "event_type": "executionFailedEventDetails",
 "timestamp": "2021-06-10 23:25:40.296000+03:00",
 "previous_event_id": 0,
 "error": {
 "type": "Runtime",
 "cause": "An error occurred while executing the state 'Wait2' (entered at the event id #9). The SecondsPath parameter does not reference an input value: $.request_payload.sec"
 }
 }
 ],
 "input": {
 "callback_url": "https://rock.site/09876ercftvghnj3iy4738c-3crv/",
 "transaction_id": "01FG3YHN4FCJ4EYW6326ZAQW6Y",
 "response_collection_id": "01FG3YHR1TYXTAAZZHMTX50HQV",
 "request_collection_id": "01FG3YHQW2TY3A2GVKX5SXAB4D"
 },
 "output": {
 "response_payload": {
 "invoice_id": "in_18jwqyLlRB0eXbMtrUQ97YBw",
 "invoice_data": {
 "object": {
 "id": "cs_temp_use_ConnectorForANYVendor integration",
 "name": "customer",
 "amount": 100000
 }
 },
 "invoice_metadata": {
 "user_id": "9872b3ck2kmXYZ"
 }
 },
 "extraction_errors": {
 "lpa.xyz": "not-found"
 }
 }
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
2
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |
| `job_id` required | `string (uuid)` path | `7c668252-d2ba-job-id-896d-1f73236287d9` | <!--source:api-specifications-->Execution ID<!--/source--> |

##### Response `200``application/json`

<!--source:api-specifications-->
6 fields
<!--/source-->
<!--source:api-specifications-->
Execution status successfully retrieved
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `status` | `string` | <!--source:api-specifications-->Execution status<!--/source-->`ABORTED``FAILED``RUNNING``SUCCEEDED``TIMED_OUT` |
| `executed_events` | `string[]` | <!--source:api-specifications-->List of executed events<!--/source--> |
| `last_event` | `string` | <!--source:api-specifications-->Last executed event<!--/source--> |
| `details` | `object[]` | <!--source:api-specifications-->Executed events details<!--/source--> |
| `input` | `object` | <!--source:api-specifications-->Short data you used for invoking the flow.<!--/source--> |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID<!--/source--> |
| `request_collection_id`required | `string` | <!--source:api-specifications-->Request collection ID<!--/source--> |
| `response_collection_id`required | `string` | <!--source:api-specifications-->Response collection ID<!--/source--> |
| `callback_url`required | `string (uri)` | <!--source:api-specifications-->Destination URL on which final result of the flow execution was configured to be sent<!--/source--> |
| `output` | `object` | <!--source:api-specifications-->Short data of the output.<!--/source--> |
| `response_payload`required | `one of` | <!--source:api-specifications-->Response payload.<!--/source--> |
| `extraction_errors`required | `one of` | <!--source:api-specifications-->Extraction errors.<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which URL the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner, flow or execution not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

`POST` `/vendors/encompass-loan/flows/update-loan/jobs`

<!--source:api-specifications-->

#### Update loan
<!--/source-->

`updateLoan`

<!--source:api-specifications-->
Create loan
<!--/source-->

<!--source:api-specifications-->
Update loan Update existing loan. Input collection must contain at least unique loan identifier. Request collection example:

```
{
 "metadata": {
 "version": 2,
 "validation": true
 },
 "data": {
 "addresses": [
 {
 "@type": "property_address",
 "@id": "01GEN93QY2E1GJ7QS9GZDY3TBH",
 "has_address_line_1_text": {
 "has_value": "209 N Highway 45"
 },
 "has_city_name": {
 "has_value": "Bonanza"
 },
 "has_postal_code": {
 "has_value": "72916"
 },
 "has_state_code": {
 "has_value": "AR"
 },
 "has_unit_identifier&quShow the restot;: {
 "has_value": "14"
 }
 }
 ],
 "contact_information": [
 {
 "@type": "contact_information",
 "@id": "01GEB6TJ18W8FYDBPQRD2NED6E",
 "has_email_address": {
 "has_value": "some.email@fake.com"
 },
 "has_home_phone_number": {
 "has_value": "555-555-555"
 }
 }
 ],
 "loan_identifiers": [
 {
 "@type": "loan_identifier",
 "@id": "01GEB6TJ17H9V8F0VZCP80242X",
 "has_loan_identifier_value": {
 "has_value": "8540f696-9a51-4c03-8292-493e520fc67b"
 }
 }
 ],
 "loans": [
 {
 "@type": "loan",
 "with_borrower": [
 "01GEB6TJ176FMNPWDCFWGPH9GH"
 ],
 "with_loan_identifier": [
 "01GEB6TJ17H9V8F0VZCP80242X"
 ],
 "@id": "01GEB6TJRS8MV4SPR98WF4X7H7"
 }
 ],
 "people": [
 {
 "@type": "borrower",
 "@id": "01GEB6TJ176FMNPWDCFWGPH9GH",
 "contact_at": [
 "01GEB6TJ18W8FYDBPQRD2NED6E"
 ],
 "has_borrower_birth_date": {
 "has_value": "1991-01-02"
 },
 "has_first_name": {
 "has_value": "Dmytro"
 },
 "has_last_name": {
 "has_value": "Gorshenin"
 }
 }
 ]
 }
 }
```

<!--/source-->

##### Request

<!--source:api-specifications-->
application/json Copy
```
{
 "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK",
 "request_collection_id": "01F7S0N7CQ31DZQYVSVPN66GNK",
 "request_payload": {},
 "callback_url": "https://webhook.site/cc87117a-36ee-4b8b-b098-e9cf209821a2"
}
```

<!--/source-->

##### Response

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
2
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |
| `Content-Type` required | `string` header | `application/json` | <!--source:api-specifications-->Content type<!--/source--> |

##### Request body`application/json`

<!--source:api-specifications-->
6 fields
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID<!--/source--> |
| `request_collection_id` | `string` | <!--source:api-specifications-->Request collection ID<!--/source--> |
| `response_collection_id` | `string` | <!--source:api-specifications-->Response collection ID<!--/source--> |
| `callback_url`required | `string (uri)` | <!--source:api-specifications-->Destination URL on which final result of the flow execution will be sent<!--/source--> |
| `request_payload`required | `object` | <!--source:api-specifications-->Data that have to passed into the flow<!--/source--> |
| `debug_config` | `object` | <!--source:api-specifications-->Debug configuration.<!--/source--> |
| `dry_run` | `boolean` | <!--source:api-specifications-->Whether to run a flow in a debug response-mocked mode. Applicable with other debug options.<!--/source-->Example `false` |
| `render_ack_url` | `string (uri)` | <!--source:api-specifications-->If flow contains `CREATE_WIDGET` step, Connector will try to acknowledge user with POST request sent to `render_ack_url`. Applicable with other debug options.<!--/source-->Example `https://notifications.example.com/rendered-widgets-w-job` |
| `poll_with` | `object` | <!--source:api-specifications-->Whether to run a flow in a debug self-poll mode. Applicable with other debug options.<!--/source--> |
| `interval`required | `integer` | <!--source:api-specifications-->Polling interval in seconds.<!--/source-->Example `30` |

##### Response `200``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Loan successfully update.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `job_id` | `string` | <!--source:api-specifications-->Execution ID<!--/source--> |
| `job_status` | `string` | <!--source:api-specifications-->Execution status<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which url the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

`GET` `/vendors/encompass-loan/flows/update-loan/jobs/{job_id}`

<!--source:api-specifications-->

#### Retrieve Update Loan Status
<!--/source-->

`retrieveUpdateLoanStatus`

<!--source:api-specifications-->
Retrieve update loan status
<!--/source-->

<!--source:api-specifications-->
This endpoint allows getting status of the job.

<!--/source-->

##### Response

<!--source:api-specifications-->
200400
<!--/source-->

<!--source:api-specifications-->
application/json Copy Execution status successfully retrieved

```
{
 "status": "FAILED",
 "executed_events": [
 "GetCredentials",
 "Wait1",
 "Wait2"
 ],
 "last_event": "Wait2",
 "details": [
 {
 "event_id": 2,
 "event_type": "stateEnteredEventDetails",
 "event_name": "GetCredentials",
 "timestamp": "2021-06-10 23:25:27.661000+03:00",
 "previous_event_id": 0,
 "input_details": {}
 },
 {
 "event_id": 6,
 "event_type": "stateExitedEventDetails",
 "event_name": "GetCredentials",
 "timestamp": "2021-06-10 23:25:30.280000+03:00",
 "previous_event_id": 5
 },
 {
 "event_id": 7,
 "event_type": "stateEnteredEventDetails",
 "event_name": "Wait1",
 "timestamp": "2021-06-10 23:25:30.289000+03:00",
 "previous_event_id": 6,
 "input_details": {}
 },
 {
 "event_id": 8,
 "event_type": "stateExitedEventDetails",
 "event_name": "Wait1",
 "timestamp": "2021-06-10 23:25:40.289000+03:00",
 "previous_event_id": 7
 },
 {
 "event_id": 9,
 "event_type": "stateEnteredEventDetails",
 "event_name": "Wait2",
 "timestamp": "2021-06-10 23:25:40.296000+03:00",
 "previous_event_id": 8,
 "input_details": {}
 },
 {
 "event_id": 10,
 "event_type": "executionFailedEventDetails",
 "timestamp": "2021-06-10 23:25:40.296000+03:00",
 "previous_event_id": 0,
 "error": {
 "type": "Runtime",
 "cause": "An error occurred while executing the state 'Wait2' (entered at the event id #9). The SecondsPath parameter does not reference an input value: $.request_payload.sec"
 }
 }
 ],
 "input": {
 "callback_url": "https://rock.site/09876ercftvghnj3iy4738c-3crv/",
 "transaction_id": "01FG3YHN4FCJ4EYW6326ZAQW6Y",
 "response_collection_id": "01FG3YHR1TYXTAAZZHMTX50HQV",
 "request_collection_id": "01FG3YHQW2TY3A2GVKX5SXAB4D"
 },
 "output": {
 "response_payload": {
 "invoice_id": "in_18jwqyLlRB0eXbMtrUQ97YBw",
 "invoice_data": {
 "object": {
 "id": "cs_temp_use_ConnectorForANYVendor integration",
 "name": "customer",
 "amount": 100000
 }
 },
 "invoice_metadata": {
 "user_id": "9872b3ck2kmXYZ"
 }
 },
 "extraction_errors": {
 "lpa.xyz": "not-found"
 }
 }
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
2
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |
| `job_id` required | `string (uuid)` path | `7c668252-d2ba-job-id-896d-1f73236287d9` | <!--source:api-specifications-->Execution ID<!--/source--> |

##### Response `200``application/json`

<!--source:api-specifications-->
6 fields
<!--/source-->
<!--source:api-specifications-->
Execution status successfully retrieved
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `status` | `string` | <!--source:api-specifications-->Execution status<!--/source-->`ABORTED``FAILED``RUNNING``SUCCEEDED``TIMED_OUT` |
| `executed_events` | `string[]` | <!--source:api-specifications-->List of executed events<!--/source--> |
| `last_event` | `string` | <!--source:api-specifications-->Last executed event<!--/source--> |
| `details` | `object[]` | <!--source:api-specifications-->Executed events details<!--/source--> |
| `input` | `object` | <!--source:api-specifications-->Short data you used for invoking the flow.<!--/source--> |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID<!--/source--> |
| `request_collection_id`required | `string` | <!--source:api-specifications-->Request collection ID<!--/source--> |
| `response_collection_id`required | `string` | <!--source:api-specifications-->Response collection ID<!--/source--> |
| `callback_url`required | `string (uri)` | <!--source:api-specifications-->Destination URL on which final result of the flow execution was configured to be sent<!--/source--> |
| `output` | `object` | <!--source:api-specifications-->Short data of the output.<!--/source--> |
| `response_payload`required | `one of` | <!--source:api-specifications-->Response payload.<!--/source--> |
| `extraction_errors`required | `one of` | <!--source:api-specifications-->Extraction errors.<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which URL the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner, flow or execution not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

`POST` `/vendors/encompass-loan/flows/get-loan/jobs`

<!--source:api-specifications-->

#### Get loan
<!--/source-->

`getLoan`

<!--source:api-specifications-->
Get loan Get loan. Input collection must contain unique loan identifier. Request collection example:

```
{
 "metadata": {
 "version": 2,
 "validation": true
 },
 "data": {
 "loan_identifiers": [
 {
 "@type": "loan_identifier",
 "@id": "01GEB6TJ17H9V8F0VZCP80242X",
 "has_loan_identifier_value": {
 "has_value": "8540f696-9a51-4c03-8292-493e520fc67b"
 }
 }
 ]
 }
 }
```

<!--/source-->

##### Request

<!--source:api-specifications-->
application/json Copy
```
{
 "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK",
 "request_collection_id": "01F7S0N7CQ31DZQYVSVPN66GNK",
 "request_payload": {},
 "callback_url": "https://webhook.site/cc87117a-36ee-4b8b-b098-e9cf209821a2"
}
```

<!--/source-->

##### Response

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
2
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |
| `Content-Type` required | `string` header | `application/json` | <!--source:api-specifications-->Content type<!--/source--> |

##### Request body`application/json`

<!--source:api-specifications-->
6 fields
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID<!--/source--> |
| `request_collection_id` | `string` | <!--source:api-specifications-->Request collection ID<!--/source--> |
| `response_collection_id` | `string` | <!--source:api-specifications-->Response collection ID<!--/source--> |
| `callback_url`required | `string (uri)` | <!--source:api-specifications-->Destination URL on which final result of the flow execution will be sent<!--/source--> |
| `request_payload`required | `object` | <!--source:api-specifications-->Data that have to passed into the flow<!--/source--> |
| `debug_config` | `object` | <!--source:api-specifications-->Debug configuration.<!--/source--> |
| `dry_run` | `boolean` | <!--source:api-specifications-->Whether to run a flow in a debug response-mocked mode. Applicable with other debug options.<!--/source-->Example `false` |
| `render_ack_url` | `string (uri)` | <!--source:api-specifications-->If flow contains `CREATE_WIDGET` step, Connector will try to acknowledge user with POST request sent to `render_ack_url`. Applicable with other debug options.<!--/source-->Example `https://notifications.example.com/rendered-widgets-w-job` |
| `poll_with` | `object` | <!--source:api-specifications-->Whether to run a flow in a debug self-poll mode. Applicable with other debug options.<!--/source--> |
| `interval`required | `integer` | <!--source:api-specifications-->Polling interval in seconds.<!--/source-->Example `30` |

##### Response `200``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Loan response collection.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `job_id` | `string` | <!--source:api-specifications-->Execution ID<!--/source--> |
| `job_status` | `string` | <!--source:api-specifications-->Execution status<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which url the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

`GET` `/vendors/encompass-loan/flows/get-loan/jobs/{job_id}`

<!--source:api-specifications-->

#### Retrieve Get Loan Status
<!--/source-->

`retrieveGetLoanStatus`

<!--source:api-specifications-->
Retrieve get loan status
<!--/source-->

<!--source:api-specifications-->
This endpoint allows getting status of the job.

<!--/source-->

##### Response

<!--source:api-specifications-->
200400
<!--/source-->

<!--source:api-specifications-->
application/json Copy Execution status successfully retrieved

```
{
 "status": "FAILED",
 "executed_events": [
 "GetCredentials",
 "Wait1",
 "Wait2"
 ],
 "last_event": "Wait2",
 "details": [
 {
 "event_id": 2,
 "event_type": "stateEnteredEventDetails",
 "event_name": "GetCredentials",
 "timestamp": "2021-06-10 23:25:27.661000+03:00",
 "previous_event_id": 0,
 "input_details": {}
 },
 {
 "event_id": 6,
 "event_type": "stateExitedEventDetails",
 "event_name": "GetCredentials",
 "timestamp": "2021-06-10 23:25:30.280000+03:00",
 "previous_event_id": 5
 },
 {
 "event_id": 7,
 "event_type": "stateEnteredEventDetails",
 "event_name": "Wait1",
 "timestamp": "2021-06-10 23:25:30.289000+03:00",
 "previous_event_id": 6,
 "input_details": {}
 },
 {
 "event_id": 8,
 "event_type": "stateExitedEventDetails",
 "event_name": "Wait1",
 "timestamp": "2021-06-10 23:25:40.289000+03:00",
 "previous_event_id": 7
 },
 {
 "event_id": 9,
 "event_type": "stateEnteredEventDetails",
 "event_name": "Wait2",
 "timestamp": "2021-06-10 23:25:40.296000+03:00",
 "previous_event_id": 8,
 "input_details": {}
 },
 {
 "event_id": 10,
 "event_type": "executionFailedEventDetails",
 "timestamp": "2021-06-10 23:25:40.296000+03:00",
 "previous_event_id": 0,
 "error": {
 "type": "Runtime",
 "cause": "An error occurred while executing the state 'Wait2' (entered at the event id #9). The SecondsPath parameter does not reference an input value: $.request_payload.sec"
 }
 }
 ],
 "input": {
 "callback_url": "https://rock.site/09876ercftvghnj3iy4738c-3crv/",
 "transaction_id": "01FG3YHN4FCJ4EYW6326ZAQW6Y",
 "response_collection_id": "01FG3YHR1TYXTAAZZHMTX50HQV",
 "request_collection_id": "01FG3YHQW2TY3A2GVKX5SXAB4D"
 },
 "output": {
 "response_payload": {
 "invoice_id": "in_18jwqyLlRB0eXbMtrUQ97YBw",
 "invoice_data": {
 "object": {
 "id": "cs_temp_use_ConnectorForANYVendor integration",
 "name": "customer",
 "amount": 100000
 }
 },
 "invoice_metadata": {
 "user_id": "9872b3ck2kmXYZ"
 }
 },
 "extraction_errors": {
 "lpa.xyz": "not-found"
 }
 }
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
2
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |
| `job_id` required | `string (uuid)` path | `7c668252-d2ba-job-id-896d-1f73236287d9` | <!--source:api-specifications-->Execution ID<!--/source--> |

##### Response `200``application/json`

<!--source:api-specifications-->
6 fields
<!--/source-->
<!--source:api-specifications-->
Execution status successfully retrieved
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `status` | `string` | <!--source:api-specifications-->Execution status<!--/source-->`ABORTED``FAILED``RUNNING``SUCCEEDED``TIMED_OUT` |
| `executed_events` | `string[]` | <!--source:api-specifications-->List of executed events<!--/source--> |
| `last_event` | `string` | <!--source:api-specifications-->Last executed event<!--/source--> |
| `details` | `object[]` | <!--source:api-specifications-->Executed events details<!--/source--> |
| `input` | `object` | <!--source:api-specifications-->Short data you used for invoking the flow.<!--/source--> |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID<!--/source--> |
| `request_collection_id`required | `string` | <!--source:api-specifications-->Request collection ID<!--/source--> |
| `response_collection_id`required | `string` | <!--source:api-specifications-->Response collection ID<!--/source--> |
| `callback_url`required | `string (uri)` | <!--source:api-specifications-->Destination URL on which final result of the flow execution was configured to be sent<!--/source--> |
| `output` | `object` | <!--source:api-specifications-->Short data of the output.<!--/source--> |
| `response_payload`required | `one of` | <!--source:api-specifications-->Response payload.<!--/source--> |
| `extraction_errors`required | `one of` | <!--source:api-specifications-->Extraction errors.<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which URL the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner, flow or execution not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

`POST` `/vendors/encompass-loan/flows/update-loan-status/jobs`

<!--source:api-specifications-->

#### Update loan statuses
<!--/source-->

`updateLoanStatus`

<!--source:api-specifications-->
Update loan statuses Update the custom loan statuses. Statuses will be mapped to the predefined custom fields that have names like CUST01FV, CUST02FV etc. Request collection example:

```
{
 "metadata": {
 "version": 2,
 "validation": true,
 "client_status": "ELIGIBLE",
 "activity_status": "PENDING APPROVAL"
 },
 "data": {
 "loan_identifiers": [
 {
 "@id": "01GDZWKTYKX1WB5A2Y4SPXZSB9",
 "@type": "loan_identifier",
 "has_loan_identifier_value": {
 "has_value": "0ab69a33-38b5-4cb7-a846-815ee6463bca"
 }
 }
 ]
 }
 }
```

<!--/source-->

##### Request

<!--source:api-specifications-->
application/json Copy
```
{
 "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK",
 "request_collection_id": "01F7S0N7CQ31DZQYVSVPN66GNK",
 "request_payload": {},
 "callback_url": "https://webhook.site/cc87117a-36ee-4b8b-b098-e9cf209821a2"
}
```

<!--/source-->

##### Response

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
2
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |
| `Content-Type` required | `string` header | `application/json` | <!--source:api-specifications-->Content type<!--/source--> |

##### Request body`application/json`

<!--source:api-specifications-->
6 fields
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID<!--/source--> |
| `request_collection_id` | `string` | <!--source:api-specifications-->Request collection ID<!--/source--> |
| `response_collection_id` | `string` | <!--source:api-specifications-->Response collection ID<!--/source--> |
| `callback_url`required | `string (uri)` | <!--source:api-specifications-->Destination URL on which final result of the flow execution will be sent<!--/source--> |
| `request_payload`required | `object` | <!--source:api-specifications-->Data that have to passed into the flow<!--/source--> |
| `debug_config` | `object` | <!--source:api-specifications-->Debug configuration.<!--/source--> |
| `dry_run` | `boolean` | <!--source:api-specifications-->Whether to run a flow in a debug response-mocked mode. Applicable with other debug options.<!--/source-->Example `false` |
| `render_ack_url` | `string (uri)` | <!--source:api-specifications-->If flow contains `CREATE_WIDGET` step, Connector will try to acknowledge user with POST request sent to `render_ack_url`. Applicable with other debug options.<!--/source-->Example `https://notifications.example.com/rendered-widgets-w-job` |
| `poll_with` | `object` | <!--source:api-specifications-->Whether to run a flow in a debug self-poll mode. Applicable with other debug options.<!--/source--> |
| `interval`required | `integer` | <!--source:api-specifications-->Polling interval in seconds.<!--/source-->Example `30` |

##### Response `200``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Customer statuses successfully updated.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `job_id` | `string` | <!--source:api-specifications-->Execution ID<!--/source--> |
| `job_status` | `string` | <!--source:api-specifications-->Execution status<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which url the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

`GET` `/vendors/encompass-loan/flows/update-loan-status/jobs/{job_id}`

<!--source:api-specifications-->

#### Retrieve Update Loan Status Result
<!--/source-->

`retrieveUpdateLoanStatusResult`

<!--source:api-specifications-->
This endpoint allows getting status of the job.

<!--/source-->

##### Response

<!--source:api-specifications-->
200400
<!--/source-->

<!--source:api-specifications-->
application/json Copy Execution status successfully retrieved

```
{
 "status": "FAILED",
 "executed_events": [
 "GetCredentials",
 "Wait1",
 "Wait2"
 ],
 "last_event": "Wait2",
 "details": [
 {
 "event_id": 2,
 "event_type": "stateEnteredEventDetails",
 "event_name": "GetCredentials",
 "timestamp": "2021-06-10 23:25:27.661000+03:00",
 "previous_event_id": 0,
 "input_details": {}
 },
 {
 "event_id": 6,
 "event_type": "stateExitedEventDetails",
 "event_name": "GetCredentials",
 "timestamp": "2021-06-10 23:25:30.280000+03:00",
 "previous_event_id": 5
 },
 {
 "event_id": 7,
 "event_type": "stateEnteredEventDetails",
 "event_name": "Wait1",
 "timestamp": "2021-06-10 23:25:30.289000+03:00",
 "previous_event_id": 6,
 "input_details": {}
 },
 {
 "event_id": 8,
 "event_type": "stateExitedEventDetails",
 "event_name": "Wait1",
 "timestamp": "2021-06-10 23:25:40.289000+03:00",
 "previous_event_id": 7
 },
 {
 "event_id": 9,
 "event_type": "stateEnteredEventDetails",
 "event_name": "Wait2",
 "timestamp": "2021-06-10 23:25:40.296000+03:00",
 "previous_event_id": 8,
 "input_details": {}
 },
 {
 "event_id": 10,
 "event_type": "executionFailedEventDetails",
 "timestamp": "2021-06-10 23:25:40.296000+03:00",
 "previous_event_id": 0,
 "error": {
 "type": "Runtime",
 "cause": "An error occurred while executing the state 'Wait2' (entered at the event id #9). The SecondsPath parameter does not reference an input value: $.request_payload.sec"
 }
 }
 ],
 "input": {
 "callback_url": "https://rock.site/09876ercftvghnj3iy4738c-3crv/",
 "transaction_id": "01FG3YHN4FCJ4EYW6326ZAQW6Y",
 "response_collection_id": "01FG3YHR1TYXTAAZZHMTX50HQV",
 "request_collection_id": "01FG3YHQW2TY3A2GVKX5SXAB4D"
 },
 "output": {
 "response_payload": {
 "invoice_id": "in_18jwqyLlRB0eXbMtrUQ97YBw",
 "invoice_data": {
 "object": {
 "id": "cs_temp_use_ConnectorForANYVendor integration",
 "name": "customer",
 "amount": 100000
 }
 },
 "invoice_metadata": {
 "user_id": "9872b3ck2kmXYZ"
 }
 },
 "extraction_errors": {
 "lpa.xyz": "not-found"
 }
 }
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
2
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |
| `job_id` required | `string (uuid)` path | `7c668252-d2ba-job-id-896d-1f73236287d9` | <!--source:api-specifications-->Execution ID<!--/source--> |

##### Response `200``application/json`

<!--source:api-specifications-->
6 fields
<!--/source-->
<!--source:api-specifications-->
Execution status successfully retrieved
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `status` | `string` | <!--source:api-specifications-->Execution status<!--/source-->`ABORTED``FAILED``RUNNING``SUCCEEDED``TIMED_OUT` |
| `executed_events` | `string[]` | <!--source:api-specifications-->List of executed events<!--/source--> |
| `last_event` | `string` | <!--source:api-specifications-->Last executed event<!--/source--> |
| `details` | `object[]` | <!--source:api-specifications-->Executed events details<!--/source--> |
| `input` | `object` | <!--source:api-specifications-->Short data you used for invoking the flow.<!--/source--> |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID<!--/source--> |
| `request_collection_id`required | `string` | <!--source:api-specifications-->Request collection ID<!--/source--> |
| `response_collection_id`required | `string` | <!--source:api-specifications-->Response collection ID<!--/source--> |
| `callback_url`required | `string (uri)` | <!--source:api-specifications-->Destination URL on which final result of the flow execution was configured to be sent<!--/source--> |
| `output` | `object` | <!--source:api-specifications-->Short data of the output.<!--/source--> |
| `response_payload`required | `one of` | <!--source:api-specifications-->Response payload.<!--/source--> |
| `extraction_errors`required | `one of` | <!--source:api-specifications-->Extraction errors.<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which URL the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner, flow or execution not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

<!--source:api-specifications-->

### Documents
<!--/source-->

`POST` `/vendors/encompass-loan/flows/upload-attachment-document/jobs`

<!--source:api-specifications-->

#### Upload Attachment Document
<!--/source-->

`uploadAttachmentDocument`

<!--source:api-specifications-->
Upload Attachment Document uploads and attach a file to a specified loan, it gets an entity reference to the document that the attachment is to be assigned to.

Request collection example:

```
{
 "metadata": {
 "validation": True,
 "version": 2
 },
 "data": {
 "documents": [
 {
 "@id": "79762ab7-cc56-4279-a400-b627fdce3ec5",
 "@type": "bailee_letter",
 "has_staircase_blob_identifier": {
 "has_value": "01GE1BVKVPFXYVXPFMQ2N1RYH3"
 }
 }
 ],
 "loan_identifiers": [
 {
 "@id": "11231233223231",
 "@type": "loan_identifier",
 "has_loan_identifier_value": {
 "has_value": "0ab69a33-38b5-4cb7-a846-815ee6463bca"
 }
 }
 ],
 "loans": [
 {
 "@id": "456463545646123",
 "@type": "loan",
 "with_loan_identifier": [
 "11231233223231"
 ]
 }
 ]
 }
 }
```

<!--/source-->

##### Request

<!--source:api-specifications-->
application/json Copy
```
{
 "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK",
 "request_collection_id": "01F7S0N7CQ31DZQYVSVPN66GNK",
 "callback_url": "https://webhook.site/cc87117a-36ee-4b8b-b098-e9cf209821a2"
}
```

<!--/source-->

##### Response

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
1
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |

##### Request body`application/json`

<!--source:api-specifications-->
6 fields
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID<!--/source--> |
| `request_collection_id` | `string` | <!--source:api-specifications-->Request collection ID<!--/source--> |
| `response_collection_id` | `string` | <!--source:api-specifications-->Response collection ID<!--/source--> |
| `callback_url`required | `string (uri)` | <!--source:api-specifications-->Destination URL on which final result of the flow execution will be sent<!--/source--> |
| `request_payload`required | `object` | <!--source:api-specifications-->Data that have to passed into the flow<!--/source--> |
| `debug_config` | `object` | <!--source:api-specifications-->Debug configuration.<!--/source--> |
| `dry_run` | `boolean` | <!--source:api-specifications-->Whether to run a flow in a debug response-mocked mode. Applicable with other debug options.<!--/source-->Example `false` |
| `render_ack_url` | `string (uri)` | <!--source:api-specifications-->If flow contains `CREATE_WIDGET` step, Connector will try to acknowledge user with POST request sent to `render_ack_url`. Applicable with other debug options.<!--/source-->Example `https://notifications.example.com/rendered-widgets-w-job` |
| `poll_with` | `object` | <!--source:api-specifications-->Whether to run a flow in a debug self-poll mode. Applicable with other debug options.<!--/source--> |
| `interval`required | `integer` | <!--source:api-specifications-->Polling interval in seconds.<!--/source-->Example `30` |

##### Response `200``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Partner credentials successfully updated.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `job_id` | `string` | <!--source:api-specifications-->Execution ID<!--/source--> |
| `job_status` | `string` | <!--source:api-specifications-->Execution status<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which URL the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

`GET` `/vendors/encompass-loan/flows/upload-attachment-document/jobs/{job_id}`

<!--source:api-specifications-->

#### Retrieve Upload Attachment Document Status
<!--/source-->

`uploadAttachmentDocumentStatus`

<!--source:api-specifications-->
Retrieve Upload Attachment Document Execution status
<!--/source-->

<!--source:api-specifications-->
This endpoint allows getting status of the job.

<!--/source-->

##### Response

<!--source:api-specifications-->
200400
<!--/source-->

<!--source:api-specifications-->
application/json Copy Execution status successfully retrieved

```
{
 "status": "FAILED",
 "executed_events": [
 "GetCredentials",
 "Wait1",
 "Wait2"
 ],
 "last_event": "Wait2",
 "details": [
 {
 "event_id": 2,
 "event_type": "stateEnteredEventDetails",
 "event_name": "GetCredentials",
 "timestamp": "2021-06-10 23:25:27.661000+03:00",
 "previous_event_id": 0,
 "input_details": {}
 },
 {
 "event_id": 6,
 "event_type": "stateExitedEventDetails",
 "event_name": "GetCredentials",
 "timestamp": "2021-06-10 23:25:30.280000+03:00",
 "previous_event_id": 5
 },
 {
 "event_id": 7,
 "event_type": "stateEnteredEventDetails",
 "event_name": "Wait1",
 "timestamp": "2021-06-10 23:25:30.289000+03:00",
 "previous_event_id": 6,
 "input_details": {}
 },
 {
 "event_id": 8,
 "event_type": "stateExitedEventDetails",
 "event_name": "Wait1",
 "timestamp": "2021-06-10 23:25:40.289000+03:00",
 "previous_event_id": 7
 },
 {
 "event_id": 9,
 "event_type": "stateEnteredEventDetails",
 "event_name": "Wait2",
 "timestamp": "2021-06-10 23:25:40.296000+03:00",
 "previous_event_id": 8,
 "input_details": {}
 },
 {
 "event_id": 10,
 "event_type": "executionFailedEventDetails",
 "timestamp": "2021-06-10 23:25:40.296000+03:00",
 "previous_event_id": 0,
 "error": {
 "type": "Runtime",
 "cause": "An error occurred while executing the state 'Wait2' (entered at the event id #9). The SecondsPath parameter does not reference an input value: $.request_payload.sec"
 }
 }
 ],
 "input": {
 "callback_url": "https://rock.site/09876ercftvghnj3iy4738c-3crv/",
 "transaction_id": "01FG3YHN4FCJ4EYW6326ZAQW6Y",
 "response_collection_id": "01FG3YHR1TYXTAAZZHMTX50HQV",
 "request_collection_id": "01FG3YHQW2TY3A2GVKX5SXAB4D"
 },
 "output": {
 "response_payload": {
 "invoice_id": "in_18jwqyLlRB0eXbMtrUQ97YBw",
 "invoice_data": {
 "object": {
 "id": "cs_temp_use_ConnectorForANYVendor integration",
 "name": "customer",
 "amount": 100000
 }
 },
 "invoice_metadata": {
 "user_id": "9872b3ck2kmXYZ"
 }
 },
 "extraction_errors": {
 "lpa.xyz": "not-found"
 }
 }
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
2
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `job_id` required | `string (uuid)` path | `7c668252-d2ba-job-id-896d-1f73236287d9` | <!--source:api-specifications-->Execution ID<!--/source--> |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |

##### Response `200``application/json`

<!--source:api-specifications-->
6 fields
<!--/source-->
<!--source:api-specifications-->
Execution status successfully retrieved
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `status` | `string` | <!--source:api-specifications-->Execution status<!--/source-->`ABORTED``FAILED``RUNNING``SUCCEEDED``TIMED_OUT` |
| `executed_events` | `string[]` | <!--source:api-specifications-->List of executed events<!--/source--> |
| `last_event` | `string` | <!--source:api-specifications-->Last executed event<!--/source--> |
| `details` | `object[]` | <!--source:api-specifications-->Executed events details<!--/source--> |
| `input` | `object` | <!--source:api-specifications-->Short data you used for invoking the flow.<!--/source--> |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID<!--/source--> |
| `request_collection_id`required | `string` | <!--source:api-specifications-->Request collection ID<!--/source--> |
| `response_collection_id`required | `string` | <!--source:api-specifications-->Response collection ID<!--/source--> |
| `callback_url`required | `string (uri)` | <!--source:api-specifications-->Destination URL on which final result of the flow execution was configured to be sent<!--/source--> |
| `output` | `object` | <!--source:api-specifications-->Short data of the output.<!--/source--> |
| `response_payload`required | `one of` | <!--source:api-specifications-->Response payload.<!--/source--> |
| `extraction_errors`required | `one of` | <!--source:api-specifications-->Extraction errors.<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which URL the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner, flow or execution not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

<!--source:api-specifications-->

### Flows
<!--/source-->

`POST` `/job/jobs/EncompassLoanRegistration/executions`

<!--source:api-specifications-->

#### Register loan
<!--/source-->

`registerLoan`

<!--source:api-specifications-->
Register loan Start the job to register a loan and upload the funding obligation attachment.

<!--/source-->

##### Request

<!--source:api-specifications-->
application/json Copy
```
{
 "request_payload": {
 "loan": {
 "id": "01bdc36b-9ac3-43b3-a759-61966602d313",
 "loanNumber": "TEST220701690",
 "applications": [
 {
 "id": "6cb659a6-0396-4ebe-9de0-aef45fea61f8",
 "legacyId": "_borrower1",
 "vods": [
 {
 "id": "6a0eb0e8-146f-4361-b72e-92be27d96d60",
 "total": 10000,
 "foreignAddressIndicator": false,
 "items": [
 {
 "itemNumber": 1,
 "urla2020CashOrMarketValueAmount": 10000,
 "foreignAddressIndicator": false
 }
 ],
 "altId": "628cd92a-7a6c-4c56-aa65-2fbce994473d"
 }
 ],
 "assetsAvailableAmount": 10000,
 "borrower": {
 "id": "6cb659a6-0396-4ebe-9de0-aef45fea61f8",
 "legacyId": "_borrower1",
 "ageAtApplicationYearsCount": 63,
 "applicantType": "Borrower",
 "authorizedCreditReportDate": "2022-07-16",
 "bankruptcyIndicatorChapterSeven": false,
 "bankruptcyIndicatorChapterEleven": false,
 "bankruptcyIndicatorChapterTwelve": false,
 "bankruptcyIndicatorChapterThirteen": false,
 "birthDate": "1958-12-12",
 "borrowerType": "Individual",
 "topRatioPercent": 0,
 "bottomRatioPercent": 0,
 "totalGrossMonthlyIncomeAmount": 0,
 "currentEmploymentDoesNotApply": false,
 "emailAddressText": "test@email.com",
 "employment": [
 {
 "id": "544aa3de-dfd5-4e0e-a5b8-fc1c2e1a2936",
 "currentEmploymentIndicator": true,
 "employerName": "Amazon",
 "noLinkToDocTrackIndicator": true,
 "altId": "d5681c90-50fd-4f89-8fac-3ae88c589387"
 }
 ],
 "firstName": "John",
 "firstNameWithMiddleName": "John",
 "fullName": "John Doe",
 "fullNameWithSuffix": "John Doe",
 "fannieFirstName": "John",
 "hmdaAge": "63",
 "isBorrower": true,
 "jointAssetLiabilityReportingIndicator1": "NotJointly",
 "lastName": "Doe",
 "lastNameWithSuffix": "Doe",
 "maritalStatusType": "Unmarried",
 "mobilePhone": "123-123-1232",
 "residences": [
 {
 "id": "6ec38e29-4af4-4ca4-b684-e1651be88536",
 "residencyType": "Current",
 "addressCity": "New York",
 "addressPostalCode": "10003",
 "addressState": "NY",
 "addressStreetLine1": "65 4th Ave",
 "addressCounty": "US",
 "countryCode": "US",
 "noLinkToDocTrackIndicator": true,
 "urla2020StreetAddress": "65 4th Ave",
 "country": "US",
 "altId": "0ffc9698-4d43-4799-9868-eb994af2a392"
 },
 {
 "id": "7aa56b7e-b230-4c79-9692-c84c964ca4cc",
 "residencyType": "Current",
 "addressCity": "NEW YORK",
 "addressPostalCode": "10003",
 "addressState": "NY",
 "addressStreetLine1": "65 4TH AVE",
 "countryCode": "US",
 "noLinkToDocTrackIndicator": true,
 "urla2020StreetAddress": "65 4TH AVE",
 "country": "US",
 "altId": "c2d12538-f9b7-409a-940c-00be98863d98"
 },
 {
 "id": "b283fac6-1862-4090-b023-e5e3f9cc5828",
 "residencyType": "Current",
 "addressCity": "NEW YORK",
 "addressPostalCode": "10003",
 "addressState": "NY",
 "addressStreetLine1": "65 4TH AVE",
 "countryCode": "US",
 "noLinkToDocTrackIndicator": true,
 "urla2020StreetAddress": "65 4TH AVE",
 "country": "US",
 "altId": "be934ee7-3355-49a7-b1be-f0c59a888080"
 }
 ],
 "subtotalLiquidAssetsMinusGiftAmount": 10000,
 "taxIdentificationIdentifier": "999-00-0000"
 },
 "coborrower": {
 "id": "75661074-5d19-4021-9d21-5355f7844ea3",
 "legacyId": "_coborrower1",
 "applicantType": "CoBorrower",
 "bankruptcyIndicatorChapterSeven": false,
 "bankruptcyIndicatorChapterEleven": false,
 "bankruptcyIndicatorChapterTwelve": false,
 "bankruptcyIndicatorChapterThirteen": false,
 "borrowerType": "Individual",
 "isBorrower": false
 },
 "creditReportReferenceIdentifier": "DFNLK5",
 "netWorthAmount": 10000,
 "propertyUsageType": "PrimaryResidence",
 "tax4506": {
 "irs4506C": true
 },
 "totalAssetsAmount": 10000,
 "totalDeposit": 10000,
 "totalUrla2020AssetsAmount": 10000,
 "borrowerPairId": "_borrower1"
 }
 ],
 "purchasePriceAmount": 449900,
 "property": {
 "fhaSecondaryResidenceIndicator": false,
 "freCashOutAmount": 0,
 "loanPurposeType": "Purchase",
 "loanPurposeTypeUrla": "Purchase",
 "occupancyDisplayField": "Primary",
 "propertyUsageType": "PrimaryResidence",
 "state": "TX",
 "typeRecordingJurisdiction": "County"
 },
 "initialInterestRateUi": 5.5,
 "creditScoreToUse": "600",
 "down_payment_amount": 12000,
 "down_payment_amount_program": "Forgivable 5%",
 "amortization_term": 120,
 "lock_days": 15,
 "lock_status": "locked",
 "manual_underwriting_indicator": true
 },
 "pricing_collection_id": "01GFNQ74RB0ZF5ANN0V5FFKPKW",
 "pricing_transaction_id": "01GFKAD45J4C62STBV61ARHJPR",
 "ami_collection_id": "01GFNQPZ5M3FY3ETYM01D0S79Y",
 "ami_transaction_id": "01GFKAD45J4C62STBV61ARHJPR"
 }
}
```

<!--/source-->

##### Response

<!--source:api-specifications-->
200400
<!--/source-->

<!--source:api-specifications-->
application/json Copy Successfully returned status of the Product flow Invocation.

```
{
 "execution_id": "01GF0J2G6DK70M1905J7RDGMM2"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
2
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `invocation_id` required | `string (ulid)` path | `d7ccedb8-8889-4657-add4-bc1s4xs97637` | <!--source:api-specifications-->Product flow invocation identifier<!--/source--> |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |

##### Request body`application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `request_payload` | `object` | <!--source:api-specifications-->Request payload object<!--/source--> |
| `loan` | `object` | <!--source:api-specifications-->Loan object<!--/source--> |
| `id` | `string` | <!--source:api-specifications-->Loan ID<!--/source-->Example `d8571da2-c021-4134-a67d-833b2e25679d` |
| `loanNumber` | `string` | <!--source:api-specifications-->Encompass Loan Number<!--/source-->Example `TEST220701690` |
| `applications` | `string[]` | <!--source:api-specifications-->List of applications<!--/source--> |
| `purchasePriceAmount` | `number` | <!--source:api-specifications-->Encompass username<!--/source-->Example `175900` |
| `property` | `object` | <!--source:api-specifications-->Property description<!--/source--> |
| `initialInterestRateUi` | `number` | <!--source:api-specifications-->Interest rate<!--/source-->Example `5.5` |
| `creditScoreToUse` | `string` | <!--source:api-specifications-->Credit score<!--/source-->Example `600` |
| `down_payment_amount` | `string` | <!--source:api-specifications-->Credit score<!--/source-->Example `12000` |
| `down_payment_amount_program` | `string` | <!--source:api-specifications-->Downpayment program<!--/source-->Example `Forgivable 5%` |
| `amortization_term` | `number` | <!--source:api-specifications-->Amortization Term<!--/source-->Example `120` |
| `lock_days` | `number` | <!--source:api-specifications-->Lock Days<!--/source-->Example `15` |
| `manual_underwriting_indicator` | `boolean` | <!--source:api-specifications-->Manual underwriting indicator<!--/source-->Example `true` |
| `lock_status` | `string` | <!--source:api-specifications-->Credit score<!--/source-->Example `locked` |
| `pricing_transaction_id` | `string` | <!--source:api-specifications-->Daily pricing transaction ID<!--/source-->Example `01GF0J2G6DK70M1905J7RDGMM45` |
| `pricing_collection_id` | `string` | <!--source:api-specifications-->Daily pricing collection ID<!--/source-->Example `01GF0J2G6DK70M1905J7RDGMM46` |
| `ami_transaction_id` | `string` | <!--source:api-specifications-->Average median income transaction ID<!--/source-->Example `01GF0J2G6DK70M1905J7RDGMM47` |
| `ami_collection_id` | `string` | <!--source:api-specifications-->Average median income collection ID<!--/source-->Example `01GF0J2G6DK70M1905J7RDGMM48` |

##### Response `200``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Successfully returned status of the Product flow Invocation.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `execution_id` | `string` | <!--source:api-specifications-->string<!--/source-->Example `01GF0J2G6DK70M1905J7RDGMM2` |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which URL the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner, flow or execution not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

<!--source:api-specifications-->

### Setup
<!--/source-->

`POST` `/setup/credentials`

<!--source:api-specifications-->

#### Set Encompass DevConnect Credentials
<!--/source-->

`setEncompassCredentials`

<!--source:api-specifications-->
Set Informative Research Credentials
<!--/source-->

<!--source:api-specifications-->

#### How to obtain credentials

##### Encompass Client ID and Client secret:

1. If you don't have Dev Connect Account, please create one using Sign Up URL
1. After you Sign in with you account, you will see the instructions for getting API KEY
1. Use Get API Key URL to obtain client id and client secret. Encompass "super admin" credentials are required to view the API Key.

#### Important Note:

The username and password fields are for Encompass account related to the instance. Username should follow format: 'username@encompass::TEBEXXX'. Make sure username & password that used in credentials are authorized to get/update the loan.

<!--/source-->

##### Request

<!--source:api-specifications-->
application/json Copy
```
{
 "encompass_instance_id": "TEBEXXXXXXXX",
 "client_id": "",
 "client_secret": "",
 "username": "admin@encompass:TEBEXXXXXXXX",
 "password": "",
 "grant_type": "password"
}
```

<!--/source-->

##### Response

<!--source:api-specifications-->
200400403422500
<!--/source-->

<!--source:api-specifications-->
application/json Copy Setup API Triggered Successfully

```
{
 "message": "Credentials are saved and verified"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Request data failed validation

```
{
 "message": "{'data': ['Missing data for required field.']}"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Invalid key for service

```
{
 "message": "Please check the key you used to call this service",
 "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Request data failed validation

```
{
 "message": "{'data': ['Missing data for required field.']}"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy The product has encountered an internal server error

```
{
 "message": "The product has encountered an internal server error"
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
1
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Staircase Environment API Key<!--/source--> |

##### Request body`application/json`

<!--source:api-specifications-->
6 fields
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `encompass_instance_id`required | `string` | <!--source:api-specifications-->The Encompass instance ID<!--/source--> |
| `username`required | `string` | <!--source:api-specifications-->The username<!--/source--> |
| `password`required | `string` | <!--source:api-specifications-->The grant type must be "password" for resource owner password credentials<!--/source--> |
| `client_id`required | `string` | <!--source:api-specifications-->The unique identifier for the client application. Replace <client_id> with the API client ID portion of the API key available from your Encompass Super Administrator<!--/source--> |
| `client_secret`required | `string` | <!--source:api-specifications-->The secret for the client application. Replace <client_secret> with the API client secret portion of the API key available from your Encompass Super Administrator<!--/source--> |
| `grant_type`required | `string` | <!--source:api-specifications-->The Grant type<!--/source-->`password` |

##### Response `200``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Setup API Triggered Successfully
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Request data failed validation
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Invalid key for service
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | — |
| `url` | `string` | — |

##### Response `422``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Request data failed validation
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `500``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
The product has encountered an internal server error
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Error Message<!--/source--> |

##### Other responses

`404`

`GET` `/setup/credentials/schema`

<!--source:api-specifications-->

#### Retrieve Partner Credentials Schema
<!--/source-->

`getCredentials`

<!--source:api-specifications-->
Get Credentials Schema
<!--/source-->

<!--source:api-specifications-->
Get credentials schema for specific partner. You can use retrieved schema for updating the partner credentials.

<!--/source-->

##### Response

<!--source:api-specifications-->
400403422500
<!--/source-->

<!--source:api-specifications-->
application/json Copy Request data failed validation

```
{
 "message": "{'data': ['Missing data for required field.']}"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Invalid key for service

```
{
 "message": "Please check the key you used to call this service",
 "url": "https://staircase.stoplight.io/docs/api-reference/customer-account-manager-service.yml/paths/~1products~1refresh/post"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy Request data failed validation

```
{
 "message": "{'data': ['Missing data for required field.']}"
}
```

<!--/source-->

<!--source:api-specifications-->
application/json Copy The product has encountered an internal server error

```
{
 "message": "The product has encountered an internal server error"
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
1
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Staircase Environment API Key<!--/source--> |

##### Response `200``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Create Adapter API Triggered Successfully
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Request data failed validation
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Invalid key for service
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | — |
| `url` | `string` | — |

##### Response `422``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Request data failed validation
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Message<!--/source--> |

##### Response `500``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
The product has encountered an internal server error
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Error Message<!--/source--> |

##### Other responses

`404`

<!--source:api-specifications-->

### Set Credentials
<!--/source-->

`PUT` `/vendors/encompass-credit/credentials`

<!--source:api-specifications-->

#### Save Encompass Dev Connect Credentials
<!--/source-->

`createDevConnectCredentials`

<!--source:api-specifications-->
This endpoint allows setting up Partner "credentials" which are used only for authorization purposes.

Notice: This method overwrites existing "credentials". For partial update use PATCH method.

<!--/source-->

##### Request

<!--source:api-specifications-->
application/json Copy
```
{
 "encompass_instance_id": "TEBEXXXXXXXX",
 "client_id": "some_client_id",
 "client_secret": "<redacted>",
 "username": "admin@encompass:TEBEXXXXXXXX",
 "password": "XXXXX",
 "grant_type": "password"
}
```

<!--/source-->

##### Response

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
1
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which url the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

##### Other responses

`200`

`PUT` `/vendors/encompass/credentials`

<!--source:api-specifications-->

#### Save Encompass Dev Connect Credentials
<!--/source-->

`createDevConnectCredentials`

<!--source:api-specifications-->
Please follow steps in Encompass Setup Documentation

<!--/source-->

##### Request

<!--source:api-specifications-->
application/json Copy
```
{
 "encompass_instance_id": "TEBEXXXXXXXX",
 "client_id": "",
 "client_secret": "",
 "grant_type": "client_credentials",
 "scope": "lp"
}
```

<!--/source-->

##### Response

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
1
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which url the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

##### Other responses

`200`

<!--source:api-specifications-->

### Webhooks
<!--/source-->

`POST` `/vendors/encompass-loan/flows/create-webhook/jobs`

<!--source:api-specifications-->

#### Create webhook
<!--/source-->

`createWebhook`

<!--source:api-specifications-->
Create webhook Create loan change webhook. A webhook will be sent for each change of the specified loan attributes.

To create a new webhook need to use another unique name otherwise existing webhook will be updated. Request example:

```
{
 "transaction_id": "encompass-loan-monitor",
 "callback_url": "",
 "request_payload": {
 "endpoint": "",
 "attributes": [
 "/applications/*/borrower/homePhoneNumber",
 "/applications/*/borrower/firstName"
 ],
 "name": "EncompassLoanChangeSubscription!1"
 }
 }
```

<!--/source-->

##### Request

<!--source:api-specifications-->
application/json Copy
```
{
 "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK",
 "request_payload": {
 "endpoint": "https://webhook.site/b97c7c03-ffd3-463e-be76-e1794eac01f6",
 "attributes": [
 "https://webhook.site/b97c7c03-ffd3-463e-be76-e1794eac01f6"
 ]
 },
 "callback_url": "https://webhook.site/b97c7c03-ffd3-463e-be76-e1794eac01f6",
 "name": "EncompassLoanChangeSubscription!1"
}
```

<!--/source-->

##### Response

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
1
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |

##### Request body`application/json`

<!--source:api-specifications-->
3 fields
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID<!--/source--> |
| `callback_url`required | `string (uri)` | <!--source:api-specifications-->Destination URL on which final result of the flow execution will be sent<!--/source--> |
| `request_payload`required | `object` | <!--source:api-specifications-->Data that have to passed into the flow<!--/source--> |
| `name` | `string` | <!--source:api-specifications-->Webhook name<!--/source-->Example `EncompassLoanChangeSubscription!1` |
| `endpoint` | `string` | <!--source:api-specifications-->Webhook endpoint<!--/source-->Example `https://webhook.site/b97c7c03-ffd3-463e-be76-e1794eac01f6` |
| `attributes` | `string[]` | <!--source:api-specifications-->List of attributes<!--/source--> |

##### Response `200``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Webhook successfully created.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `job_id` | `string` | <!--source:api-specifications-->Execution ID<!--/source--> |
| `job_status` | `string` | <!--source:api-specifications-->Execution status<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which URL the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

`POST` `/vendors/encompass-loan/flows/delete-webhook/jobs`

<!--source:api-specifications-->

#### Delete webhook
<!--/source-->

`deleteWebhook`

<!--source:api-specifications-->
Delete webhook Delete specific webhook.

Request example:

```
{
 "transaction_id": "encompass-loan-monitor",
 "callback_url": "",
 "request_payload": {
 "id": "a55e8ca2-1169-45e1-a05e-5df0ec8096e3"
 }
 }
```

<!--/source-->

##### Request

<!--source:api-specifications-->
application/json Copy
```
{
 "transaction_id": "01F7S0N7CQ31DZQYVSVPN66GNK",
 "request_payload": {
 "id": "a55e8ca2-1169-45e1-a05e-5df0ec8096e3"
 },
 "callback_url": "https://webhook.site/b97c7c03-ffd3-463e-be76-e1794eac01f6"
}
```

<!--/source-->

##### Response

<!--source:api-specifications-->
application/json Copy Bad request

```
{
 "message": {
 "schema_type": [
 "Must be one of: create, update."
 ]
 }
}
```

<!--/source-->

##### Parameters

<!--source:api-specifications-->
2
<!--/source-->

| Parameter | Type | Example | Description |
| --- | --- | --- | --- |
| `x-api-key` required | `string` header | `xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx` | <!--source:api-specifications-->Environment API Key.<!--/source--> |
| `Content-Type` required | `string` header | `application/json` | <!--source:api-specifications-->Content type<!--/source--> |

##### Request body`application/json`

<!--source:api-specifications-->
3 fields
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `transaction_id`required | `string` | <!--source:api-specifications-->Transaction ID<!--/source--> |
| `callback_url`required | `string (uri)` | <!--source:api-specifications-->Destination URL on which final result of the flow execution will be sent<!--/source--> |
| `request_payload`required | `object` | <!--source:api-specifications-->Data that have to passed into the flow<!--/source--> |
| `id` | `string` | <!--source:api-specifications-->Webhook id<!--/source-->Example `a55e8ca2-1169-45e1-a05e-5df0ec8096e3` |

##### Response `200``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Webhook successfully deleted.
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `job_id` | `string` | <!--source:api-specifications-->Execution ID<!--/source--> |
| `job_status` | `string` | <!--source:api-specifications-->Execution status<!--/source--> |

##### Response `400``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Bad request
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `one of` | <!--source:api-specifications-->Either message or object with additional properties.<!--/source--> |

##### Response `403``application/json`

<!--source:api-specifications-->
2 fields
<!--/source-->
<!--source:api-specifications-->
Forbidden
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Request forbidden -- authorization will not help<!--/source--> |
| `url` | `string (url)` | <!--source:api-specifications-->Indicates at which url the error occurs<!--/source--> |

##### Response `404``application/json`

<!--source:api-specifications-->
1 fields
<!--/source-->
<!--source:api-specifications-->
Partner not found
<!--/source-->

| Field | Type | Description |
| --- | --- | --- |
| `message` | `string` | <!--source:api-specifications-->Nothing matches the given URI<!--/source--> |

## Errors

`400``403``404``413``422``429``500`

## Products it serves

- LOS
- LOS
- Connection

## Position in the ordering

- Credit configured per lender

## How this integration is built

- **connection configuration** — The wire protocol. One repository per vendor API call, not per vendor.

- **language configuration** — The field mapping between the vendor's vocabulary and the canonical model.

- **flow file** — The four-way translation: canonical request, vendor request, vendor response, canonical response.

- **waterfall priority** — One line naming where this vendor sits in the vertical's ordering.

- **status call** — Activating the vendor for a lender, optionally with the lender's own credentials.

## Evidence

This vendor is on the roster because each of the following resolves to a committed artifact.

- `AUS-integration-service`
- `adapter-accelerator-service`
- `appraisal-service`
- `asset-setup-service`
- `athlete-service`
- `athlete-tasks-services`
- `athlete-tasks-services-site-data`
- `athlete-tasks-temp-services`
- `avm-service`
- `borrower-money-assistant-service`
- `bot-coborrower-military-service-collector`
- `bot-military-service-collector`
- `bot-price-assistant`
- `cfpb-service`
- `chatmtg-ask-service`
- `cheapest-mortgage-analysis-service`
- `closing-fulfillment-service`
- `collateral-underwriting-lookup-service`
- `collateral-underwriting-router-service`
- `colleteral-service`
- `communication-services-data`
- `communication-services-pipeline`
- `company-organization-mock-services`
- `company-services`
- `company-services-mocks`
- `compilance-qc-service`
- `compliance-service`
- `content-service`
- `create_campaign_service`
- `credit-encompass-integration`
- `credit-gRate-ecs-integration-service`
- `credit-meridian-integration-service`
- `credit-pp-data product/data/flows/encompass-credit-report.json`
- `credit-pp-data product/data/flows/encompass-process-epc-transaction.json`
- `credit-pp-data product/data/flows/encompass-process-from-custom-input-form.json`
- `credit-pp-data product/data/flows/encompass-service-order.json`
- `credit-service`
- `data-processing-service`
- `demo-service`
- `demo-service-2`
- `dijkstra-service-template`
- `doc-41-service`
- `document-creation-service`
- `documentation-content-service`
- `dummy-service`
- `eclosing-service`
- `employment-setup-service`
- `encompass-aus-service`
- `encompass-dev-connect-data`
- `encompass-devconnect-service-data`
- `encompass-homegen-service-application`
- `encompass-integration-custom-forms`
- `encompass-language`
- `encompass-leadoff-service-application`
- `encompass-loan-conditions-data`
- `encompass-loan-dashboard-data`
- `encompass-loan-data`
- `encompass-loan-documents-data`
- `encompass-loan-language-data`
- `encompass-loan-management-data`
- `encompass-loan-notification-data`
- `encompass-manage-vols-api`
- `encompass-manage-vols-connection-configuration`
- `encompass-order-service-v1-connection-configuration`
- `encompass-registration-data`
- `encompass-stavvy-data`
- `encompass-update-loan-api`
- `encompass-update-loan-connection-configuration`
- `encompass-update-loan-field-values-api`
- `encompass-update-loan-field-values-connection-configuration`
- `encompass-webhook-management`
- `enotary-service`
- `esign-service`
- `faq-bot-service`
- `fees-integration-service`
- `fees-service`
- `fees-setup-service`
- `finance-service-mock`
- `finance-services-data`
- `funding-service`
- `hello-world-service`
- `homegen-temp-service`
- `homegen-update-price`
- `homgen-price-loan`
- `identity-service`
- `income-service`
- `income-setup-service`
- `inspection-service`
- `insurance-service`
- `insurance-setup-service`
- `language-automation-service`
- `leadoff-pdf-temp-service`
- `leads-new-service`
- `loan-application-service`
- `loan-officer-gpt-app-dev-torvalds`
- `loan-officer-gpt-app2`
- `loan_officer_gpt`
- `loanboarding-setup-service`
- `lookup_invite_service`
- `los-encompass-automatization-data`
- `los-encompass-input-adapter-data`
- `los-encompass-output-adapter-data`
- `los-encompass-process-automation`
- `los-encompass-service-application`
- `los-encompass-service-application-data`
- `los-meridian-service`
- `los-service`
- `los-service-application`
- `los-setup-service`
- `los-setup-service-data`
- `market-index-price-assistant`
- `marketing-bot-assistant-service`
- `meridian-setup-service`
- `mortgage-adapter-los-encompass-order-service-data`
- `mortgage-contract-price-eligibility-optimalblue-configuration`
- `mortgage-insurance-service`
- `mortgage-integration-encompass-epc-service-data`
- `mortgage-integration-encompass-loan-adapter-data`
- `mortgage-integration-encompass-loan-dailyai-crm-historic-data`
- `mortgage-integration-encompass-loan-management-data`
- `mortgage-integration-encompass-product`
- `mortgage-integration-encompass-setup-service`
- `mortgage-integration-encompass-webhook-service`
- `mortgage-verification-income-truv-setup-service`
- `mortgate-integration-encompass-loan-dailyai-crm-data`
- `new_lead_service`
- `new_lisitng_service`
- `other-investors-service`
- `pager_service`
- `partner-encompass-api_user_authentication-connection-configuration`
- `partner-encompass-dc-get-loan-connection-configuration`
- `partner-encompass-dc-token-connection-configuration`
- `partner-encompass-epc-token-connection-configuration`
- `partner-encompass-service-order-connection-configuration`
- `pos-service`
- `price-bot-api_calls`
- `price-bot-taskset`
- `price-data`
- `price-optimalblue-integration-service`
- `price_calculator_lib`
- `price_engine`
- `price_estimate_bot_UI`
- `price_util`
- `pricing-service`
- `product-prices`
- `property-taxes-service`
- `public-image-service`
- `qc-service`
- `rule-engine-service`
- `sales-service`
- `security-performance-service`
- `service-api-publisher`
- `service-lpa-product-endpoints`
- `service-mismo-dictionary`
- `service-mismo-lpa-translator`
- `service-mismo-to-neptune-csv`
- `service-pipeline-flows-api`
- `service-product`
- `service-sdk-generator`
- `service-swagger-validator`
- `service-template`
- `service-translate-json-mismo`
- `service-validator-api`
- `service-web-template`
- `simple-multi-stack-service`
- `sitemap-listings-update-service`
- `start-loan-application-choices`
- `stavvy-encompass-get-loan`
- `stavvy-encompass-get-loan-pp`
- `tax-service`
- `tax-setup-service`
- `textract-service`
- `title-insurance-service`
- `title-service`
- `update-leads-service`
- `wilqo-service`
- `x-service`
