HomeGuidesAPI ReferenceChangelogDiscussions
GuidesAPI ReferenceDiscussions

Conditional Events

Type

Possible entity types that generate Conditional Events include:

  • application
  • disclosure
  • document

Action

Conditional events may be associated with an action:

  • created
  • deleted
  • updated

Solution

Various Blend solutions may trigger Conditional Events, including:

  • AUTO
  • CONSUMER_MORTGAGE
  • CONSUMER_BANKING
  • INSURANCE
  • WHOLESALE_MORTGAGE

Object Format

{
  "id": UUID
  "firstEmittedAt": ISO8601 DateTime String
  "lastEmittedAt": ISO8601 DateTime String
  "attempt": Integer
  "status": String
  "data": {
    "id": UUID
    "type": String
    "action": String
    "solution": String
    "trigger": {
      "type": String
      "triggeredAt": ISO8601 DateTime String
      "metadata": Object // Optional
    },
    "fields": {
      "keyName": {
        "value": String
        "metadata": Object // Optional
        "links": LinkObject // Optional
      }
    }
  },
  "links": {
  	"parties": {
    	"href": "https://api.beta.blend.com/applications/:id/parties",
    	"meta": { // Optional
      	"count": 10 // Optional
    	}
  	}
  }
}

Example: Application Submitted

When a party completes a loan application and elects to "submit" that application, Blend generates a Conditional Event. The inclusion of the "trigger" attribute is the primary differentiator between data model driven and conditional events.

{
  "id": "81b05a0e-823c-46f3-8403-9823328d3126",
  "firstEmittedAt": "2019-01-16T16:47:40.991Z",
  "lastEmittedAt": "2019-01-16T16:47:40.991Z",
  "attempt": 1,
  "status": "EMITTED",
  "data": {
    "id": "23a12aaa-bde2-422e-aad7-32106819bc1d",
    "type": "application",
    "action": "updated",
    "solution": "CONSUMER_MORTGAGE",
    "trigger": {
      "type": "SUBMITTED",
      "triggeredAt": "2019-01-16T16:47:40.031Z"
    },
    "fields": {
      "solutionSubType": {
        "value": "LOAN"
      }
    }
  },
  "links": {
  	"parties": {
    	"href": "https://api.beta.blend.com/applications/23a12aaa-bde2-422e-aad7-32106819bc1d/parties"
  	}
  }
}